Package snap.view

Class BoxViewProxy<T extends View>

All Implemented Interfaces:
Cloneable
Direct Known Subclasses:
ScaleBoxProxy

public class BoxViewProxy<T extends View> extends ParentViewProxy<T>
A ViewProxy that can layout content in the manner of BoxView for any View.
  • Constructor Details

    • BoxViewProxy

      public BoxViewProxy(View aParent)
      Constructor for given parent view.
    • BoxViewProxy

      public BoxViewProxy(View aParent, View aChild, boolean isFillWidth, boolean isFillHeight)
      Constructor for given parent view and FillWidth, FillHeight params.
  • Method Details

    • getPrefWidthImpl

      protected double getPrefWidthImpl(double aH)
      Returns preferred width of layout.
      Specified by:
      getPrefWidthImpl in class ParentViewProxy<T extends View>
    • getPrefHeightImpl

      protected double getPrefHeightImpl(double aW)
      Returns preferred height of layout.
      Specified by:
      getPrefHeightImpl in class ParentViewProxy<T extends View>
    • layoutProxy

      public void layoutProxy()
      Performs Box layout for given parent, child and fill width/height.
      Specified by:
      layoutProxy in class ParentViewProxy<T extends View>