Class SetCurrentPageTool
java.lang.Object
com.levigo.jadice.web.client.tool.Tool
com.levigo.jadice.web.client.tools.SetCurrentPageTool
- All Implemented Interfaces:
MenuContributor
This tool allows to jump to a specific page. It is used by the
ThumbnailView to set the
current page when the user clicks on the thumbnails.
The default behavior is to jump to the page if the user double clicks the page with the left mouse button.
The click count can be configured via setActivationClickCount(int).
-
Nested Class Summary
Nested classes/interfaces inherited from class com.levigo.jadice.web.client.tool.Tool
Tool.ActivationRequest -
Field Summary
Fields inherited from class com.levigo.jadice.web.client.tool.Tool
DEFAULT_PRIORITY, MAX_PRIORITY, MIN_PRIORITY -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintReturns the current activation click count (left mouse button).protected voidhandleKeyPressed(KeyEditEvent e, boolean isActive) Invoked when a key has been pressed.protected voidhandleMouseClicked(MouseEditEvent e, boolean isActive) Invoked when the mouse button has been clicked (pressed and released) on a component.protected voidhandleTouchStart(TouchEditEvent e, boolean isActive) Invoked when a touch started.voidsetActivationClickCount(int activationClickCount) Sets the activation click count to the desired value.Methods inherited from class com.levigo.jadice.web.client.tool.Tool
contribute, ensureDebugId, getActivationFeedback, getActivationFeedback, getActivationRequest, getActivationRequestForKeyPressed, getActivationRequestForMouseDragged, getActivationRequestForMousePressed, getActivationRequestForTouchMove, getActivationRequestForTouchStart, getDispatchPriority, getManager, getRenderPriority, handleEditEvent, handleGestureChange, handleGestureEnd, handleGestureStart, handleKeyReleased, handleKeyTyped, handleMouseDragged, handleMouseEntered, handleMouseExited, handleMouseMoved, handleMousePressed, handleMouseReleased, handleMouseWheelMoved, handlePointerDown, handlePointerMove, handlePointerUp, handleTouchEnd, handleTouchMove, propagatePropertyChange, render, setActive, setCursor, setCursor, setEnabled, setManager, setStatusFeedback
-
Constructor Details
-
SetCurrentPageTool
public SetCurrentPageTool()
-
-
Method Details
-
handleMouseClicked
Description copied from class:ToolInvoked when the mouse button has been clicked (pressed and released) on a component.- Overrides:
handleMouseClickedin classTool- Parameters:
e- theMouseEditEventisActive- whether this tool is currently active
-
handleTouchStart
Description copied from class:ToolInvoked when a touch started.- Overrides:
handleTouchStartin classTool- Parameters:
e- theTouchEditEventisActive- whether this tool is currently active
-
handleKeyPressed
Description copied from class:ToolInvoked when a key has been pressed. See the class description forKeyEventfor a definition of a key pressed event.- Overrides:
handleKeyPressedin classTool- Parameters:
e- theMouseEditEventisActive- whether this tool is currently active
-
getActivationClickCount
public int getActivationClickCount()Returns the current activation click count (left mouse button).- Returns:
- the click count
-
setActivationClickCount
public void setActivationClickCount(int activationClickCount) Sets the activation click count to the desired value.Default: 2 (double click with left mouse button)
- Parameters:
activationClickCount- how many left mouse button hits count as "click"?
-