20 package net.sf.gridarta.gui.mapuserlistener;
22 import java.util.IdentityHashMap;
34 import org.jetbrains.annotations.NotNull;
35 import org.jetbrains.annotations.Nullable;
74 public void mapCreated(@NotNull
final MapControl<G, A, R> mapControl,
final boolean interactive) {
100 mapUserListeners.put(mapView, mapMouseListener);
106 assert mapMouseListener != null;
127 mapManager.addMapManagerListener(mapManagerListener);
void addMapViewsListener(@NotNull final MapControl< G, A, R > mapControl, @NotNull final MapViewsListener< G, A, R > listener)
Adds a MapViewsListener to be notified of events.
void removeMapViewsListener(@NotNull final MapControl< G, A, R > mapControl, @NotNull final MapViewsListener< G, A, R > listener)
Removes a MapViewsListener to be notified of events.
A MapManager manages all opened maps.
final MapManagerListener< G, A, R > mapManagerListener
The MapManagerListener for tracking MapControl instances.
Graphical User Interface of Gridarta.
final Map< MapView< G, A, R >, MapMouseListener< G, A, R > > mapUserListeners
Maps MapView instance to attached MapMouseListener.
Tracks map views and attaches/detaches MapMouseListener instances.
Stores all existing MapViews.
void closeNotify()
Must be called when this object is freed.
Base package of all Gridarta classes.
final ToolPalette< G, A, R > toolPalette
The ToolPalette to attach to.
void addMapManager(@NotNull final MapManager< G, A, R > mapManager)
Registers a MapManager to track.
Reflects a game object (object on a map).
Interface for listeners listening to MapManager changes.
GameObjects are the objects based on Archetypes found on maps.
Tracks mouse actions and calls the appropriate MouseOpListeners.
final MapViewsListener< G, A, R > mapViewsListener
The MapViewsListener attached to all MapControl instances.
Base classes for rendering maps.
Interface for listeners interested in MapViewsManager related events.
Currently nothing more than a marker interface for unification.
A map view consists of a map grid and a map cursor, and is attached to a map control.
MapUserListenerManager(@NotNull final ToolPalette< G, A, R > toolPalette, @NotNull final MapViewsManager< G, A, R > mapViewsManager)
Creates a new instance.
final MapViewsManager< G, A, R > mapViewsManager
The MapViewsManager.
Interface for MapArchObjects.