|
1 /* |
|
2 * Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). |
|
3 * All rights reserved. |
|
4 * This component and the accompanying materials are made available |
|
5 * under the terms of "Eclipse Public License v1.0" |
|
6 * which accompanies this distribution, and is available |
|
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
8 * |
|
9 * Initial Contributors: |
|
10 * Nokia Corporation - initial contribution. |
|
11 * |
|
12 * Contributors: |
|
13 * |
|
14 * Description: |
|
15 * |
|
16 */ |
|
17 |
|
18 #ifndef CNTVIEWPARAMETERS_H |
|
19 #define CNTVIEWPARAMETERS_H |
|
20 |
|
21 #include <qtcontacts.h> |
|
22 #include "qtpbkglobal.h" |
|
23 |
|
24 QTM_USE_NAMESPACE |
|
25 |
|
26 class QTPBK_EXPORT CntViewParameters |
|
27 { |
|
28 public: |
|
29 enum ViewId |
|
30 { |
|
31 noView=0, //exit |
|
32 defaultView, //first view |
|
33 namesView, |
|
34 commLauncherView, |
|
35 serviceContactCardView, |
|
36 serviceAssignContactCardView, |
|
37 myCardView, |
|
38 myCardSelectionView, |
|
39 serviceContactSelectionView, |
|
40 collectionView, |
|
41 collectionFavoritesView, |
|
42 collectionFavoritesSelectionView, |
|
43 editView, |
|
44 serviceEditView, |
|
45 serviceSubEditView, |
|
46 emailEditorView, |
|
47 namesEditorView, |
|
48 urlEditorView, |
|
49 companyEditorView, |
|
50 phoneNumberEditorView, |
|
51 onlineAccountEditorView, |
|
52 noteEditorView, |
|
53 familyDetailEditorView, |
|
54 addressEditorView, |
|
55 dateEditorView, |
|
56 imageEditorView, |
|
57 serviceContactFetchView, |
|
58 groupEditorView, |
|
59 groupMemberView, |
|
60 groupActionsView, |
|
61 historyView |
|
62 }; |
|
63 |
|
64 public: |
|
65 CntViewParameters(CntViewParameters::ViewId activateView = CntViewParameters::noView, |
|
66 CntViewParameters::ViewId previousViewId = CntViewParameters::defaultView); |
|
67 |
|
68 CntViewParameters( const CntViewParameters &viewParameters ); |
|
69 |
|
70 virtual ~CntViewParameters(); |
|
71 |
|
72 public: |
|
73 //view to be activated |
|
74 void setNextViewId(const CntViewParameters::ViewId activateViewId); |
|
75 CntViewParameters::ViewId nextViewId() const; |
|
76 |
|
77 //view to be called when user clicks on back in the activated view |
|
78 void setPreviousViewId(const CntViewParameters::ViewId previousViewId); |
|
79 CntViewParameters::ViewId previousViewId() const; |
|
80 |
|
81 //selected contact |
|
82 void setSelectedContact(const QContact &contact); |
|
83 QContact selectedContact() const; |
|
84 |
|
85 //selected contactdetail |
|
86 void setSelectedDetail(const QContactDetail &detail); |
|
87 QContactDetail selectedDetail() const; |
|
88 |
|
89 //selected action (needed for popup display at least) |
|
90 void setSelectedAction(const QString &action); |
|
91 QString selectedAction() const; |
|
92 |
|
93 //selected group contact |
|
94 void setSelectedGroupContact(const QContact &contact); |
|
95 QContact selectedGroupContact() const; |
|
96 |
|
97 private: |
|
98 CntViewParameters::ViewId mActivateViewId; |
|
99 CntViewParameters::ViewId mPreviousViewId; |
|
100 |
|
101 QContact mContact; |
|
102 QContactDetail mDetail; |
|
103 QString mAction; |
|
104 QContact mGroupContact; |
|
105 |
|
106 }; |
|
107 #endif //CNTVIEWPARAMETERS_H |
|
108 |
|
109 // EOF |