summaryrefslogtreecommitdiffstats
path: root/desktop-widgets/CMakeLists.txt
diff options
context:
space:
mode:
authorGravatar Tomaz Canabrava <tcanabrava@kde.org>2017-04-04 19:21:30 +0200
committerGravatar Dirk Hohndel <dirk@hohndel.org>2017-04-06 18:23:25 -0700
commit1fc4fba69fed8607d9b961086a88bcf362a482a5 (patch)
treed063efda90ddcd0324f648ab4be48d2282f5c1ff /desktop-widgets/CMakeLists.txt
parent8a71196e4e58dfb3534fda5f00856a0223726689 (diff)
downloadsubsurface-1fc4fba69fed8607d9b961086a88bcf362a482a5.tar.gz
Break down MainTab into smaller classes
Maintab is one of our most complex classes, and it's something I'm not actually proud of. But it currently works and the idea of splitting it was in my head for quite a while. This is the third or fourth tentative of splitting it, and this time I let the most complex part of it untouched, the Notes and Equipment tab are way too complex to untangle right now on my limited time. A new class 'TabBase' should be used for any new tab that we may create, and added on the MainTab (see the new lines on the MainTab constructor). Also, Extra Info, Information, Photos and Statistics where ported to this new way helping reduce the number of lines and functions on the MainTab quite a bit. Overall this is a step in the right direction for the future. Signed-off-by: Tomaz Canabrava <tcanabrava@kde.org> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'desktop-widgets/CMakeLists.txt')
-rw-r--r--desktop-widgets/CMakeLists.txt13
1 files changed, 11 insertions, 2 deletions
diff --git a/desktop-widgets/CMakeLists.txt b/desktop-widgets/CMakeLists.txt
index 0e7601196..2cf6382dd 100644
--- a/desktop-widgets/CMakeLists.txt
+++ b/desktop-widgets/CMakeLists.txt
@@ -36,7 +36,6 @@ set (SUBSURFACE_UI
filterwidget.ui
listfilter.ui
locationInformation.ui
- maintab.ui
mainwindow.ui
plannerDetails.ui
plannerSettings.ui
@@ -51,6 +50,11 @@ set (SUBSURFACE_UI
urldialog.ui
usersurvey.ui
webservices.ui
+ tab-widgets/maintab.ui
+ tab-widgets/TabDiveStatistics.ui
+ tab-widgets/TabDiveInformation.ui
+ tab-widgets/TabDivePhotos.ui
+ tab-widgets/TabDiveExtraInfo.ui
)
# the interface, in C++
@@ -64,7 +68,6 @@ set(SUBSURFACE_INTERFACE
downloadfromdivecomputer.cpp
globe.cpp
kmessagewidget.cpp
- maintab.cpp
mainwindow.cpp
modeldelegates.cpp
notificationwidget.cpp
@@ -82,6 +85,12 @@ set(SUBSURFACE_INTERFACE
undocommands.cpp
locationinformation.cpp
qtwaitingspinner.cpp
+ tab-widgets/TabDiveStatistics.cpp
+ tab-widgets/TabDiveInformation.cpp
+ tab-widgets/TabDivePhotos.cpp
+ tab-widgets/TabDiveExtraInfo.cpp
+ tab-widgets/maintab.cpp
+ tab-widgets/TabBase.cpp
)
if(NOT NO_USERMANUAL)