hades.gui
Class SelectAllCommand

java.lang.Object
  extended byjava.util.EventObject
      extended byhades.gui.Command
          extended byhades.gui.SelectAllCommand
All Implemented Interfaces:
java.awt.event.ActionListener, java.util.EventListener, FigCanvasListener, java.awt.event.KeyListener, java.awt.event.MouseListener, java.awt.event.MouseMotionListener, java.io.Serializable

public class SelectAllCommand
extends Command

SelectAllCommand - select all visible objects on the Hades editor canvas: this includes SimObject's symbols, Signal's wire segments and solder dots, and other FigObjects.

See Also:
Serialized Form

Field Summary
(package private)  ObjectCanvas canvas
           
 
Fields inherited from class hades.gui.Command
console, debug, editor, ready, versionString
 
Fields inherited from class java.util.EventObject
source
 
Constructor Summary
SelectAllCommand(Editor editor)
           
 
Method Summary
 void execute()
          execute(): add all visible editor objects to the editor's Selection.
 java.lang.String getDescription()
           
 void mousePressed(FigCanvasEvent ME)
          extract the screen and world coordinates of this Event, and dispatch to setPosition().
 void setPosition(java.awt.Point SP, java.awt.Point WP)
          note that 'select all' does not require any mouse coords.
 java.lang.String toString()
           
 void undo()
          undo(): do nothing but print a warning.
 
Methods inherited from class hades.gui.Command
actionPerformed, cancel, dbg, getLogExtraArguments, initialize, isReady, keyPressed, keyReleased, keyTyped, message, mouseClicked, mouseDragged, mouseEntered, mouseExited, mouseMoved, mousePressed, mouseReleased, statusMessage, writePositionLogMessage
 
Methods inherited from class java.util.EventObject
getSource
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

canvas

ObjectCanvas canvas
Constructor Detail

SelectAllCommand

public SelectAllCommand(Editor editor)
Method Detail

execute

public void execute()
execute(): add all visible editor objects to the editor's Selection. Unlike other commands, this command is not registered with the UndoStack. Instead, use a DeselectAllCommand to undo a SelectAll.

Overrides:
execute in class Command

undo

public void undo()
undo(): do nothing but print a warning.

In general, it is not useful to undo a SelectAllCommand, because all previous selection status has been lost. Instead, use a DeselectAllCommand to deselect objects.

Overrides:
undo in class Command

mousePressed

public void mousePressed(FigCanvasEvent ME)
extract the screen and world coordinates of this Event, and dispatch to setPosition().

Specified by:
mousePressed in interface FigCanvasListener
Overrides:
mousePressed in class Command

setPosition

public void setPosition(java.awt.Point SP,
                        java.awt.Point WP)
note that 'select all' does not require any mouse coords.

Overrides:
setPosition in class Command

toString

public java.lang.String toString()
Overrides:
toString in class Command

getDescription

public java.lang.String getDescription()
Overrides:
getDescription in class Command