Package org.opencms.acacia.client
Class CmsButtonBarHandler
java.lang.Object
org.opencms.acacia.client.CmsButtonBarHandler
- All Implemented Interfaces:
com.google.gwt.event.dom.client.MouseOutHandler
,com.google.gwt.event.dom.client.MouseOverHandler
,com.google.gwt.event.shared.EventHandler
public final class CmsButtonBarHandler
extends Object
implements com.google.gwt.event.dom.client.MouseOverHandler, com.google.gwt.event.dom.client.MouseOutHandler
Helper class for controlling visibility of button hover bars of attribute value views.
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
CSS class used for identifying widgets which normally react to hover events in touch-only mode.static final CmsButtonBarHandler
Global instance of the button bar handler.static final int
The timeout for hiding the buttons. -
Method Summary
Modifier and TypeMethodDescriptionprotected void
addSubmenu
(CmsChoiceMenuEntryWidget entryWidget) Adds a new submenu.protected void
cleanUpSubmenus
(CmsChoiceMenuEntryWidget entryWidget) Removes unnecessary submenus when the user hovers over a given menu entry.void
closeAll()
Closes all visible button bars and menus.protected CmsChoiceSubmenu
Gets the last entry in the current list of active submenus.void
onMouseOut
(com.google.gwt.event.dom.client.MouseOutEvent event) void
onMouseOver
(com.google.gwt.event.dom.client.MouseOverEvent event) protected void
removeSubmenu
(CmsChoiceSubmenu submenu) Removes a submenu and hides it.protected void
setWidgetService
(I_CmsWidgetService widgetService) Sets the widget service.protected boolean
useClickAsFakeHover
(com.google.gwt.user.client.EventListener source, boolean isMouseDown) In touch-only mode, this is used to process some clicks to trigger actions that would be normally triggered by hovering over the same GUI element.
-
Field Details
-
HOVERABLE_MARKER
CSS class used for identifying widgets which normally react to hover events in touch-only mode.- See Also:
-
INSTANCE
Global instance of the button bar handler. -
TIMEOUT
The timeout for hiding the buttons.- See Also:
-
-
Method Details
-
closeAll
Closes all visible button bars and menus. -
onMouseOut
- Specified by:
onMouseOut
in interfacecom.google.gwt.event.dom.client.MouseOutHandler
- See Also:
-
MouseOutHandler.onMouseOut(com.google.gwt.event.dom.client.MouseOutEvent)
-
onMouseOver
- Specified by:
onMouseOver
in interfacecom.google.gwt.event.dom.client.MouseOverHandler
- See Also:
-
MouseOverHandler.onMouseOver(com.google.gwt.event.dom.client.MouseOverEvent)
-
setWidgetService
Sets the widget service.- Parameters:
widgetService
- the widget service
-
useClickAsFakeHover
protected boolean useClickAsFakeHover(com.google.gwt.user.client.EventListener source, boolean isMouseDown) In touch-only mode, this is used to process some clicks to trigger actions that would be normally triggered by hovering over the same GUI element.- Parameters:
source
- the event sourceisMouseDown
- true if the event is a mousedown event- Returns:
- true if the event should be cancelled
-