diff options
author | Berthold Stoeger <bstoeger@mail.tuwien.ac.at> | 2018-05-03 19:19:54 +0200 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2018-05-13 07:08:34 -0700 |
commit | 57bf174c4f0092d25865b7f15b864c9bbaa45eda (patch) | |
tree | b535cea18d651ec3a665c7b6f1aefa015f695a4e /desktop-widgets/mainwindow.h | |
parent | 9d342d0e1aac56c44a80e5025d4cf3b89c5746cf (diff) | |
download | subsurface-57bf174c4f0092d25865b7f15b864c9bbaa45eda.tar.gz |
Desktop: On dive edit from the dive list or map, switch to new state
If "Edit dive" is selected from the dive list or the map view, switch
to a new mode, which shows the dive infos and the profile.
After the edit, switch back to the previous state.
Fixes #1213
Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
Diffstat (limited to 'desktop-widgets/mainwindow.h')
-rw-r--r-- | desktop-widgets/mainwindow.h | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/desktop-widgets/mainwindow.h b/desktop-widgets/mainwindow.h index 03ebcf636..3a9848f62 100644 --- a/desktop-widgets/mainwindow.h +++ b/desktop-widgets/mainwindow.h @@ -54,7 +54,8 @@ public: MAP_MAXIMIZED, INFO_MAXIMIZED, PROFILE_MAXIMIZED, - LIST_MAXIMIZED + LIST_MAXIMIZED, + EDIT }; MainWindow(); @@ -87,6 +88,8 @@ public: NotificationWidget *getNotificationWidget(); void enableDisableCloudActions(); void setCheckedActionFilterTags(bool checked); + void enterEditState(); + void exitEditState(); private slots: @@ -190,6 +193,7 @@ private: QAction *actionPreviousDive; UserManual *helpView; CurrentState state; + CurrentState stateBeforeEdit; QString filter_open(); QString filter_import(); static MainWindow *m_Instance; @@ -210,6 +214,7 @@ private: QString lastUsedDir(); void updateLastUsedDir(const QString &s); void registerApplicationState(const QByteArray& state, QWidget *topLeft, QWidget *topRight, QWidget *bottomLeft, QWidget *bottomRight); + void enterState(CurrentState); bool filesAsArguments; UpdateManager *updateManager; |