org.zkoss.zul.api
Interface Popup

All Superinterfaces:
java.lang.Cloneable, Component, HtmlBasedComponent, Scope, java.io.Serializable, XulElement
All Known Subinterfaces:
Menupopup
All Known Implementing Classes:
Menupopup, Popup

public interface Popup
extends XulElement

A container that is displayed as a popup. The popup window does not have any special frame. Popups can be displayed when an element is clicked by assigning the id of the popup to either the XulElement.setPopup(java.lang.String), XulElement.setContext(java.lang.String) or XulElement.setTooltip(java.lang.String) attribute of the element.

Default HtmlBasedComponent.getZclass(): z-popup.(since 3.5.0)

Since:
3.5.2
Author:
tomyeh

Field Summary
 
Fields inherited from interface org.zkoss.zk.ui.Component
APPLICATION_SCOPE, COMPONENT_SCOPE, DESKTOP_SCOPE, PAGE_SCOPE, REQUEST_SCOPE, SESSION_SCOPE, SPACE_SCOPE
 
Method Summary
 void close()
          Closes this popup at the client.
 void open(Component ref)
          Opens this popup right below the specified component at the cleint.
 void open(Component ref, java.lang.String position)
          Opens this popup right below the specified component at the client.
 void open(int x, int y)
          Opens this popup to the specified location at the client.
 void open(java.lang.String x, java.lang.String y)
          Opens this popup to the specified location at the client.
 
Methods inherited from interface org.zkoss.zul.impl.api.XulElement
getAction, getContext, getCtrlKeys, getPopup, getTooltip, setAction, setContext, setContext, setCtrlKeys, setPopup, setPopup, setTooltip, setTooltip
 
Methods inherited from interface org.zkoss.zk.ui.api.HtmlBasedComponent
focus, getHeight, getLeft, getSclass, getStyle, getTooltiptext, getTop, getWidth, getZclass, getZindex, getZIndex, setDraggable, setDroppable, setFocus, setHeight, setLeft, setSclass, setStyle, setTooltiptext, setTop, setWidth, setZclass, setZindex, setZIndex
 
Methods inherited from interface org.zkoss.zk.ui.Component
addEventListener, addForward, addForward, addForward, addForward, appendChild, applyProperties, clone, containsVariable, detach, getAttribute, getAttribute, getAttributeOrFellow, getAttributes, getAttributes, getAuService, getChildren, getDefinition, getDesktop, getFellow, getFellow, getFellowIfAny, getFellowIfAny, getFellows, getFirstChild, getId, getLastChild, getListenerIterator, getMold, getNamespace, getNextSibling, getPage, getParent, getPreviousSibling, getRoot, getSpaceOwner, getUuid, getVariable, getWidgetClass, getWidgetListener, getWidgetListenerNames, getWidgetOverride, getWidgetOverrideNames, hasAttribute, hasAttribute, hasAttributeOrFellow, hasFellow, hasFellow, insertBefore, invalidate, isInvalidated, isListenerAvailable, isVisible, removeAttribute, removeAttribute, removeChild, removeEventListener, removeForward, removeForward, setAttribute, setAttribute, setAuService, setId, setMold, setPage, setPageBefore, setParent, setVariable, setVisible, setWidgetListener, setWidgetOverride, unsetVariable
 
Methods inherited from interface org.zkoss.zk.ui.ext.Scope
addScopeListener, getAttribute, hasAttribute, removeAttribute, removeScopeListener, setAttribute
 

Method Detail

open

void open(java.lang.String x,
          java.lang.String y)
Opens this popup to the specified location at the client.

In most cases, the popup is shown automatically when specified in the tooltip, popup and context properties ( XulElement.setTooltip(java.lang.String), XulElement.setPopup(java.lang.String), and XulElement.setContext(java.lang.String)). However, if you want to show it manually, you can invoke this method directly.

Parameters:
x - the X coordinate
y - the Y coordinate

open

void open(int x,
          int y)
Opens this popup to the specified location at the client.

In most cases, the popup is shown automatically when specified in the tooltip, popup and context properties ( XulElement.setTooltip(java.lang.String), XulElement.setPopup(java.lang.String), and XulElement.setContext(java.lang.String)). However, if you want to show it manually, you can invoke this method directly.

Parameters:
x - the X coordinate
y - the Y coordinate

open

void open(Component ref)
Opens this popup right below the specified component at the cleint.

In most cases, the popup is shown automatically when specified in the tooltip, popup and context properties ( XulElement.setTooltip(java.lang.String), XulElement.setPopup(java.lang.String), and XulElement.setContext(java.lang.String)). However, if you want to show it manually, you can invoke this method directly.

Parameters:
ref - the reference component to position the popup. It cannot be

open

void open(Component ref,
          java.lang.String position)
Opens this popup right below the specified component at the client.

In most cases, the popup is shown automatically when specified in the tooltip, popup and context properties (XulElement.setTooltip(java.lang.String), XulElement.setPopup(java.lang.String), and XulElement.setContext(java.lang.String)). However, if you want to show it manually, you can invoke this method directly.

Possible values for the position attribute are:

Parameters:
ref - the reference component to position the popup. It cannot be null.
position - the descriptions above are for a locale where the UI is displayed left to right and top to bottom. In this case, before is the top, after is the bottom, start is the left and end is the right. For right to left locales, start is the right and end is the left.
Since:
3.6.1

close

void close()
Closes this popup at the client.

In most cases, the popup is closed automatically when the user clicks outside of the popup.



Copyright © 2005-2009 Potix Corporation. All Rights Reserved. SourceForge.net Logo