LayoutManager gathers all external events which would affect the layout of the windows and redirect the event to AppWindowManager.
The height of the windows would be affected by some global factor:
- The height of StatusBar.
- The existence of Software Home Button.
- The existence of Keyboard.
When the size state of one of them is changed, LayoutManager
would send system-resize
event.
Members
-
static fullscreenHeight
-
Gives the possible height for a fullscreen window.
-
static keyboardEnabled :Boolean
-
Record the keyboard is enabled now or not.
-
static usualHeight
-
Gives the possible height for a normal window.
Methods
-
static match(width, height, isFullScreen) → {Boolean}
-
Match the given size with current layout.
Parameters:
Name Type Description width Number The matched width
height Number The matched height
isFullScreen Boolean To match fullscreen case or not
Returns:
BooleanMatches current layout or not
Events
-
system-resize
-
Fired when layout needs to be adjusted.