summaryrefslogtreecommitdiffstats
path: root/core
diff options
context:
space:
mode:
authorGravatar Tomaz Canabrava <tcanabrava@kde.org>2016-10-17 17:50:55 +0200
committerGravatar Dirk Hohndel <dirk@hohndel.org>2016-10-18 11:12:33 -0700
commita42b05578fe731ce0b722e5c7383d616880289ef (patch)
tree9edd7965c3da102f508d0c765ff727c6c48755aa /core
parent9c4b0170bfc321a31c6f3d0f7cd34edfa74fe1f4 (diff)
downloadsubsurface-a42b05578fe731ce0b722e5c7383d616880289ef.tar.gz
Tests for Units Preferences
Signed-off-by: Tomaz Canabrava <tcanabrava@kde.org> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'core')
-rw-r--r--core/subsurface-qt/SettingsObjectWrapper.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/core/subsurface-qt/SettingsObjectWrapper.cpp b/core/subsurface-qt/SettingsObjectWrapper.cpp
index 009ca6403..101e6650c 100644
--- a/core/subsurface-qt/SettingsObjectWrapper.cpp
+++ b/core/subsurface-qt/SettingsObjectWrapper.cpp
@@ -1557,7 +1557,9 @@ int UnitsSettings::verticalSpeedTime() const
QString UnitsSettings::unitSystem() const
{
- return QString(); /*FIXME: there's no char * units on the prefs. */
+ return prefs.unit_system == METRIC ? QStringLiteral("metric")
+ : prefs.unit_system == IMPERIAL ? QStringLiteral("imperial")
+ : QStringLiteral("personalized");
}
bool UnitsSettings::coordinatesTraditional() const