mirror of
https://github.com/aseprite/aseprite.git
synced 2025-03-17 13:20:45 +00:00
Add some logging in debug mode for Cmd() members
This commit is contained in:
parent
5b05c23722
commit
ec2ef30f20
@ -26,6 +26,7 @@ Cmd::~Cmd()
|
||||
|
||||
void Cmd::execute(Context* ctx)
|
||||
{
|
||||
DLOG("Cmd: Executing cmd '%s'\n", typeid(*this).name());
|
||||
ASSERT(m_state == State::NotExecuted);
|
||||
|
||||
m_ctx = ctx;
|
||||
@ -40,6 +41,7 @@ void Cmd::execute(Context* ctx)
|
||||
|
||||
void Cmd::undo()
|
||||
{
|
||||
DLOG("Cmd: Undo cmd '%s'\n", typeid(*this).name());
|
||||
ASSERT(m_state == State::Executed || m_state == State::Redone);
|
||||
|
||||
onUndo();
|
||||
@ -52,6 +54,7 @@ void Cmd::undo()
|
||||
|
||||
void Cmd::redo()
|
||||
{
|
||||
DLOG("Cmd: Redo cmd '%s'\n", typeid(*this).name());
|
||||
ASSERT(m_state == State::Undone);
|
||||
|
||||
onRedo();
|
||||
|
Loading…
x
Reference in New Issue
Block a user