Class CmsGalleriesTab
java.lang.Object
com.google.gwt.user.client.ui.UIObject
com.google.gwt.user.client.ui.Widget
com.google.gwt.user.client.ui.Composite
org.opencms.ade.galleries.client.ui.A_CmsTab
org.opencms.ade.galleries.client.ui.A_CmsListTab
org.opencms.ade.galleries.client.ui.CmsGalleriesTab
- All Implemented Interfaces:
com.google.gwt.event.logical.shared.HasAttachHandlers,com.google.gwt.event.logical.shared.ValueChangeHandler<String>,com.google.gwt.event.shared.EventHandler,com.google.gwt.event.shared.HasHandlers,com.google.gwt.user.client.EventListener,com.google.gwt.user.client.ui.HasVisibility,com.google.gwt.user.client.ui.IsRenderable,com.google.gwt.user.client.ui.IsWidget,I_CmsTruncable
Provides the widget for the galleries(folder) tab.
It displays the available gallery folders in the given order.
- Since:
- 8.0.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprotected classA class which generates list items incrementally to fill the galleries tab.protected classCommand for adding more list items to the list of publish items.protected classA class which generates tree items incrementally to fill the galleries tab.Nested classes/interfaces inherited from class org.opencms.ade.galleries.client.ui.A_CmsListTab
A_CmsListTab.A_SelectionHandler, A_CmsListTab.SelectHandlerNested classes/interfaces inherited from class com.google.gwt.user.client.ui.UIObject
com.google.gwt.user.client.ui.UIObject.DebugIdImpl, com.google.gwt.user.client.ui.UIObject.DebugIdImplEnabled -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected static final intThe batch size for adding new elements to the tab.The labels to display for groups.protected Iterator<CmsTreeItem> An iterator which produces new list items which should be added to the tab.protected org.opencms.ade.galleries.shared.CmsGalleryGroupThe group of the gallery folder list item that was last rendered.List of selected galleries.Fields inherited from class org.opencms.ade.galleries.client.ui.A_CmsListTab
DIALOG_CSS, m_infoLabel, m_list, m_options, m_quickSearch, m_scrollList, m_searchButton, m_sortSelectBox, m_tabFields inherited from class org.opencms.ade.galleries.client.ui.A_CmsTab
m_tabTextAccessorFields inherited from class com.google.gwt.user.client.ui.UIObject
DEBUG_ID_PREFIX -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidaddChildren(CmsTreeItem parent, List<org.opencms.ade.galleries.shared.CmsGalleryTreeEntry> children, List<String> selectedGalleries) Adds children to the gallery tree and select the galleries.protected CmsTreeItemcreateTreeItem(org.opencms.ade.galleries.shared.CmsGalleryFolderBean galleryInfo, List<String> selectedGalleries, boolean forTree, boolean useGroups) Creates a tree item widget used in list and tree view of this tab.voidfillContent(List<org.opencms.ade.galleries.shared.CmsGalleryFolderBean> galleryInfos, List<String> selectedGalleries, boolean grouped) Fill the content of the galleries tab panel.protected StringgetGroupName(org.opencms.ade.galleries.shared.CmsGalleryGroup group) Gets the label to display for a group.getParamPanels(org.opencms.ade.galleries.shared.CmsGallerySearchBean searchObj) Returns the search parameters to display within the result tab.protected LinkedHashMap<String, String> Returns a list with sort values for this tab.protected CmsGalleriesTabHandlerReturns the tab handler.protected booleanReturns if this tab has quick filter enabled.booleanReturns the value of the "loading" flag, which indicates whether new elements are currently being added into the galleries tab.protected voidAdds more gallery list items to display in the tab, if available.voidWill be triggered when a tab is selected.static voidopenOptimizeGalleryDialog(org.opencms.util.CmsUUID id) Opens the 'optimize gallery' dialog for the given structure id of a galleryvoidsetLoading(boolean loading) Sets the "loading" flag.voiduncheckGalleries(List<String> galleries) De-selects the galleries in the galleries list.voidupdateListContent(List<org.opencms.ade.galleries.shared.CmsGalleryFolderBean> galleries, List<String> selectedGalleries, boolean useGroups) Update the galleries list.voidupdateTreeContent(List<org.opencms.ade.galleries.shared.CmsGalleryTreeEntry> galleryTreeEntries, List<String> selectedGalleries) Update the galleries tree.Methods inherited from class org.opencms.ade.galleries.client.ui.A_CmsListTab
addWidgetToFrontOfList, addWidgetToList, addWidgetToOptions, cancelQuickFilterTimer, checkQuickSearchStatus, clearList, createCustomUploadButton, createNewExternalLinkButton, createOptimizeButton, createScrollList, createSelectBox, createSelectButton, createSelectResourceButton, createUploadButtonForTarget, getList, getRequiredHeight, hasQuickSearch, init, onContentChange, onResize, onValueChange, quickSearch, scheduleQuickFilterTimer, searchTreeItem, setSortSelectBoxValue, truncateMethods inherited from class org.opencms.ade.galleries.client.ui.A_CmsTab
clearParams, getTabId, isSelected, onDeselection, removeParam, setTabTextAccessorMethods inherited from class com.google.gwt.user.client.ui.Composite
claimElement, getWidget, initializeClaimedElement, initWidget, isAttached, onAttach, onBrowserEvent, onDetach, render, render, resolvePotentialElement, setWidgetMethods inherited from class com.google.gwt.user.client.ui.Widget
addAttachHandler, addBitlessDomHandler, addDomHandler, addHandler, asWidget, asWidgetOrNull, createHandlerManager, delegateEvent, doAttachChildren, doDetachChildren, fireEvent, getHandlerCount, getLayoutData, getParent, isOrWasAttached, onLoad, onUnload, removeFromParent, setLayoutData, sinkEvents, unsinkEventsMethods inherited from class com.google.gwt.user.client.ui.UIObject
addStyleDependentName, addStyleName, ensureDebugId, ensureDebugId, ensureDebugId, getAbsoluteLeft, getAbsoluteTop, getElement, getOffsetHeight, getOffsetWidth, getStyleElement, getStyleName, getStyleName, getStylePrimaryName, getStylePrimaryName, getTitle, isVisible, isVisible, onEnsureDebugId, removeStyleDependentName, removeStyleName, setElement, setElement, setHeight, setPixelSize, setSize, setStyleDependentName, setStyleName, setStyleName, setStyleName, setStyleName, setStylePrimaryName, setStylePrimaryName, setTitle, setVisible, setVisible, setWidth, sinkBitlessEvent, toString
-
Field Details
-
LOAD_BATCH_SIZE
The batch size for adding new elements to the tab.- See Also:
-
m_groupLabels
The labels to display for groups. -
m_itemIterator
An iterator which produces new list items which should be added to the tab. -
m_lastGroup
The group of the gallery folder list item that was last rendered. -
m_selectedGalleries
List of selected galleries.
-
-
Constructor Details
-
CmsGalleriesTab
Constructor.- Parameters:
tabHandler- the tab handler
-
-
Method Details
-
openOptimizeGalleryDialog
Opens the 'optimize gallery' dialog for the given structure id of a gallery- Parameters:
id- the structure id of a gallery
-
fillContent
public void fillContent(List<org.opencms.ade.galleries.shared.CmsGalleryFolderBean> galleryInfos, List<String> selectedGalleries, boolean grouped) Fill the content of the galleries tab panel.- Parameters:
galleryInfos- the gallery info beansselectedGalleries- the list of galleries to selectgrouped- true if the items should be broken into groups
-
isLoading
Returns the value of the "loading" flag, which indicates whether new elements are currently being added into the galleries tab.- Returns:
- the "loading" flag
-
onSelection
Description copied from class:A_CmsTabWill be triggered when a tab is selected.- Overrides:
onSelectionin classA_CmsTab- See Also:
-
setLoading
Sets the "loading" flag.- Parameters:
loading- the new value of the loading flag
-
uncheckGalleries
De-selects the galleries in the galleries list.- Parameters:
galleries- the galleries to deselect
-
updateListContent
public void updateListContent(List<org.opencms.ade.galleries.shared.CmsGalleryFolderBean> galleries, List<String> selectedGalleries, boolean useGroups) Update the galleries list.- Parameters:
galleries- the new gallery listselectedGalleries- the list of galleries to selectuseGroups- true if the galleries should be broken into groups (this assumes the galleries have already been sorted correctly)
-
updateTreeContent
public void updateTreeContent(List<org.opencms.ade.galleries.shared.CmsGalleryTreeEntry> galleryTreeEntries, List<String> selectedGalleries) Update the galleries tree.- Parameters:
galleryTreeEntries- the new gallery tree listselectedGalleries- the list of galleries to select
-
addChildren
protected void addChildren(CmsTreeItem parent, List<org.opencms.ade.galleries.shared.CmsGalleryTreeEntry> children, List<String> selectedGalleries) Adds children to the gallery tree and select the galleries.- Parameters:
parent- the parent itemchildren- the list of childrenselectedGalleries- the list of galleries to select
-
getSortList
Description copied from class:A_CmsListTabReturns a list with sort values for this tab.- Specified by:
getSortListin classA_CmsListTab- Returns:
- list of sort order value/text pairs
- See Also:
-
getTabHandler
Description copied from class:A_CmsTabReturns the tab handler.- Specified by:
getTabHandlerin classA_CmsTab- Returns:
- the tab handler
- See Also:
-
hasQuickFilter
Description copied from class:A_CmsListTabReturns if this tab has quick filter enabled.- Overrides:
hasQuickFilterin classA_CmsListTab- Returns:
trueif this tab has quick filter enabled- See Also:
-
loadMoreItems
Adds more gallery list items to display in the tab, if available.
-