From e49d6213ad129284a45d53c3fcdc03249e84efe2 Mon Sep 17 00:00:00 2001 From: Tomaz Canabrava Date: Thu, 3 Sep 2015 14:20:19 -0300 Subject: [PATCH] Move qt-ui to desktop-widgets Since we have now destkop and mobile versions, 'qt-ui' was a very poor name choice for a folder that contains only destkop-enabled widgets. Also, move the graphicsview-common.h/cpp to subsurface-core because it doesn't depend on qgraphicsview, it merely implements all the colors that we use throughout Subsurface, and we will use colors on both desktop and mobile versions Same thing applies for metrics.h/cpp Signed-off-by: Tomaz Canabrava Signed-off-by: Dirk Hohndel --- CMakeLists.txt | 8 +- {qt-ui => desktop-widgets}/CMakeLists.txt | 2 - {qt-ui => desktop-widgets}/about.cpp | 0 {qt-ui => desktop-widgets}/about.h | 0 {qt-ui => desktop-widgets}/about.ui | 0 .../btdeviceselectiondialog.cpp | 0 .../btdeviceselectiondialog.h | 0 .../btdeviceselectiondialog.ui | 0 .../configuredivecomputerdialog.cpp | 0 .../configuredivecomputerdialog.h | 0 .../configuredivecomputerdialog.ui | 0 {qt-ui => desktop-widgets}/css/tableviews.css | 0 .../divecomponentselection.ui | 0 .../divecomputermanagementdialog.cpp | 0 .../divecomputermanagementdialog.h | 0 .../divecomputermanagementdialog.ui | 0 {qt-ui => desktop-widgets}/divelistview.cpp | 0 {qt-ui => desktop-widgets}/divelistview.h | 0 .../divelogexportdialog.cpp | 0 .../divelogexportdialog.h | 0 .../divelogexportdialog.ui | 0 .../divelogimportdialog.cpp | 0 .../divelogimportdialog.h | 0 .../divelogimportdialog.ui | 0 .../divepicturewidget.cpp | 0 .../divepicturewidget.h | 0 {qt-ui => desktop-widgets}/diveplanner.cpp | 0 {qt-ui => desktop-widgets}/diveplanner.h | 0 {qt-ui => desktop-widgets}/diveplanner.ui | 0 .../diveshareexportdialog.cpp | 0 .../diveshareexportdialog.h | 0 .../diveshareexportdialog.ui | 0 .../downloadfromdivecomputer.cpp | 0 .../downloadfromdivecomputer.h | 0 .../downloadfromdivecomputer.ui | 0 {qt-ui => desktop-widgets}/filterwidget.ui | 0 {qt-ui => desktop-widgets}/globe.cpp | 0 {qt-ui => desktop-widgets}/globe.h | 0 .../groupedlineedit.cpp | 0 {qt-ui => desktop-widgets}/groupedlineedit.h | 0 {qt-ui => desktop-widgets}/kmessagewidget.cpp | 0 {qt-ui => desktop-widgets}/kmessagewidget.h | 0 {qt-ui => desktop-widgets}/listfilter.ui | 0 .../locationInformation.ui | 0 .../locationinformation.cpp | 0 .../locationinformation.h | 0 {qt-ui => desktop-widgets}/maintab.cpp | 0 {qt-ui => desktop-widgets}/maintab.h | 0 {qt-ui => desktop-widgets}/maintab.ui | 6 +- {qt-ui => desktop-widgets}/mainwindow.cpp | 1 + {qt-ui => desktop-widgets}/mainwindow.h | 0 {qt-ui => desktop-widgets}/mainwindow.ui | 0 .../marble/GeoDataTreeModel.h | 0 {qt-ui => desktop-widgets}/modeldelegates.cpp | 0 {qt-ui => desktop-widgets}/modeldelegates.h | 0 .../notificationwidget.cpp | 0 .../notificationwidget.h | 0 {qt-ui => desktop-widgets}/plannerDetails.ui | 0 {qt-ui => desktop-widgets}/plannerSettings.ui | 0 {qt-ui => desktop-widgets}/preferences.cpp | 0 {qt-ui => desktop-widgets}/preferences.h | 0 {qt-ui => desktop-widgets}/preferences.ui | 0 {qt-ui => desktop-widgets}/printdialog.cpp | 0 {qt-ui => desktop-widgets}/printdialog.h | 0 {qt-ui => desktop-widgets}/printer.cpp | 0 {qt-ui => desktop-widgets}/printer.h | 0 {qt-ui => desktop-widgets}/printoptions.cpp | 0 {qt-ui => desktop-widgets}/printoptions.h | 0 {qt-ui => desktop-widgets}/printoptions.ui | 0 .../profile/animationfunctions.cpp | 0 .../profile/animationfunctions.h | 0 .../profile/divecartesianaxis.cpp | 0 .../profile/divecartesianaxis.h | 2 +- .../profile/diveeventitem.cpp | 0 .../profile/diveeventitem.h | 0 .../profile/divelineitem.cpp | 0 .../profile/divelineitem.h | 0 .../profile/divepixmapitem.cpp | 0 .../profile/divepixmapitem.h | 0 .../profile/diveprofileitem.cpp | 0 .../profile/diveprofileitem.h | 1 - .../profile/diverectitem.cpp | 0 .../profile/diverectitem.h | 0 .../profile/divetextitem.cpp | 3 + .../profile/divetextitem.h | 4 +- .../profile/divetooltipitem.cpp | 0 .../profile/divetooltipitem.h | 0 .../profile/profilewidget2.cpp | 0 .../profile/profilewidget2.h | 1 - .../profile/ruleritem.cpp | 0 .../profile/ruleritem.h | 0 .../profile/tankitem.cpp | 0 {qt-ui => desktop-widgets}/profile/tankitem.h | 0 .../qtwaitingspinner.cpp | 0 {qt-ui => desktop-widgets}/qtwaitingspinner.h | 0 {qt-ui => desktop-widgets}/renumber.ui | 0 {qt-ui => desktop-widgets}/searchbar.ui | 0 {qt-ui => desktop-widgets}/setpoint.ui | 0 {qt-ui => desktop-widgets}/shiftimagetimes.ui | 0 {qt-ui => desktop-widgets}/shifttimes.ui | 0 {qt-ui => desktop-widgets}/simplewidgets.cpp | 0 {qt-ui => desktop-widgets}/simplewidgets.h | 0 {qt-ui => desktop-widgets}/socialnetworks.cpp | 0 {qt-ui => desktop-widgets}/socialnetworks.h | 0 .../socialnetworksdialog.ui | 0 {qt-ui => desktop-widgets}/starwidget.cpp | 0 {qt-ui => desktop-widgets}/starwidget.h | 0 .../statistics/monthstatistics.cpp | 0 .../statistics/monthstatistics.h | 0 .../statistics/statisticsbar.cpp | 0 .../statistics/statisticsbar.h | 0 .../statistics/statisticswidget.cpp | 0 .../statistics/statisticswidget.h | 0 .../statistics/yearstatistics.cpp | 0 .../statistics/yearstatistics.h | 0 .../subsurfacewebservices.cpp | 0 .../subsurfacewebservices.h | 0 {qt-ui => desktop-widgets}/tableview.cpp | 0 {qt-ui => desktop-widgets}/tableview.h | 0 {qt-ui => desktop-widgets}/tableview.ui | 0 {qt-ui => desktop-widgets}/tagwidget.cpp | 0 {qt-ui => desktop-widgets}/tagwidget.h | 0 {qt-ui => desktop-widgets}/templateedit.cpp | 0 {qt-ui => desktop-widgets}/templateedit.h | 0 {qt-ui => desktop-widgets}/templateedit.ui | 0 {qt-ui => desktop-widgets}/templatelayout.cpp | 0 {qt-ui => desktop-widgets}/templatelayout.h | 0 {qt-ui => desktop-widgets}/undocommands.cpp | 0 {qt-ui => desktop-widgets}/undocommands.h | 0 {qt-ui => desktop-widgets}/updatemanager.cpp | 0 {qt-ui => desktop-widgets}/updatemanager.h | 0 {qt-ui => desktop-widgets}/urldialog.ui | 0 {qt-ui => desktop-widgets}/usermanual.cpp | 0 {qt-ui => desktop-widgets}/usermanual.h | 0 {qt-ui => desktop-widgets}/usersurvey.cpp | 0 {qt-ui => desktop-widgets}/usersurvey.h | 0 {qt-ui => desktop-widgets}/usersurvey.ui | 0 {qt-ui => desktop-widgets}/webservices.ui | 0 main.cpp | 6 +- qt-gui.cpp | 2 +- qt-models/diveplotdatamodel.cpp | 2 +- qt-models/filtermodels.cpp | 4 +- qt-ui/graphicsview-common.h | 94 ------------------- subsurface-core/CMakeLists.txt | 2 + .../color.cpp | 2 +- subsurface-core/color.h | 85 +++++++++++++++++ {qt-ui => subsurface-core}/metrics.cpp | 0 {qt-ui => subsurface-core}/metrics.h | 0 148 files changed, 110 insertions(+), 115 deletions(-) rename {qt-ui => desktop-widgets}/CMakeLists.txt (98%) rename {qt-ui => desktop-widgets}/about.cpp (100%) rename {qt-ui => desktop-widgets}/about.h (100%) rename {qt-ui => desktop-widgets}/about.ui (100%) rename {qt-ui => desktop-widgets}/btdeviceselectiondialog.cpp (100%) rename {qt-ui => desktop-widgets}/btdeviceselectiondialog.h (100%) rename {qt-ui => desktop-widgets}/btdeviceselectiondialog.ui (100%) rename {qt-ui => desktop-widgets}/configuredivecomputerdialog.cpp (100%) rename {qt-ui => desktop-widgets}/configuredivecomputerdialog.h (100%) rename {qt-ui => desktop-widgets}/configuredivecomputerdialog.ui (100%) rename {qt-ui => desktop-widgets}/css/tableviews.css (100%) rename {qt-ui => desktop-widgets}/divecomponentselection.ui (100%) rename {qt-ui => desktop-widgets}/divecomputermanagementdialog.cpp (100%) rename {qt-ui => desktop-widgets}/divecomputermanagementdialog.h (100%) rename {qt-ui => desktop-widgets}/divecomputermanagementdialog.ui (100%) rename {qt-ui => desktop-widgets}/divelistview.cpp (100%) rename {qt-ui => desktop-widgets}/divelistview.h (100%) rename {qt-ui => desktop-widgets}/divelogexportdialog.cpp (100%) rename {qt-ui => desktop-widgets}/divelogexportdialog.h (100%) rename {qt-ui => desktop-widgets}/divelogexportdialog.ui (100%) rename {qt-ui => desktop-widgets}/divelogimportdialog.cpp (100%) rename {qt-ui => desktop-widgets}/divelogimportdialog.h (100%) rename {qt-ui => desktop-widgets}/divelogimportdialog.ui (100%) rename {qt-ui => desktop-widgets}/divepicturewidget.cpp (100%) rename {qt-ui => desktop-widgets}/divepicturewidget.h (100%) rename {qt-ui => desktop-widgets}/diveplanner.cpp (100%) rename {qt-ui => desktop-widgets}/diveplanner.h (100%) rename {qt-ui => desktop-widgets}/diveplanner.ui (100%) rename {qt-ui => desktop-widgets}/diveshareexportdialog.cpp (100%) rename {qt-ui => desktop-widgets}/diveshareexportdialog.h (100%) rename {qt-ui => desktop-widgets}/diveshareexportdialog.ui (100%) rename {qt-ui => desktop-widgets}/downloadfromdivecomputer.cpp (100%) rename {qt-ui => desktop-widgets}/downloadfromdivecomputer.h (100%) rename {qt-ui => desktop-widgets}/downloadfromdivecomputer.ui (100%) rename {qt-ui => desktop-widgets}/filterwidget.ui (100%) rename {qt-ui => desktop-widgets}/globe.cpp (100%) rename {qt-ui => desktop-widgets}/globe.h (100%) rename {qt-ui => desktop-widgets}/groupedlineedit.cpp (100%) rename {qt-ui => desktop-widgets}/groupedlineedit.h (100%) rename {qt-ui => desktop-widgets}/kmessagewidget.cpp (100%) rename {qt-ui => desktop-widgets}/kmessagewidget.h (100%) rename {qt-ui => desktop-widgets}/listfilter.ui (100%) rename {qt-ui => desktop-widgets}/locationInformation.ui (100%) rename {qt-ui => desktop-widgets}/locationinformation.cpp (100%) rename {qt-ui => desktop-widgets}/locationinformation.h (100%) rename {qt-ui => desktop-widgets}/maintab.cpp (100%) rename {qt-ui => desktop-widgets}/maintab.h (100%) rename {qt-ui => desktop-widgets}/maintab.ui (99%) rename {qt-ui => desktop-widgets}/mainwindow.cpp (99%) rename {qt-ui => desktop-widgets}/mainwindow.h (100%) rename {qt-ui => desktop-widgets}/mainwindow.ui (100%) rename {qt-ui => desktop-widgets}/marble/GeoDataTreeModel.h (100%) rename {qt-ui => desktop-widgets}/modeldelegates.cpp (100%) rename {qt-ui => desktop-widgets}/modeldelegates.h (100%) rename {qt-ui => desktop-widgets}/notificationwidget.cpp (100%) rename {qt-ui => desktop-widgets}/notificationwidget.h (100%) rename {qt-ui => desktop-widgets}/plannerDetails.ui (100%) rename {qt-ui => desktop-widgets}/plannerSettings.ui (100%) rename {qt-ui => desktop-widgets}/preferences.cpp (100%) rename {qt-ui => desktop-widgets}/preferences.h (100%) rename {qt-ui => desktop-widgets}/preferences.ui (100%) rename {qt-ui => desktop-widgets}/printdialog.cpp (100%) rename {qt-ui => desktop-widgets}/printdialog.h (100%) rename {qt-ui => desktop-widgets}/printer.cpp (100%) rename {qt-ui => desktop-widgets}/printer.h (100%) rename {qt-ui => desktop-widgets}/printoptions.cpp (100%) rename {qt-ui => desktop-widgets}/printoptions.h (100%) rename {qt-ui => desktop-widgets}/printoptions.ui (100%) rename {qt-ui => desktop-widgets}/profile/animationfunctions.cpp (100%) rename {qt-ui => desktop-widgets}/profile/animationfunctions.h (100%) rename {qt-ui => desktop-widgets}/profile/divecartesianaxis.cpp (100%) rename {qt-ui => desktop-widgets}/profile/divecartesianaxis.h (98%) rename {qt-ui => desktop-widgets}/profile/diveeventitem.cpp (100%) rename {qt-ui => desktop-widgets}/profile/diveeventitem.h (100%) rename {qt-ui => desktop-widgets}/profile/divelineitem.cpp (100%) rename {qt-ui => desktop-widgets}/profile/divelineitem.h (100%) rename {qt-ui => desktop-widgets}/profile/divepixmapitem.cpp (100%) rename {qt-ui => desktop-widgets}/profile/divepixmapitem.h (100%) rename {qt-ui => desktop-widgets}/profile/diveprofileitem.cpp (100%) rename {qt-ui => desktop-widgets}/profile/diveprofileitem.h (99%) rename {qt-ui => desktop-widgets}/profile/diverectitem.cpp (100%) rename {qt-ui => desktop-widgets}/profile/diverectitem.h (100%) rename {qt-ui => desktop-widgets}/profile/divetextitem.cpp (98%) rename {qt-ui => desktop-widgets}/profile/divetextitem.h (94%) rename {qt-ui => desktop-widgets}/profile/divetooltipitem.cpp (100%) rename {qt-ui => desktop-widgets}/profile/divetooltipitem.h (100%) rename {qt-ui => desktop-widgets}/profile/profilewidget2.cpp (100%) rename {qt-ui => desktop-widgets}/profile/profilewidget2.h (99%) rename {qt-ui => desktop-widgets}/profile/ruleritem.cpp (100%) rename {qt-ui => desktop-widgets}/profile/ruleritem.h (100%) rename {qt-ui => desktop-widgets}/profile/tankitem.cpp (100%) rename {qt-ui => desktop-widgets}/profile/tankitem.h (100%) rename {qt-ui => desktop-widgets}/qtwaitingspinner.cpp (100%) rename {qt-ui => desktop-widgets}/qtwaitingspinner.h (100%) rename {qt-ui => desktop-widgets}/renumber.ui (100%) rename {qt-ui => desktop-widgets}/searchbar.ui (100%) rename {qt-ui => desktop-widgets}/setpoint.ui (100%) rename {qt-ui => desktop-widgets}/shiftimagetimes.ui (100%) rename {qt-ui => desktop-widgets}/shifttimes.ui (100%) rename {qt-ui => desktop-widgets}/simplewidgets.cpp (100%) rename {qt-ui => desktop-widgets}/simplewidgets.h (100%) rename {qt-ui => desktop-widgets}/socialnetworks.cpp (100%) rename {qt-ui => desktop-widgets}/socialnetworks.h (100%) rename {qt-ui => desktop-widgets}/socialnetworksdialog.ui (100%) rename {qt-ui => desktop-widgets}/starwidget.cpp (100%) rename {qt-ui => desktop-widgets}/starwidget.h (100%) rename {qt-ui => desktop-widgets}/statistics/monthstatistics.cpp (100%) rename {qt-ui => desktop-widgets}/statistics/monthstatistics.h (100%) rename {qt-ui => desktop-widgets}/statistics/statisticsbar.cpp (100%) rename {qt-ui => desktop-widgets}/statistics/statisticsbar.h (100%) rename {qt-ui => desktop-widgets}/statistics/statisticswidget.cpp (100%) rename {qt-ui => desktop-widgets}/statistics/statisticswidget.h (100%) rename {qt-ui => desktop-widgets}/statistics/yearstatistics.cpp (100%) rename {qt-ui => desktop-widgets}/statistics/yearstatistics.h (100%) rename {qt-ui => desktop-widgets}/subsurfacewebservices.cpp (100%) rename {qt-ui => desktop-widgets}/subsurfacewebservices.h (100%) rename {qt-ui => desktop-widgets}/tableview.cpp (100%) rename {qt-ui => desktop-widgets}/tableview.h (100%) rename {qt-ui => desktop-widgets}/tableview.ui (100%) rename {qt-ui => desktop-widgets}/tagwidget.cpp (100%) rename {qt-ui => desktop-widgets}/tagwidget.h (100%) rename {qt-ui => desktop-widgets}/templateedit.cpp (100%) rename {qt-ui => desktop-widgets}/templateedit.h (100%) rename {qt-ui => desktop-widgets}/templateedit.ui (100%) rename {qt-ui => desktop-widgets}/templatelayout.cpp (100%) rename {qt-ui => desktop-widgets}/templatelayout.h (100%) rename {qt-ui => desktop-widgets}/undocommands.cpp (100%) rename {qt-ui => desktop-widgets}/undocommands.h (100%) rename {qt-ui => desktop-widgets}/updatemanager.cpp (100%) rename {qt-ui => desktop-widgets}/updatemanager.h (100%) rename {qt-ui => desktop-widgets}/urldialog.ui (100%) rename {qt-ui => desktop-widgets}/usermanual.cpp (100%) rename {qt-ui => desktop-widgets}/usermanual.h (100%) rename {qt-ui => desktop-widgets}/usersurvey.cpp (100%) rename {qt-ui => desktop-widgets}/usersurvey.h (100%) rename {qt-ui => desktop-widgets}/usersurvey.ui (100%) rename {qt-ui => desktop-widgets}/webservices.ui (100%) delete mode 100644 qt-ui/graphicsview-common.h rename qt-ui/graphicsview-common.cpp => subsurface-core/color.cpp (99%) rename {qt-ui => subsurface-core}/metrics.cpp (100%) rename {qt-ui => subsurface-core}/metrics.h (100%) diff --git a/CMakeLists.txt b/CMakeLists.txt index 7e4e5f53d..74b9d0d94 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -37,10 +37,10 @@ set(CMAKE_MODULE_PATH include_directories(. ${CMAKE_CURRENT_BINARY_DIR} ${CMAKE_BINARY_DIR} - ${CMAKE_BINARY_DIR}/qt-ui - qt-ui + ${CMAKE_BINARY_DIR}/desktop-widgets + desktop-widgets/ qt-models - qt-ui/profile + desktop-widgets/profile subsurface-core/ ) @@ -362,7 +362,7 @@ if(CMAKE_SYSTEM_NAME STREQUAL "Linux" AND NOT ANDROID) set(SUBSURFACE_LINK_LIBRARIES ${SUBSURFACE_LINK_LIBRARIES} -lpthread) endif() -add_subdirectory(qt-ui) +add_subdirectory(desktop-widgets) # create the executables if(SUBSURFACE_MOBILE) diff --git a/qt-ui/CMakeLists.txt b/desktop-widgets/CMakeLists.txt similarity index 98% rename from qt-ui/CMakeLists.txt rename to desktop-widgets/CMakeLists.txt index 45447771a..2c373b83f 100644 --- a/qt-ui/CMakeLists.txt +++ b/desktop-widgets/CMakeLists.txt @@ -23,12 +23,10 @@ set(SUBSURFACE_INTERFACE diveshareexportdialog.cpp downloadfromdivecomputer.cpp globe.cpp - graphicsview-common.cpp kmessagewidget.cpp maintab.cpp mainwindow.cpp modeldelegates.cpp - metrics.cpp notificationwidget.cpp preferences.cpp simplewidgets.cpp diff --git a/qt-ui/about.cpp b/desktop-widgets/about.cpp similarity index 100% rename from qt-ui/about.cpp rename to desktop-widgets/about.cpp diff --git a/qt-ui/about.h b/desktop-widgets/about.h similarity index 100% rename from qt-ui/about.h rename to desktop-widgets/about.h diff --git a/qt-ui/about.ui b/desktop-widgets/about.ui similarity index 100% rename from qt-ui/about.ui rename to desktop-widgets/about.ui diff --git a/qt-ui/btdeviceselectiondialog.cpp b/desktop-widgets/btdeviceselectiondialog.cpp similarity index 100% rename from qt-ui/btdeviceselectiondialog.cpp rename to desktop-widgets/btdeviceselectiondialog.cpp diff --git a/qt-ui/btdeviceselectiondialog.h b/desktop-widgets/btdeviceselectiondialog.h similarity index 100% rename from qt-ui/btdeviceselectiondialog.h rename to desktop-widgets/btdeviceselectiondialog.h diff --git a/qt-ui/btdeviceselectiondialog.ui b/desktop-widgets/btdeviceselectiondialog.ui similarity index 100% rename from qt-ui/btdeviceselectiondialog.ui rename to desktop-widgets/btdeviceselectiondialog.ui diff --git a/qt-ui/configuredivecomputerdialog.cpp b/desktop-widgets/configuredivecomputerdialog.cpp similarity index 100% rename from qt-ui/configuredivecomputerdialog.cpp rename to desktop-widgets/configuredivecomputerdialog.cpp diff --git a/qt-ui/configuredivecomputerdialog.h b/desktop-widgets/configuredivecomputerdialog.h similarity index 100% rename from qt-ui/configuredivecomputerdialog.h rename to desktop-widgets/configuredivecomputerdialog.h diff --git a/qt-ui/configuredivecomputerdialog.ui b/desktop-widgets/configuredivecomputerdialog.ui similarity index 100% rename from qt-ui/configuredivecomputerdialog.ui rename to desktop-widgets/configuredivecomputerdialog.ui diff --git a/qt-ui/css/tableviews.css b/desktop-widgets/css/tableviews.css similarity index 100% rename from qt-ui/css/tableviews.css rename to desktop-widgets/css/tableviews.css diff --git a/qt-ui/divecomponentselection.ui b/desktop-widgets/divecomponentselection.ui similarity index 100% rename from qt-ui/divecomponentselection.ui rename to desktop-widgets/divecomponentselection.ui diff --git a/qt-ui/divecomputermanagementdialog.cpp b/desktop-widgets/divecomputermanagementdialog.cpp similarity index 100% rename from qt-ui/divecomputermanagementdialog.cpp rename to desktop-widgets/divecomputermanagementdialog.cpp diff --git a/qt-ui/divecomputermanagementdialog.h b/desktop-widgets/divecomputermanagementdialog.h similarity index 100% rename from qt-ui/divecomputermanagementdialog.h rename to desktop-widgets/divecomputermanagementdialog.h diff --git a/qt-ui/divecomputermanagementdialog.ui b/desktop-widgets/divecomputermanagementdialog.ui similarity index 100% rename from qt-ui/divecomputermanagementdialog.ui rename to desktop-widgets/divecomputermanagementdialog.ui diff --git a/qt-ui/divelistview.cpp b/desktop-widgets/divelistview.cpp similarity index 100% rename from qt-ui/divelistview.cpp rename to desktop-widgets/divelistview.cpp diff --git a/qt-ui/divelistview.h b/desktop-widgets/divelistview.h similarity index 100% rename from qt-ui/divelistview.h rename to desktop-widgets/divelistview.h diff --git a/qt-ui/divelogexportdialog.cpp b/desktop-widgets/divelogexportdialog.cpp similarity index 100% rename from qt-ui/divelogexportdialog.cpp rename to desktop-widgets/divelogexportdialog.cpp diff --git a/qt-ui/divelogexportdialog.h b/desktop-widgets/divelogexportdialog.h similarity index 100% rename from qt-ui/divelogexportdialog.h rename to desktop-widgets/divelogexportdialog.h diff --git a/qt-ui/divelogexportdialog.ui b/desktop-widgets/divelogexportdialog.ui similarity index 100% rename from qt-ui/divelogexportdialog.ui rename to desktop-widgets/divelogexportdialog.ui diff --git a/qt-ui/divelogimportdialog.cpp b/desktop-widgets/divelogimportdialog.cpp similarity index 100% rename from qt-ui/divelogimportdialog.cpp rename to desktop-widgets/divelogimportdialog.cpp diff --git a/qt-ui/divelogimportdialog.h b/desktop-widgets/divelogimportdialog.h similarity index 100% rename from qt-ui/divelogimportdialog.h rename to desktop-widgets/divelogimportdialog.h diff --git a/qt-ui/divelogimportdialog.ui b/desktop-widgets/divelogimportdialog.ui similarity index 100% rename from qt-ui/divelogimportdialog.ui rename to desktop-widgets/divelogimportdialog.ui diff --git a/qt-ui/divepicturewidget.cpp b/desktop-widgets/divepicturewidget.cpp similarity index 100% rename from qt-ui/divepicturewidget.cpp rename to desktop-widgets/divepicturewidget.cpp diff --git a/qt-ui/divepicturewidget.h b/desktop-widgets/divepicturewidget.h similarity index 100% rename from qt-ui/divepicturewidget.h rename to desktop-widgets/divepicturewidget.h diff --git a/qt-ui/diveplanner.cpp b/desktop-widgets/diveplanner.cpp similarity index 100% rename from qt-ui/diveplanner.cpp rename to desktop-widgets/diveplanner.cpp diff --git a/qt-ui/diveplanner.h b/desktop-widgets/diveplanner.h similarity index 100% rename from qt-ui/diveplanner.h rename to desktop-widgets/diveplanner.h diff --git a/qt-ui/diveplanner.ui b/desktop-widgets/diveplanner.ui similarity index 100% rename from qt-ui/diveplanner.ui rename to desktop-widgets/diveplanner.ui diff --git a/qt-ui/diveshareexportdialog.cpp b/desktop-widgets/diveshareexportdialog.cpp similarity index 100% rename from qt-ui/diveshareexportdialog.cpp rename to desktop-widgets/diveshareexportdialog.cpp diff --git a/qt-ui/diveshareexportdialog.h b/desktop-widgets/diveshareexportdialog.h similarity index 100% rename from qt-ui/diveshareexportdialog.h rename to desktop-widgets/diveshareexportdialog.h diff --git a/qt-ui/diveshareexportdialog.ui b/desktop-widgets/diveshareexportdialog.ui similarity index 100% rename from qt-ui/diveshareexportdialog.ui rename to desktop-widgets/diveshareexportdialog.ui diff --git a/qt-ui/downloadfromdivecomputer.cpp b/desktop-widgets/downloadfromdivecomputer.cpp similarity index 100% rename from qt-ui/downloadfromdivecomputer.cpp rename to desktop-widgets/downloadfromdivecomputer.cpp diff --git a/qt-ui/downloadfromdivecomputer.h b/desktop-widgets/downloadfromdivecomputer.h similarity index 100% rename from qt-ui/downloadfromdivecomputer.h rename to desktop-widgets/downloadfromdivecomputer.h diff --git a/qt-ui/downloadfromdivecomputer.ui b/desktop-widgets/downloadfromdivecomputer.ui similarity index 100% rename from qt-ui/downloadfromdivecomputer.ui rename to desktop-widgets/downloadfromdivecomputer.ui diff --git a/qt-ui/filterwidget.ui b/desktop-widgets/filterwidget.ui similarity index 100% rename from qt-ui/filterwidget.ui rename to desktop-widgets/filterwidget.ui diff --git a/qt-ui/globe.cpp b/desktop-widgets/globe.cpp similarity index 100% rename from qt-ui/globe.cpp rename to desktop-widgets/globe.cpp diff --git a/qt-ui/globe.h b/desktop-widgets/globe.h similarity index 100% rename from qt-ui/globe.h rename to desktop-widgets/globe.h diff --git a/qt-ui/groupedlineedit.cpp b/desktop-widgets/groupedlineedit.cpp similarity index 100% rename from qt-ui/groupedlineedit.cpp rename to desktop-widgets/groupedlineedit.cpp diff --git a/qt-ui/groupedlineedit.h b/desktop-widgets/groupedlineedit.h similarity index 100% rename from qt-ui/groupedlineedit.h rename to desktop-widgets/groupedlineedit.h diff --git a/qt-ui/kmessagewidget.cpp b/desktop-widgets/kmessagewidget.cpp similarity index 100% rename from qt-ui/kmessagewidget.cpp rename to desktop-widgets/kmessagewidget.cpp diff --git a/qt-ui/kmessagewidget.h b/desktop-widgets/kmessagewidget.h similarity index 100% rename from qt-ui/kmessagewidget.h rename to desktop-widgets/kmessagewidget.h diff --git a/qt-ui/listfilter.ui b/desktop-widgets/listfilter.ui similarity index 100% rename from qt-ui/listfilter.ui rename to desktop-widgets/listfilter.ui diff --git a/qt-ui/locationInformation.ui b/desktop-widgets/locationInformation.ui similarity index 100% rename from qt-ui/locationInformation.ui rename to desktop-widgets/locationInformation.ui diff --git a/qt-ui/locationinformation.cpp b/desktop-widgets/locationinformation.cpp similarity index 100% rename from qt-ui/locationinformation.cpp rename to desktop-widgets/locationinformation.cpp diff --git a/qt-ui/locationinformation.h b/desktop-widgets/locationinformation.h similarity index 100% rename from qt-ui/locationinformation.h rename to desktop-widgets/locationinformation.h diff --git a/qt-ui/maintab.cpp b/desktop-widgets/maintab.cpp similarity index 100% rename from qt-ui/maintab.cpp rename to desktop-widgets/maintab.cpp diff --git a/qt-ui/maintab.h b/desktop-widgets/maintab.h similarity index 100% rename from qt-ui/maintab.h rename to desktop-widgets/maintab.h diff --git a/qt-ui/maintab.ui b/desktop-widgets/maintab.ui similarity index 99% rename from qt-ui/maintab.ui rename to desktop-widgets/maintab.ui index 2c515a225..7bc516b1a 100644 --- a/qt-ui/maintab.ui +++ b/desktop-widgets/maintab.ui @@ -525,8 +525,8 @@ 0 0 - 70 - 16 + 445 + 754 @@ -1229,7 +1229,7 @@ TagWidget QPlainTextEdit -
qt-ui/tagwidget.h
+
tagwidget.h
DivePictureWidget diff --git a/qt-ui/mainwindow.cpp b/desktop-widgets/mainwindow.cpp similarity index 99% rename from qt-ui/mainwindow.cpp rename to desktop-widgets/mainwindow.cpp index e0476381f..e1e0d81a2 100644 --- a/qt-ui/mainwindow.cpp +++ b/desktop-widgets/mainwindow.cpp @@ -50,6 +50,7 @@ #include #include #include +#include "subsurface-core/color.h" #if defined(FBSUPPORT) #include "socialnetworks.h" diff --git a/qt-ui/mainwindow.h b/desktop-widgets/mainwindow.h similarity index 100% rename from qt-ui/mainwindow.h rename to desktop-widgets/mainwindow.h diff --git a/qt-ui/mainwindow.ui b/desktop-widgets/mainwindow.ui similarity index 100% rename from qt-ui/mainwindow.ui rename to desktop-widgets/mainwindow.ui diff --git a/qt-ui/marble/GeoDataTreeModel.h b/desktop-widgets/marble/GeoDataTreeModel.h similarity index 100% rename from qt-ui/marble/GeoDataTreeModel.h rename to desktop-widgets/marble/GeoDataTreeModel.h diff --git a/qt-ui/modeldelegates.cpp b/desktop-widgets/modeldelegates.cpp similarity index 100% rename from qt-ui/modeldelegates.cpp rename to desktop-widgets/modeldelegates.cpp diff --git a/qt-ui/modeldelegates.h b/desktop-widgets/modeldelegates.h similarity index 100% rename from qt-ui/modeldelegates.h rename to desktop-widgets/modeldelegates.h diff --git a/qt-ui/notificationwidget.cpp b/desktop-widgets/notificationwidget.cpp similarity index 100% rename from qt-ui/notificationwidget.cpp rename to desktop-widgets/notificationwidget.cpp diff --git a/qt-ui/notificationwidget.h b/desktop-widgets/notificationwidget.h similarity index 100% rename from qt-ui/notificationwidget.h rename to desktop-widgets/notificationwidget.h diff --git a/qt-ui/plannerDetails.ui b/desktop-widgets/plannerDetails.ui similarity index 100% rename from qt-ui/plannerDetails.ui rename to desktop-widgets/plannerDetails.ui diff --git a/qt-ui/plannerSettings.ui b/desktop-widgets/plannerSettings.ui similarity index 100% rename from qt-ui/plannerSettings.ui rename to desktop-widgets/plannerSettings.ui diff --git a/qt-ui/preferences.cpp b/desktop-widgets/preferences.cpp similarity index 100% rename from qt-ui/preferences.cpp rename to desktop-widgets/preferences.cpp diff --git a/qt-ui/preferences.h b/desktop-widgets/preferences.h similarity index 100% rename from qt-ui/preferences.h rename to desktop-widgets/preferences.h diff --git a/qt-ui/preferences.ui b/desktop-widgets/preferences.ui similarity index 100% rename from qt-ui/preferences.ui rename to desktop-widgets/preferences.ui diff --git a/qt-ui/printdialog.cpp b/desktop-widgets/printdialog.cpp similarity index 100% rename from qt-ui/printdialog.cpp rename to desktop-widgets/printdialog.cpp diff --git a/qt-ui/printdialog.h b/desktop-widgets/printdialog.h similarity index 100% rename from qt-ui/printdialog.h rename to desktop-widgets/printdialog.h diff --git a/qt-ui/printer.cpp b/desktop-widgets/printer.cpp similarity index 100% rename from qt-ui/printer.cpp rename to desktop-widgets/printer.cpp diff --git a/qt-ui/printer.h b/desktop-widgets/printer.h similarity index 100% rename from qt-ui/printer.h rename to desktop-widgets/printer.h diff --git a/qt-ui/printoptions.cpp b/desktop-widgets/printoptions.cpp similarity index 100% rename from qt-ui/printoptions.cpp rename to desktop-widgets/printoptions.cpp diff --git a/qt-ui/printoptions.h b/desktop-widgets/printoptions.h similarity index 100% rename from qt-ui/printoptions.h rename to desktop-widgets/printoptions.h diff --git a/qt-ui/printoptions.ui b/desktop-widgets/printoptions.ui similarity index 100% rename from qt-ui/printoptions.ui rename to desktop-widgets/printoptions.ui diff --git a/qt-ui/profile/animationfunctions.cpp b/desktop-widgets/profile/animationfunctions.cpp similarity index 100% rename from qt-ui/profile/animationfunctions.cpp rename to desktop-widgets/profile/animationfunctions.cpp diff --git a/qt-ui/profile/animationfunctions.h b/desktop-widgets/profile/animationfunctions.h similarity index 100% rename from qt-ui/profile/animationfunctions.h rename to desktop-widgets/profile/animationfunctions.h diff --git a/qt-ui/profile/divecartesianaxis.cpp b/desktop-widgets/profile/divecartesianaxis.cpp similarity index 100% rename from qt-ui/profile/divecartesianaxis.cpp rename to desktop-widgets/profile/divecartesianaxis.cpp diff --git a/qt-ui/profile/divecartesianaxis.h b/desktop-widgets/profile/divecartesianaxis.h similarity index 98% rename from qt-ui/profile/divecartesianaxis.h rename to desktop-widgets/profile/divecartesianaxis.h index 27cfa62d8..cc7d0bcf7 100644 --- a/qt-ui/profile/divecartesianaxis.h +++ b/desktop-widgets/profile/divecartesianaxis.h @@ -3,7 +3,7 @@ #include #include -#include +#include "subsurface-core/color.h" class QPropertyAnimation; class DiveTextItem; diff --git a/qt-ui/profile/diveeventitem.cpp b/desktop-widgets/profile/diveeventitem.cpp similarity index 100% rename from qt-ui/profile/diveeventitem.cpp rename to desktop-widgets/profile/diveeventitem.cpp diff --git a/qt-ui/profile/diveeventitem.h b/desktop-widgets/profile/diveeventitem.h similarity index 100% rename from qt-ui/profile/diveeventitem.h rename to desktop-widgets/profile/diveeventitem.h diff --git a/qt-ui/profile/divelineitem.cpp b/desktop-widgets/profile/divelineitem.cpp similarity index 100% rename from qt-ui/profile/divelineitem.cpp rename to desktop-widgets/profile/divelineitem.cpp diff --git a/qt-ui/profile/divelineitem.h b/desktop-widgets/profile/divelineitem.h similarity index 100% rename from qt-ui/profile/divelineitem.h rename to desktop-widgets/profile/divelineitem.h diff --git a/qt-ui/profile/divepixmapitem.cpp b/desktop-widgets/profile/divepixmapitem.cpp similarity index 100% rename from qt-ui/profile/divepixmapitem.cpp rename to desktop-widgets/profile/divepixmapitem.cpp diff --git a/qt-ui/profile/divepixmapitem.h b/desktop-widgets/profile/divepixmapitem.h similarity index 100% rename from qt-ui/profile/divepixmapitem.h rename to desktop-widgets/profile/divepixmapitem.h diff --git a/qt-ui/profile/diveprofileitem.cpp b/desktop-widgets/profile/diveprofileitem.cpp similarity index 100% rename from qt-ui/profile/diveprofileitem.cpp rename to desktop-widgets/profile/diveprofileitem.cpp diff --git a/qt-ui/profile/diveprofileitem.h b/desktop-widgets/profile/diveprofileitem.h similarity index 99% rename from qt-ui/profile/diveprofileitem.h rename to desktop-widgets/profile/diveprofileitem.h index 2160782f7..0bba7f7a3 100644 --- a/qt-ui/profile/diveprofileitem.h +++ b/desktop-widgets/profile/diveprofileitem.h @@ -5,7 +5,6 @@ #include #include -#include "graphicsview-common.h" #include "divelineitem.h" /* This is the Profile Item, it should be used for quite a lot of things diff --git a/qt-ui/profile/diverectitem.cpp b/desktop-widgets/profile/diverectitem.cpp similarity index 100% rename from qt-ui/profile/diverectitem.cpp rename to desktop-widgets/profile/diverectitem.cpp diff --git a/qt-ui/profile/diverectitem.h b/desktop-widgets/profile/diverectitem.h similarity index 100% rename from qt-ui/profile/diverectitem.h rename to desktop-widgets/profile/diverectitem.h diff --git a/qt-ui/profile/divetextitem.cpp b/desktop-widgets/profile/divetextitem.cpp similarity index 98% rename from qt-ui/profile/divetextitem.cpp rename to desktop-widgets/profile/divetextitem.cpp index 9c7848cd4..3bf00d68f 100644 --- a/qt-ui/profile/divetextitem.cpp +++ b/desktop-widgets/profile/divetextitem.cpp @@ -1,6 +1,9 @@ #include "divetextitem.h" #include "mainwindow.h" #include "profilewidget2.h" +#include "subsurface-core/color.h" + +#include DiveTextItem::DiveTextItem(QGraphicsItem *parent) : QGraphicsItemGroup(parent), internalAlignFlags(Qt::AlignHCenter | Qt::AlignVCenter), diff --git a/qt-ui/profile/divetextitem.h b/desktop-widgets/profile/divetextitem.h similarity index 94% rename from qt-ui/profile/divetextitem.h rename to desktop-widgets/profile/divetextitem.h index 3991fe7f3..be0adf292 100644 --- a/qt-ui/profile/divetextitem.h +++ b/desktop-widgets/profile/divetextitem.h @@ -3,8 +3,8 @@ #include #include -#include "graphicsview-common.h" -#include + +class QBrush; /* A Line Item that has animated-properties. */ class DiveTextItem : public QObject, public QGraphicsItemGroup { diff --git a/qt-ui/profile/divetooltipitem.cpp b/desktop-widgets/profile/divetooltipitem.cpp similarity index 100% rename from qt-ui/profile/divetooltipitem.cpp rename to desktop-widgets/profile/divetooltipitem.cpp diff --git a/qt-ui/profile/divetooltipitem.h b/desktop-widgets/profile/divetooltipitem.h similarity index 100% rename from qt-ui/profile/divetooltipitem.h rename to desktop-widgets/profile/divetooltipitem.h diff --git a/qt-ui/profile/profilewidget2.cpp b/desktop-widgets/profile/profilewidget2.cpp similarity index 100% rename from qt-ui/profile/profilewidget2.cpp rename to desktop-widgets/profile/profilewidget2.cpp diff --git a/qt-ui/profile/profilewidget2.h b/desktop-widgets/profile/profilewidget2.h similarity index 99% rename from qt-ui/profile/profilewidget2.h rename to desktop-widgets/profile/profilewidget2.h index 2d1a7bfb4..f11ec5be1 100644 --- a/qt-ui/profile/profilewidget2.h +++ b/desktop-widgets/profile/profilewidget2.h @@ -13,7 +13,6 @@ // * // * It needs to be dynamic, things should *flow* on it, not just appear / disappear. // */ -#include "graphicsview-common.h" #include "divelineitem.h" #include "diveprofileitem.h" #include "display.h" diff --git a/qt-ui/profile/ruleritem.cpp b/desktop-widgets/profile/ruleritem.cpp similarity index 100% rename from qt-ui/profile/ruleritem.cpp rename to desktop-widgets/profile/ruleritem.cpp diff --git a/qt-ui/profile/ruleritem.h b/desktop-widgets/profile/ruleritem.h similarity index 100% rename from qt-ui/profile/ruleritem.h rename to desktop-widgets/profile/ruleritem.h diff --git a/qt-ui/profile/tankitem.cpp b/desktop-widgets/profile/tankitem.cpp similarity index 100% rename from qt-ui/profile/tankitem.cpp rename to desktop-widgets/profile/tankitem.cpp diff --git a/qt-ui/profile/tankitem.h b/desktop-widgets/profile/tankitem.h similarity index 100% rename from qt-ui/profile/tankitem.h rename to desktop-widgets/profile/tankitem.h diff --git a/qt-ui/qtwaitingspinner.cpp b/desktop-widgets/qtwaitingspinner.cpp similarity index 100% rename from qt-ui/qtwaitingspinner.cpp rename to desktop-widgets/qtwaitingspinner.cpp diff --git a/qt-ui/qtwaitingspinner.h b/desktop-widgets/qtwaitingspinner.h similarity index 100% rename from qt-ui/qtwaitingspinner.h rename to desktop-widgets/qtwaitingspinner.h diff --git a/qt-ui/renumber.ui b/desktop-widgets/renumber.ui similarity index 100% rename from qt-ui/renumber.ui rename to desktop-widgets/renumber.ui diff --git a/qt-ui/searchbar.ui b/desktop-widgets/searchbar.ui similarity index 100% rename from qt-ui/searchbar.ui rename to desktop-widgets/searchbar.ui diff --git a/qt-ui/setpoint.ui b/desktop-widgets/setpoint.ui similarity index 100% rename from qt-ui/setpoint.ui rename to desktop-widgets/setpoint.ui diff --git a/qt-ui/shiftimagetimes.ui b/desktop-widgets/shiftimagetimes.ui similarity index 100% rename from qt-ui/shiftimagetimes.ui rename to desktop-widgets/shiftimagetimes.ui diff --git a/qt-ui/shifttimes.ui b/desktop-widgets/shifttimes.ui similarity index 100% rename from qt-ui/shifttimes.ui rename to desktop-widgets/shifttimes.ui diff --git a/qt-ui/simplewidgets.cpp b/desktop-widgets/simplewidgets.cpp similarity index 100% rename from qt-ui/simplewidgets.cpp rename to desktop-widgets/simplewidgets.cpp diff --git a/qt-ui/simplewidgets.h b/desktop-widgets/simplewidgets.h similarity index 100% rename from qt-ui/simplewidgets.h rename to desktop-widgets/simplewidgets.h diff --git a/qt-ui/socialnetworks.cpp b/desktop-widgets/socialnetworks.cpp similarity index 100% rename from qt-ui/socialnetworks.cpp rename to desktop-widgets/socialnetworks.cpp diff --git a/qt-ui/socialnetworks.h b/desktop-widgets/socialnetworks.h similarity index 100% rename from qt-ui/socialnetworks.h rename to desktop-widgets/socialnetworks.h diff --git a/qt-ui/socialnetworksdialog.ui b/desktop-widgets/socialnetworksdialog.ui similarity index 100% rename from qt-ui/socialnetworksdialog.ui rename to desktop-widgets/socialnetworksdialog.ui diff --git a/qt-ui/starwidget.cpp b/desktop-widgets/starwidget.cpp similarity index 100% rename from qt-ui/starwidget.cpp rename to desktop-widgets/starwidget.cpp diff --git a/qt-ui/starwidget.h b/desktop-widgets/starwidget.h similarity index 100% rename from qt-ui/starwidget.h rename to desktop-widgets/starwidget.h diff --git a/qt-ui/statistics/monthstatistics.cpp b/desktop-widgets/statistics/monthstatistics.cpp similarity index 100% rename from qt-ui/statistics/monthstatistics.cpp rename to desktop-widgets/statistics/monthstatistics.cpp diff --git a/qt-ui/statistics/monthstatistics.h b/desktop-widgets/statistics/monthstatistics.h similarity index 100% rename from qt-ui/statistics/monthstatistics.h rename to desktop-widgets/statistics/monthstatistics.h diff --git a/qt-ui/statistics/statisticsbar.cpp b/desktop-widgets/statistics/statisticsbar.cpp similarity index 100% rename from qt-ui/statistics/statisticsbar.cpp rename to desktop-widgets/statistics/statisticsbar.cpp diff --git a/qt-ui/statistics/statisticsbar.h b/desktop-widgets/statistics/statisticsbar.h similarity index 100% rename from qt-ui/statistics/statisticsbar.h rename to desktop-widgets/statistics/statisticsbar.h diff --git a/qt-ui/statistics/statisticswidget.cpp b/desktop-widgets/statistics/statisticswidget.cpp similarity index 100% rename from qt-ui/statistics/statisticswidget.cpp rename to desktop-widgets/statistics/statisticswidget.cpp diff --git a/qt-ui/statistics/statisticswidget.h b/desktop-widgets/statistics/statisticswidget.h similarity index 100% rename from qt-ui/statistics/statisticswidget.h rename to desktop-widgets/statistics/statisticswidget.h diff --git a/qt-ui/statistics/yearstatistics.cpp b/desktop-widgets/statistics/yearstatistics.cpp similarity index 100% rename from qt-ui/statistics/yearstatistics.cpp rename to desktop-widgets/statistics/yearstatistics.cpp diff --git a/qt-ui/statistics/yearstatistics.h b/desktop-widgets/statistics/yearstatistics.h similarity index 100% rename from qt-ui/statistics/yearstatistics.h rename to desktop-widgets/statistics/yearstatistics.h diff --git a/qt-ui/subsurfacewebservices.cpp b/desktop-widgets/subsurfacewebservices.cpp similarity index 100% rename from qt-ui/subsurfacewebservices.cpp rename to desktop-widgets/subsurfacewebservices.cpp diff --git a/qt-ui/subsurfacewebservices.h b/desktop-widgets/subsurfacewebservices.h similarity index 100% rename from qt-ui/subsurfacewebservices.h rename to desktop-widgets/subsurfacewebservices.h diff --git a/qt-ui/tableview.cpp b/desktop-widgets/tableview.cpp similarity index 100% rename from qt-ui/tableview.cpp rename to desktop-widgets/tableview.cpp diff --git a/qt-ui/tableview.h b/desktop-widgets/tableview.h similarity index 100% rename from qt-ui/tableview.h rename to desktop-widgets/tableview.h diff --git a/qt-ui/tableview.ui b/desktop-widgets/tableview.ui similarity index 100% rename from qt-ui/tableview.ui rename to desktop-widgets/tableview.ui diff --git a/qt-ui/tagwidget.cpp b/desktop-widgets/tagwidget.cpp similarity index 100% rename from qt-ui/tagwidget.cpp rename to desktop-widgets/tagwidget.cpp diff --git a/qt-ui/tagwidget.h b/desktop-widgets/tagwidget.h similarity index 100% rename from qt-ui/tagwidget.h rename to desktop-widgets/tagwidget.h diff --git a/qt-ui/templateedit.cpp b/desktop-widgets/templateedit.cpp similarity index 100% rename from qt-ui/templateedit.cpp rename to desktop-widgets/templateedit.cpp diff --git a/qt-ui/templateedit.h b/desktop-widgets/templateedit.h similarity index 100% rename from qt-ui/templateedit.h rename to desktop-widgets/templateedit.h diff --git a/qt-ui/templateedit.ui b/desktop-widgets/templateedit.ui similarity index 100% rename from qt-ui/templateedit.ui rename to desktop-widgets/templateedit.ui diff --git a/qt-ui/templatelayout.cpp b/desktop-widgets/templatelayout.cpp similarity index 100% rename from qt-ui/templatelayout.cpp rename to desktop-widgets/templatelayout.cpp diff --git a/qt-ui/templatelayout.h b/desktop-widgets/templatelayout.h similarity index 100% rename from qt-ui/templatelayout.h rename to desktop-widgets/templatelayout.h diff --git a/qt-ui/undocommands.cpp b/desktop-widgets/undocommands.cpp similarity index 100% rename from qt-ui/undocommands.cpp rename to desktop-widgets/undocommands.cpp diff --git a/qt-ui/undocommands.h b/desktop-widgets/undocommands.h similarity index 100% rename from qt-ui/undocommands.h rename to desktop-widgets/undocommands.h diff --git a/qt-ui/updatemanager.cpp b/desktop-widgets/updatemanager.cpp similarity index 100% rename from qt-ui/updatemanager.cpp rename to desktop-widgets/updatemanager.cpp diff --git a/qt-ui/updatemanager.h b/desktop-widgets/updatemanager.h similarity index 100% rename from qt-ui/updatemanager.h rename to desktop-widgets/updatemanager.h diff --git a/qt-ui/urldialog.ui b/desktop-widgets/urldialog.ui similarity index 100% rename from qt-ui/urldialog.ui rename to desktop-widgets/urldialog.ui diff --git a/qt-ui/usermanual.cpp b/desktop-widgets/usermanual.cpp similarity index 100% rename from qt-ui/usermanual.cpp rename to desktop-widgets/usermanual.cpp diff --git a/qt-ui/usermanual.h b/desktop-widgets/usermanual.h similarity index 100% rename from qt-ui/usermanual.h rename to desktop-widgets/usermanual.h diff --git a/qt-ui/usersurvey.cpp b/desktop-widgets/usersurvey.cpp similarity index 100% rename from qt-ui/usersurvey.cpp rename to desktop-widgets/usersurvey.cpp diff --git a/qt-ui/usersurvey.h b/desktop-widgets/usersurvey.h similarity index 100% rename from qt-ui/usersurvey.h rename to desktop-widgets/usersurvey.h diff --git a/qt-ui/usersurvey.ui b/desktop-widgets/usersurvey.ui similarity index 100% rename from qt-ui/usersurvey.ui rename to desktop-widgets/usersurvey.ui diff --git a/qt-ui/webservices.ui b/desktop-widgets/webservices.ui similarity index 100% rename from qt-ui/webservices.ui rename to desktop-widgets/webservices.ui diff --git a/main.cpp b/main.cpp index 171876abf..e7259c3f3 100644 --- a/main.cpp +++ b/main.cpp @@ -8,9 +8,9 @@ #include "dive.h" #include "qt-gui.h" #include "subsurfacestartup.h" -#include "qt-ui/mainwindow.h" -#include "qt-ui/diveplanner.h" -#include "qt-ui/graphicsview-common.h" +#include "desktop-widgets/mainwindow.h" +#include "desktop-widgets/diveplanner.h" +#include "subsurface-core/color.h" #include "qthelper.h" #include diff --git a/qt-gui.cpp b/qt-gui.cpp index a4997a6fe..5c7157fe6 100644 --- a/qt-gui.cpp +++ b/qt-gui.cpp @@ -2,7 +2,7 @@ /* Qt UI implementation */ #include "dive.h" #include "display.h" -#include "qt-ui/mainwindow.h" +#include "desktop-widgets/mainwindow.h" #include "helpers.h" #include diff --git a/qt-models/diveplotdatamodel.cpp b/qt-models/diveplotdatamodel.cpp index f219947ac..de156bfac 100644 --- a/qt-models/diveplotdatamodel.cpp +++ b/qt-models/diveplotdatamodel.cpp @@ -1,8 +1,8 @@ #include "diveplotdatamodel.h" #include "dive.h" #include "profile.h" -#include "graphicsview-common.h" #include "divelist.h" +#include "subsurface-core/color.h" DivePlotDataModel::DivePlotDataModel(QObject *parent) : QAbstractTableModel(parent), diff --git a/qt-models/filtermodels.cpp b/qt-models/filtermodels.cpp index 29853cb3d..f56f4be1c 100644 --- a/qt-models/filtermodels.cpp +++ b/qt-models/filtermodels.cpp @@ -1,7 +1,9 @@ #include "filtermodels.h" #include "models.h" -#include "divelistview.h" #include "display.h" +#include "divetripmodel.h" + +#include #define CREATE_INSTANCE_METHOD( CLASS ) \ CLASS *CLASS::instance() \ diff --git a/qt-ui/graphicsview-common.h b/qt-ui/graphicsview-common.h deleted file mode 100644 index 2a757b2ae..000000000 --- a/qt-ui/graphicsview-common.h +++ /dev/null @@ -1,94 +0,0 @@ -#ifndef GRAPHICSVIEW_COMMON_H -#define GRAPHICSVIEW_COMMON_H - -#include "subsurface-core/color.h" -#include -#include -#include - -#define SAC_COLORS_START_IDX SAC_1 -#define SAC_COLORS 9 -#define VELOCITY_COLORS_START_IDX VELO_STABLE -#define VELOCITY_COLORS 5 - -typedef enum { - /* SAC colors. Order is important, the SAC_COLORS_START_IDX define above. */ - SAC_1, - SAC_2, - SAC_3, - SAC_4, - SAC_5, - SAC_6, - SAC_7, - SAC_8, - SAC_9, - - /* Velocity colors. Order is still important, ref VELOCITY_COLORS_START_IDX. */ - VELO_STABLE, - VELO_SLOW, - VELO_MODERATE, - VELO_FAST, - VELO_CRAZY, - - /* gas colors */ - PO2, - PO2_ALERT, - PN2, - PN2_ALERT, - PHE, - PHE_ALERT, - O2SETPOINT, - CCRSENSOR1, - CCRSENSOR2, - CCRSENSOR3, - PP_LINES, - - /* Other colors */ - TEXT_BACKGROUND, - ALERT_BG, - ALERT_FG, - EVENTS, - SAMPLE_DEEP, - SAMPLE_SHALLOW, - SMOOTHED, - MINUTE, - TIME_GRID, - TIME_TEXT, - DEPTH_GRID, - MEAN_DEPTH, - HR_TEXT, - HR_PLOT, - HR_AXIS, - DEPTH_TOP, - DEPTH_BOTTOM, - TEMP_TEXT, - TEMP_PLOT, - SAC_DEFAULT, - BOUNDING_BOX, - PRESSURE_TEXT, - BACKGROUND, - BACKGROUND_TRANS, - CEILING_SHALLOW, - CEILING_DEEP, - CALC_CEILING_SHALLOW, - CALC_CEILING_DEEP, - TISSUE_PERCENTAGE, - GF_LINE, - AMB_PRESSURE_LINE -} color_indice_t; - - -/* profile_color[color indice] = COLOR(screen color, b/w printer color, color printer}} printer & screen colours could be different */ - -extern QMap > profile_color; -void fill_profile_color(); -QColor getColor(const color_indice_t i, bool isGrayscale = false); -QColor getSacColor(int sac, int diveSac); -struct text_render_options { - double size; - color_indice_t color; - double hpos, vpos; -}; - -typedef text_render_options text_render_options_t; -#endif // GRAPHICSVIEW_COMMON_H diff --git a/subsurface-core/CMakeLists.txt b/subsurface-core/CMakeLists.txt index e7f531527..60efb7d92 100644 --- a/subsurface-core/CMakeLists.txt +++ b/subsurface-core/CMakeLists.txt @@ -70,6 +70,8 @@ set(SUBSURFACE_CORE_LIB_SRCS divelogexportlogic.cpp qt-init.cpp qtserialbluetooth.cpp + metrics.cpp + color.cpp ${SERIAL_FTDI} ${PLATFORM_SRC} ${BT_CORE_SRC_FILES} diff --git a/qt-ui/graphicsview-common.cpp b/subsurface-core/color.cpp similarity index 99% rename from qt-ui/graphicsview-common.cpp rename to subsurface-core/color.cpp index a1813ce2d..cf6f43916 100644 --- a/qt-ui/graphicsview-common.cpp +++ b/subsurface-core/color.cpp @@ -1,4 +1,4 @@ -#include "graphicsview-common.h" +#include "color.h" QMap > profile_color; diff --git a/subsurface-core/color.h b/subsurface-core/color.h index 7938e59a6..57ad77242 100644 --- a/subsurface-core/color.h +++ b/subsurface-core/color.h @@ -5,6 +5,8 @@ from http://chir.ag/projects/name-that-color */ #include +#include +#include // Greens #define CAMARONE1 QColor::fromRgbF(0.0, 0.4, 0.0, 1) @@ -64,4 +66,87 @@ // Magentas #define MEDIUMREDVIOLET1_HIGHER_TRANS QColor::fromRgbF(0.7, 0.2, 0.7, 0.1) +#define SAC_COLORS_START_IDX SAC_1 +#define SAC_COLORS 9 +#define VELOCITY_COLORS_START_IDX VELO_STABLE +#define VELOCITY_COLORS 5 + +typedef enum { + /* SAC colors. Order is important, the SAC_COLORS_START_IDX define above. */ + SAC_1, + SAC_2, + SAC_3, + SAC_4, + SAC_5, + SAC_6, + SAC_7, + SAC_8, + SAC_9, + + /* Velocity colors. Order is still important, ref VELOCITY_COLORS_START_IDX. */ + VELO_STABLE, + VELO_SLOW, + VELO_MODERATE, + VELO_FAST, + VELO_CRAZY, + + /* gas colors */ + PO2, + PO2_ALERT, + PN2, + PN2_ALERT, + PHE, + PHE_ALERT, + O2SETPOINT, + CCRSENSOR1, + CCRSENSOR2, + CCRSENSOR3, + PP_LINES, + + /* Other colors */ + TEXT_BACKGROUND, + ALERT_BG, + ALERT_FG, + EVENTS, + SAMPLE_DEEP, + SAMPLE_SHALLOW, + SMOOTHED, + MINUTE, + TIME_GRID, + TIME_TEXT, + DEPTH_GRID, + MEAN_DEPTH, + HR_TEXT, + HR_PLOT, + HR_AXIS, + DEPTH_TOP, + DEPTH_BOTTOM, + TEMP_TEXT, + TEMP_PLOT, + SAC_DEFAULT, + BOUNDING_BOX, + PRESSURE_TEXT, + BACKGROUND, + BACKGROUND_TRANS, + CEILING_SHALLOW, + CEILING_DEEP, + CALC_CEILING_SHALLOW, + CALC_CEILING_DEEP, + TISSUE_PERCENTAGE, + GF_LINE, + AMB_PRESSURE_LINE +} color_indice_t; + +extern QMap > profile_color; +void fill_profile_color(); +QColor getColor(const color_indice_t i, bool isGrayscale = false); +QColor getSacColor(int sac, int diveSac); +struct text_render_options { + double size; + color_indice_t color; + double hpos, vpos; +}; + +typedef text_render_options text_render_options_t; + #endif // COLOR_H diff --git a/qt-ui/metrics.cpp b/subsurface-core/metrics.cpp similarity index 100% rename from qt-ui/metrics.cpp rename to subsurface-core/metrics.cpp diff --git a/qt-ui/metrics.h b/subsurface-core/metrics.h similarity index 100% rename from qt-ui/metrics.h rename to subsurface-core/metrics.h