Package org.opencms.ade.publish.client
Class CmsPublishDialog
java.lang.Object
com.google.gwt.user.client.ui.UIObject
com.google.gwt.user.client.ui.Widget
com.google.gwt.user.client.ui.Panel
com.google.gwt.user.client.ui.SimplePanel
com.google.gwt.user.client.ui.PopupPanel
org.opencms.gwt.client.ui.CmsPopup
org.opencms.ade.publish.client.CmsPublishDialog
- All Implemented Interfaces:
com.google.gwt.event.logical.shared.HasAttachHandlers,com.google.gwt.event.logical.shared.HasCloseHandlers<com.google.gwt.user.client.ui.PopupPanel>,com.google.gwt.event.shared.HasHandlers,com.google.gwt.user.client.EventListener,com.google.gwt.user.client.EventPreview,com.google.gwt.user.client.ui.AcceptsOneWidget,com.google.gwt.user.client.ui.HasAnimation,com.google.gwt.user.client.ui.HasOneWidget,com.google.gwt.user.client.ui.HasVisibility,com.google.gwt.user.client.ui.HasWidgets,com.google.gwt.user.client.ui.HasWidgets.ForIsWidget,com.google.gwt.user.client.ui.IsWidget,com.google.gwt.user.client.ui.SourcesPopupEvents,Iterable<com.google.gwt.user.client.ui.Widget>,I_CmsAutoHider
Main class for the publish dialog.
This class is mostly responsible for the control flow and RPC calls of the publish dialog.
It delegates most of the actual GUI work to the CmsPublishSelectPanel and CmsBrokenLinksPanel classes.
- Since:
- 8.0.0
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumA type which represents the state of a publish action.Nested classes/interfaces inherited from class org.opencms.gwt.client.ui.CmsPopup
CmsPopup.HistoryHandlerNested classes/interfaces inherited from class com.google.gwt.user.client.ui.PopupPanel
com.google.gwt.user.client.ui.PopupPanel.AnimationType, com.google.gwt.user.client.ui.PopupPanel.PositionCallbackNested 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.DebugIdImplEnabledNested classes/interfaces inherited from interface com.google.gwt.user.client.ui.HasWidgets
com.google.gwt.user.client.ui.HasWidgets.ForIsWidget -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intThe dialog width in pixels.protected CmsPublishSelectPanelThe panel for selecting the resources to publish or remove from the publish list.The project map used by showPublishDialog.static final intThe index of the "broken links" panel.static final intThe index of the publish selection panel.Fields inherited from class org.opencms.gwt.client.ui.CmsPopup
DEFAULT_WIDTH, m_closeCommand, m_notificationWidgetInstalled, m_windowWidth, WIDE_WIDTHFields inherited from class com.google.gwt.user.client.ui.UIObject
DEBUG_ID_PREFIX -
Constructor Summary
ConstructorsConstructorDescriptionCmsPublishDialog(org.opencms.ade.publish.shared.CmsPublishData initData, Runnable refreshAction, I_CmsContentEditorHandler editorHandler) Constructs a new publish dialog. -
Method Summary
Modifier and TypeMethodDescriptionvoidexecuteAction(org.opencms.ade.publish.shared.CmsWorkflowAction actionKey) Executes the specified action for the selected resources.Gets the context menu handler.Returns the content editor handler.Gets the failure message.org.opencms.ade.publish.shared.CmsWorkflowActionGets the last workflow action.Gets the context menu handler.org.opencms.ade.publish.shared.CmsPublishOptionsReturns the current publish options.protected org.opencms.ade.publish.shared.CmsWorkflowReturns the selected workflow.protected static org.opencms.ade.publish.shared.rpc.I_CmsPublishServiceAsyncReturns the publish service instance.getState()Gets the publish dialog state.protected org.opencms.ade.publish.shared.CmsWorkflowActionParamsGets the workflow action parameters to which the workflow action should be applied.booleanChecks whether the publish dialog has failed.booleanChecks whether the publish dialog has succeeded.voidonCancel()Method which is called when the cancel button is pressed.voidonGoBack()Method which is called when the back button is pressed.voidonReceivePublishList(org.opencms.ade.publish.shared.CmsPublishGroupList groups) Method which is called after the publish list has been received from the server.voidonReceiveStatus(org.opencms.ade.publish.shared.CmsWorkflowResponse brokenResources) Method which is called after the status from a publish action has arrived.voidsetIncludeRelated(boolean includeRelated) Sets the include related resources option.voidsetIncludeSiblings(boolean includeSiblings) Sets the include sibling resources option.protected voidsetLastAction(org.opencms.ade.publish.shared.CmsWorkflowAction action) Sets the last workflow action.voidsetPanel(int panelId) Changes the currently active panel.voidThis is called when the user just changed the project.voidsetProjectId(org.opencms.util.CmsUUID projectId) Sets the selected project id.voidsetWorkflowId(String workflowId) Sets the selected workflow id.static voidshowPublishDialog(Runnable refreshAction) Convenience method which opens a publish dialog.static voidshowPublishDialog(HashMap<String, String> params, com.google.gwt.event.logical.shared.CloseHandler<com.google.gwt.user.client.ui.PopupPanel> handler, Runnable refreshAction, I_CmsContentEditorHandler editorHandler) Convenience method which opens a publish dialog.static voidshowPublishDialog(org.opencms.ade.publish.shared.CmsPublishData result, com.google.gwt.event.logical.shared.CloseHandler<com.google.gwt.user.client.ui.PopupPanel> handler, Runnable refreshAction, I_CmsContentEditorHandler editorHandler) Shows the publish dialog.voidsucceed()Sets the publish dialog state to 'success'.voidMethod which is called when the publish options are changed.Methods inherited from class org.opencms.gwt.client.ui.CmsPopup
add, add, addButton, addButton, addDialogClose, adjustIndex, beginDragging, catchNotifications, center, centerHorizontally, checkIndexBoundsForAccess, checkIndexBoundsForInsertion, clear, continueDragging, createDialogNotificationWidget, doAttachChildren, doDetachChildren, endDragging, getAvailableHeight, getCaption, getChildren, getContainerElement, getWidget, getWidgetCount, getWidgetIndex, getWidgetIndex, getWidth, hasCaption, hide, hide, insert, insert, insertFront, installNotificationWidget, iterator, onBrowserEvent, onDetach, onPreviewNativeEvent, remove, remove, removeAllButtons, removeButton, removePadding, setBackgroundColor, setCaption, setHeight, setHeight, setMainContent, setPixelSize, setPositionFixed, setSize, setSpecialBackgroundClass, setUseAnimation, setWidget, setWidth, setWidth, show, showArrow, wrapWithBorderPaddingMethods inherited from class com.google.gwt.user.client.ui.PopupPanel
addAutoHidePartner, addCloseHandler, addPopupListener, getAnimationType, getGlassElement, getGlassStyleName, getOffsetHeight, getOffsetWidth, getPopupLeft, getPopupTop, getStyleElement, getTitle, isAnimationEnabled, isAutoHideEnabled, isAutoHideOnHistoryEventsEnabled, isGlassEnabled, isModal, isPreviewingAllNativeEvents, isShowing, isVisible, onEventPreview, onKeyDownPreview, onKeyPressPreview, onKeyUpPreview, onUnload, removeAutoHidePartner, removePopupListener, setAnimationEnabled, setAnimationType, setAutoHideEnabled, setAutoHideOnHistoryEventsEnabled, setGlassEnabled, setGlassStyleName, setModal, setPopupPosition, setPopupPositionAndShow, setPreviewingAllNativeEvents, setTitle, setVisible, showRelativeToMethods inherited from class com.google.gwt.user.client.ui.SimplePanel
getWidget, setWidgetMethods inherited from class com.google.gwt.user.client.ui.Panel
add, adopt, orphan, removeMethods inherited from class com.google.gwt.user.client.ui.Widget
addAttachHandler, addBitlessDomHandler, addDomHandler, addHandler, asWidget, asWidgetOrNull, createHandlerManager, delegateEvent, fireEvent, getHandlerCount, getLayoutData, getParent, isAttached, isOrWasAttached, onAttach, onLoad, removeFromParent, setLayoutData, sinkEvents, unsinkEventsMethods inherited from class com.google.gwt.user.client.ui.UIObject
addStyleDependentName, addStyleName, ensureDebugId, ensureDebugId, ensureDebugId, getAbsoluteLeft, getAbsoluteTop, getElement, getStyleName, getStyleName, getStylePrimaryName, getStylePrimaryName, isVisible, onEnsureDebugId, removeStyleDependentName, removeStyleName, resolvePotentialElement, setElement, setElement, setStyleDependentName, setStyleName, setStyleName, setStyleName, setStyleName, setStylePrimaryName, setStylePrimaryName, setVisible, sinkBitlessEvent, toStringMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface com.google.gwt.event.shared.HasHandlers
fireEventMethods inherited from interface org.opencms.gwt.client.ui.I_CmsAutoHider
addAutoHidePartner, isAutoHideEnabled, isAutoHideOnHistoryEventsEnabled, removeAutoHidePartner, setAutoHideEnabled, setAutoHideOnHistoryEventsEnabledMethods inherited from interface java.lang.Iterable
forEach, spliterator
-
Field Details
-
DIALOG_WIDTH
The dialog width in pixels.- See Also:
-
m_staticProjects
The project map used by showPublishDialog. -
PANEL_BROKEN_LINKS
The index of the "broken links" panel.- See Also:
-
PANEL_SELECT
The index of the publish selection panel.- See Also:
-
m_publishSelectPanel
The panel for selecting the resources to publish or remove from the publish list.
-
-
Constructor Details
-
Method Details
-
showPublishDialog
Convenience method which opens a publish dialog.- Parameters:
refreshAction- the action to execute after a context menu triggered refresh
-
getService
Returns the publish service instance.- Returns:
- the publish service instance
-
getContextMenuHandler
Gets the context menu handler.- Returns:
- the context menu handler
-
getEditorHandler
Returns the content editor handler.- Returns:
- the content editor handler
-
getFailureMessage
Gets the failure message.- Returns:
- the failure message
-
getLastAction
Gets the last workflow action.- Returns:
- the last workflow action
-
getMenuHandler
Gets the context menu handler. -
getPublishOptions
Returns the current publish options.- Returns:
- a publish options bean
-
getState
Gets the publish dialog state.- Returns:
- the publish dialog state
-
hasFailed
Checks whether the publish dialog has failed.- Returns:
- checks whether the publish dialog has succeeded
-
hasSucceeded
Checks whether the publish dialog has succeeded.- Returns:
- true if the publish dialog has succeeded
-
onCancel
Method which is called when the cancel button is pressed. -
onGoBack
Method which is called when the back button is pressed. -
setIncludeRelated
Sets the include related resources option.- Parameters:
includeRelated- the include related option
-
setIncludeSiblings
Sets the include sibling resources option.- Parameters:
includeSiblings- the include siblings option
-
setPanel
Changes the currently active panel.- Parameters:
panelId- the number of the panel to show
-
setProjectChanged
This is called when the user just changed the project. -
setProjectId
Sets the selected project id.- Parameters:
projectId- the project id
-
setWorkflowId
Sets the selected workflow id.- Parameters:
workflowId- the workflow id
-
succeed
Sets the publish dialog state to 'success'. -
updateResourceList
Method which is called when the publish options are changed. -
getSelectedWorkflow
Returns the selected workflow.- Returns:
- the selected workflow
-
getWorkflowActionParams
Gets the workflow action parameters to which the workflow action should be applied.- Returns:
- the workflow action parameters