diff options
Diffstat (limited to 'tracker-pt/module')
-rw-r--r-- | tracker-pt/module/export.hpp | 11 | ||||
-rw-r--r-- | tracker-pt/module/module.cpp | 11 | ||||
-rw-r--r-- | tracker-pt/module/module.hpp | 18 |
3 files changed, 33 insertions, 7 deletions
diff --git a/tracker-pt/module/export.hpp b/tracker-pt/module/export.hpp new file mode 100644 index 00000000..a733c9fe --- /dev/null +++ b/tracker-pt/module/export.hpp @@ -0,0 +1,11 @@ +// generates export.hpp for each module from compat/linkage.hpp + +#pragma once + +#include "compat/linkage-macros.hpp" + +#ifdef BUILD_TRACKER_PT +# define OTR_PT_EXPORT OTR_GENERIC_EXPORT +#else +# define OTR_PT_EXPORT OTR_GENERIC_IMPORT +#endif diff --git a/tracker-pt/module/module.cpp b/tracker-pt/module/module.cpp index 5c298ca5..4731175a 100644 --- a/tracker-pt/module/module.cpp +++ b/tracker-pt/module/module.cpp @@ -1,6 +1,6 @@ #include "ftnoir_tracker_pt.h" -#include "api/plugin-api.hpp" +#include "module.hpp" #include "camera.h" #include "frame.hpp" #include "point_extractor.h" @@ -54,16 +54,13 @@ struct dialog_pt : TrackerDialog_PT dialog_pt(); }; -class metadata_pt : public Metadata -{ - QString name() { return _("PointTracker 1.1"); } - QIcon icon() { return QIcon(":/Resources/Logo_IR.png"); } -}; - // ns pt_module using namespace pt_module; dialog_pt::dialog_pt() : TrackerDialog_PT(module_name) {} +QString metadata_pt::name() { return tr("PointTracker 1.1"); } +QIcon metadata_pt::icon() { return QIcon(":/Resources/Logo_IR.png"); } + OPENTRACK_DECLARE_TRACKER(tracker_pt, dialog_pt, metadata_pt) diff --git a/tracker-pt/module/module.hpp b/tracker-pt/module/module.hpp new file mode 100644 index 00000000..4a2cb919 --- /dev/null +++ b/tracker-pt/module/module.hpp @@ -0,0 +1,18 @@ +#pragma once + +#include "api/plugin-api.hpp" +#include <QtGlobal> +#include <QIcon> + +namespace pt_module +{ + +class Q_DECL_EXPORT metadata_pt : public Metadata +{ + Q_OBJECT + + QString name(); + QIcon icon(); +}; + +} // ns pt_module |