implemented keyframe type changing
Implemented the UI to change a keyframe's type along with the ValueChanged signals that should result.
This commit is contained in:
@@ -1,6 +1,19 @@
|
||||
#include "keyframeviewundo.h"
|
||||
|
||||
KeyframeViewUndo::KeyframeViewUndo()
|
||||
KeyframeSetTypeCommand::KeyframeSetTypeCommand(NodeKeyframePtr key, NodeKeyframe::Type type, QUndoCommand *parent) :
|
||||
QUndoCommand(parent),
|
||||
key_(key),
|
||||
old_type_(key->type()),
|
||||
new_type_(type)
|
||||
{
|
||||
}
|
||||
|
||||
void KeyframeSetTypeCommand::redo()
|
||||
{
|
||||
key_->set_type(new_type_);
|
||||
}
|
||||
|
||||
void KeyframeSetTypeCommand::undo()
|
||||
{
|
||||
key_->set_type(old_type_);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user