Dashboard > Fluid > ... > Layout Handler - v0.3 > ModuleLayoutHandler - v0.3
ModuleLayoutHandler - v0.3
Added by Anastasia Cheetham, last edited by Erin Yu on Sep 24, 2008  (view change)
Labels: 
(None)


This documentation refers to the v0.3 released version of the Module Layout Handler code.

The ModuleLayoutHandler is a Layout Handler - v0.3 used by the Layout Reorderer. It is designed to assist the Reorderer in working with arbitrary content modules, for example portlets in a portal environment.

Constructor

new fluid.ModuleLayoutHandler(layout, targetPerms[, options]);

Parameters

layout

A set of key/value pairs that describe the structural layout of the modules, as follows:
   id: the string identifier of the container of the modules
   columns: an array of key/value pairs describing the columns of the module layout, as follows:
      id: the string identifier of the column element
      children: an array of the string identifiers of the modules in the given column.

Still need help?

Join the fluid-talk mailing list and ask your questions there.

A layout object may look like this:

{
    id:"t2",
    columns:[
        { id:"c1", children:["portletA","portletB","portletC","portletD"]},
        { id:"c2", children:["portletE","portletF"]   },
        { id:"c3", children:["portletG","portletH","portletI"]}
    ]
}

The ModuleLayoutHandler (unlike the ListLayoutHandler - v0.3 and GridLayoutHandler - v0.3) works exclusively with the layou and targetPerms object, and does not query the actual DOM structure. For detailed information about the structure of the layout object, see Layout Customizer - Layout and Permissions - v0.3

targetPerms

A two-dimensional array of binary flags describing the movement permissions of the modules.

For detailed information about the structure of the targetPerms object, see Layout Customizer - Layout and Permissions - v0.3

options (optional)

An optional set of key/value pairs that configure the Layout Handler:

Name Description
orderChangedCallback A function to be called each time the order of items has changed, to communicate the new order to the server. (see Order-changed Callback - v0.3)
willShowKBDropWarning A function to be called each time the drop warning is shown. If nothing is provided, the drop warning will be displayed superimposed on the module being moved.

Site running on a free Atlassian Confluence Open Source Project License granted to The FLUID Project. Evaluate Confluence today.
Powered by Atlassian Confluence, the Enterprise Wiki. (Version: 2.5 Build:#805 Apr 26, 2007) - Bug/feature request - Contact Administrators