public class DefaultMouseManager
extends java.lang.Object
implements org.graphstream.ui.view.util.MouseManager, android.view.View.OnTouchListener
Modifier and Type | Field and Description |
---|---|
protected android.content.Context |
context |
protected org.graphstream.ui.graphicGraph.GraphicElement |
curElement |
protected android.view.ScaleGestureDetector |
gestureManager
Manager to detect gesture (pinch)
and the context needed
|
protected org.graphstream.ui.graphicGraph.GraphicGraph |
graph
The graph to modify according to the view actions.
|
protected org.graphstream.ui.view.View |
view
The view this manager operates upon.
|
protected float |
x1 |
protected float |
x2 |
protected float |
y1 |
protected float |
y2 |
Constructor and Description |
---|
DefaultMouseManager() |
DefaultMouseManager(java.util.EnumSet<org.graphstream.ui.view.util.InteractiveElement> types) |
Modifier and Type | Method and Description |
---|---|
protected void |
elementMoving(org.graphstream.ui.graphicGraph.GraphicElement element,
android.view.MotionEvent event) |
java.util.EnumSet<org.graphstream.ui.view.util.InteractiveElement> |
getManagedTypes() |
void |
init(org.graphstream.ui.graphicGraph.GraphicGraph graph,
org.graphstream.ui.view.View view) |
void |
initContext(android.content.Context context) |
protected void |
mouseButtonPress(android.view.MotionEvent event) |
protected void |
mouseButtonPressOnElement(org.graphstream.ui.graphicGraph.GraphicElement element,
android.view.MotionEvent event) |
protected void |
mouseButtonRelease(android.view.MotionEvent event,
java.lang.Iterable<org.graphstream.ui.graphicGraph.GraphicElement> elementsInArea) |
protected void |
mouseButtonReleaseOffElement(org.graphstream.ui.graphicGraph.GraphicElement element,
android.view.MotionEvent event) |
boolean |
onTouch(android.view.View v,
android.view.MotionEvent event) |
void |
release() |
protected org.graphstream.ui.view.View view
protected org.graphstream.ui.graphicGraph.GraphicGraph graph
protected org.graphstream.ui.graphicGraph.GraphicElement curElement
protected float x1
protected float x2
protected float y1
protected float y2
protected android.view.ScaleGestureDetector gestureManager
protected android.content.Context context
public DefaultMouseManager()
public DefaultMouseManager(java.util.EnumSet<org.graphstream.ui.view.util.InteractiveElement> types)
public void init(org.graphstream.ui.graphicGraph.GraphicGraph graph, org.graphstream.ui.view.View view)
init
in interface org.graphstream.ui.view.util.MouseManager
public void initContext(android.content.Context context)
public java.util.EnumSet<org.graphstream.ui.view.util.InteractiveElement> getManagedTypes()
getManagedTypes
in interface org.graphstream.ui.view.util.MouseManager
public void release()
release
in interface org.graphstream.ui.view.util.MouseManager
public boolean onTouch(android.view.View v, android.view.MotionEvent event)
onTouch
in interface android.view.View.OnTouchListener
protected void mouseButtonPress(android.view.MotionEvent event)
protected void mouseButtonRelease(android.view.MotionEvent event, java.lang.Iterable<org.graphstream.ui.graphicGraph.GraphicElement> elementsInArea)
protected void mouseButtonPressOnElement(org.graphstream.ui.graphicGraph.GraphicElement element, android.view.MotionEvent event)
protected void elementMoving(org.graphstream.ui.graphicGraph.GraphicElement element, android.view.MotionEvent event)
protected void mouseButtonReleaseOffElement(org.graphstream.ui.graphicGraph.GraphicElement element, android.view.MotionEvent event)