]> Shamusworld >> Repos - architektonas/blob - src/base/dialogfactory.h
Bugfixes related to removing Snapper class.
[architektonas] / src / base / dialogfactory.h
1 #ifndef __DIALOGFACTORY_H__
2 #define __DIALOGFACTORY_H__
3
4 #include "dialogfactoryadapter.h"
5
6 #define DIALOGFACTORY DialogFactory::instance()->getFactoryObject()
7
8 class DialogFactoryInterface;
9
10 /**
11  * Interface for objects that can create and show dialogs.
12  */
13 class DialogFactory
14 {
15         private:
16                 DialogFactory();
17
18         public:
19                 virtual ~DialogFactory();
20
21                 static DialogFactory * instance();
22
23                 void setFactoryObject(DialogFactoryInterface * fo);
24                 DialogFactoryInterface * getFactoryObject();
25                 void commandMessage(const QString & m);
26
27         private:
28                 DialogFactoryInterface * factoryObject;
29                 DialogFactoryAdapter factoryAdapter;
30                 static DialogFactory * uniqueInstance;
31 };
32
33 #endif  // __DIALOGFACTORY_H__