Class CmsDirectEditToolbarHandler
java.lang.Object
org.opencms.gwt.client.ui.A_CmsToolbarHandler
org.opencms.ade.editprovider.client.CmsDirectEditToolbarHandler
- All Implemented Interfaces:
I_CmsActionHandler
,I_CmsContextMenuHandler
,I_CmsToolbarHandler
A toolbar handler for the Toolbar direct edit provider.
- Since:
- 8.0.0
-
Constructor Summary
ConstructorDescriptionCmsDirectEditToolbarHandler
(CmsDirectEditEntryPoint entryPoint) 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
insertContextMenu
(List<org.opencms.gwt.shared.CmsContextMenuEntryBean> menuBeans, org.opencms.util.CmsUUID structureId) Inserts the context menu.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.void
Sets the context menu button.void
Opens the publish dialog.void
showToolbar
(boolean show) Toggles the visibility of the toolbar.void
unlockResource
(org.opencms.util.CmsUUID structureId) Unlocks the resource if appropriate.Methods inherited from class org.opencms.gwt.client.ui.A_CmsToolbarHandler
transformEntries, transformSingleEntry
-
Constructor Details
-
CmsDirectEditToolbarHandler
Constructor.- Parameters:
entryPoint
- the entry point
-
-
Method Details
-
activateSelection
Description copied from interface:I_CmsToolbarHandler
Activates the selection button.- See Also:
-
deactivateCurrentButton
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:
-
insertContextMenu
public void insertContextMenu(List<org.opencms.gwt.shared.CmsContextMenuEntryBean> menuBeans, org.opencms.util.CmsUUID structureId) Inserts the context menu.- Parameters:
menuBeans
- the menu beans from the serverstructureId
- the structure id of the resource at which the workplace should be opened
-
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
-
setContextMenuButton
Sets the context menu button.- Parameters:
button
- the context menu button
-
showPublishDialog
Opens the publish dialog. -
showToolbar
Toggles the visibility of the toolbar.- Parameters:
show
-true
to show the toolbar
-
unlockResource
Description copied from interface:I_CmsContextMenuHandler
Unlocks the resource if appropriate.- Parameters:
structureId
- the structure id of the resource to lock- See Also:
-