public class Stepbar extends XulElement
Only support browsers that support Flex. (IE11, Edge, Chrome, Firefox, Safari)
Default getZclass()
: z-stepbar.
HtmlBasedComponent.ExtraCtrl
AbstractComponent.Children
_zclass
APPLICATION_SCOPE, COMPONENT_SCOPE, DESKTOP_SCOPE, PAGE_SCOPE, REQUEST_SCOPE, SESSION_SCOPE, SPACE_SCOPE
AFTER_CHILD_ADDED, AFTER_CHILD_REMOVED, AFTER_PAGE_ATTACHED, AFTER_PAGE_DETACHED, CE_BUSY_IGNORE, CE_DUPLICATE_IGNORE, CE_IMPORTANT, CE_NON_DEFERRABLE, CE_REPEAT_IGNORE
Constructor and Description |
---|
Stepbar() |
Modifier and Type | Method and Description |
---|---|
boolean |
back()
Activate previous step if possible.
|
void |
beforeChildAdded(Component child,
Component insertBefore)
Default: does nothing.
|
int |
getActiveIndex()
Return the index of the active step.
|
Step |
getActiveStep()
Return the active step.
|
StepModel<?> |
getModel()
Returns the step model associated with this stepbar, or null if this stepbar is not associated with any step model.
|
StepRenderer |
getStepRenderer() |
java.util.List<Step> |
getSteps()
Returns the steps in this stepbar.
|
java.lang.String |
getZclass()
Returns the ZK Cascading Style class(es) for this component.
|
boolean |
insertBefore(Component newChild,
Component refChild)
Inserts a child before the reference child.
|
boolean |
isLinear()
Returns whether the steps in this stepbar are displayed by order.
|
boolean |
isWrappedLabels()
Returns whether the labels in children steps is wrapped.
|
boolean |
next()
Activate next step if possible.
|
void |
onInitRender() |
void |
onPageAttached(Page newpage,
Page oldpage)
Default: handles special event listeners.
|
void |
onPageDetached(Page page)
Default: handles special event listeners.
|
boolean |
removeChild(Component child)
Removes a child.
|
protected void |
renderProperties(ContentRenderer renderer)
Renders the content of this component, excluding the enclosing
tags and children.
|
void |
service(AuRequest request,
boolean everError)
Processes an AU request.
|
void |
setActiveIndex(int activeIndex)
Sets the index of the active step.
|
void |
setActiveStep(Step step)
Sets the active step.
|
void |
setLinear(boolean linear)
Sets whether the steps in this stepbar are displayed by order.
|
void |
setModel(StepModel<?> model)
Sets the step model associated with this stepbar.
|
void |
setStepRenderer(StepRenderer stepRenderer) |
void |
setWrappedLabels(boolean wrappedLabels)
Sets whether the labels in children steps is wrapped.
|
clone, getContext, getCtrlKeys, getPopup, getPropertyAccess, getTooltip, setContext, setContext, setContextAttributes, setCtrlKeys, setPopup, setPopup, setPopupAttributes, setTooltip, setTooltip, setTooltipAttributes
addSclass, evalCSSFlex, focus, getAction, getDraggable, getDroppable, getExtraCtrl, getHeight, getHflex, getLeft, getRenderdefer, getSclass, getStyle, getTabindex, getTabindexInteger, getTooltiptext, getTop, getVflex, getWidth, getZindex, getZIndex, removeSclass, removeSclass, setAction, setClass, setDraggable, setDroppable, setFocus, setHeight, setHeight0, setHeightDirectly, setHflex, setHflex0, setHflexDirectly, setLeft, setLeftDirectly, setRenderdefer, setSclass, setStyle, setTabindex, setTabindex, setTooltiptext, setTop, setTopDirectly, setVflex, setVflex0, setVflexDirectly, setWidth, setWidth0, setWidthDirectly, setZclass, setZindex, setZIndex, setZIndexDirectly
addAnnotation, addAnnotation, addCallback, addClientEvent, addEventHandler, addEventListener, addEventListener, addForward, addForward, addForward, addForward, addMoved, addRedrawCallback, addScopeListener, addShadowRoot, addShadowRootBefore, addSharedEventHandlerMap, appendChild, applyProperties, beforeChildRemoved, beforeParentChanged, detach, didActivate, didActivate, didDeserialize, didDeserialize, disableBindingAnnotation, disableClientUpdate, enableBindingAnnotation, getAnnotatedProperties, getAnnotatedPropertiesBy, getAnnotation, getAnnotation, getAnnotations, getAnnotations, getAnnotations, getAttribute, getAttribute, getAttribute, getAttributeOrFellow, getAttributes, getAttributes, getAuService, getAutag, getCallback, getChildren, getClientAttribute, getClientDataAttribute, getClientEvents, getDefaultMold, getDefinition, getDesktop, getEventHandler, getEventHandlerNames, getEventListenerMap, getEventListeners, getFellow, getFellow, getFellowIfAny, getFellowIfAny, getFellows, getFirstChild, getId, getLastChild, getListenerIterator, getMold, getNextSibling, getPage, getParent, getPreviousSibling, getRedrawCallback, getRoot, getShadowFellowIfAny, getShadowRoots, getShadowVariable, getShadowVariable, getShadowVariable0, getSpaceOwner, getSpecialRendererOutput, getStubonly, getSubBindingAnnotationCount, getTemplate, getTemplateNames, getUuid, getWidgetAttribute, getWidgetAttributeNames, getWidgetClass, getWidgetListener, getWidgetListenerNames, getWidgetOverride, getWidgetOverrideNames, hasAttribute, hasAttribute, hasAttribute, hasAttributeOrFellow, hasBindingAnnotation, hasFellow, hasFellow, hasSubBindingAnnotation, invalidate, invalidatePartial, isChildable, isInitialized, isInvalidated, isListenerAvailable, isVisible, onChildAdded, onChildRemoved, onWrongValue, query, queryAll, redraw, redrawChildren, removeAttribute, removeAttribute, removeAttribute, removeCallback, removeEventListener, removeForward, removeForward, removeRedrawCallback, removeScopeListener, removeShadowRoot, render, render, render, replace, response, response, response, service, sessionDidActivate, sessionWillPassivate, setAttribute, setAttribute, setAttribute, setAuService, setAutag, setClientAttribute, setClientDataAttribute, setDefinition, setDefinition, setId, setMold, setPage, setPageBefore, setParent, setStubonly, setStubonly, setSubBindingAnnotationCount, setTemplate, setVisible, setVisibleDirectly, setWidgetAttribute, setWidgetClass, setWidgetListener, setWidgetOverride, smartUpdate, smartUpdate, smartUpdate, smartUpdate, smartUpdate, smartUpdate, smartUpdate, smartUpdate, smartUpdate, smartUpdateWidgetListener, smartUpdateWidgetOverride, toString, updateByClient, updateSubBindingAnnotationCount, willPassivate, willPassivate, willSerialize, willSerialize
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
invalidatePartial
public boolean isWrappedLabels()
Default: false.
public void setWrappedLabels(boolean wrappedLabels)
wrappedLabels
- the labels in children steps is wrapped.public boolean isLinear()
Default: true.
public void setLinear(boolean linear)
linear
- whether the steps in this stepbar are displayed by order.public int getActiveIndex()
Default: 0.
public void setActiveIndex(int activeIndex)
activeIndex
- the index of the active step.public Step getActiveStep()
Default: first step.
public void setActiveStep(Step step)
step
- the active step.public StepRenderer getStepRenderer()
public void setStepRenderer(StepRenderer stepRenderer)
public StepModel<?> getModel()
Default: null.
public void setModel(StepModel<?> model)
model
- the stepbar model to associate, or null to dis-associate any previous model.UiException
- if failed to initialize with the modelpublic void onInitRender()
public void onPageAttached(Page newpage, Page oldpage)
AbstractComponent
onPageAttached
in interface ComponentCtrl
onPageAttached
in class AbstractComponent
newpage
- the new page (never null).oldpage
- the previous page, if any, or null if it didn't
belong to any page.ComponentCtrl.onPageAttached(org.zkoss.zk.ui.Page, org.zkoss.zk.ui.Page)
public void onPageDetached(Page page)
AbstractComponent
onPageDetached
in interface ComponentCtrl
onPageDetached
in class AbstractComponent
page
- the previous page (never null)ComponentCtrl.onPageDetached(org.zkoss.zk.ui.Page)
public boolean next()
public boolean back()
public java.util.List<Step> getSteps()
It is the same as AbstractComponent.getChildren()
.
public void beforeChildAdded(Component child, Component insertBefore)
AbstractComponent
beforeChildAdded
in interface ComponentCtrl
beforeChildAdded
in class AbstractComponent
child
- the child to be added (never null).insertBefore
- another child component that the new child
will be inserted before it. If null, the new child will be the
last child.ComponentCtrl.beforeChildAdded(org.zkoss.zk.ui.Component, org.zkoss.zk.ui.Component)
public boolean insertBefore(Component newChild, Component refChild)
Component
You could use Component.setParent(org.zkoss.zk.ui.Component)
or Component.appendChild(org.zkoss.zk.ui.Component)
instead of this method, unless
you want to control where to put the child.
Note: Component.setParent(org.zkoss.zk.ui.Component)
always calls back Component.insertBefore(org.zkoss.zk.ui.Component, org.zkoss.zk.ui.Component)
and/or Component.removeChild(org.zkoss.zk.ui.Component)
,
while Component.insertBefore(org.zkoss.zk.ui.Component, org.zkoss.zk.ui.Component)
and Component.removeChild(org.zkoss.zk.ui.Component)
always calls back Component.setParent(org.zkoss.zk.ui.Component)
,
if the parent is changed. Thus, you don't need to override
both Component.insertBefore(org.zkoss.zk.ui.Component, org.zkoss.zk.ui.Component)
and Component.setParent(org.zkoss.zk.ui.Component)
, if you want
to customize the behavior.
If you would like to monitor if a component is attached or detached
from a page, you could register a desktop listener implementing
UiLifeCycle
.
insertBefore
in interface Component
insertBefore
in class AbstractComponent
newChild
- the new child to be inserted.refChild
- the child before which you want the new child
being inserted. If null, the new child is append to the end.public boolean removeChild(Component child)
Component
Component.detach()
) and it will be removed
if it is no longer used.
You could use Component.setParent(org.zkoss.zk.ui.Component)
with null instead of this method.
Note: Component.setParent(org.zkoss.zk.ui.Component)
always calls back Component.insertBefore(org.zkoss.zk.ui.Component, org.zkoss.zk.ui.Component)
and/or Component.removeChild(org.zkoss.zk.ui.Component)
,
while Component.insertBefore(org.zkoss.zk.ui.Component, org.zkoss.zk.ui.Component)
and Component.removeChild(org.zkoss.zk.ui.Component)
always calls back Component.setParent(org.zkoss.zk.ui.Component)
,
if the parent is changed. Thus, you don't need to override
both Component.insertBefore(org.zkoss.zk.ui.Component, org.zkoss.zk.ui.Component)
and Component.setParent(org.zkoss.zk.ui.Component)
, if you want
to customize the behavior.
If you would like to monitor if a component is attached or detached
from a page, you could register a desktop listener implementing
UiLifeCycle
.
removeChild
in interface Component
removeChild
in class AbstractComponent
protected void renderProperties(ContentRenderer renderer) throws java.io.IOException
HtmlBasedComponent
renderProperties
in class XulElement
java.io.IOException
public void service(AuRequest request, boolean everError)
HtmlBasedComponent
Default: it handles onClick, onDoubleClick, onRightClick onMove, onSize, onZIndex.
service
in interface ComponentCtrl
service
in class HtmlBasedComponent
everError
- whether any error ever occurred before
processing this request.AbstractComponent.setAuService(org.zkoss.zk.au.AuService)
public java.lang.String getZclass()
HtmlBasedComponent
AbstractComponent.getMold()
).
Default: null (the default value depends on element).
HtmlBasedComponent.setZclass(java.lang.String)
) will completely replace the default style
of a component. In other words, the default style of a component
is associated with the default value of HtmlBasedComponent.getZclass()
.
Once it is changed, the default style won't be applied at all.
If you want to perform small adjustments, use HtmlBasedComponent.setSclass(java.lang.String)
instead.
getZclass
in class HtmlBasedComponent
HtmlBasedComponent.getSclass()
Copyright © 2005-2021 Potix Corporation. All Rights Reserved.