Class CmsSitemapToolbarHandler
java.lang.Object
org.opencms.gwt.client.ui.A_CmsToolbarHandler
org.opencms.ade.sitemap.client.toolbar.CmsSitemapToolbarHandler
- All Implemented Interfaces:
I_CmsActionHandler
,I_CmsContextMenuHandler
,I_CmsToolbarHandler
The toolbar handler used for the sitemap toolbar context menu.
-
Constructor Summary
ConstructorDescriptionCmsSitemapToolbarHandler
(List<org.opencms.gwt.shared.CmsContextMenuEntryBean> menuBeans) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionvoid
Activates the selection button.void
De-activates the current button.void
ensureLockOnResource
(org.opencms.util.CmsUUID structureId, I_CmsSimpleCallback<Boolean> callback) Tries to lock the given resource and returnstrue
on success.Returns the currently active button (may be null).Returns the available context menu commands as a map by class name.Returns the context type.Returns the editor handler.void
Leaves the current page calling the target URI.void
loadContextMenu
(org.opencms.util.CmsUUID structureId, org.opencms.gwt.shared.CmsCoreData.AdeContext context) Loads the context menu.void
onSiteOrProjectChange
(String sitePath, String serverLink) Called when site and or project have been changed.void
refreshResource
(org.opencms.util.CmsUUID structureId) Reloads the resource edited.void
setActiveButton
(I_CmsToolbarButton button) Sets the currently active tool-bar button.transformEntries
(List<org.opencms.gwt.shared.CmsContextMenuEntryBean> menuBeans, org.opencms.util.CmsUUID structureId) Transforms a list of context menu entry beans to a list of context menu entries.void
unlockResource
(org.opencms.util.CmsUUID structureId) Unlocks the resource if appropriate.Methods inherited from class org.opencms.gwt.client.ui.A_CmsToolbarHandler
transformSingleEntry
-
Constructor Details
-
CmsSitemapToolbarHandler
Constructor.- Parameters:
menuBeans
- the context menu entry beans
-
-
Method Details
-
activateSelection
Description copied from interface:I_CmsToolbarHandler
Activates the selection button.- See Also:
-
deactivateCurrentButton
Description copied from interface:I_CmsToolbarHandler
De-activates the current button. -
ensureLockOnResource
public void ensureLockOnResource(org.opencms.util.CmsUUID structureId, I_CmsSimpleCallback<Boolean> callback) Description copied from interface:I_CmsContextMenuHandler
Tries to lock the given resource and returnstrue
on success. If not successful a warning should be displayed.- Parameters:
structureId
- the structure id of the resource to lockcallback
- the callback to execute- See Also:
-
getActiveButton
Description copied from interface:I_CmsToolbarHandler
Returns the currently active button (may be null).- Returns:
- the currently active button
- See Also:
-
getContextMenuCommands
Description copied from interface:I_CmsContextMenuHandler
Returns the available context menu commands as a map by class name.- Returns:
- the available context menu commands as a map by class name
- See Also:
-
getContextType
Description copied from interface:I_CmsContextMenuHandler
Returns the context type.- Returns:
- the context type
- See Also:
-
getEditorHandler
Description copied from interface:I_CmsContextMenuHandler
Returns the editor handler.- Returns:
- the editor handler
- See Also:
-
leavePage
Description copied from interface:I_CmsActionHandler
Leaves the current page calling the target URI.- Parameters:
targetUri
- the target URI- See Also:
-
onSiteOrProjectChange
Description copied from interface:I_CmsActionHandler
Called when site and or project have been changed.- Parameters:
sitePath
- the site path to the target resourceserverLink
- the server link to the resource- See Also:
-
refreshResource
Description copied from interface:I_CmsActionHandler
Reloads the resource edited.- Parameters:
structureId
- the structure id of the resource to lock- See Also:
-
setActiveButton
Sets the currently active tool-bar button.- Parameters:
button
- the button
-
transformEntries
public List<I_CmsContextMenuEntry> transformEntries(List<org.opencms.gwt.shared.CmsContextMenuEntryBean> menuBeans, org.opencms.util.CmsUUID structureId) Description copied from class:A_CmsToolbarHandler
Transforms a list of context menu entry beans to a list of context menu entries.- Overrides:
transformEntries
in classA_CmsToolbarHandler
- Parameters:
menuBeans
- the list of context menu entry beansstructureId
- the id of the resource for which to transform the context menu entries- Returns:
- a list of context menu entries
- See Also:
-
unlockResource
Description copied from interface:I_CmsContextMenuHandler
Unlocks the resource if appropriate.- Parameters:
structureId
- the structure id of the resource to lock- See Also:
-