MCPcopy Create free account
hub / github.com/codenameone/CodenameOne / laidOut

Method laidOut

CodenameOne/src/com/codename1/ui/Component.java:7929–7953  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

7927 /// This is a callback method to inform the Component when it's been laidout
7928 /// on the parent Container
7929 protected void laidOut() {
7930 if (!isCellRenderer()) {
7931 CodenameOneImplementation ci = Display.impl;
7932 if (ci.isEditingText()) {
7933 return;
7934 }
7935 int ivk = getInvisibleAreaUnderVKB();
7936
7937 if (isScrollableY() && getScrollY() > 0 && getScrollY() + getHeight() >
7938 getScrollDimension().getHeight() + ivk) {
7939 setScrollY(getScrollDimension().getHeight() - getHeight() + ivk);
7940 }
7941 if (isScrollableX() && getScrollX() > 0 && getScrollX() + getWidth() >
7942 getScrollDimension().getWidth()) {
7943 setScrollX(getScrollDimension().getWidth() - getWidth());
7944 }
7945 if (!isScrollableY() && getScrollY() > 0) {
7946 setScrollY(0);
7947 }
7948 if (!isScrollableX() && getScrollX() > 0) {
7949 setScrollX(0);
7950 }
7951 updateNativeOverlay();
7952 }
7953 }
7954
7955 /// Invoked to indicate that the component initialization is being reversed
7956 /// since the component was detached from the container hierarchy. This allows

Callers 1

doLayoutMethod · 0.95

Calls 15

isCellRendererMethod · 0.95
isEditingTextMethod · 0.95
isScrollableYMethod · 0.95
getScrollYMethod · 0.95
getHeightMethod · 0.95
getScrollDimensionMethod · 0.95
setScrollYMethod · 0.95
isScrollableXMethod · 0.95
getScrollXMethod · 0.95
getWidthMethod · 0.95
setScrollXMethod · 0.95

Tested by

no test coverage detected