Package org.gephi.preview.spi
Interface PreviewMouseListener
-
public interface PreviewMouseListener
Listener for mouse events in Preview.
Listeners will always receive left mouse button events. Right button is reserved for zooming and moving the canvas
In order to enable a
PreviewMouseListener
, annotate it withServiceProvider
annotation and implementMouseResponsiveRenderer
in aRenderer
and return true for the listener in theneedsPreviewMouseListener
method.- Author:
- Eduardo Ramos
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
mouseClicked(PreviewMouseEvent event, PreviewProperties properties, Workspace workspace)
A single click event.void
mouseDragged(PreviewMouseEvent event, PreviewProperties properties, Workspace workspace)
If your listener needs to receive drag events, you must mark the previous press event as consumed.void
mousePressed(PreviewMouseEvent event, PreviewProperties properties, Workspace workspace)
A mouse press event.void
mouseReleased(PreviewMouseEvent event, PreviewProperties properties, Workspace workspace)
If your listener needs to receive release events, you must mark the previous press event as consumed.
-
-
-
Method Detail
-
mouseClicked
void mouseClicked(PreviewMouseEvent event, PreviewProperties properties, Workspace workspace)
A single click event.- Parameters:
event
- Mouse eventproperties
- Preview properties for the workspaceworkspace
- Current workspace
-
mousePressed
void mousePressed(PreviewMouseEvent event, PreviewProperties properties, Workspace workspace)
A mouse press event. If your listener needs to receive drag or release events, you must mark the previous press event as consumed.- Parameters:
event
- Mouse eventproperties
- Preview properties for the workspaceworkspace
- Current workspace
-
mouseDragged
void mouseDragged(PreviewMouseEvent event, PreviewProperties properties, Workspace workspace)
If your listener needs to receive drag events, you must mark the previous press event as consumed.- Parameters:
event
- Mouse eventproperties
- Preview properties for the workspaceworkspace
- Current workspace
-
mouseReleased
void mouseReleased(PreviewMouseEvent event, PreviewProperties properties, Workspace workspace)
If your listener needs to receive release events, you must mark the previous press event as consumed.- Parameters:
event
- Mouse eventproperties
- Preview properties for the workspaceworkspace
- Current workspace
-
-