public class CmsResourceSelectDialog extends com.vaadin.ui.CustomComponent
| Modifier and Type | Class and Description |
|---|---|
static class |
CmsResourceSelectDialog.Options
Class for site select options.
|
com.vaadin.ui.HasComponents.ComponentAttachDetachNotifier, com.vaadin.ui.HasComponents.ComponentAttachEvent, com.vaadin.ui.HasComponents.ComponentAttachListener, com.vaadin.ui.HasComponents.ComponentDetachEvent, com.vaadin.ui.HasComponents.ComponentDetachListenercom.vaadin.ui.Component.ErrorEvent, com.vaadin.ui.Component.Event, com.vaadin.ui.Component.Focusable, com.vaadin.ui.Component.Listenercom.vaadin.server.ClientConnector.AttachEvent, com.vaadin.server.ClientConnector.AttachListener, com.vaadin.server.ClientConnector.ConnectorErrorEvent, com.vaadin.server.ClientConnector.DetachEvent, com.vaadin.server.ClientConnector.DetachListener| Modifier and Type | Field and Description |
|---|---|
protected CmsObject |
m_currentCms
The CMS context.
|
protected CmsResourceFilter |
m_filter
The resource filter.
|
protected CmsResource |
m_root
The resource initially displayed at the root of the tree.
|
static java.lang.String |
PROPERTY_SITE_CAPTION
The property used for the site caption.
|
| Constructor and Description |
|---|
CmsResourceSelectDialog(CmsResourceFilter filter)
Creates a new instance.
|
CmsResourceSelectDialog(CmsResourceFilter filter,
CmsObject cms)
public constructor with given CmsObject.
|
CmsResourceSelectDialog(CmsResourceFilter filter,
CmsObject cms,
CmsResourceSelectDialog.Options options)
public constructor.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addSelectionHandler(I_CmsSelectionHandler<CmsResource> handler)
Adds a resource selection handler.
|
protected CmsResourceTreeTable |
createTree(CmsObject cms,
CmsResource root)
Creates the resource tree for the given root.
|
void |
disableSiteSwitch()
Disables the option to select resources from other sites.
|
protected CmsResourceSelectDialogContents |
getContents()
Gets the content panel of this dialog.
|
protected CmsResourceTreeTable |
getFileTree()
Gets the file tree.
|
protected void |
onSiteChange(java.lang.String site)
Called when the user changes the site.
|
void |
openPath(java.lang.String path)
Opens the given path.
|
void |
showSitemapView(boolean showSitemapView)
Switches between the folders and sitemap view of the tree.
|
void |
showStartResource(CmsResource startResource)
Displays the start resource by opening all nodes in the tree leading to it.
|
protected void |
updateRoot(CmsObject rootCms,
CmsResource siteRootResource)
Updates the current site root resource.
|
protected void |
updateView()
Updates the filtering state.
|
getComponentCount, getCompositionRoot, getState, getState, iterator, setCompositionRootaddContextClickListener, addListener, addShortcutListener, addStyleName, attach, beforeClientResponse, detach, findAncestor, fireComponentErrorEvent, fireComponentEvent, focus, getActionManager, getCaption, getComponentError, getCustomAttributes, getData, getDebugId, getDescription, getErrorMessage, getHeight, getHeightUnits, getIcon, getId, getLocale, getParent, getPrimaryStyleName, getStyleName, getWidth, getWidthUnits, isCaptionAsHtml, isConnectorEnabled, isEnabled, isOrHasAncestor, isReadOnly, isRequiredIndicatorVisible, isResponsive, isVisible, readDesign, removeContextClickListener, removeListener, removeShortcutListener, removeStyleName, setCaption, setCaptionAsHtml, setComponentError, setData, setDebugId, setDescription, setDescription, setEnabled, setHeight, setHeight, setHeightUndefined, setIcon, setId, setLocale, setParent, setPrimaryStyleName, setReadOnly, setRequiredIndicatorVisible, setResponsive, setSizeFull, setSizeUndefined, setStyleName, setVisible, setWidth, setWidth, setWidthUndefined, writeDesignaddAttachListener, addDetachListener, addExtension, addListener, addListener, addListener, addMethodInvocationToQueue, createState, encodeState, equals, fireEvent, getAllChildrenIterable, getConnectorId, getErrorHandler, getExtensions, getListeners, getResource, getRpcManager, getRpcProxy, getSession, getStateType, getUI, handleConnectorRequest, hashCode, hasListeners, isAttached, isThis, markAsDirty, markAsDirtyRecursive, registerRpc, registerRpc, removeAttachListener, removeDetachListener, removeExtension, removeListener, removeListener, removeListener, removeListener, requestRepaint, requestRepaintAll, retrievePendingRpcCalls, setErrorHandler, setResource, updateDiffstateclone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitaddListener, addStyleName, addStyleNames, attach, getCaption, getDescription, getIcon, getId, getLocale, getParent, getPrimaryStyleName, getStyleName, getUI, isEnabled, isVisible, readDesign, removeListener, removeStyleName, removeStyleNames, setCaption, setEnabled, setIcon, setId, setParent, setPrimaryStyleName, setStyleName, setStyleName, setVisible, writeDesignaddAttachListener, addDetachListener, beforeClientResponse, detach, encodeState, getErrorHandler, getExtensions, getRpcManager, getStateType, handleConnectorRequest, isAttached, isConnectorEnabled, markAsDirty, markAsDirtyRecursive, removeAttachListener, removeDetachListener, removeExtension, requestRepaint, requestRepaintAll, retrievePendingRpcCalls, setErrorHandlerpublic static final java.lang.String PROPERTY_SITE_CAPTION
protected CmsObject m_currentCms
protected CmsResourceFilter m_filter
protected CmsResource m_root
public CmsResourceSelectDialog(CmsResourceFilter filter) throws CmsException
filter - the resource filter to useCmsException - if something goes wrongpublic CmsResourceSelectDialog(CmsResourceFilter filter, CmsObject cms) throws CmsException
filter - filter the resource filter to usecms - CmsObejct to useCmsException - if something goes wrongpublic CmsResourceSelectDialog(CmsResourceFilter filter, CmsObject cms, CmsResourceSelectDialog.Options options) throws CmsException
filter - resource filtercms - CmsObjectoptions - optionsCmsException - exceptionpublic void addSelectionHandler(I_CmsSelectionHandler<CmsResource> handler)
handler - the handlerpublic void disableSiteSwitch()
public void openPath(java.lang.String path)
path - the path to openpublic void showSitemapView(boolean showSitemapView)
showSitemapView - true to show the sitemap viewpublic void showStartResource(CmsResource startResource)
startResource - the resource which should be shown in the treeprotected CmsResourceTreeTable createTree(CmsObject cms, CmsResource root)
cms - the CMS contextroot - the root resourceprotected CmsResourceSelectDialogContents getContents()
protected CmsResourceTreeTable getFileTree()
protected void onSiteChange(java.lang.String site)
site - the new site rootprotected void updateRoot(CmsObject rootCms, CmsResource siteRootResource)
rootCms - the CMS contextsiteRootResource - the resource corresponding to a site rootprotected void updateView()