From 8f119dcf72db445530b39e0722c3afad7c130efb Mon Sep 17 00:00:00 2001 From: Berthold Stoeger Date: Mon, 15 Jul 2019 23:44:39 +0200 Subject: Cleanup: remove includes from qthelper.h To reduce interdependencies, remove the dive.h and divelist.h includes in qthelper.h Signed-off-by: Berthold Stoeger --- core/checkcloudconnection.cpp | 1 + core/cloudstorage.cpp | 1 + core/downloadfromdcthread.cpp | 1 + core/git-access.c | 1 + core/gpslocation.cpp | 1 + core/qt-init.cpp | 1 + core/qthelper.h | 7 ++++--- 7 files changed, 10 insertions(+), 3 deletions(-) (limited to 'core') diff --git a/core/checkcloudconnection.cpp b/core/checkcloudconnection.cpp index b912160c1..1d8870742 100644 --- a/core/checkcloudconnection.cpp +++ b/core/checkcloudconnection.cpp @@ -8,6 +8,7 @@ #include "pref.h" #include "qthelper.h" #include "git-access.h" +#include "dive.h" // for "verbose" #include "checkcloudconnection.h" diff --git a/core/cloudstorage.cpp b/core/cloudstorage.cpp index 77d9153e9..4e7ff10f0 100644 --- a/core/cloudstorage.cpp +++ b/core/cloudstorage.cpp @@ -2,6 +2,7 @@ #include "cloudstorage.h" #include "pref.h" #include "qthelper.h" +#include "dive.h" #include "settings/qPrefCloudStorage.h" #include diff --git a/core/downloadfromdcthread.cpp b/core/downloadfromdcthread.cpp index 1112d6027..9763cbdd8 100644 --- a/core/downloadfromdcthread.cpp +++ b/core/downloadfromdcthread.cpp @@ -2,6 +2,7 @@ #include "core/libdivecomputer.h" #include "core/qthelper.h" #include "core/settings/qPrefDiveComputer.h" +#include "core/divelist.h" #include #if defined(Q_OS_ANDROID) #include "core/subsurface-string.h" diff --git a/core/git-access.c b/core/git-access.c index f4f040ab9..ff27ebcf7 100644 --- a/core/git-access.c +++ b/core/git-access.c @@ -22,6 +22,7 @@ #include "membuffer.h" #include "strndup.h" #include "qthelper.h" +#include "dive.h" #include "git-access.h" #include "gettext.h" #include "sha1.h" diff --git a/core/gpslocation.cpp b/core/gpslocation.cpp index 3c63d4dbd..acc5b1da5 100644 --- a/core/gpslocation.cpp +++ b/core/gpslocation.cpp @@ -4,6 +4,7 @@ #include "qt-models/gpslistmodel.h" #include "core/pref.h" #include "core/qthelper.h" +#include "core/divelist.h" // for mark_divelist_changed() #include "core/settings/qPrefLocationService.h" #include #include diff --git a/core/qt-init.cpp b/core/qt-init.cpp index ad1671655..c06aeae00 100644 --- a/core/qt-init.cpp +++ b/core/qt-init.cpp @@ -5,6 +5,7 @@ #include #include #include "qthelper.h" +#include "dive.h" // for "verbose" #include "core/settings/qPref.h" char *settings_suffix = NULL; diff --git a/core/qthelper.h b/core/qthelper.h index 685525a70..74185b467 100644 --- a/core/qthelper.h +++ b/core/qthelper.h @@ -5,8 +5,9 @@ #include #include #include -#include "dive.h" -#include "divelist.h" +#include "core/pref.h" + +struct picture; // 1) Types @@ -26,7 +27,7 @@ QString distance_string(int distanceInMeters); bool gpsHasChanged(struct dive *dive, struct dive *master, const QString &gps_text, bool *parsed_out = 0); QList getDivesInTrip(struct dive_trip *trip); QString get_gas_string(struct gasmix gas); -QString get_divepoint_gas_string(struct dive *d, const divedatapoint& dp); +QString get_divepoint_gas_string(struct dive *d, const struct divedatapoint &dp); QString get_taglist_string(struct tag_entry *tag_list); void read_hashes(); void write_hashes(); -- cgit v1.2.3-70-g09d2