gridx.modules.HLayout
Object » _Module » gridx.modules.HLayout
dojo.require("gridx.modules.HLayout");
Defined in gridx/modules/HLayout.js
When a user creates a grid with a given width, it means the width of the whole grid, which includes grid body, row header, and virtical scrollerbar (and maybe more in the future). So the width of the grid body must be calculated out so as to layout the grid properly. This module calculates grid body width by collecting width from all the registered grid UI parts. It is assumed that the width of these UI parts will not change when grid is resized.
Method Summary
- _layout()
- getAPIPath()
- load(args, startup)
- reLayout() Re-layout the grid horizontally. This means calculated the width of all registered grid UI components except the grid body. Then update the grid body width. Usually there's no need for users to call this method. It'll be automatically called when calling grid.resize().
- register(ready, refNode, isTail) Register a 'refNode' so this module can calculate its width when it is 'ready'
Event Summary
- onUpdateWidth() Fired when the body width is updated.
Methods
Overrides _Module
Re-layout the grid horizontally. This means calculated the width of all registered
grid UI components except the grid body. Then update the grid body width.
Usually there's no need for users to call this method. It'll be automatically called
when calling grid.resize().
Overrides _Module
Register a 'refNode' so this module can calculate its width when it is 'ready'
Parameter | Type | Description |
---|---|---|
ready | dojo.Deferred|null | A deferred object indicating when the DOM node is ready for width calculation. If omitted, it means the refNode can be calculated at any time. |
refNode | DOMNode | The DOM node that represents a UI part in grid. |
isTail | Boolean | Optional. If the 'refNode' appears after(LTR: right, RTL: left) the grid body, set this to true. |