| org.zkoss.zk.ui.HtmlBasedComponent org.zkoss.zul.impl.XulElement
All known Subclasses: org.zkoss.zul.Menuseparator, org.zkoss.zul.Image, org.zkoss.zul.Box, org.zkoss.zul.Groupbox, org.zkoss.zul.Window, org.zkoss.zul.Grid, org.zkoss.zul.Treeitem, org.zkoss.zul.Treerow, org.zkoss.zul.Listitem, org.zkoss.zul.Treechildren, org.zkoss.zul.Tree, org.zkoss.zul.Tabs, org.zkoss.zul.Tabpanel, org.zkoss.zul.Foot, org.zkoss.zul.Menubar, org.zkoss.zul.Row, org.zkoss.zkex.zul.LayoutRegion, org.zkoss.zul.Include, org.zkoss.zul.Listfoot, org.zkoss.zul.Html, org.zkoss.zul.Listbox, org.zkoss.zul.Popup, org.zkoss.zul.Iframe, org.zkoss.zul.Auxhead, org.zkoss.zul.Audio, org.zkoss.zul.Progressmeter, org.zkoss.zul.Separator, org.zkoss.zul.Tabpanels, org.zkoss.zul.impl.HeadersElement, org.zkoss.zul.Label, org.zkoss.zul.Toolbar, org.zkoss.zul.Rows, org.zkoss.zul.Treefoot, org.zkoss.zul.Radiogroup, org.zkoss.zul.impl.LabelElement, org.zkoss.zul.impl.InputElement, org.zkoss.zul.Slider, org.zkoss.zul.Tabbox, org.zkoss.zul.Div, org.zkoss.zul.Paging, org.zkoss.zul.Calendar, org.zkoss.zul.Bandpopup, org.zkoss.zul.Splitter,
XulElement | abstract public class XulElement extends HtmlBasedComponent (Code) | | The fundamental class for XUL elements.
author: tomyeh |
Method Summary | |
public String | getAction() Returns the client-side action (CSA). | public String | getActionAttrs() Returns the HTML attributes representing the client-side action,
or "" if no client-side action is defined. | protected String | getAllOnClickAttrs(boolean ignoreOnClick) Returns the attributes for onClick, onRightClick and onDoubleClick
by checking whether the corresponding listeners are added,
or null if none is added. | public String | getContext() Returns the ID of the popup (
Popup ) that should appear
when the user right-clicks on the element (aka., context menu). | public String | getInnerAttrs() Generates the Client-Side-Action attributes to the interior tag. | public String | getOuterAttrs() | public String | getPopup() Returns the ID of the popup (
Popup ) that should appear
when the user clicks on the element. | public String | getTooltip() Returns the ID of the popup (
Popup ) that should be used
as a tooltip window when the mouse hovers over the element for a moment. | public void | setAction(String action) Sets the client-side action. | public void | setContext(String context) Sets the ID of the popup (
Popup ) that should appear
when the user right-clicks on the element (aka., context menu).
An onOpen event is sent to the context menu if it is going to
appear. | public void | setContext(Popup popup) Sets the UUID of the popup that should appear
when the user right-clicks on the element (aka., context menu). | public void | setPopup(String popup) Sets the ID of the popup (
Popup ) that should appear
when the user clicks on the element.
An onOpen event is sent to the popup menu if it is going to
appear. | public void | setPopup(Popup popup) Sets the UUID of the popup that should appear
when the user clicks on the element. | public void | setTooltip(String tooltip) Sets the ID of the popup (
Popup ) that should be used
as a tooltip window when the mouse hovers over the element for a moment.
An onOpen event is sent to the tooltip if it is going to
appear. | public void | setTooltip(Popup popup) Sets the UUID of the popup that should be used
as a tooltip window when the mouse hovers over the element for a moment. |
getAction | public String getAction()(Code) | | Returns the client-side action (CSA).
The format:
action1: javascript1; javascript2; action2: javascript3
You could specify any action as long as JavaScript supports,
such as onfocus, onblur, onmouseover and onmousout.
|
getActionAttrs | public String getActionAttrs()(Code) | | Returns the HTML attributes representing the client-side action,
or "" if no client-side action is defined.
since: 3.0.0 |
getAllOnClickAttrs | protected String getAllOnClickAttrs(boolean ignoreOnClick)(Code) | | Returns the attributes for onClick, onRightClick and onDoubleClick
by checking whether the corresponding listeners are added,
or null if none is added.
Parameters: ignoreOnClick - whether to ignore onClick |
getContext | public String getContext()(Code) | | Returns the ID of the popup (
Popup ) that should appear
when the user right-clicks on the element (aka., context menu).
Default: null (no context menu).
|
getInnerAttrs | public String getInnerAttrs()(Code) | | Generates the Client-Side-Action attributes to the interior tag.
Reason: onfocus is the main use.
|
getPopup | public String getPopup()(Code) | | Returns the ID of the popup (
Popup ) that should appear
when the user clicks on the element.
Default: null (no poppup).
|
getTooltip | public String getTooltip()(Code) | | Returns the ID of the popup (
Popup ) that should be used
as a tooltip window when the mouse hovers over the element for a moment.
The tooltip will automatically disappear when the mouse is moved.
Default: null (no tooltip).
|
setAction | public void setAction(String action)(Code) | | Sets the client-side action.
|
setContext | public void setContext(String context)(Code) | | Sets the ID of the popup (
Popup ) that should appear
when the user right-clicks on the element (aka., context menu).
An onOpen event is sent to the context menu if it is going to
appear. Therefore, developers can manipulate it dynamically
(perhaps based on OpenEvent.getReference) by listening to the onOpen
event.
Note: To simplify the use, it ignores the ID space when locating
the component at the client. In other words, it searches for the
first component with the specified ID, no matter it is in
the same ID space or not.
(since 3.0.2) If there are two components with the same ID (of course, in
different ID spaces), you can specify the UUID with the following
format:
uuid(comp_uuid)
Example:
<label context="some">
<label context="uuid(${some.uuid})"/>
Both reference a component whose ID is "some".
But, if there are several components with the same ID,
the first one can reference to any of them.
And, the second one reference to the component in the same ID space
(of the label component).
See Also: XulElement.setContext(Popup) |
setContext | public void setContext(Popup popup)(Code) | | Sets the UUID of the popup that should appear
when the user right-clicks on the element (aka., context menu).
Note: it actually invokes
setContext("uuid(" + popup.getUuid() + ")")
since: 3.0.2 See Also: XulElement.setContext(String) |
setPopup | public void setPopup(String popup)(Code) | | Sets the ID of the popup (
Popup ) that should appear
when the user clicks on the element.
An onOpen event is sent to the popup menu if it is going to
appear. Therefore, developers can manipulate it dynamically
(perhaps based on OpenEvent.getReference) by listening to the onOpen
event.
Note: To simplify the use, it ignores the ID space when locating
the component at the client. In other words, it searches for the
first component with the specified ID, no matter it is in
the same ID space or not.
(since 3.0.2) If there are two components with the same ID (of course, in
different ID spaces), you can specify the UUID with the following
format:
uuid(comp_uuid)
See Also: XulElement.setPopup(Popup) |
setPopup | public void setPopup(Popup popup)(Code) | | Sets the UUID of the popup that should appear
when the user clicks on the element.
Note: it actually invokes
setPopup("uuid(" + popup.getUuid() + ")")
since: 3.0.2 See Also: XulElement.setPopup(String) |
setTooltip | public void setTooltip(String tooltip)(Code) | | Sets the ID of the popup (
Popup ) that should be used
as a tooltip window when the mouse hovers over the element for a moment.
An onOpen event is sent to the tooltip if it is going to
appear. Therefore, developers can manipulate it dynamically
(perhaps based on OpenEvent.getReference) by listening to the onOpen
event.
Note: To simplify the use, it ignores the ID space when locating
the component at the client. In other words, it searches for the
first component with the specified ID, no matter it is in
the same ID space or not.
(since 3.0.2) If there are two components with the same ID (of course, in
different ID spaces), you can specify the UUID with the following
format:
uuid(comp_uuid)
See Also: XulElement.setTooltip(Popup) |
setTooltip | public void setTooltip(Popup popup)(Code) | | Sets the UUID of the popup that should be used
as a tooltip window when the mouse hovers over the element for a moment.
Note: it actually invokes
setTooltip("uuid(" + popup.getUuid() + ")")
since: 3.0.2 See Also: XulElement.setTooltip(String) |
|
|