Gridarta Editor
net.sf.gridarta.action.ArchAttributesAction< G extends GameObject< G, A, R, A extends MapArchObject< A, R extends Archetype< G, A, R > Class Template Reference

An EditorAction that opens the game object attributes dialog for the currently selected game object. More...

+ Inheritance diagram for net.sf.gridarta.action.ArchAttributesAction< G extends GameObject< G, A, R, A extends MapArchObject< A, R extends Archetype< G, A, R >:
+ Collaboration diagram for net.sf.gridarta.action.ArchAttributesAction< G extends GameObject< G, A, R, A extends MapArchObject< A, R extends Archetype< G, A, R >:

Public Member Functions

void activeMapViewChanged (@Nullable final MapView< G, A, R > mapView)
 This event handler is called when the current map view has changed. More...
 
void archAttributes ()
 Action method for "arch attributes". More...
 
 ArchAttributesAction (@NotNull final GameObjectAttributesDialogFactory< G, A, R > gameObjectAttributesDialogFactory)
 Creates a new instance. More...
 
void mapCursorChangedGameObject (@Nullable final MapSquare< G, A, R > mapSquare, @Nullable final G gameObject)
 Called whenever the selected game object has changed. More...
 
void mapCursorChangedMode ()
 This event handler is called when MapCursor changes mode (drag, select). More...
 
void mapCursorChangedPos (@NotNull final Point location)
 This event handler is called when MapCursor has moved. More...
 
void mapCursorChangedSize ()
 Called whenever the map cursor's map grid size has changed. More...
 
void mapViewClosing (@NotNull final MapView< G, A, R > mapView)
 This event handler is called when a map view is to be closed. More...
 
void mapViewCreated (@NotNull final MapView< G, A, R > mapView)
 This event handler is called when a map view was created. More...
 
void setAction (@NotNull final Action action, @NotNull final String name)
 Sets the Action instance for this editor action. More...
 

Private Member Functions

boolean doArchAttributes (final boolean performAction)
 Executes the "arch attributes" action. More...
 
void updateActions ()
 Updates the enabled state of action. More...
 

Private Attributes

Action action
 The associated Action. More...
 
MapView< G, A, R > currentMapView
 The active map view, or. More...
 
final GameObjectAttributesDialogFactory< G, A, R > gameObjectAttributesDialogFactory
 The factory for creating game object attributes dialog instances. More...
 

Detailed Description

An EditorAction that opens the game object attributes dialog for the currently selected game object.

Author
Andreas Kirschbaum

Definition at line 43 of file ArchAttributesAction.java.

Constructor & Destructor Documentation

◆ ArchAttributesAction()

net.sf.gridarta.action.ArchAttributesAction< G extends GameObject< G, A, R, A extends MapArchObject< A, R extends Archetype< G, A, R >.ArchAttributesAction ( @NotNull final GameObjectAttributesDialogFactory< G, A, R >  gameObjectAttributesDialogFactory)

Member Function Documentation

◆ activeMapViewChanged()

void net.sf.gridarta.action.ArchAttributesAction< G extends GameObject< G, A, R, A extends MapArchObject< A, R extends Archetype< G, A, R >.activeMapViewChanged ( @Nullable final MapView< G, A, R >  mapView)

This event handler is called when the current map view has changed.

Parameters
mapViewthe new map view or
null
if no opened map view exists

Implements net.sf.gridarta.gui.map.mapview.MapViewManagerListener< G extends GameObject< G, A, R, A extends MapArchObject< A, R extends Archetype< G, A, R >.

Definition at line 121 of file ArchAttributesAction.java.

References net.sf.gridarta.action.ArchAttributesAction< G extends GameObject< G, A, R, A extends MapArchObject< A, R extends Archetype< G, A, R >.updateActions().

+ Here is the call graph for this function:

◆ archAttributes()

void net.sf.gridarta.action.ArchAttributesAction< G extends GameObject< G, A, R, A extends MapArchObject< A, R extends Archetype< G, A, R >.archAttributes ( )

Action method for "arch attributes".

Definition at line 78 of file ArchAttributesAction.java.

References net.sf.gridarta.action.ArchAttributesAction< G extends GameObject< G, A, R, A extends MapArchObject< A, R extends Archetype< G, A, R >.doArchAttributes().

+ Here is the call graph for this function:

