public class SelectionAdapter extends Objectimplements MouseListener , MouseMotionListener , MouseUser , PaintListener , MapWindowChangeListener
| Constructor and Description |
|---|
SelectionAdapter(Viewer
Create a SelectionAdapter for the given viewer.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addSelectionChangeListener(SelectionChangeListener
Add a listener that get informed on changes of the selections.
|
void |
changed()
|
void |
clearSelection()
|
GeographicSelection |
getGeographicSelection()
|
boolean |
getMouseActive()
|
IntSelection |
getSelection()
|
boolean |
isSnapSelection()
|
void |
mouseClicked(MouseEvent
|
void |
mouseDragged(MouseEvent
|
void |
mouseEntered(MouseEvent
|
void |
mouseExited(MouseEvent
|
void |
mouseMoved(MouseEvent
|
void |
mousePressed(MouseEvent
|
void |
mouseReleased(MouseEvent
|
void |
onPaint(TileMapWindow
|
void |
removeSelectionChangeListener(SelectionChangeListener
Remove a listener from the list of selection listeners.
|
void |
setGeographicSelection(GeographicSelection
Set the current geographic selection
|
void |
setMouseActive(boolean state)
|
void |
setSnapSelection(boolean b)
|
public SelectionAdapter(Viewerviewer)
viewer - the viewer to wrap
public boolean getMouseActive()
public void setMouseActive(boolean state)
public void mouseClicked(MouseEvente)
public void mousePressed(MouseEvente)
public void mouseReleased(MouseEvente)
public void mouseEntered(MouseEvente)
public void mouseExited(MouseEvente)
public void mouseDragged(MouseEvente)
public void mouseMoved(MouseEvente)
public void onPaint(TileMapWindowmapWindow, Graphics g)
public IntSelectiongetSelection()
public GeographicSelectiongetGeographicSelection()
public void setGeographicSelection(GeographicSelectiondegrees)
degrees - the new selection.
public void clearSelection()
public void changed()
public boolean isSnapSelection()
public void setSnapSelection(boolean b)
b - whether the selection should snap to the map.
public void addSelectionChangeListener(SelectionChangeListenerlistener)
listener - the listener to add.
public void removeSelectionChangeListener(SelectionChangeListenerlistener)
listener - the listener to remove.