various small code cleanups and improvements

Largely refactoring work to make the code somewhat nicer to work with.
This commit is contained in:
itsmattkc
2019-12-26 19:00:08 +11:00
parent 83077c939e
commit 61c60e00d6
87 changed files with 596 additions and 567 deletions
+1 -3
View File
@@ -20,9 +20,7 @@
#include "undostack.h"
OliveUndoStack olive::undo_stack;
void OliveUndoStack::pushIfHasChildren(QUndoCommand *command)
void UndoStack::pushIfHasChildren(QUndoCommand *command)
{
if (command->childCount() > 0) {
push(command);
+1 -8
View File
@@ -23,7 +23,7 @@
#include <QUndoStack>
class OliveUndoStack : public QUndoStack {
class UndoStack : public QUndoStack {
public:
/**
* @brief A wrapper for push() that either pushes if the command has children or deletes if not
@@ -33,11 +33,4 @@ public:
void pushIfHasChildren(QUndoCommand* command);
};
namespace olive {
/**
* @brief A static undo stack for undoable commands throughout Olive
*/
extern OliveUndoStack undo_stack;
}
#endif // UNDOSTACK_H