class MouseInput
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
private IntSet |
buttons |
private static int |
DRAG_DROP |
private static int |
DRAG_ENTER |
private static int |
DRAG_LEAVE |
private static int |
DRAG_OVER |
private java.util.BitSet |
dragActions
What drag actions have been performed?
|
private int |
dragButton
What button started the drag operation?
|
private boolean |
dragInProgress
Are we currently processing drag and drop?
|
private MonocleView |
dragView
On what View is the drag operation currently over?
|
private static MouseInput |
instance |
private MouseState |
state |
Constructor and Description |
---|
MouseInput() |
Modifier and Type | Method and Description |
---|---|
(package private) static MouseInput |
getInstance() |
(package private) void |
getState(MouseState result)
Retrieves the current state of mouse buttons and of the cursor.
|
(package private) void |
notifyDragStart() |
private void |
notifyMouse(MonocleView view,
int eventType,
int button,
int relX,
int relY,
int x,
int y,
int modifiers,
boolean isPopupTrigger,
boolean synthesized) |
private void |
postMouseEvent(MonocleView view,
int eventType,
int button,
int relX,
int relY,
int x,
int y,
int modifiers,
boolean isPopupTrigger,
boolean synthesized) |
(package private) void |
setState(MouseState newState,
boolean synthesized)
Sets a new state for mouse buttons and coordinates, generating input
events where appropriate.
|
private static MouseInput instance
private MouseState state
private IntSet buttons
private boolean dragInProgress
private int dragButton
private MonocleView dragView
private java.util.BitSet dragActions
private static final int DRAG_ENTER
private static final int DRAG_LEAVE
private static final int DRAG_OVER
private static final int DRAG_DROP
static MouseInput getInstance()
void getState(MouseState result)
result
- a MouseState to which to copy data on the current mouse
buttons and coordinates.void setState(MouseState newState, boolean synthesized)
newState
- the new statesynthesized
- true if this state change is synthesized from a change
in touch state; false if this state change comes from
an actual relative pointing devices or from the Glass
robot.private void postMouseEvent(MonocleView view, int eventType, int button, int relX, int relY, int x, int y, int modifiers, boolean isPopupTrigger, boolean synthesized)
private void notifyMouse(MonocleView view, int eventType, int button, int relX, int relY, int x, int y, int modifiers, boolean isPopupTrigger, boolean synthesized)
void notifyDragStart()