summaryrefslogtreecommitdiffstats
path: root/qt-ui/mainwindow.h
diff options
context:
space:
mode:
authorGravatar Grace Karanja <gracie.karanja89@gmail.com>2015-02-09 09:24:32 +0100
committerGravatar Dirk Hohndel <dirk@hohndel.org>2015-02-09 21:02:13 -0800
commitc5138b2090e50cf76a51af1c561a31b5e01485db (patch)
tree1b1673e4b9b9cddc95d693776c89e49a84ca0b03 /qt-ui/mainwindow.h
parent853dfa66735db874cc16688e6fd9ad9320474e37 (diff)
downloadsubsurface-c5138b2090e50cf76a51af1c561a31b5e01485db.tar.gz
Add menu entries for undo/redo
Add an edit menu with undo and redo submenus, and connect them to the UndoBuffer class. The submenus are only enabled when needed. Signed-off-by: Grace Karanja <gracie.karanja89@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'qt-ui/mainwindow.h')
-rw-r--r--qt-ui/mainwindow.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/qt-ui/mainwindow.h b/qt-ui/mainwindow.h
index 2364caadc..641c9ec9b 100644
--- a/qt-ui/mainwindow.h
+++ b/qt-ui/mainwindow.h
@@ -30,6 +30,7 @@ class QWebView;
class QSettings;
class UpdateManager;
class UserManual;
+class UndoBuffer;
enum MainWindowTitleFormat {
MWTF_DEFAULT,
@@ -82,6 +83,7 @@ public:
void setPlanNotes(const char *notes);
void printPlan();
void checkSurvey(QSettings *s);
+ UndoBuffer *undoBuffer;
private
slots:
/* file menu action */
@@ -151,6 +153,9 @@ slots:
void on_paste_triggered();
void on_actionFilterTags_triggered();
void on_actionConfigure_Dive_Computer_triggered();
+ void on_action_Undo_triggered();
+ void on_action_Redo_triggered();
+ void checkForUndoAndRedo();
protected:
void closeEvent(QCloseEvent *);