diff options
author | Berthold Stoeger <bstoeger@mail.tuwien.ac.at> | 2018-07-03 16:52:20 +0200 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2018-07-04 05:33:31 +0800 |
commit | 57c01f7a66ccd04fc2e83b67a840519db4661798 (patch) | |
tree | 4134dd2be823ea62ab3370cfb7ee567a6a53d4ec /core/divesite-helper.cpp | |
parent | 2f951413303e10a80e540cacd0c6c282f8ce82cc (diff) | |
download | subsurface-57c01f7a66ccd04fc2e83b67a840519db4661798.tar.gz |
Translations: unify gettextFromC::tr() and QObject::tr()
There were two catch-all classes for translations outside of class
context. gettextFromC was used exclusively from C, but C++ used
both, gettextFromC and QObject. Some of the string were even present
in both. Therefore, unify to gettextFromC throughout the code base.
Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
Diffstat (limited to 'core/divesite-helper.cpp')
-rw-r--r-- | core/divesite-helper.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/core/divesite-helper.cpp b/core/divesite-helper.cpp index 56030afd1..55ebb3aba 100644 --- a/core/divesite-helper.cpp +++ b/core/divesite-helper.cpp @@ -1,6 +1,7 @@ // SPDX-License-Identifier: GPL-2.0 #include "divesite.h" #include "pref.h" +#include "gettextfromc.h" QString constructLocationTags(struct dive_site *ds, bool for_maintab) { @@ -17,7 +18,7 @@ QString constructLocationTags(struct dive_site *ds, bool for_maintab) } if (!prefs_set && !for_maintab) { - locationTag = QString("<small><small>") + QObject::tr("No dive site layout categories set in preferences!") + + locationTag = QString("<small><small>") + gettextFromC::tr("No dive site layout categories set in preferences!") + QString("</small></small>"); return locationTag; } @@ -25,7 +26,7 @@ QString constructLocationTags(struct dive_site *ds, bool for_maintab) return locationTag; if (for_maintab) - locationTag = QString("<small><small>(") + QObject::tr("Tags") + QString(": "); + locationTag = QString("<small><small>(") + gettextFromC::tr("Tags") + QString(": "); else locationTag = QString("<small><small>"); QString connector; |