Class ALcdGXYNewControllerModel2

java.lang.Object
com.luciad.view.gxy.controller.ALcdGXYNewControllerModel2
All Implemented Interfaces:
ILcdUndoableSource
Direct Known Subclasses:
ALcdAPP6AGXYNewControllerModel, ALcdMS2525bGXYNewControllerModel, ALcyGXYNewControllerModel

public abstract class ALcdGXYNewControllerModel2 extends Object implements ILcdUndoableSource
Contains the logic for creating objects on an ILcdGXYView.

Once a defining position is decided upon (e.g. by a mouse click), the method getGXYLayer is called to retrieve a relevant layer and a new, uninitialized object is created using the method create.

Further initialization steps (e.g. by a mouse click), are executed by the method edit, which by default delegates the real work to the ILcdGXYEditor of the object. Finally, when the creation finishes, the commit method ensures that the object is added to a model and/or layer. From this moment on, visualization of and interaction with the object is typically handed over to the layer.

While the creation process is ongoing (e.g., the user is moving the mouse), the objects are not edited all the time, they are just painted in their temporary state. The method paint takes care of this. This method is typically invoked often (e.g. on mouse move) while the creation process is ongoing.

At all times - before an edit, during an edit or after an edit - the correct mouse cursor is provided by the method mouseCursor.

This controller model fires undoable events for every edit step by reusing the undoable events fired by the ILcdGXYEditors, or by cloning the object if the editor does not implement ILcdUndoableSource.

Since:
9.0
See Also: