The <contextmenu> represents a context (right-click) menu.
Example 17. lz.contextmenu example
<canvas height="60">
<view width="240" height="40" bgcolor="#aeaeae">
<contextmenu>
<contextmenuitem caption="menu item"/>
</contextmenu>
<text align="center">Right click for context menu</text>
</view>
</canvas>
| Name (CSS property) | Type (tag) | Type (js) | Default | Category |
|---|---|---|---|---|
delegate
|
expression | lz.handler | read/write | |
| Sets the delegate which will be called when a menu item is selected. An onselect event is also sent. | ||||
classroot, cloneManager, data, datapath, defaultplacement, id, ignoreplacement, immediateparent, inited, initstage, name, nodeLevel, options, parent, placement, styleclass, subnodes, transition
Methods
| addItem() |
|---|
| clearItems() |
|---|
| filterItems() |
|---|
| Parameter Name | Type | Description |
|---|---|---|
| target | lz.view | The view over which the context menu is being requested, null if no view applies. |
| Returns | Type | Description |
|---|---|---|
| [lz.contextmenuitem] | The items that should be displayed in the context menu |
| getItems() |
|---|
| hideBuiltInItems() |
|---|
| makeMenuItem() |
|---|
| Parameter Name | Type | Description |
|---|---|---|
| title | String | menu item name |
| delegate | lz.handler | delegate to execute when item is selected |
| showBuiltInItems() |
|---|
animate, applyConstraintMethod, applyData, childOf, completeInstantiation, construct, createChildren, dataBindAttribute, destroy, determinePlacement, getOption, getUID, init, lookupSourceLocator, releaseConstraint, releaseConstraintMethod, searchImmediateSubnodes, searchSubnodes, setOption, setSelected, updateData
Copyright © 2002-2010 Laszlo Systems, Inc. All Rights Reserved. Unauthorized use, duplication or distribution is strictly prohibited. This is the proprietary information of Laszlo Systems, Inc. Use is subject to license terms.