Class UIContainer
- All Implemented Interfaces:
EventListener,IFocusComp,IMessageBox,IComponent,ICustomDataProvider,IGProp<GProp<?>[]>,IPropCnr,IUIComp,IUIContainer,IUIContextMenuOwner,IUIFocusComp,IVSComponentListener,IVSComponentState,IVSFieldListener,IVSGenericComponentListener,Cloneable
- Direct Known Subclasses:
AbstractContentUIContainer,EUIContainer,MList,MUIHeading,MUITabBar,UIAccordion,UICalendarList,UIMap,UIMenu,UIMenuBar,UIPanelBase,UIPanelPartCnr,UISwapContainer,UITabContainer,UITable,UITitlePane
- Author:
- Christopher Mindus
Nested Class Summary
Nested classes/interfaces inherited from interface com.iizix.gyro.IMessageBox
IMessageBox.IconNested classes/interfaces inherited from interface com.iizix.prop.vs.IVSComponentState
IVSComponentState.StateField Summary
FieldsModifier and TypeFieldDescriptionstatic final Class<?>[]Accepted children components array: UIComp class.static final StringThe property name for VS connection for state and focus.static final StringThe property name for empty container warning issuing, if property is not present or true, the warning will be shown.Fields inherited from class com.iizix.prop.ui.UIComp
EMPTY, REMOTE_FOCUS_EVENT, styles, vsFieldFields inherited from class com.iizix.prop.PropCnr
EMPTY_CLASSES, EMPTY_CNRS, EXTENDS_FRAMEWORK_ERROR_ID, nameTableFields inherited from class com.iizix.prop.GProp
GPDEBUG, PROP_ATTR_STRING_EDITOR_PROP, PROP_ATTR_STRING_ERRORED_NAME, PROP_ATTR_STRING_EXTENDS, PROP_ATTR_STRING_EXTENDS_FINAL, PROP_ATTR_STRING_EXTENDS_PRIVATE, PROP_ATTR_STRING_NULLABLE, PROP_ATTR_STRING_PRIVATE, PROP_ATTR_STRING_PRIVATE_CHANGE_EVENT, PROP_ATTR_STRING_READ_ONLY, PROP_USER_1, PROP_USER_2Fields inherited from interface com.iizix.prop.IGProp
EQC_ERROR_IGNORE_ALL, EQC_ERROR_IGNORE_REFERENCES, EQC_IGNORE_ARRAY, EQC_IGNORE_VOLATILE_OR_EDITOR, EQC_PRIVATE, EQC_SAVE_FILE, EXT_CONTAINER_EXTENDS, EXT_CONTAINER_EXTENDS_VALID, EXT_EXTENDED, EXT_FINAL, EXT_OVERRIDES, EXT_OVERRIDES_FINAL_ERR, EXT_PRIVATEFields inherited from interface com.iizix.gyro.IMessageBox
ICON_ERROR, ICON_INFORMATION, ICON_MAP, ICON_NONE, ICON_QUESTION, ICON_WARNINGFields inherited from interface com.iizix.prop.ui.IUIComp
ERROR, INFORMATION, NONE, REMOTE_FOCUS_EVENT, WARNINGConstructor Summary
ConstructorsConstructorDescriptionCreates an UI container with the specified name with a null value.UIContainer(Atom propertyAtom) Creates an UI container with the specified name with a null value.UIContainer(Atom propertyAtom, GProp<?>[] properties) Creates an UI container with the specified name and properties.Method Summary
Modifier and TypeMethodDescriptionprotected voidAdds the predefined properties for this container.protected voidAdds the predefined containers for identifications, fields and actions.Returns if this container can accept focus itself or for one of its children components.clone()Creates a clone out of this property.Creates the components for the Editor.booleanReturns whether the container should have children in a normal conditions, i.e.Returns the size of the component in pixels.intGets the UI component count.UIComp[]Gets the UI components of the container.Gets the container associated with this layout manager and the UI container.intGets the device type: -1=mobile, 0=both, 1=desktop.Gets the first VS component encountered for state and focus of this container or in the parent tree up to the panel level.<COMP extends UIComp>
COMPgetFirstUIComponent(String name, Class<COMP> uiClass) Gets the first UI component of the specified name and UI class.<COMP extends UIComp>
COMPgetFirstUIComponentNull(String name, Class<COMP> uiClass) Gets the first UI component of the specified name and UI class.voidAdds the predefined containers for identifications, fields and actions.UIComp[]getRadioSelectionComponents(String groupName) Gets the components being part of the selection group specified.getSelectedRadioComponent(String groupName) Gets the currently selected radio component in the group.<COMP extends UIComp>
COMPgetUIComponent(@UIRef String uiPath, Class<COMP> uiClass) Gets a UI component with relative reference from this container.<COMP extends UIComp>
COMPgetUIComponentNull(@UIRef String uiPath, Class<COMP> uiClass) Gets a UI component with relative reference from this container.final VSComponentGets the VS component for state and focus of this container.booleanReturns if the container has implicit component horizontal fill.booleanReturns if the container has implicit component vertical fill.protected final voidinvokeOnUICreateTree(UIPanelBase panel) Invokes the onUICreate method for the component if a panel is present.booleanReturns whether the container should have children in a normal conditions, i.e.booleanReturns if the component can show the context menu in mobile mode.booleanDoes this component requires a height.booleanDoes this component requires a width?voidonBroken(VSComponentReference reference, VSComponent component) Called when the property reference has been broken, i.e.voidonComponentSelectedInParent(boolean on) Called by the parent container to inform that this component has been selected in its container.voidonResolved(VSComponentReference reference, VSComponent component) Called when the property reference has been resolved.protected voidonSelectionChanged(boolean on) Called when the container is selected as the current container in an index-based single-selection container such as accordion, swap and tab containers.protected voidonSelectionChanged(GEvent event) Method called when the selection of the component changed due to a property change (value changed, property added or removed).voidonStateChanged(VSComponent component, IVSComponentState.State state, boolean on) Called when the VS component changes state.protected final voidCalled when a property container has been virtualized because it was added into another property container that was virtualized, and this container was not.protected voidonVSComponentSelectionChanged(boolean on) Called when the VS component has its selected state changed.voidResets the component ID, typically when copied or saved in order to add make copies of the (some) component data.booleansetRadioSelectionComponent(IUIRadioComponent radioComponent, boolean isSelected) Sets the selection to the specified radio component.setUIContainerFocus(UIComp requestor, boolean doAnimate) Sets the focus to the UI container and all its parents.protected voidUpdates the reference to the UIComps instance named Atom.COMPONENTS, used when cloning and for the panel part container (or any time the UIComps instance has been changed).booleanverify(PropVerification verification) Verifies this property container.protected booleanverifyComponentScope(UIContainer scopeContainer, String what, PropVerification verification, VSComponent vsOuter) Verifies that this component has it's VS references inside the outer VS reference.Methods inherited from class com.iizix.prop.ui.UIComp
add, addMappings, assignFontInfoResolver, canAlignX, canAlignY, canFillX, canFillY, canRequestFocus, canRequestFocus, clearErrorMessage, couldRequestFocusIfVirtualized, createStyles, createTitleProp, disconnectVSField, enterVSProcessing, exitVSProcessing, fireSelection, fireSelection, forbiddenGetCustomDataMap, getBadge, getBestVSFieldValueType, getComponentID, getComponentMappings, getErrorMessage, getErrorMessage, getErrorMessageEx, getErrorMessageString, getErrorMessageString, getErrorMessageStringEx, getFixHeight, getFixWidth, getFontInfo, getForcedAlignX, getForcedAlignY, getKStringText, getLayout, getLayoutMgr, getLayoutMgr, getMappedVSComponent, getMessage, getMessageText, getPixelHeight, getPixelWidth, getSize, getStyles, getStyles, getText, getTitle, getTitleKS, getTitlePKS, getTooltip, getTooltipText, getTrigger, getUIPanel, getUIParent, getValue, getValue, getVirtualSpace, getVSField, hasExplicitHeight, hasExplicitWidth, hasFocus, hasImplicitHeight, hasImplicitWidth, hasSelectionChanged, initPropCnr, isEnabled, isMobile, isReadOnly, isRTL, isVisible, isVSFieldDisconnected, mustHaveExplicitHeight, mustHaveExplicitWidth, onBroken, onEventSelf, onFocusGained, onNotifySelectionChanged, onParentStateChanged, onPrepare, onPrepare, onPropDispose, onRemoteEvent, onResolved, onStateChanged, onValueChanged, processVSComponentSelection, reconnectVSField, requestFocus, requestFocus, requestFocus, requestFocus, requestFocusEx, requestFocusEx, requestFocusEx, requestFocusEx, setBadge, setBadge, setComponentToVSField, setEnabled, setEnabled, setErrorMessage, setErrorMessage, setErrorMessage, setErrorMessage, setHTMLText, setLayoutMgr, setMessage, setMessage, setReadOnly, setReadOnly, setText, setText, setTitle, setTitle, setTitle, setTooltip, setTooltip, setVisible, setVisible, setVSFieldMessageToComponent, setVSFieldToComponentMethods inherited from class com.iizix.prop.PropCnr
__transferChildProps, addProp, addProp, addProp2, addProp2, appendPropValue, completeVirtualize, containsProp, containsProp, convertLoadedProp, createCopyOfAtom, createUniqueAtom, createUniqueAtom, createUniqueAtom, createVSReference, doPropEqualsArrayValues, enablePropCommunication, enablePropHashMap, equalsTree, equalsTree, getAllProps, getAllProps, getAllProps, getAllProps, getAllProps, getAllProps, getAllProps, getAllProps, getBool, getBool, getBool, getBool, getChildPropError, getChildPropError, getChildPropErrorSeverity, getChildPropErrorSeverity, getErrorsProp, getExtendsContainer, getExtendsError, getExtendsName, getExtendsOverride, getExtendsPossibleClasses, getFirstProp, getFirstProp, getFocusEngine, getInt, getInt, getInt, getInt, getLong, getLong, getLong, getLong, getNumber, getNumber, getNumber, getNumber, getPossibleChildren, getProp, getProp, getProp, getProp, getProp, getProp, getProp, getProp, getProp, getProp, getProp, getPropBaseReference, getPropCnr, getPropCount, getPropCount, getPropIndex, getPropIndex, getPropIndexes, getProps, getProps, getPropValue, getPropValue, getPropValue, getPropValue, getPropValue, getPropValue, getPropValue, getPropValue0, getRetargetedVerifyContainer, getString, getString, getString, getString, getValueClasses, getVSReference, hasSendData, initializeElement, initializeExtendsFramework, initializeProp, initializeValue, insertProp, insertProp2, isChild, isExtendsOverriden, isExtendsPropertyValid, isExtendsRoot, isPropAddRemoveAllowed, isPropCommunicating, isPropExtended, isSibling, list, list, logPropNotFound, maybeAddProp, onInsertProp, onPropRemoved, onPropTreeInitialized, onReferenceEvent, onVirtualizationCompleted, paramString, prepare, removeAllProps, removeAllProps2, removeProp, removeProp, removeProp, removeProp, removeProp, removeProp, removeProp, removeProp2, removeProp2, removeProp2, removeProp2, removeProp2, removeProp2, removeProp2, reorderProps, replaceProps, requestFocus, requestFocusEx, resolveReferences, resolveRuntimeReferences, setBool, setBool, setBool, setBool, setCreateRequiredProp, setExtendsName, setExtendsOverride, setInt, setInt, setInt, setLong, setLong, setLong, setLong, setNumber, setNumber, setNumber, setNumber, setProp, setProp, setProp, setProp2, setProp2, setPropValue, setPropValue, setPropValue, setPropValue, setPropValue, setPropValue, setString, setString, setString, setString, shouldCreateProps, shouldSerializeToXML, toElementString, toNativeValue0, usePropHashMap, usesPropIndex, validateChildPropInValue, validateClassInstances, validatePropType, validatePropValue, verifyInternalUseOnly, verifyTree, virtualizeMethods inherited from class com.iizix.prop.GProp
addPropError, addPropListener, convertPropError, dispose, equals, equals, equalsErrors, equalsObj, equalsPropValue, equalValues, extendsClone, finalize, fine, fine, finer, finer, finest, finest, fromElementString, getAliasName, getAppSessionGyro, getAppWorker, getAtomPath, getAttribute, getChildReferencePropName, getClientSessionGyro, getClientWorker, getConstraints, getEnvironment, getErroredPropItems, getErroredProps, getErrorsProp, getExtendsRootContainer, getFullPropName, getFullPropName, getFullPropNameDebug, getFullPropNameDebug, getListeners, getModuleFolder, getModuleFolder, getParent, getParent, getProjectName, getPropAtom, getPropError, getPropError, getPropErroredName, getPropErrorSeverity, getPropExtendsFlags, getPropFromPath, getPropFromPath, getPropFromReference, getPropFromReference, getPropIndex, getPropName, getPropPath, getPropPath, getPropReferenceTarget, getPropRootPropMgr, getPropTreeErrorSeverity, getPropValue, getPropValue, getPropValueObject, getReferencePropName, getReferencePropNameNoAssert, getRelativePropName, getRootFromName, getRootName, getRootParent, getRootParentNoAssert, getTreeLock, hasChanged, hasCircularReferencesError, hasPrivateChangeEventProp, hasPropError, hasPropTreeError, info, info, initializeGElement, initializeGProp, isDisposed, isPropChildOf, isPropClientCreated, isPropCreateRequired, isPropExtended, isPropExtendsFinal, isPropExtendsPrivate, isPropExtendsPrivateInRoot, isPropExtendsPrivateInRoot, isPropFile, isPropFolder, isPropForEditor, isPropNullable, isPropPrivate, isPropPrivateAtCreation, isPropReadOnly, isPropReferenceTreeValid, isPropRoot, isPropRootLoading, isPropRootTreeModificationsAllowed, isPropUSER, isPropValueTreeLockNeeded, isPropVirtualized, isPropVirtualizing, isPropVolatile, isPropVolatileOrEditorOnly, isProxied, list, list, list, mapAliasToReference, mapAliasToReference, mapReferenceToAlias, mapReferenceToAlias, mapReferenceToProjectRelative, modifyPropValue, moveProp, moveProp, moveProp, onEvent, onPropInvalidateCache, onPropParentChanged, onPropValueSet, paramString, paramValue, post, post, removePropError, removePropListener, removePropUSER, renameProp, renameProp2, resetChangedTree, setChanged, setConstraints, setConstraints, setParent, setPrivateChangeEventProp, setPrivateCreateRequiredProp, setPropError, setPropErroredName, setPropExtended, setPropExtendsFinal, setPropExtendsPrivate, setPropForEditor, setPropNullable, setPropPrivate, setPropReadOnly, setPropUSER, setPropValue, setPropValue, setPropValue, setPropValueIncognito, setPropVolatile, severe, severe, severe, shouldSerializeToXML, throwIfReadOnly, toNativeValue, toString, toString, triggerRemoteEvent, triggerRemoteEvent, validateProp, warning, warning, warningMethods inherited from class java.lang.Object
getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface com.iizix.IComponent
clearErrorMessage, getBadge, getKStringText, getLayoutMgr, getMessage, getMessageText, getStyles, getText, getTooltip, getTooltipText, getUIPanel, getUIParent, isEnabled, isReadOnly, isVisible, messageBox, requestFocus, requestFocus, requestFocusEx, requestFocusEx, setBadge, setBadge, setEnabled, setErrorMessage, setErrorMessage, setHTMLText, setLayoutMgr, setMessage, setMessage, setReadOnly, setText, setText, setTooltip, setTooltip, setVisibleMethods inherited from interface com.iizix.prop.ICustomDataProvider
forbiddenGetCustomDataMap, getCustomData, putCustomData, putCustomDataIfAbsentMethods inherited from interface com.iizix.gyro.IFocusComp
requestFocus, requestFocus, requestFocusEx, requestFocusExMethods inherited from interface com.iizix.prop.IGProp
addPropError, addPropListener, dispose, equals, fine, fine, finer, finer, finest, finest, fromElementString, getAppSessionGyro, getAtomPath, getClientSessionGyro, getConstraints, getEnvironment, getErroredPropItems, getErroredProps, getErrorsProp, getExtendsRootContainer, getFullPropName, getFullPropNameDebug, getModuleFolder, getModuleFolder, getParent, getParent, getPropAtom, getPropBaseReference, getPropError, getPropError, getPropErrorSeverity, getPropExtendsFlags, getPropFromPath, getPropFromReference, getPropIndex, getPropName, getPropPath, getPropPath, getPropRootPropMgr, getPropTreeErrorSeverity, getPropValue, getPropValue, getReferencePropName, getRelativePropName, getRootParent, getTreeLock, getValueClasses, getVSReference, hasChanged, hasCircularReferencesError, hasPrivateChangeEventProp, hasPropError, hasPropTreeError, info, info, initializeGElement, initializeGProp, isDisposed, isPropChildOf, isPropClientCreated, isPropCommunicating, isPropCreateRequired, isPropExtended, isPropExtendsFinal, isPropExtendsPrivate, isPropExtendsPrivateInRoot, isPropExtendsPrivateInRoot, isPropFile, isPropFolder, isPropNullable, isPropPrivate, isPropReadOnly, isPropReferenceTreeValid, isPropRoot, isPropVirtualized, list, list, list, list, list, mapAliasToReference, mapReferenceToAlias, mapReferenceToProjectRelative, moveProp, moveProp, moveProp, onEvent, onEventSelf, onPropTreeInitialized, onRemoteEvent, removePropError, removePropListener, renameProp, resolveRuntimeReferences, setChanged, setConstraints, setConstraints, setParent, setPrivateChangeEventProp, setPropError, setPropExtendsFinal, setPropExtendsPrivate, setPropNullable, setPropPrivate, setPropReadOnly, setPropValue, setPropValue, severe, severe, severe, toElementString, toNativeValue, triggerRemoteEvent, triggerRemoteEvent, validateProp, validatePropType, validatePropValue, warning, warning, warningMethods inherited from interface com.iizix.gyro.IMessageBox
messageBox, messageBoxMethods inherited from interface com.iizix.prop.IPropCnr
addProp, addProp, addProp2, addProp2, canRequestFocus, canRequestFocus, canRequestFocus, containsProp, containsProp, couldRequestFocusIfVirtualized, couldRequestFocusIfVirtualized, couldRequestFocusIfVirtualized, createCopyOfAtom, createUniqueAtom, createUniqueAtom, enablePropCommunication, enablePropHashMap, getAllProps, getAllProps, getAllProps, getAllProps, getAllProps, getAllProps, getAllProps, getAllProps, getBool, getBool, getBool, getBool, getChildPropError, getChildPropError, getChildPropErrorSeverity, getChildPropErrorSeverity, getErrorsProp, getExtendsError, getExtendsName, getExtendsPossibleClasses, getFirstProp, getFirstProp, getFocusEngine, getInt, getInt, getInt, getInt, getLong, getLong, getLong, getLong, getNumber, getNumber, getNumber, getNumber, getPossibleChildren, getProp, getProp, getProp, getProp, getProp, getProp, getProp, getProp, getProp, getProp, getProp, getPropCnr, getPropCount, getPropIndex, getPropIndex, getPropIndexes, getProps, getProps, getPropValue, getPropValue, getPropValue, getPropValue, getPropValue, getPropValue, getPropValue, getString, getString, getString, getString, hasFocus, initializeExtendsFramework, insertProp, insertProp2, isChild, isExtendsOverriden, isExtendsRoot, isPropAddRemoveAllowed, isPropExtended, isSibling, removeAllProps, removeAllProps2, removeProp, removeProp, removeProp, removeProp, removeProp, removeProp, removeProp, removeProp2, removeProp2, removeProp2, removeProp2, removeProp2, removeProp2, removeProp2, reorderProps, requestFocus, requestFocusEx, setBool, setBool, setBool, setBool, setExtendsName, setExtendsOverride, setInt, setInt, setInt, setLong, setLong, setLong, setLong, setNumber, setNumber, setNumber, setNumber, setProp, setProp, setProp, setProp2, setProp2, setPropValue, setPropValue, setPropValue, setPropValue, setPropValue, setPropValue, setString, setString, setString, setString, usePropHashMap, usesPropIndex, validateClassInstancesMethods inherited from interface com.iizix.prop.ui.IUIComp
disconnectVSField, getComponentID, getComponentMappings, getContainerFirstUIComponent, getContainerFirstUIComponentNull, getErrorMessage, getErrorMessage, getFixHeight, getFixWidth, getLayout, getLayoutMgr, getPanelUIComponent, getPanelUIComponentNull, getUIRef, getValue, getValue, getVirtualSpace, getVSField, isMobile, isRTL, isVSFieldDisconnected, reconnectVSField, setComponentToVSField, setErrorMessage, setErrorMessage, setVSFieldMessageToComponent, setVSFieldToComponentMethods inherited from interface com.iizix.prop.ui.IUIContextMenuOwner
getContainedContextMenu, getContextMenu, getReferencedContextMenu, isContextMenuSupported, onBroken, onResolvedMethods inherited from interface com.iizix.prop.ui.IUIFocusComp
onFocusGained, onFocusLostMethods inherited from interface com.iizix.prop.vs.IVSComponentListener
onParentStateChangedMethods inherited from interface com.iizix.prop.vs.IVSFieldListener
getBestVSFieldValueType, onBroken, onResolved, onStateChanged, onValueChanged
Field Details
UICOMP_CLASS
Accepted children components array: UIComp class.VS_STATE_FOCUS_PROP_NAME
The property name for VS connection for state and focus.- See Also:
WARN_EMPTY_PROP_NAME
The property name for empty container warning issuing, if property is not present or true, the warning will be shown.- See Also:
Constructor Details
UIContainer
public UIContainer()Creates an UI container with the specified name with a null value.UIContainer
Creates an UI container with the specified name with a null value.- Parameters:
propertyAtom- the property atom.
UIContainer
Creates an UI container with the specified name and properties.- Parameters:
propertyAtom- the property atom.properties- the property array value for the property.- Throws:
PropException- as structural changes in containers on client is prohibited.
Method Details
clone
Creates a clone out of this property. The cloning is overridden by the subclasses in order to handle cloning of its class variables appropriately.Cloning is used for "virtualization" of a property tree in the server. Client property classes will therefore throw
CloneNotSupportedException.Once a tree has been cloned, the change-flag is reset, and the create-flag is set. All listeners are also removed! The new cloned property is an orphan, i.e. has no parent set. All children properties are also (deep) cloned.
Note that the cloning process is done WITHOUT thread synchronization for performance reasons, thus no modifications should be done to the tree!
addPredefinedProps
Adds the predefined properties for this container. This method is called once just after construction of the property container and sometimes population of it.This implementation creates the UIComps property named Atom.COMPONENTS for the UI components, and saves the reference to it for fast access.
- Overrides:
addPredefinedPropsin classPropCnr- Throws:
PropException- For property exceptions.
addPredefinedPropsImpl
Adds the predefined containers for identifications, fields and actions. This method is overridden fully by the Editor versions of the class.- Throws:
PropException- For property exceptions.
getPredefinedProps
public void getPredefinedProps()Adds the predefined containers for identifications, fields and actions. This method is overridden fully by the Editor versions of the class.- Overrides:
getPredefinedPropsin classUIComp
updateUICompsReference
protected void updateUICompsReference()Updates the reference to the UIComps instance named Atom.COMPONENTS, used when cloning and for the panel part container (or any time the UIComps instance has been changed).resetComponentID
public void resetComponentID()Resets the component ID, typically when copied or saved in order to add make copies of the (some) component data. The operation is recursive.- Overrides:
resetComponentIDin classUIComp
onVirtualContainerCreated
protected final void onVirtualContainerCreated()Called when a property container has been virtualized because it was added into another property container that was virtualized, and this container was not. Typically, UI and VS will issue a onUICreate or onVSCreate.- Overrides:
onVirtualContainerCreatedin classPropCnr
invokeOnUICreateTree
Invokes the onUICreate method for the component if a panel is present. This method should only be invoked when a component is resolved during the post-resolve virtualization process, or when a component is added into an already virtualized UI component tree.The OnCreate method is called first for the parents, then its children recursively.
- Overrides:
invokeOnUICreateTreein classUIComp- Parameters:
panel- The panel in which the component is a child of (or the panel itself).- Throws:
NullPointerException- If thepanelisnull.
hasImplicitAlignFillX
public boolean hasImplicitAlignFillX()Returns if the container has implicit component horizontal fill.The default behavior is to forward the reply to
LayoutMgr.hasImplicitAlignFillX().- Overrides:
hasImplicitAlignFillXin classUIComp- Returns:
- true means component will always fill the space in X, false otherwise.
hasImplicitAlignFillY
public boolean hasImplicitAlignFillY()Returns if the container has implicit component vertical fill.The default behavior is to forward the reply to
LayoutMgr.hasImplicitAlignFillY().- Overrides:
hasImplicitAlignFillYin classUIComp- Returns:
- true means component will always fill the space in Y, false otherwise.
getDeviceType
public int getDeviceType()Gets the device type: -1=mobile, 0=both, 1=desktop.- Specified by:
getDeviceTypein interfaceIUIComp
isMobileContextMenuSupported
public boolean isMobileContextMenuSupported()Returns if the component can show the context menu in mobile mode.- Specified by:
isMobileContextMenuSupportedin interfaceIUIContextMenuOwner- Returns:
- Container component does not by default supports context menus for mobile.
createCompsCnr
Creates the components for the Editor.getCompsCnr
Gets the container associated with this layout manager and the UI container.- Specified by:
getCompsCnrin interfaceIUIContainer- Returns:
- The UI components container.
getComponents
Gets the UI components of the container.- Specified by:
getComponentsin interfaceIUIContainer- Returns:
- The array of components, always non-null.
getComponentCount
public int getComponentCount()Gets the UI component count.- Specified by:
getComponentCountin interfaceIUIContainer- Returns:
- The UI component count.
isEmptyContainerAllowed
public boolean isEmptyContainerAllowed()Returns whether the container should have children in a normal conditions, i.e. a warning message should be displayed in the Designer when it is empty. This is intended to be used to avoid use of empty containers. Some containers, e.g. the mobile heading is allowed to be empty.- Returns:
- false (default) not to allow empty container, true otherwise.
doIssueEmptyContainerWarning
public boolean doIssueEmptyContainerWarning()Returns whether the container should have children in a normal conditions, i.e. a warning message should be displayed in the Designer when it is empty. This is intended to be used to avoid use of empty containers. Some containers, e.g. the mobile heading is allowed to be empty.- Returns:
- false (default) not to allow empty container, true otherwise.
getRadioSelectionComponents
Gets the components being part of the selection group specified. Each component returned implements the thisIRadioComponentinterface.- Specified by:
getRadioSelectionComponentsin interfaceIUIContainer- Parameters:
groupName- The group name, possibly null (for default).- Returns:
- An array of the selection components.
getSelectedRadioComponent
Gets the currently selected radio component in the group.- Specified by:
getSelectedRadioComponentin interfaceIUIContainer- Parameters:
groupName- The group name, possibly null.- Returns:
- The selected radio component, null for none.
setRadioSelectionComponent
Sets the selection to the specified radio component.- Specified by:
setRadioSelectionComponentin interfaceIUIContainer- Parameters:
radioComponent- The radio-interface-implementing (interfaceIUIRadioComponentcomponent.isSelected- The selection state.- Returns:
- true if at least one change occurred, false for none.
canAcceptUIContainerFocus
Returns if this container can accept focus itself or for one of its children components. If this is a component and not a container, this request is redirected to the parent container.This method recurses up to the topmost UI container, and all containers must return null for this method to return null.
Typically, a container returns itself as instance if it is disabled or hidden.
- Specified by:
canAcceptUIContainerFocusin interfaceIUIComp- Overrides:
canAcceptUIContainerFocusin classUIComp- Returns:
- null if this container (or parent container if this is a component) and all containers up to the topmost level returns null, otherwise the container that did not accept focus.
setUIContainerFocus
Sets the focus to the UI container and all its parents. This method is called when focus is to be set to a component, making it possible for containers such as accordion/swap/tab to change its main container into view.Subclasses must override this method to process it, but make sure to call
super.setUIContainerFocus(requestor)first!- Specified by:
setUIContainerFocusin interfaceIUIComp- Overrides:
setUIContainerFocusin classUIComp- Parameters:
requestor- The requestor is a child to this container.doAnimate- Flag to enable animation when selection is changed for e.g. accordion, swap or tab containers.- Returns:
- null for success, otherwise an error message why it failed.
getVSStateFocus
Gets the VS component for state and focus of this container.- Overrides:
getVSStateFocusin classUIComp- Returns:
- The component (generally a VS Group), null if none is set.
getFirstContainerVSStateFocus
Gets the first VS component encountered for state and focus of this container or in the parent tree up to the panel level.- Overrides:
getFirstContainerVSStateFocusin classUIComp- Returns:
- The component (generally a VS Group), null if none is set.
onResolved
Called when the property reference has been resolved. UI components use this method to set its state according to the VS component.- Specified by:
onResolvedin interfaceIVSGenericComponentListener- Parameters:
reference- The VSComponentReference instance holding the component reference.component- The VS component reference that is now resolved.
onBroken
Called when the property reference has been broken, i.e. unresolved.- Specified by:
onBrokenin interfaceIVSGenericComponentListener- Parameters:
reference- The VSComponentReference instance holding the component reference.component- The VS component reference that is now unresolved.
onStateChanged
Called when the VS component changes state.- Specified by:
onStateChangedin interfaceIVSGenericComponentListener- Parameters:
component- The VS component.state- The state change.on- New state.
onVSComponentSelectionChanged
protected void onVSComponentSelectionChanged(boolean on) Called when the VS component has its selected state changed. By default, the parent container is verified for selection support. These are typically accordion, swap, tab containers.- Parameters:
on- The selected state.
onComponentSelectedInParent
public void onComponentSelectedInParent(boolean on) Called by the parent container to inform that this component has been selected in its container. The containers that call this method are typically accordion, swap and tab containers.The container processes this method by selecting the VSComponent for state and focus that may be connected.
- Overrides:
onComponentSelectedInParentin classUIComp- Parameters:
on- The selection state.
onSelectionChanged
Method called when the selection of the component changed due to a property change (value changed, property added or removed).- Overrides:
onSelectionChangedin classUIComp- Parameters:
event- The event that causes the selection change.
onSelectionChanged
protected void onSelectionChanged(boolean on) Called when the container is selected as the current container in an index-based single-selection container such as accordion, swap and tab containers.verify
Verifies this property container. The check performed is the extension of classes and that no circular reference is present.verifyComponentScope
protected boolean verifyComponentScope(UIContainer scopeContainer, String what, PropVerification verification, VSComponent vsOuter) Verifies that this component has it's VS references inside the outer VS reference.- Overrides:
verifyComponentScopein classUIComp- Parameters:
scopeContainer- The scope container.what- What the scope container is.verification- The property verification class.vsOuter- The outer VS parent.- Returns:
- true if OK, false if somehow outside.
getUIComponent
public <COMP extends UIComp> COMP getUIComponent(@UIRef String uiPath, Class<COMP> uiClass) throws NotFoundException Gets a UI component with relative reference from this container.Note: A UI path is not the same as a property path, it omits the UI container UIComps instance from the path.
Note 2: If the path is empty, "this" component is returned if the component class
uiClassmatches, otherwiseNotFoundExceptionis thrown.- Parameters:
uiPath- The UI path for the component.uiClass- The UI class of the component.- Returns:
- The component, never null.
- Throws:
NotFoundException- The not-found exception is thrown if the component is not found instead of returning null.
getUIComponentNull
Gets a UI component with relative reference from this container.Note: A UI path is not the same as a property path, it omits the UI container UIComps instance from the path.
Note 2: If the path is empty, "this" component is returned if the component class
uiClassmatches, otherwisenullis returned.- Parameters:
uiPath- The UI path for the component.uiClass- The UI class of the component.- Returns:
- The component, or null if not found.
getFirstUIComponent
public <COMP extends UIComp> COMP getFirstUIComponent(String name, Class<COMP> uiClass) throws NotFoundException Gets the first UI component of the specified name and UI class. The search for the component is done from this container and its children containers.- Specified by:
getFirstUIComponentin interfaceIUIComp- Parameters:
name- The name of the component.uiClass- The UI class of the component.- Returns:
- The component, never null.
- Throws:
NotFoundException- The not-found exception is thrown if the component is not found instead of returning null.
getFirstUIComponentNull
Gets the first UI component of the specified name and UI class. The search for the component is done from this container and its children containers.- Specified by:
getFirstUIComponentNullin interfaceIUIComp- Parameters:
name- The name of the component.uiClass- The UI class of the component.- Returns:
- The component, or null if not found.
mustHaveWidth
public boolean mustHaveWidth()Does this component requires a width?- Overrides:
mustHaveWidthin classUIComp- Returns:
- true if the width must be defined and non-zero, false otherwise.
mustHaveHeight
public boolean mustHaveHeight()Does this component requires a height.- Overrides:
mustHaveHeightin classUIComp- Returns:
- true if the height must be defined and non-zero, false otherwise.
getApproximateSize
Returns the size of the component in pixels. The size is a calculation and does not exactly reflect the real size that may be different due to additional styles not taken into account by this method. The size is calculated from the font of the component and default or defined values (such as character length or number of lines for text area).- Specified by:
getApproximateSizein classUIComp- Returns:
- The size of the component: 300x200.