diff options
Diffstat (limited to 'singleapplication.h')
-rw-r--r-- | singleapplication.h | 32 |
1 files changed, 16 insertions, 16 deletions
diff --git a/singleapplication.h b/singleapplication.h index 1fe5c12..dc6beb3 100644 --- a/singleapplication.h +++ b/singleapplication.h @@ -1,14 +1,8 @@ #ifndef SINGLE_APPLICATION_H #define SINGLE_APPLICATION_H +#include <QtCore/QtGlobal> -// Change this to inherit from QGuiApplication or QCoreApplication -#ifndef QAPPLICATION_CLASS - #define QAPPLICATION_CLASS QCoreApplication -#endif - -#define QUOTE(C) #C -#define INCLUDE_FILE(C) QUOTE(C) -#include INCLUDE_FILE(QAPPLICATION_CLASS) +#include QT_STRINGIFY(QAPPLICATION_CLASS) class SingleApplicationPrivate; @@ -18,19 +12,25 @@ class SingleApplicationPrivate; */ class SingleApplication : public QAPPLICATION_CLASS { - Q_OBJECT + Q_OBJECT + Q_DECLARE_PRIVATE(SingleApplication) + + typedef QAPPLICATION_CLASS app_t; + public: - explicit SingleApplication(int&, char *[]); - ~SingleApplication(); + explicit SingleApplication(int&, char *[]); + ~SingleApplication(); -signals: - void showUp(); +Q_SIGNALS: + void showUp(); -private slots: - void slotConnectionEstablished(); +private Q_SLOTS: + void slotConnectionEstablished(); private: - SingleApplicationPrivate *d_ptr; + SingleApplicationPrivate *d_ptr; + + }; #endif // SINGLE_APPLICATION_H |