diff options
author | Stanislaw Halik <sthalik@misaki.pl> | 2018-04-05 03:23:38 +0200 |
---|---|---|
committer | Stanislaw Halik <sthalik@misaki.pl> | 2018-04-05 03:23:52 +0200 |
commit | c0165f8b48852a1aca782d606ba4f1ea48eee6ba (patch) | |
tree | 433441689808ca741889b078407bc49fade746de /proto-ft | |
parent | eb32a2ac02c6d1adcfeb0a1a5522f8aaea442489 (diff) |
modules: now use i18n
Diffstat (limited to 'proto-ft')
-rw-r--r-- | proto-ft/ftnoir_protocol_ft.cpp | 4 | ||||
-rw-r--r-- | proto-ft/ftnoir_protocol_ft.h | 10 |
2 files changed, 9 insertions, 5 deletions
diff --git a/proto-ft/ftnoir_protocol_ft.cpp b/proto-ft/ftnoir_protocol_ft.cpp index 1c3dcafe..6b245ed3 100644 --- a/proto-ft/ftnoir_protocol_ft.cpp +++ b/proto-ft/ftnoir_protocol_ft.cpp @@ -115,7 +115,7 @@ void freetrack::pose(const double* headpose) (void)CSV::getGameData(id, t.table, gamename); if (gamename.isEmpty() && id > 0) - gamename = _("Unknown game"); + gamename = tr("Unknown game"); static_assert(sizeof(LONG) == 4, ""); static_assert(sizeof(int) == 4, ""); @@ -171,7 +171,7 @@ void freetrack::set_protocols(bool ft, bool npclient) module_status freetrack::initialize() { if (!shm.success()) - return error(_("Can't load freetrack memory mapping")); + return error(tr("Can't load freetrack memory mapping")); bool use_ft = false, use_npclient = false; diff --git a/proto-ft/ftnoir_protocol_ft.h b/proto-ft/ftnoir_protocol_ft.h index 843d1f34..18a5596f 100644 --- a/proto-ft/ftnoir_protocol_ft.h +++ b/proto-ft/ftnoir_protocol_ft.h @@ -13,6 +13,7 @@ #include "freetrackclient/fttypes.h" #include "compat/shm.h" +#include "compat/tr.hpp" #include "options/options.hpp" #include "api/plugin-api.hpp" @@ -33,8 +34,10 @@ struct settings : opts { {} }; -class freetrack : public IProtocol +class freetrack : public TR, public IProtocol { + Q_OBJECT + public: freetrack(); ~freetrack() override; @@ -81,7 +84,8 @@ private slots: class freetrackDll : public Metadata { -public: - QString name() { return otr_tr("freetrack 2.0 Enhanced"); } + Q_OBJECT + + QString name() { return tr("freetrack 2.0 Enhanced"); } QIcon icon() { return QIcon(":/images/freetrack.png"); } }; |