appcontext.h 473 B

1234567891011121314151617181920212223242526
  1. #ifndef __APPCONTEXT_H__
  2. #define __APPCONTEXT_H__
  3. #include <QObject>
  4. #include "pluginmanager.h"
  5. #include "projectmanager.h"
  6. class AppContext : public QObject
  7. {
  8. Q_OBJECT
  9. explicit AppContext(QObject *parent = nullptr);
  10. ~AppContext();
  11. public:
  12. static AppContext &instance();
  13. const PluginManager &pluginManager();
  14. ProjectManager &projectManager();
  15. private:
  16. PluginManager m_pluginMgr;
  17. ProjectManager m_projectMgr;
  18. };
  19. #endif // APPCONTEXT_H