Taxonomy Categories:
Member Functions:
Interface Category:
API.
Inherits From:
TCanvasRectDragInteractor
Inherited By:
None.
Purpose:
Interactor to manage standard GrafEdit selection. Standard selection works as follows. Mouse down on a graphic selects it after first deselecting any prior selection. Shift-select adds the graphic to any prior selection. Mouse down on an empty part of the canvas begins drag-through selection. During drag-through selection, a rubberband rectangle is stretched from the location of mouse down to each mouse move location until the mouse button is released. At this point all graphics that are completely contained in the rectangle are selected after first deselecting any prior selection. Shift-drag-through select adds graphics in the rectangle to any prior selection. A special case of drag-through selection is clicking on an empty portion of the canvas. This deselects all graphics because the result is an empty rectangle that contains no graphics.
Instantiation:
Allocate on the heap or the stack.
Deriving Classes:
Intended to be used as is but can also be derived.
Concurrency:
Not multithread safe.
Resource Use:
No special requirements.
TCanvasSelectionInteractor (MCanvasSelection * adoptInitialSelection, MToolHandler *, TCanvasView *)
Interface Category:
API.
Purpose:
Constructs from a selection alias, tool handler alias, and view alias.
Calling Context:
Called to create a new interactor.
Parameters:
- MCanvasSelection * adoptInitialSelection -An alias to the current selection that will be changed as the result of the interaction.
- MToolHandler * -An alias to the application's tool handler.
- TCanvasView * -An alias to the canvas view.
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
virtual ~ TCanvasSelectionInteractor ()
Interface Category:
API.
Purpose:
Destructor.
Calling Context:
Called to destroy an object.
Parameters:
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
virtual void StartInteraction ()
Interface Category:
API.
Purpose:
Override to define what happens at the beginning of the drag interaction (upon mouse down).
Calling Context:
Called by the Graphics Editing framework.
Parameters:
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
This function should not concern clients who use the interactor.
virtual void EndInteraction ()
Interface Category:
API.
Purpose:
Override to define what happens at the end of the drag interaction (upon mouse up).
Calling Context:
Called by the Graphics Editing framework.
Parameters:
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
This function should not concern clients who use the interactor.
virtual bool MouseMoved (TMouseMovedEvent &)
Interface Category:
API.
Purpose:
Handles the mouse-moved event in the context of selection interacation.
Calling Context:
Called by the Mouse Input framework. Clients do not call this function. Derived classes must call the base class implementation.
Parameters:
Return Value:
Returns true because the mouse-moved event is always handled.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
virtual void ContinueInteraction ()
Interface Category:
API.
Purpose:
Override to define what happens as interaction continues.
Calling Context:
Called by the Graphics Editing framework.
Parameters:
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
This function should not concern clients who use the interactor.
Click the icon to mail questions or corrections about this material to Taligent personnel.
Copyright©1995 Taligent,Inc. All rights reserved.