public class NoteLayer extends AbstractModifiableLayer implements java.awt.event.MouseListener
Layer.LayerAction, Layer.LayerGpxExportAction, Layer.LayerSaveAction, Layer.LayerSaveAsAction, Layer.MultiLayerAction, Layer.SeparatorLayerAction| Modifier and Type | Field and Description |
|---|---|
private NoteData |
noteData |
ICON_SIZE, NAME_PROP, OPACITY_PROP, propertyChangeSupport, VISIBLE_PROP| Constructor and Description |
|---|
NoteLayer()
Convenience constructor that creates a layer with an empty note list
|
NoteLayer(java.util.List<Note> notes,
java.lang.String name)
Create a new note layer with a set of notes
|
| Modifier and Type | Method and Description |
|---|---|
javax.swing.Icon |
getIcon()
Return a representative small image for this layer.
|
java.lang.Object |
getInfoComponent() |
javax.swing.Action[] |
getMenuEntries()
Returns list of actions.
|
NoteData |
getNoteData()
Returns the note data store being used by this layer
|
java.lang.String |
getToolTipText() |
private void |
init() |
boolean |
isMergable(Layer other) |
boolean |
isModified()
Determines if data managed by this layer has been modified.
|
void |
mergeFrom(Layer from)
Merges the given layer into this layer.
|
void |
mouseClicked(java.awt.event.MouseEvent e) |
void |
mouseEntered(java.awt.event.MouseEvent e) |
void |
mouseExited(java.awt.event.MouseEvent e) |
void |
mousePressed(java.awt.event.MouseEvent e) |
void |
mouseReleased(java.awt.event.MouseEvent e) |
void |
paint(java.awt.Graphics2D g,
MapView mv,
Bounds box)
Paint the dataset using the engine set.
|
boolean |
requiresUploadToServer()
Determines if the data managed by this layer needs to be uploaded to
the server because it contains modified data.
|
void |
visitBoundingBox(BoundingXYVisitor v) |
createUploadTask, getUploadDialog, isUploadDiscouraged, onPostSaveToFile, onPostUploadToServer, requiresSaveToFileaddPropertyChangeListener, checkSaveConditions, createAndOpenSaveFileChooser, destroy, fireOpacityChanged, fireVisibleChanged, getAssociatedFile, getColor, getName, getOpacity, hookUpMapView, isBackgroundLayer, isChanged, isInfoResizable, isProjectionSupported, isSavable, isVisible, nameSupportedProjections, onPostLoadFromFile, projectionChanged, removePropertyChangeListener, setAssociatedFile, setBackgroundLayer, setName, setOpacity, setVisible, toggleVisiblepublic NoteLayer(java.util.List<Note> notes, java.lang.String name)
notes - A list of notes to show in this layername - The name of the layer. Typically "Notes"public NoteLayer()
private void init()
public NoteData getNoteData()
public boolean isModified()
AbstractModifiableLayerisModified in class AbstractModifiableLayerpublic boolean requiresUploadToServer()
AbstractModifiableLayerrequiresUploadToServer in class AbstractModifiableLayerpublic void paint(java.awt.Graphics2D g, MapView mv, Bounds box)
Layerpaint in interface MapViewPaintablepaint in class Layermv - The object that can translate GeoPoints to screen coordinates.public javax.swing.Icon getIcon()
Layerpublic java.lang.String getToolTipText()
getToolTipText in class Layerpublic void mergeFrom(Layer from)
Layerpublic boolean isMergable(Layer other)
isMergable in class Layerother - The other layer that is tested to be mergable with this.public void visitBoundingBox(BoundingXYVisitor v)
visitBoundingBox in class Layerpublic java.lang.Object getInfoComponent()
getInfoComponent in class Layerpublic javax.swing.Action[] getMenuEntries()
LayergetMenuEntries in class Layerpublic void mouseClicked(java.awt.event.MouseEvent e)
mouseClicked in interface java.awt.event.MouseListenerpublic void mousePressed(java.awt.event.MouseEvent e)
mousePressed in interface java.awt.event.MouseListenerpublic void mouseReleased(java.awt.event.MouseEvent e)
mouseReleased in interface java.awt.event.MouseListenerpublic void mouseEntered(java.awt.event.MouseEvent e)
mouseEntered in interface java.awt.event.MouseListenerpublic void mouseExited(java.awt.event.MouseEvent e)
mouseExited in interface java.awt.event.MouseListener