summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2019-03-28 08:35:21 +0100
committerStanislaw Halik <sthalik@misaki.pl>2019-03-28 08:58:40 +0100
commit753013079c2e2d2db82dd096c642c5140f1de772 (patch)
treeeeac8dc26beaa88e8415895845916077cc9b108c
parentc3ade73cad4332165548709ee8db904040ddafdb (diff)
compat/tr: make header-only for the api header
-rw-r--r--compat/tr.cpp12
-rw-r--r--compat/tr.hpp12
2 files changed, 4 insertions, 20 deletions
diff --git a/compat/tr.cpp b/compat/tr.cpp
deleted file mode 100644
index 58f0a71a..00000000
--- a/compat/tr.cpp
+++ /dev/null
@@ -1,12 +0,0 @@
-#include "tr.hpp"
-
-
-TR::TR() : QObject(nullptr) {}
-
-TR::TR(const TR&) : QObject(nullptr) {}
-
-TR& TR::operator=(const TR&)
-{
- return *this;
-}
-
diff --git a/compat/tr.hpp b/compat/tr.hpp
index 6af45161..4504f791 100644
--- a/compat/tr.hpp
+++ b/compat/tr.hpp
@@ -1,18 +1,14 @@
#pragma once
#include <QObject>
-#include "export.hpp"
// The class does nothing except provide a fake assignment operator for QObject
// It's meant to be used inside classes that need i18n support but are returned by value.
-class OTR_COMPAT_EXPORT TR : public QObject
+struct TR : QObject
{
- Q_OBJECT
+ TR() = default;
+ TR(const TR&) {}
-public:
- TR();
- TR(const TR&);
-
- TR& operator=(const TR& other);
+ TR& operator=(const TR&) { return *this; }
};