Template class for selection context.
Template helper to build selection contexts.
#include <MTemplateManipulator.h>
Public Member Functions | |
MTemplateSelectionContext () | |
Constructor. | |
virtual | ~MTemplateSelectionContext () |
Destructor. | |
virtual void | toolOnSetup (MEvent &event) |
Sets up a active list modified message which will trigger manipulator create/delete operations. | |
virtual void | toolOffCleanup () |
Removes the callback. | |
virtual void | namesOfAttributes (MStringArray &namesOfAttributes) |
Override to specify which attributes are required on the selected geometry. | |
virtual void | setInitialState () |
Override to set manipulator initial state. | |
bool | validGeometrySelected () |
Ensure that valid geometry is selected. | |
Static Public Member Functions | |
static void | updateManipulators (void *data) |
Callback that creates the manipulator if valid geometry is selected. |
virtual void toolOnSetup | ( | MEvent & | event | ) | [inline, virtual] |
Sets up a active list modified message which will trigger manipulator create/delete operations.
[in] | event | The event hat triggered it. |
Reimplemented from MPxContext.
virtual void namesOfAttributes | ( | MStringArray & | namesOfAttributes | ) | [inline, virtual] |
Override to specify which attributes are required on the selected geometry.
[in] | namesOfAttributes | Array of attribute names. |
virtual void setInitialState | ( | ) | [inline, virtual] |
Override to set manipulator initial state.
static void updateManipulators | ( | void * | data | ) | [inline, static] |
Callback that creates the manipulator if valid geometry is selected.
Also removes the manipulator if no geometry is selected. Handles connecting the manipulator to multiply selected nodes.
[in] | data | Pointer to the current context class. |