public class CmsGwtDialogExtension extends com.vaadin.server.AbstractExtension implements I_CmsGwtDialogServerRpc
com.vaadin.server.ClientConnector.AttachEvent, com.vaadin.server.ClientConnector.AttachListener, com.vaadin.server.ClientConnector.ConnectorErrorEvent, com.vaadin.server.ClientConnector.DetachEvent, com.vaadin.server.ClientConnector.DetachListener
Constructor and Description |
---|
CmsGwtDialogExtension(com.vaadin.ui.UI ui,
I_CmsUpdateListener<java.lang.String> updateListener)
Creates a new instance and binds it to a UI instance.
|
Modifier and Type | Method and Description |
---|---|
void |
editPointer(CmsResource resource)
Opens the dialog for editing pointer resources.
|
void |
editProperties(CmsUUID structureId,
boolean editName)
Open property editor for the resource with the given structure id.
|
protected CmsPublishData |
getPublishData(CmsProject project)
Gets the publish data for the given project.
|
protected CmsPublishData |
getPublishData(java.util.List<CmsResource> directPublishResources)
Gets the publish data for the given resources.
|
protected java.lang.String |
getSerializedPublishData(CmsPublishData data)
Serializes a CmsPublishData object into string form using the GWT serialization.
|
void |
onClose(boolean reinitUI)
Disposes of the extension and tells the server whether to re-init the UI.
|
void |
onClose(java.util.List<java.lang.String> changedStructureIds,
long delayMillis)
Disposes of the extension, and tells the server which resources have changed.
|
void |
openCategories(CmsResource resource)
Opens the categories dialog for the given resource.
|
void |
openGalleryDialog(CmsResource resource)
Opens the gallery dialog for the given gallery folder.
|
void |
openInfoDialog(CmsResource resource)
Opens the resource info dialog.
|
void |
openLockReport(CmsResource resource)
Opens the lock report for the given resource.
|
void |
openPublishDialog(CmsProject project)
Opens the publish dialog for the given project.
|
void |
openPublishDialog(java.util.List<CmsResource> resources)
Tells the client to open the publish dialog for the given resources.
|
void |
openReplaceDialog(CmsUUID structureId)
Opens the 'Replace' dialog for the resource with the given structure id.
|
void |
showAbout()
Shows the OpenCms about dialog.
|
void |
showPreview(CmsUUID id,
java.lang.Integer version,
CmsHistoryVersion.OfflineOnline offlineOnline)
Shows the prewview dialog for a given resource and version.
|
void |
showUserPreferences()
Shows the user preferences.
|
extend, getParent, getSupportedParentType, remove, setParent
addAttachListener, addDetachListener, addExtension, addListener, addListener, addListener, addMethodInvocationToQueue, attach, beforeClientResponse, createState, detach, encodeState, equals, fireEvent, getAllChildrenIterable, getConnectorId, getErrorHandler, getExtensions, getListeners, getResource, getRpcManager, getRpcProxy, getSession, getState, getState, getStateType, getUI, handleConnectorRequest, hashCode, hasListeners, isAttached, isConnectorEnabled, isThis, markAsDirty, markAsDirtyRecursive, registerRpc, registerRpc, removeAttachListener, removeDetachListener, removeExtension, removeListener, removeListener, removeListener, removeListener, requestRepaint, requestRepaintAll, retrievePendingRpcCalls, setErrorHandler, setResource
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
addAttachListener, addDetachListener, attach, beforeClientResponse, detach, encodeState, getErrorHandler, getExtensions, getRpcManager, getStateType, getUI, handleConnectorRequest, isAttached, isConnectorEnabled, markAsDirty, markAsDirtyRecursive, removeAttachListener, removeDetachListener, removeExtension, requestRepaint, requestRepaintAll, retrievePendingRpcCalls, setErrorHandler
public CmsGwtDialogExtension(com.vaadin.ui.UI ui, I_CmsUpdateListener<java.lang.String> updateListener)
ui
- the UI to bind this extension toupdateListener
- the update listenerpublic void editPointer(CmsResource resource)
resource
- the pointer resourcepublic void editProperties(CmsUUID structureId, boolean editName)
structureId
- the structure id of a resourceeditName
- controls whether the file name should be editablepublic void onClose(boolean reinitUI)
I_CmsGwtDialogServerRpc
onClose
in interface I_CmsGwtDialogServerRpc
reinitUI
- true
to reinit the UII_CmsGwtDialogServerRpc.onClose(boolean)
public void onClose(java.util.List<java.lang.String> changedStructureIds, long delayMillis)
I_CmsGwtDialogServerRpc
onClose
in interface I_CmsGwtDialogServerRpc
changedStructureIds
- the structure ids of changed resources, as stringsdelayMillis
- time to delay the RPC (for allowing short background operations to finish)I_CmsGwtDialogServerRpc.onClose(java.util.List, long)
public void openCategories(CmsResource resource)
resource
- the resourcepublic void openGalleryDialog(CmsResource resource)
resource
- the gallery folder resourcepublic void openInfoDialog(CmsResource resource)
resource
- the resourcepublic void openLockReport(CmsResource resource)
resource
- the resource for which to display the lock reportpublic void openPublishDialog(CmsProject project)
project
- the project for which to open the dialogpublic void openPublishDialog(java.util.List<CmsResource> resources)
resources
- the resources for which to open the publish dialog.public void openReplaceDialog(CmsUUID structureId)
structureId
- the structure idpublic void showAbout()
public void showPreview(CmsUUID id, java.lang.Integer version, CmsHistoryVersion.OfflineOnline offlineOnline)
id
- the structure id of the resourceversion
- the versionofflineOnline
- indicates whether we want the offlne or online versionpublic void showUserPreferences()
protected CmsPublishData getPublishData(CmsProject project)
project
- the project to open publish dialog forprotected CmsPublishData getPublishData(java.util.List<CmsResource> directPublishResources)
directPublishResources
- the resources to publishprotected java.lang.String getSerializedPublishData(CmsPublishData data)
data
- the publish data