Envision
A visual programming IDE for object-oriented languages
|
Public Types | |
using | CommentCreationFunction = std::function< Model::Node *()> |
enum | CursorMoveOrientation { NoOrientation , VerticalOrientation , HorizontalOrientation } |
Public Member Functions | |
virtual void | action (Visualization::Item *target, const QString &action) |
ActionPrompt * | actionPrompt () |
void | addCommand (Command *command) |
virtual void | beforeEvent (Visualization::Item *target, QEvent *event) override |
virtual void | command (Visualization::Item *target, const QString &command, const std::unique_ptr< Visualization::Cursor > &cursor) override |
const QList< Command * > & | commands () |
TODO: Commands are not inherited when the handler is inherited. More... | |
virtual void | focusInEvent (Visualization::Item *target, QFocusEvent *event) override |
virtual void | keyPressEvent (Visualization::Item *target, QKeyEvent *event) override |
virtual void | mouseDoubleClickEvent (Visualization::Item *target, QGraphicsSceneMouseEvent *event) override |
virtual void | mouseMoveEvent (Visualization::Item *target, QGraphicsSceneMouseEvent *event) override |
virtual void | mousePressEvent (Visualization::Item *target, QGraphicsSceneMouseEvent *event) override |
virtual void | mouseReleaseEvent (Visualization::Item *target, QGraphicsSceneMouseEvent *event) override |
void | removeActionPrompt () |
bool | removeFromList (Visualization::Item *target) |
Removes the node visualized by target from the list which contains it. More... | |
void | showActionPrompt (Visualization::Item *actionRecevier, bool autoExecuteAction) |
void | toggleComment (Visualization::Item *itemWithComment, Model::Node *aNode, bool hideOnly) |
virtual void | wheelEvent (Visualization::Item *target, QGraphicsSceneWheelEvent *event) override |
Public Member Functions inherited from Visualization::InteractionHandler | |
virtual | ~InteractionHandler () |
virtual void | afterEvent (Item *target, QEvent *event) |
virtual void | command (Item *target, const QString &command, const std::unique_ptr< Cursor > &cursor) |
virtual void | contextMenuEvent (Item *target, QGraphicsSceneContextMenuEvent *event) |
virtual void | dragEnterEvent (Item *target, QGraphicsSceneDragDropEvent *event) |
virtual void | dragLeaveEvent (Item *target, QGraphicsSceneDragDropEvent *event) |
virtual void | dragMoveEvent (Item *target, QGraphicsSceneDragDropEvent *event) |
virtual void | dropEvent (Item *target, QGraphicsSceneDragDropEvent *event) |
virtual void | focusOutEvent (Item *target, QFocusEvent *event) |
virtual void | hoverEnterEvent (Item *target, QGraphicsSceneHoverEvent *event) |
virtual void | hoverLeaveEvent (Item *target, QGraphicsSceneHoverEvent *event) |
virtual void | hoverMoveEvent (Item *target, QGraphicsSceneHoverEvent *event) |
virtual void | keyReleaseEvent (Item *target, QKeyEvent *event) |
Static Public Member Functions | |
static CommandExecutionEngine * | executionEngine () |
static void | fixCursorPositionForUndoAfterTreeManagerChange () |
static GenericHandler * | instance () |
static void | setCommandExecutionEngine (CommandExecutionEngine *engine) |
static void | setCommentCreationFunction (CommentCreationFunction f) |
Static Public Member Functions inherited from Visualization::InteractionHandler | |
static InteractionHandler * | instance () |
static bool | isClick (Item *target) |
static bool | isDrag (Item *target) |
Protected Member Functions | |
GenericHandler () | |
virtual void | filterSelectedItems (Visualization::Item *target, QGraphicsSceneMouseEvent *event) |
bool | moveCursor (Visualization::Item *target, int key) |
Protected Member Functions inherited from Visualization::InteractionHandler | |
InteractionHandler () | |
Static Private Member Functions | |
static GenericHandlerManagerListener & | managerListener () |
static void | recordCursorPosition (Visualization::Item *target) |
static void | resetCursorOrigin () |
Private Attributes | |
QList< Command * > | supportedCommands |
Static Private Attributes | |
static ActionPrompt * | actionPrompt_ {} |
static CommentCreationFunction | createComment_ {} |
static CursorMoveOrientation | cursorMoveOrientation_ = NoOrientation |
static QRect | cursorOrigin_ |
static QList< QPair< Visualization::Item *, QPoint > > | cursorPositionsForUndo_ {} |
static int | cursorUndoIndex_ {-1} |
static CommandExecutionEngine * | executionEngine_ = CommandExecutionEngine::instance() |
static QHash< int, QPoint > | keyToViewItemIndexMap_ |
static QPair< Visualization::Item *, QPoint > | lastCursorPosition_ |
using Interaction::GenericHandler::CommentCreationFunction = std::function<Model::Node* ()> |
|
protected |
|
virtual |
ActionPrompt * Interaction::GenericHandler::actionPrompt | ( | ) |
|
inline |
|
overridevirtual |
Reimplemented from Visualization::InteractionHandler.
|
overridevirtual |
|
inline |
TODO: Commands are not inherited when the handler is inherited.
Is this right?
|
static |
|
protectedvirtual |
|
static |
|
overridevirtual |
Reimplemented from Visualization::InteractionHandler.
|
static |
|
overridevirtual |
Reimplemented from Visualization::InteractionHandler.
Reimplemented in OOInteraction::HStatementItemList, OOInteraction::HProject, OOInteraction::HModule, OOInteraction::HMethod, OOInteraction::HClass, OOInteraction::HArrayInitializer, Interaction::HPromptShell, Interaction::HWebBrowserItem, Interaction::HViewItem, Interaction::HRootItem, Interaction::HList, Interaction::HInfoNode, Comments::HCommentText, Comments::HCommentFreeNode, Comments::HCommentDiagramShape, Comments::HCommentDiagramConnector, OOInteraction::HStatement, OOInteraction::HReturnStatement, OOInteraction::HLoop, OOInteraction::HKeywordStatement, OOInteraction::HIfStatement, OOInteraction::HFormalArgument, OOInteraction::HForEachStatement, OOInteraction::HExpression, Interaction::HBinaryNode, Interaction::HText, Interaction::HActionPrompt, InformationScripting::HQuery, and Comments::HComment.
|
staticprivate |
|
overridevirtual |
Reimplemented from Visualization::InteractionHandler.
Reimplemented in Interaction::HText, and Interaction::HComposite.
|
overridevirtual |
Reimplemented from Visualization::InteractionHandler.
Reimplemented in Interaction::HWebBrowserItem, Interaction::HRootItem, Interaction::HMovableItem, Comments::HCommentImage, Comments::HCommentDiagramShape, Comments::HCommentDiagram, CodeReview::HCodeReviewOverlay, Interaction::HText, and Interaction::HPositionLayout.
|
overridevirtual |
Reimplemented from Visualization::InteractionHandler.
Reimplemented in VersionControlUI::HObjectPathCrumb, Interaction::HWebBrowserItem, Interaction::HRootItem, Interaction::HMovableItem, Comments::HCommentText, Comments::HCommentImage, Comments::HCommentDiagramShape, Comments::HCommentDiagramConnector, Comments::HCommentDiagram, Interaction::HText, and Interaction::HPositionLayout.
|
overridevirtual |
Reimplemented from Visualization::InteractionHandler.
Reimplemented in VersionControlUI::HObjectPathCrumb, Comments::HCommentImage, Comments::HCommentDiagramShape, Comments::HCommentDiagram, Interaction::HText, and Interaction::HPositionLayout.
|
protected |
|
staticprivate |
void Interaction::GenericHandler::removeActionPrompt | ( | ) |
bool Interaction::GenericHandler::removeFromList | ( | Visualization::Item * | target | ) |
Removes the node visualized by target from the list which contains it.
Returns true if target has a parent of type VList and its list node contains the target node. Otherwise this method does nothing and returns false.
|
staticprivate |
|
static |
|
inlinestatic |
void Interaction::GenericHandler::showActionPrompt | ( | Visualization::Item * | actionRecevier, |
bool | autoExecuteAction | ||
) |
void Interaction::GenericHandler::toggleComment | ( | Visualization::Item * | itemWithComment, |
Model::Node * | aNode, | ||
bool | hideOnly | ||
) |
|
overridevirtual |
Reimplemented from Visualization::InteractionHandler.
|
staticprivate |
|
staticprivate |
|
staticprivate |
|
staticprivate |
|
staticprivate |
|
staticprivate |
|
staticprivate |
|
staticprivate |
|
staticprivate |
|
private |