fix texture id bug, few gestures bugs solved

This commit is contained in:
2017-05-12 01:30:56 +01:00
parent 6f785c1944
commit 6dbb8bf3a1
9 changed files with 58 additions and 26 deletions

View File

@@ -15,19 +15,8 @@ public:
static ActionManager I;
std::stack<std::unique_ptr<Action>> m_actions;
size_t m_memory = 0;
static void add(Action* action)
{
I.m_actions.emplace(action);
I.m_memory += action->memory();
LOG("History: %.2f KB", I.m_memory / 1024.f);
}
static void undo()
{
I.m_actions.top()->undo();
I.m_memory -= I.m_actions.top()->memory();
I.m_actions.pop();
LOG("History: %.2f KB", I.m_memory / 1024.f);
}
static void add(Action* action);
static void undo();
static bool empty()
{
return I.m_actions.empty();