Skip to content

DIWNE::Actions::EditorAction

Helper class for actions that require an explicit reference to the NodeEditor they are active in.

#include "DIWNE/Core/diwne_actions.h"

Inherits from DIWNE::Actions::DiwneAction

Inherited by DIWNE::Actions::DragNodeAction

Public Functions

Name
EditorAction(NodeEditor & editor, const std::string & name, const std::shared_ptr< DiwneObject > & source)

Public Attributes

Name
NodeEditor &editor

Additional inherited members

Public Functions inherited from DIWNE::Actions::DiwneAction

Name
DiwneAction(const std::string & name, const std::shared_ptr< DiwneObject > & source)
virtual~DiwneAction() =default
voidend()<br>Marks the action to end at the end of the next frame.
boolhasSameSource(const DiwneAction & action) const<br>Checks whether the source of this and another action are the same.
boolisSource(const DiwneObject * object) const<br>Checks whether passed object is the source of this action (eg. the object that started it.
virtual voidonEnd()<br>Called at the end of the frame after the frame in which the action has ended. Called after onFrameEnd().
virtual voidonFrameEnd()<br>Called at the end of each frame the action is active for, called before onEnd() on the last frame.

Public Attributes inherited from DIWNE::Actions::DiwneAction

Name
std::stringname
std::weak_ptr< DiwneObject >source

Friends inherited from DIWNE::Actions::DiwneAction

Name
classDIWNE::InteractionState

Public Functions Documentation

function EditorAction

cpp
inline EditorAction(
    NodeEditor & editor,
    const std::string & name,
    const std::shared_ptr< DiwneObject > & source
)
inline EditorAction(
    NodeEditor & editor,
    const std::string & name,
    const std::shared_ptr< DiwneObject > & source
)

Public Attributes Documentation

variable editor

cpp
NodeEditor & editor;
NodeEditor & editor;

Updated on 2025-05-31 at 12:55:31 +0000