Class ZmOverview
Extends
DwtComposite.
Creates an overview. An overview is a DwtComposite that holds tree views.
Defined in: ZmOverview.js.
Class Summary
Constructor Attributes |
Constructor Name and Description |
|
|
Method Summary
Method Attributes |
Method Name and Description |
|
Clears the tree views.
|
|
Returns the first selected item within this overview.
|
|
Searches the tree views for the tree item whose data object has the given ID and type.
|
|
Gets the parent element for the given tree id.
|
|
Gets the tree view.
|
|
Gets the tree views.
|
|
Given a tree item, de-selects all items in the overview's
other tree views, enforcing single selection within the overview.
|
|
Displays the given list of tree views in this overview.
|
|
Selects the item with the given ID within the given tree in this overview.
|
|
Sets the given tree view.
|
- Methods borrowed from class DwtComposite:
- addChild, cleanupSeparators, dispose, getChild, getChildren, getNumChildren, getTabGroupMember, removeChild, removeChildren
- Methods borrowed from class DwtControl:
- addClassName, addControlListener, addDisposeListener, addListener, appendElement, blur, clearContent, clearHandler, condClassName, delClassName, focus, getBounds, getClassName, getContent, getCursor, getData, getDragBox, getDragSource, getDropTarget, getEnabled, getFocusElement, getH, getHtmlElement, getHTMLElId, getInsetBounds, getInsets, getLocation, getMargins, getOpacity, getOuterSize, getPosition, getScrollContainer, getScrollStyle, getSize, getTooltipBase, getToolTipContent, getVisibility, getVisible, getW, getX, getXW, getY, getYH, getZIndex, hasFocus, isAlertShown, isDisposed, isInitialized, isListenerRegistered, notifyListeners, preventContextMenu, preventSelection, removeAllListeners, removeControlListener, removeDisposeListener, removeListener, reparent, reparentHtmlElement, replaceElement, setBounds, setClassName, setContent, setCursor, setData, setDisplay, setDisplayState, setDragBox, setDragSource, setDropTarget, setEnabled, setEventPropagation, setFocusElement, setHandler, setHtmlElementId, setLocation, setOpacity, setPosition, setScrollStyle, setSize, setToolTipContent, setVisibility, setVisible, setZIndex, showAlert, zShow
Class Detail
ZmOverview(params, controller)
Author: Conrad Damon.
- Parameters:
-
{Hash} params
- a hash of parameters
-
{String} params.id
- the id for the HTML element
-
{String} params.overviewId
- the overview id
-
{String} params.containerId
- the overview container id (multi-account)
-
{Array} params.treeIds
- an array of organizer types that may be displayed in this overview
-
{ZmZimbraAccount} params.account
- the account this overview belongs to
-
{DwtControl} params.parent
- the containing widget
-
{String} params.overviewClass
- the class name for overview DIV
-
{constant} params.posStyle
- the positioning style for overview DIV
-
{constant} params.scroll
- the scrolling style for overview DIV
-
{Boolean} params.selectionSupported
true left-click selection is supported
-
{Boolean} params.actionSupported
true if right-click action menus are supported
-
{Boolean} params.dndSupported
true if drag-and-drop is supported
-
{String} params.headerClass
- the class name for header item
-
{Boolean} params.showUnread
- if
true , unread counts will be shown
-
{Boolean} params.showNewButtons
- if
true , tree headers may have buttons for creating new organizers
-
{constant} params.treeStyle
- the default display style for tree views
-
{Boolean} params.isCheckedByDefault
- the default state for "checked" display style
-
{Boolean} params.noTooltips
- if
true , do not show toolt ips for tree items
-
{Boolean} params.skipImplicit
- if
true , do not save implicit prefs of expanded/collapsed node status for this overview (see ZmDialog.prototype._setOverview)
-
{Boolean} params.dynamicWidth
- if
true , the width is dynamic, i.e. the width is auto instead of fixed. Used for ZmDolderChooser so far.
-
{ZmOverviewController} controller
- the overview controller
Method Detail
clear()
Clears the tree views.
{Object}
getSelected(typeOnly)
Returns the first selected item within this overview.
- Parameters:
-
{Boolean} typeOnly
- if
true , return the type only
- Returns:
- {Object} the item (or type if
typeOnly ) or null if not found
{Object}
getTreeItemById(id, type)
Searches the tree views for the tree item whose data object has the given ID and type.
- Parameters:
-
{int} id
- the id to look for
-
{constant} type
- the item must also have this type
- Returns:
- {Object} the item or
null if not found
{Object}
getTreeParent(treeId)
Gets the parent element for the given tree id.
- Parameters:
-
{String} treeId
- the tree id
- Returns:
- {Object} the tree parent element
Gets the tree view.
- Parameters:
-
{String} treeId
- the tree id
- Returns:
- {Object} the tree view
{Array}
getTreeViews()
Gets the tree views.
- Returns:
- {Array} an array of tree ids
itemSelected(treeItem)
Given a tree item, de-selects all items in the overview's
other tree views, enforcing single selection within the overview.
Passing a null argument will clear selection in all tree views.
- Parameters:
-
{DwtTreeItem} treeItem
- the tree item
set(treeIds, omit)
Displays the given list of tree views in this overview.
- Parameters:
-
{Array} treeIds
- an array of organizer ids
-
{Hash} omit
- the hash of organizer ids to ignore
setSelected(id, type)
Selects the item with the given ID within the given tree in this overview.
- Parameters:
-
{String} id
- the item id
-
{constant} type
- the tree type
setTreeView(treeId, omit)
Sets the given tree view. Its tree controller is responsible for using the appropriate
data tree to populate the tree view. The tree controller will be lazily created if
necessary. The tree view is cleared before it is set. The tree view inherits options
from this overview.
- Parameters:
-
{String} treeId
- the organizer ID
-
{Hash} omit
- a hash of organizer ids to ignore
|