List and Tree Events"

From Documentation
m (Created page with '{{ZKDevelopersGuidePageHeader}} == List and Tree Events == {| border="1" ! <center>Event Name</center> ! <center>Components</center> ! <center>Description</center> |- | onSel…')
 
m
Line 15: Line 15:
 
tree
 
tree
 
combobox
 
combobox
| Event: <tt>org.zkoss.zk.ui.event.SelectEvent</tt>
+
| Event: <javadoc>org.zkoss.zk.ui.event.SelectEvent</javadoc>
  
 
Denotes user has selected one or multiple child components. For a <tt>listbox</tt>, it is a set of <tt>listitems</tt>. For a tree, it is a set of <tt>treeitems</tt>. For a <tt>tabbox</tt>, it is a <tt>tab</tt>.
 
Denotes user has selected one or multiple child components. For a <tt>listbox</tt>, it is a set of <tt>listitems</tt>. For a tree, it is a set of <tt>treeitems</tt>. For a <tt>tabbox</tt>, it is a <tt>tab</tt>.
Line 30: Line 30:
 
menupopup
 
menupopup
 
window
 
window
| Event: <tt>org.zkoss.zk.ui.event.OpenEvent</tt>
+
| Event: <javadoc>org.zkoss.zk.ui.event.OpenEvent</javadoc>
  
 
Denotes the user has opened or closed a component. Note: unlike <tt>onClose</tt>, this event is only a notification. The client sends this event after opening or closing the component. It has a function named isOpen() allowing you to check whether it is open or closed.
 
Denotes the user has opened or closed a component. Note: unlike <tt>onClose</tt>, this event is only a notification. The client sends this event after opening or closing the component. It has a function named isOpen() allowing you to check whether it is open or closed.
Line 45: Line 45:
 
menupopup
 
menupopup
 
window
 
window
| Event: <tt>org.zkoss.zk.ui.event.OpenEvent</tt>
+
| Event: <javadoc>org.zkoss.zk.ui.event.OpenEvent</javadoc>
  
 
There is no onClose event. There is only an onOpen event, however you can determine the state by using the <tt>onOpen</tt> function to check whether it is open or closed.
 
There is no onClose event. There is only an onOpen event, however you can determine the state by using the <tt>onOpen</tt> function to check whether it is open or closed.

Revision as of 01:53, 15 July 2010


Stop.png This documentation is for an older version of ZK. For the latest one, please click here.


List and Tree Events

Event Name
Components
Description
onSelect listbox

tabbox tab tree combobox

Event: SelectEvent

Denotes user has selected one or multiple child components. For a listbox, it is a set of listitems. For a tree, it is a set of treeitems. For a tabbox, it is a tab.

Please note: onSelect is sent to both a tab and the tabbox. Therefore you can choose which component to add event listener to.

onOpen north

east west south groupbox treeitem combobox bandbox menupopup window

Event: OpenEvent

Denotes the user has opened or closed a component. Note: unlike onClose, this event is only a notification. The client sends this event after opening or closing the component. It has a function named isOpen() allowing you to check whether it is open or closed.

It is useful to implement load-on-demand by listening to the onOpen event, and creating components when the first time the component is opened.

onClose north

east west south groupbox treeitem combobox bandbox menupopup window

Event: OpenEvent

There is no onClose event. There is only an onOpen event, however you can determine the state by using the onOpen function to check whether it is open or closed.



Last Update : 2010/07/15

Copyright © Potix Corporation. This article is licensed under GNU Free Documentation License.