From 03f38cf3ed339a9e774362248f8cb9f2cebee66a Mon Sep 17 00:00:00 2001 From: Philipp Spitzer Date: Wed, 28 Jul 2021 23:35:48 +0200 Subject: [PATCH] Add active conference to application class. --- src/app/application.h | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/src/app/application.h b/src/app/application.h index 53727db..e01dfc5 100644 --- a/src/app/application.h +++ b/src/app/application.h @@ -21,18 +21,26 @@ #define APPLICATION_H #include +#include class Application : public QApplication { Q_OBJECT public: - Application(int& argc, char** argv) - : QApplication(argc, argv) - { } - virtual ~Application() { } + Application(int& argc, char** argv): QApplication(argc, argv) {} + virtual ~Application() {} virtual bool notify(QObject* receiver, QEvent* event); + + void setActiveConference(Conference& conference) {mActiveConference = conference; mHasActiveConference = true;} + void unsetActiveConference() {mHasActiveConference = false;} + Conference& activeConference() {return mActiveConference;} + bool hasActiveConference() const {return mHasActiveConference;} + +private: + bool mHasActiveConference = false; + Conference mActiveConference; }; #endif -- 2.39.5