equal
deleted
inserted
replaced
17 #ifndef _CNTSETTINGSVIEW_H__ |
17 #ifndef _CNTSETTINGSVIEW_H__ |
18 #define _CNTSETTINGSVIEW_H__ |
18 #define _CNTSETTINGSVIEW_H__ |
19 |
19 |
20 #include <cntabstractview.h> |
20 #include <cntabstractview.h> |
21 #include <QObject> |
21 #include <QObject> |
22 #include <hbdataformmodel.h> |
|
23 |
22 |
24 class HbAction; |
23 class HbAction; |
25 class HbView; |
24 class HbView; |
26 class HbDataForm; |
25 class HbDataForm; |
27 class HbDataFormModelItem; |
|
28 class HbDocumentLoader; |
26 class HbDocumentLoader; |
29 |
27 class CntSettingsModel; |
30 class CntSettingsModel : public HbDataFormModel |
|
31 { |
|
32 Q_OBJECT |
|
33 |
|
34 public: |
|
35 virtual ~CntSettingsModel(){} |
|
36 virtual void saveSettings() = 0; |
|
37 virtual void loadSettings() = 0; |
|
38 }; |
|
39 |
|
40 class CntDefaultSettingsModel : public CntSettingsModel |
|
41 { |
|
42 Q_OBJECT |
|
43 |
|
44 public: |
|
45 CntDefaultSettingsModel(); |
|
46 ~CntDefaultSettingsModel(); |
|
47 |
|
48 public: |
|
49 void saveSettings(); |
|
50 void loadSettings(); |
|
51 |
|
52 private: |
|
53 HbDataFormModelItem* mOrder; |
|
54 }; |
|
55 |
28 |
56 class CntSettingsView : public QObject, public CntAbstractView |
29 class CntSettingsView : public QObject, public CntAbstractView |
57 { |
30 { |
58 Q_OBJECT |
31 Q_OBJECT |
59 |
32 |
65 void activate( CntAbstractViewManager* aMgr, const CntViewParameters aArgs ); |
38 void activate( CntAbstractViewManager* aMgr, const CntViewParameters aArgs ); |
66 void deactivate(); |
39 void deactivate(); |
67 bool isDefault() const; |
40 bool isDefault() const; |
68 HbView* view() const; |
41 HbView* view() const; |
69 int viewId() const; |
42 int viewId() const; |
70 |
43 |
71 private slots: |
44 private slots: |
72 void back(); |
45 void back(); |
73 |
46 |
74 private: |
47 private: |
75 HbDocumentLoader* document(); |
48 HbDocumentLoader* document(); |
83 CntAbstractViewManager* mViewMgr; |
56 CntAbstractViewManager* mViewMgr; |
84 CntViewParameters mArgs; |
57 CntViewParameters mArgs; |
85 |
58 |
86 CntSettingsModel* mModel; |
59 CntSettingsModel* mModel; |
87 |
60 |
88 friend class TestCntEditView; |
61 friend class TestCntSettings; |
89 }; |
62 }; |
90 #endif |
63 #endif |
91 |
64 |