Package org.opencms.gwt.client.seo
Class CmsSeoOptionsDialog
- 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.gwt.client.seo.CmsSeoOptionsDialog
-
- 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
,java.lang.Iterable<com.google.gwt.user.client.ui.Widget>
,I_CmsAutoHider
,I_CmsFormHandler
public class CmsSeoOptionsDialog extends CmsPopup implements I_CmsFormHandler
The SEO options dialog, which makes it possible to both edit the SEO relevant properties of a resource as well as alias paths for the resource.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.opencms.gwt.client.ui.CmsPopup
CmsPopup.HistoryHandler
-
Nested 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.PositionCallback
-
-
Field Summary
Fields Modifier and Type Field Description protected static CmsAliasMessages
aliasMessages
The alias messages.protected CmsAliasList
m_aliasList
The inner alias list.protected int
m_aliasValidationStatus
The validation status for the aliases.protected com.google.gwt.user.client.ui.FlowPanel
m_panel
The root panel for this dialog.protected int
m_propertyValidationStatus
The validation status for the properties.protected org.opencms.util.CmsUUID
m_structureId
The structure id of the resource whose aliases are being edited.protected static java.lang.String[]
seoProperties
The properties which should be displayed.protected static int
VALIDATION_FAILED
The validation has detected an error.protected static int
VALIDATION_OK
The validation has finished successfully.protected static int
VALIDATION_RUNNING
The validation isn't finished yet.-
Fields inherited from class org.opencms.gwt.client.ui.CmsPopup
DEFAULT_WIDTH, m_closeCommand, m_notificationWidgetInstalled, m_windowWidth, WIDE_WIDTH
-
-
Constructor Summary
Constructors Constructor Description CmsSeoOptionsDialog(org.opencms.util.CmsUUID structureId, org.opencms.gwt.shared.CmsListInfoBean infoBean, java.util.List<org.opencms.gwt.shared.alias.CmsAliasBean> aliases, java.util.Map<java.lang.String,org.opencms.xml.content.CmsXmlContentProperty> propertyConfig, I_CmsPropertyEditorHandler propertyEditorHandler)
Creates a new dialog instance.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
isSubmitting()
Returns true if properties are currently being submitted.static void
loadAliases(org.opencms.util.CmsUUID structureId, com.google.gwt.user.client.rpc.AsyncCallback<java.util.List<org.opencms.gwt.shared.alias.CmsAliasBean>> callback)
Loads the aliases for a given page.protected void
onClickSave()
The method which is called when the user clicks the save button of the dialog.void
onSubmitValidationResult(CmsForm form, boolean ok)
This method is called when the validation triggered by an attempt to submit the form has finished.void
onValidationResult(CmsForm form, boolean ok)
This method is called when the normal validation triggered by changing fields has finished.protected void
saveAliases()
Saves the aliases.void
saveAliases(org.opencms.util.CmsUUID uuid, java.util.List<org.opencms.gwt.shared.alias.CmsAliasBean> aliases)
Saves the aliases for a given page.protected void
saveProperties()
Saves the properties.void
show()
void
update(boolean submit)
Updates the validation status and optionally submits the data.-
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, showArrow, wrapWithBorderPadding
-
Methods 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, showRelativeTo
-
Methods 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, unsinkEvents
-
Methods 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, toString
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.opencms.gwt.client.ui.I_CmsAutoHider
addAutoHidePartner, isAutoHideEnabled, isAutoHideOnHistoryEventsEnabled, removeAutoHidePartner, setAutoHideEnabled, setAutoHideOnHistoryEventsEnabled
-
-
-
-
Field Detail
-
aliasMessages
protected static CmsAliasMessages aliasMessages
The alias messages.
-
seoProperties
protected static java.lang.String[] seoProperties
The properties which should be displayed.
-
VALIDATION_FAILED
protected static final int VALIDATION_FAILED
The validation has detected an error.- See Also:
- Constant Field Values
-
VALIDATION_OK
protected static final int VALIDATION_OK
The validation has finished successfully.- See Also:
- Constant Field Values
-
VALIDATION_RUNNING
protected static final int VALIDATION_RUNNING
The validation isn't finished yet.- See Also:
- Constant Field Values
-
m_aliasList
protected CmsAliasList m_aliasList
The inner alias list.
-
m_aliasValidationStatus
protected int m_aliasValidationStatus
The validation status for the aliases.
-
m_panel
protected com.google.gwt.user.client.ui.FlowPanel m_panel
The root panel for this dialog.
-
m_propertyValidationStatus
protected int m_propertyValidationStatus
The validation status for the properties.
-
m_structureId
protected org.opencms.util.CmsUUID m_structureId
The structure id of the resource whose aliases are being edited.
-
-
Constructor Detail
-
CmsSeoOptionsDialog
public CmsSeoOptionsDialog(org.opencms.util.CmsUUID structureId, org.opencms.gwt.shared.CmsListInfoBean infoBean, java.util.List<org.opencms.gwt.shared.alias.CmsAliasBean> aliases, java.util.Map<java.lang.String,org.opencms.xml.content.CmsXmlContentProperty> propertyConfig, I_CmsPropertyEditorHandler propertyEditorHandler)
Creates a new dialog instance.- Parameters:
structureId
- the structure id of the resource whose aliases are being editedinfoBean
- a bean containing the information to display in the resource info boxaliases
- the existing aliases of the resourcepropertyConfig
- the property configurationpropertyEditorHandler
- the property editor handler
-
-
Method Detail
-
loadAliases
public static void loadAliases(org.opencms.util.CmsUUID structureId, com.google.gwt.user.client.rpc.AsyncCallback<java.util.List<org.opencms.gwt.shared.alias.CmsAliasBean>> callback)
Loads the aliases for a given page.- Parameters:
structureId
- the structure id of the pagecallback
- the callback for the loaded aliases
-
isSubmitting
public boolean isSubmitting()
Description copied from interface:I_CmsFormHandler
Returns true if properties are currently being submitted.- Specified by:
isSubmitting
in interfaceI_CmsFormHandler
- Returns:
- true if properties are being submitted
-
onSubmitValidationResult
public void onSubmitValidationResult(CmsForm form, boolean ok)
Description copied from interface:I_CmsFormHandler
This method is called when the validation triggered by an attempt to submit the form has finished.- Specified by:
onSubmitValidationResult
in interfaceI_CmsFormHandler
- Parameters:
form
- the formok
- the validation result- See Also:
I_CmsFormHandler.onSubmitValidationResult(org.opencms.gwt.client.ui.input.form.CmsForm, boolean)
-
onValidationResult
public void onValidationResult(CmsForm form, boolean ok)
Description copied from interface:I_CmsFormHandler
This method is called when the normal validation triggered by changing fields has finished.- Specified by:
onValidationResult
in interfaceI_CmsFormHandler
- Parameters:
form
- the formok
- the validation result- See Also:
I_CmsFormHandler.onValidationResult(org.opencms.gwt.client.ui.input.form.CmsForm, boolean)
-
saveAliases
public void saveAliases(org.opencms.util.CmsUUID uuid, java.util.List<org.opencms.gwt.shared.alias.CmsAliasBean> aliases)
Saves the aliases for a given page.- Parameters:
uuid
- the page structure idaliases
- the aliases to save
-
show
public void show()
- Overrides:
show
in classCmsPopup
- See Also:
CmsPopup.show()
-
update
public void update(boolean submit)
Updates the validation status and optionally submits the data.- Parameters:
submit
- the submit flag
-
onClickSave
protected void onClickSave()
The method which is called when the user clicks the save button of the dialog.
-
saveAliases
protected void saveAliases()
Saves the aliases.
-
saveProperties
protected void saveProperties()
Saves the properties.
-
-