X-Git-Url: https://vaikene.ee/gitweb/pswgen11.html?a=blobdiff_plain;ds=inline;f=src%2Flibs%2FCommon%2Fapp.h;h=58b3401d0b8451280137b86f83d9d7d3b1ecc9b6;hb=de270ece1b764b19968e14420f538321f1c06b15;hp=3bcde5aaa045c422acaeff53658b9529e40c6be7;hpb=be0e791df48f5a8c9bb4c16f65b62e41e1149552;p=evaf
diff --git a/src/libs/Common/app.h b/src/libs/Common/app.h
index 3bcde5a..58b3401 100644
--- a/src/libs/Common/app.h
+++ b/src/libs/Common/app.h
@@ -3,7 +3,7 @@
* @brief Application interface implementation
* @author Enar Vaikene
*
- * Copyright (c) 2011 Enar Vaikene
+ * Copyright (c) 2011-2019 Enar Vaikene
*
* This file is part of the eVaf C++ cross-platform application development framework.
*
@@ -25,6 +25,8 @@
#include
#include
+class QEvent;
+
namespace eVaf {
namespace Common {
namespace Internal {
@@ -38,6 +40,11 @@ class App : public iApp
public:
+ /**
+ * Destroys the iApp interface instance
+ */
+ static void destroyInstance();
+
App();
virtual ~App();
@@ -48,6 +55,8 @@ public:
*/
bool init();
+ virtual bool event(QEvent *);
+
/*
iApp interface
*/
@@ -57,6 +66,8 @@ public:
virtual QString const xmlFileName() const;
+ virtual int exec();
+
virtual void restart();
virtual void quit(bool err = false);
@@ -78,7 +89,7 @@ public:
virtual QString const qtPluginsDir() const;
-private:
+private: // Members
/// Flag indicating that the eVaf application is ready
bool mReady;
@@ -113,6 +124,17 @@ private:
/// Name of the documentation directory
mutable QString mDocDir;
+ /// Event numbers
+ uint mEvQuit;
+ uint mEvRestart;
+ uint mEvReady;
+ uint mEvTerminating;
+
+
+private: // Methods
+
+ void setReady(bool value);
+
};
} // namespace eVaf::Common::Internal