◆ doArchAttributes()

◆ mapCursorChangedGameObject()

void net.sf.gridarta.action.ArchAttributesAction< G extends GameObject< G, A, R, A extends MapArchObject< A, R extends Archetype< G, A, R >.mapCursorChangedGameObject ( @Nullable final MapSquare< G, A, R >  mapSquare,
@Nullable final G  gameObject 
)

Called whenever the selected game object has changed.

This function is not called if mapCursorChangedPos(Point) occurs concurrently.

Parameters
mapSquarethe newly selected map square or
null
if no map square is selected
gameObjectthe newly selected game object or
null
if no game object is selected

Implements net.sf.gridarta.model.mapcursor.MapCursorListener< G extends GameObject< G, A, R, A extends MapArchObject< A, R extends Archetype< G, A, R >.

Definition at line 147 of file ArchAttributesAction.java.

◆ mapCursorChangedMode()

void net.sf.gridarta.action.ArchAttributesAction< G extends GameObject< G, A, R, A extends MapArchObject< A, R extends Archetype< G, A, R >.mapCursorChangedMode ( )

◆ mapCursorChangedPos()

void net.sf.gridarta.action.ArchAttributesAction< G extends GameObject< G, A, R, A extends MapArchObject< A, R extends Archetype< G, A, R >.mapCursorChangedPos ( @NotNull final Point  location)

◆ mapCursorChangedSize()

void net.sf.gridarta.action.ArchAttributesAction< G extends GameObject< G, A, R, A extends MapArchObject< A, R extends Archetype< G, A, R >.mapCursorChangedSize ( )

◆ mapViewClosing()

void net.sf.gridarta.action.ArchAttributesAction< G extends GameObject< G, A, R, A extends MapArchObject< A, R extends Archetype< G, A, R >.mapViewClosing ( @NotNull final MapView< G, A, R >  mapView)

This event handler is called when a map view is to be closed.

Parameters
mapViewthe map view that is to be closed

Implements net.sf.gridarta.gui.map.mapview.MapViewManagerListener< G extends GameObject< G, A, R, A extends MapArchObject< A, R extends Archetype< G, A, R >.

Definition at line 132 of file ArchAttributesAction.java.

◆ mapViewCreated()

void net.sf.gridarta.action.ArchAttributesAction< G extends GameObject< G, A, R, A extends MapArchObject< A, R extends Archetype< G, A, R >.mapViewCreated ( @NotNull final MapView< G, A, R >  mapView)

This event handler is called when a map view was created.

Parameters
mapViewthe created map view

Implements net.sf.gridarta.gui.map.mapview.MapViewManagerListener< G extends GameObject< G, A, R, A extends MapArchObject< A, R extends Archetype< G, A, R >.

Definition at line 127 of file ArchAttributesAction.java.

◆ setAction()

void net.sf.gridarta.action.ArchAttributesAction< G extends GameObject< G, A, R, A extends MapArchObject< A, R extends Archetype< G, A, R >.setAction ( @NotNull final Action  action,
@NotNull final String  name 
)

Sets the Action instance for this editor action.

Parameters
actionthe action instance
namethe name of the action

Implements net.sf.gridarta.utils.EditorAction.

Definition at line 83 of file ArchAttributesAction.java.

References net.sf.gridarta.action.ArchAttributesAction< G extends GameObject< G, A, R, A extends MapArchObject< A, R extends Archetype< G, A, R >.action.

◆ updateActions()

Member Data Documentation

◆ action

Action net.sf.gridarta.action.ArchAttributesAction< G extends GameObject< G, A, R, A extends MapArchObject< A, R extends Archetype< G, A, R >.action
private

◆ currentMapView

MapView<G, A, R> net.sf.gridarta.action.ArchAttributesAction< G extends GameObject< G, A, R, A extends MapArchObject< A, R extends Archetype< G, A, R >.currentMapView
private

The active map view, or.

null

if no map view exists.

Definition at line 55 of file ArchAttributesAction.java.

◆ gameObjectAttributesDialogFactory

final GameObjectAttributesDialogFactory<G, A, R> net.sf.gridarta.action.ArchAttributesAction< G extends GameObject< G, A, R, A extends MapArchObject< A, R extends Archetype< G, A, R >.gameObjectAttributesDialogFactory
private

The documentation for this class was generated from the following file: