public class MouseToolManager
extends java.lang.Object
implements java.awt.event.MouseListener, java.awt.event.MouseMotionListener
| Modifier and Type | Class and Description |
|---|---|
private static class |
MouseToolManager.StackEntry |
| Modifier and Type | Field and Description |
|---|---|
static int |
EVENT_DRAG |
static int |
EVENT_LEFTCLICK |
static int |
EVENT_LEFTDOUBLECLICK |
static int |
EVENT_LEFTPRESS |
static int |
EVENT_LEFTRELEASE |
static int |
EVENT_MOVE |
static int |
EVENT_RIGHTCLICK |
static int |
EVENT_RIGHTDOUBLECLICK |
static int |
EVENT_RIGHTPRESS |
static int |
EVENT_RIGHTRELEASE |
static int |
EVENTS_LEFTDRAG |
static int |
EVENTS_RIGHTDRAG |
private MouseTool |
lockedTool |
static int |
MASK_CONTROL |
static int |
MASK_SHIFT |
private TopicMapGraphPanel |
panel |
private java.util.ArrayList<MouseToolManager.StackEntry> |
toolStack |
| Constructor and Description |
|---|
MouseToolManager(TopicMapGraphPanel panel)
Creates a new instance of MouseToolManager
|
| Modifier and Type | Method and Description |
|---|---|
void |
addTool(int events,
int modifiers,
MouseTool tool) |
void |
addTool(int events,
MouseTool tool) |
void |
clearToolStack() |
private boolean |
dispatchEvent(java.awt.event.MouseEvent e,
int event,
MouseTool tool) |
boolean |
lockTool(MouseTool tool) |
void |
mouseClicked(java.awt.event.MouseEvent e) |
void |
mouseDragged(java.awt.event.MouseEvent e) |
void |
mouseEntered(java.awt.event.MouseEvent e) |
void |
mouseExited(java.awt.event.MouseEvent e) |
void |
mouseMoved(java.awt.event.MouseEvent e) |
void |
mousePressed(java.awt.event.MouseEvent e) |
void |
mouseReleased(java.awt.event.MouseEvent e) |
void |
paint(java.awt.Graphics2D g2) |
void |
processEvent(java.awt.event.MouseEvent e,
int event) |
void |
releaseLockedTool() |
void |
updateCursor(int modifiers,
int x,
int y) |
public static final int EVENT_LEFTCLICK
public static final int EVENT_RIGHTCLICK
public static final int EVENT_LEFTDOUBLECLICK
public static final int EVENT_RIGHTDOUBLECLICK
public static final int EVENT_LEFTPRESS
public static final int EVENT_RIGHTPRESS
public static final int EVENT_LEFTRELEASE
public static final int EVENT_RIGHTRELEASE
public static final int EVENT_DRAG
public static final int EVENT_MOVE
public static final int EVENTS_LEFTDRAG
public static final int EVENTS_RIGHTDRAG
public static final int MASK_SHIFT
public static final int MASK_CONTROL
private java.util.ArrayList<MouseToolManager.StackEntry> toolStack
private MouseTool lockedTool
private TopicMapGraphPanel panel
public MouseToolManager(TopicMapGraphPanel panel)
public void addTool(int events,
MouseTool tool)
public void addTool(int events,
int modifiers,
MouseTool tool)
public boolean lockTool(MouseTool tool)
public void releaseLockedTool()
public void clearToolStack()
public void updateCursor(int modifiers,
int x,
int y)
public void paint(java.awt.Graphics2D g2)
private boolean dispatchEvent(java.awt.event.MouseEvent e,
int event,
MouseTool tool)
public void processEvent(java.awt.event.MouseEvent e,
int event)
public void mouseReleased(java.awt.event.MouseEvent e)
mouseReleased in interface java.awt.event.MouseListenerpublic void mousePressed(java.awt.event.MouseEvent e)
mousePressed in interface java.awt.event.MouseListenerpublic void mouseExited(java.awt.event.MouseEvent e)
mouseExited in interface java.awt.event.MouseListenerpublic void mouseEntered(java.awt.event.MouseEvent e)
mouseEntered in interface java.awt.event.MouseListenerpublic void mouseClicked(java.awt.event.MouseEvent e)
mouseClicked in interface java.awt.event.MouseListenerpublic void mouseMoved(java.awt.event.MouseEvent e)
mouseMoved in interface java.awt.event.MouseMotionListenerpublic void mouseDragged(java.awt.event.MouseEvent e)
mouseDragged in interface java.awt.event.MouseMotionListenerCopyright 2004-2015 Wandora Team