Package 

Class LayoutShadowNode

  • All Implemented Interfaces:
    com.facebook.react.uimanager.ReactShadowNode

    
    public class LayoutShadowNode
    extends ReactShadowNodeImpl
                        

    Supply setters for base view layout properties such as width, height, flex properties, borders, etc.

    Checking for isVirtual everywhere is a hack to get around the fact that some virtual nodes still have layout properties set on them in JS: for example, a component that returns a may or may not be embedded in a parent text. There are better solutions that should probably be explored, namely using the VirtualText class in JS and setting the correct set of validAttributes

    • Method Summary

      Modifier and Type Method Description
      void setWidth(Dynamic width)
      void setMinWidth(Dynamic minWidth)
      void setCollapsable(boolean collapsable)
      void setMaxWidth(Dynamic maxWidth)
      void setHeight(Dynamic height)
      void setMinHeight(Dynamic minHeight)
      void setMaxHeight(Dynamic maxHeight)
      void setFlex(float flex)
      void setFlexGrow(float flexGrow)
      void setFlexShrink(float flexShrink)
      void setFlexBasis(Dynamic flexBasis)
      void setAspectRatio(float aspectRatio)
      void setFlexDirection(@Nullable() String flexDirection)
      void setFlexWrap(@Nullable() String flexWrap)
      void setAlignSelf(@Nullable() String alignSelf)
      void setAlignItems(@Nullable() String alignItems)
      void setAlignContent(@Nullable() String alignContent)
      void setJustifyContent(@Nullable() String justifyContent)
      void setOverflow(@Nullable() String overflow)
      void setDisplay(@Nullable() String display)
      void setMargins(int index, Dynamic margin)
      void setPaddings(int index, Dynamic padding)
      void setBorderWidths(int index, float borderWidth)
      void setPositionValues(int index, Dynamic position)
      void setPosition(@Nullable() String position)
      void setShouldNotifyOnLayout(boolean shouldNotifyOnLayout)
      void setShouldNotifyPointerEnter(boolean value)
      void setShouldNotifyPointerLeave(boolean value)
      void setShouldNotifyPointerMove(boolean value)
      • Methods inherited from class com.facebook.react.uimanager.ReactShadowNodeImpl

        addChildAt, addNativeChildAt, calculateLayout, calculateLayout, calculateLayoutOnChildren, dirty, dispatchUpdates, dispose, getChildAt, getChildCount, getFlex, getHeightMeasureSpec, getHierarchyInfo, getLayoutDirection, getLayoutHeight, getLayoutParent, getLayoutWidth, getLayoutX, getLayoutY, getNativeChildCount, getNativeKind, getNativeOffsetForChild, getNativeParent, getPadding, getParent, getReactTag, getRootTag, getScreenHeight, getScreenWidth, getScreenX, getScreenY, getStyleHeight, getStylePadding, getStyleWidth, getThemedContext, getTotalNativeChildren, getViewClass, getWidthMeasureSpec, hasNewLayout, hasUnseenUpdates, hasUpdates, hoistNativeChildren, indexOf, indexOfNativeChild, isDescendantOf, isDirty, isLayoutOnly, isMeasureDefined, isVirtual, isVirtualAnchor, isYogaLeafNode, markLayoutSeen, markUpdateSeen, markUpdated, onAfterUpdateTransaction, onBeforeLayout, onCollectExtraUpdates, removeAllNativeChildren, removeAndDisposeAllChildren, removeChildAt, removeNativeChildAt, setAlignContent, setAlignItems, setAlignSelf, setBaselineFunction, setBorder, setDefaultPadding, setDisplay, setFlexBasis, setFlexBasisAuto, setFlexBasisPercent, setFlexDirection, setFlexWrap, setIsLayoutOnly, setJustifyContent, setLayoutDirection, setLayoutParent, setLocalData, setMargin, setMarginAuto, setMarginPercent, setMeasureFunction, setMeasureSpecs, setOverflow, setPadding, setPaddingPercent, setPosition, setPositionPercent, setPositionType, setReactTag, setRootTag, setStyleAspectRatio, setStyleHeight, setStyleHeightAuto, setStyleHeightPercent, setStyleMaxHeight, setStyleMaxHeightPercent, setStyleMaxWidth, setStyleMaxWidthPercent, setStyleMinHeight, setStyleMinHeightPercent, setStyleMinWidth, setStyleMinWidthPercent, setStyleWidth, setStyleWidthAuto, setStyleWidthPercent, setThemedContext, setViewClassName, shouldNotifyOnLayout, toString, updateProperties
      • Methods inherited from class com.facebook.react.uimanager.ReactShadowNode

        addChildAt, addNativeChildAt, dispatchUpdates, getChildAt, getLayoutParent, getNativeOffsetForChild, getNativeParent, getParent, indexOf, indexOfNativeChild, isDescendantOf, removeChildAt, removeNativeChildAt, setLayoutParent
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait