|
1 /* |
|
2 * Copyright (c) 2002-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: Declaration of Rights Object MTM UI |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef RIGHTSOBJECTMTMUI_H |
|
20 #define RIGHTSOBJECTMTMUI_H |
|
21 |
|
22 // INCLUDES |
|
23 #include <e32base.h> |
|
24 #include <mtmuibas.h> |
|
25 #include <aknserverapp.h> |
|
26 |
|
27 // CONSTANTS |
|
28 // MACRightsObjectS |
|
29 // DATA TYPES |
|
30 enum TMessageType |
|
31 { |
|
32 ERo, //open RO manager embedded |
|
33 ERoapTrigger, //open roap with file name |
|
34 ERoapTriggerRoAcquisition // remove prefix and open roap with file name. |
|
35 }; |
|
36 // FUNCTION PROTOTYPES |
|
37 |
|
38 // FORWARD DECLARATIONS |
|
39 class CAknLaunchAppService; |
|
40 |
|
41 class CDocumentHandler; |
|
42 |
|
43 |
|
44 // CLASS DECLARATION |
|
45 /** |
|
46 * CRightsObjectMtmUi |
|
47 * |
|
48 * @lib romtmui.lib |
|
49 * @since 2.5 |
|
50 */ |
|
51 // |
|
52 // CRightsObjectMtmUi: User Interface MTM |
|
53 // |
|
54 class CRightsObjectMtmUi : public CBaseMtmUi , public MAknServerAppExitObserver , public MApaServerAppExitObserver |
|
55 { |
|
56 public: |
|
57 // Construction |
|
58 /** |
|
59 * Two-phased constructor. |
|
60 */ |
|
61 static CRightsObjectMtmUi* NewL( CBaseMtm& aBaseMtm , CRegisteredMtmDll& aRegisteredMtmDll ); |
|
62 |
|
63 // Destruction |
|
64 |
|
65 /** |
|
66 * Destructor. |
|
67 */ |
|
68 ~CRightsObjectMtmUi(); |
|
69 |
|
70 /************************************* |
|
71 * |
|
72 * from CBaseMtmUi |
|
73 * |
|
74 **************************************/ |
|
75 |
|
76 |
|
77 /** |
|
78 * CancelL. |
|
79 * @since 2.5 |
|
80 * |
|
81 * Not Supported |
|
82 * |
|
83 */ |
|
84 CMsvOperation* CancelL( TRequestStatus& aStatus, const CMsvEntrySelection& aSelection ); |
|
85 |
|
86 // Context-specific |
|
87 /** |
|
88 * OpenL. |
|
89 * @since 2.5 |
|
90 * |
|
91 * @param aStatus The request status to be completed when the operation has finished |
|
92 * @return If successful, this is an asynchronously completing open operation. |
|
93 * If failed, this is a completed operation, with status set to the relevant error code. |
|
94 */ |
|
95 CMsvOperation* OpenL( TRequestStatus& aStatus ); |
|
96 |
|
97 /** |
|
98 * OpenL. |
|
99 * @since 2.5 |
|
100 * |
|
101 * @param aStatus The request status to be completed when the operation has finished |
|
102 * @param aSelection Selection of message entries |
|
103 * @return If successful, this is an asynchronously completing open operation. |
|
104 * If failed, this is a completed operation, with status set to the relevant error code. |
|
105 */ |
|
106 CMsvOperation* OpenL( TRequestStatus& aStatus , const CMsvEntrySelection& aSelection ); |
|
107 |
|
108 /** |
|
109 * CloseL. |
|
110 * @since 2.5 |
|
111 * |
|
112 * Not Supported |
|
113 * |
|
114 */ |
|
115 CMsvOperation* CloseL( TRequestStatus& aStatus ); |
|
116 |
|
117 /** |
|
118 * CloseL. |
|
119 * @since 2.5 |
|
120 * |
|
121 * Not Supported |
|
122 * |
|
123 */ |
|
124 CMsvOperation* CloseL( TRequestStatus& aStatus , const CMsvEntrySelection& aSelection ); |
|
125 |
|
126 // Launches editor/settings dialog as appropriate |
|
127 /** |
|
128 * EditL. |
|
129 * @since 2.5 |
|
130 * |
|
131 * Not Supported |
|
132 * |
|
133 */ |
|
134 CMsvOperation* EditL( TRequestStatus& aStatus ); |
|
135 |
|
136 /** |
|
137 * EditL. |
|
138 * @since 2.5 |
|
139 * |
|
140 * Not Supported |
|
141 * |
|
142 */ |
|
143 CMsvOperation* EditL( TRequestStatus& aStatus , const CMsvEntrySelection& aSelection ) ; |
|
144 |
|
145 // Launches viewer/settings dialog as appropriate |
|
146 /** |
|
147 * ViewL. |
|
148 * @since 2.5 |
|
149 * |
|
150 * @param aStatus The request status to be completed when the operation has finished |
|
151 * @return If successful, this is an asynchronously completing open operation. |
|
152 * If failed, this is a completed operation, with status set to the relevant error code. |
|
153 */ |
|
154 CMsvOperation* ViewL( TRequestStatus& aStatus ); |
|
155 |
|
156 /** |
|
157 * ViewL. |
|
158 * @since 2.5 |
|
159 * |
|
160 * @param aStatus The request status to be completed when the operation has finished |
|
161 * @param aSelection Selection of message entries |
|
162 * @return If successful, this is an asynchronously completing open operation. |
|
163 * If failed, this is a completed operation, with status set to the relevant error code. |
|
164 */ |
|
165 CMsvOperation* ViewL( TRequestStatus& aStatus , const CMsvEntrySelection& aSelection ); |
|
166 |
|
167 // Reply/forward |
|
168 /** |
|
169 * ReplyL. |
|
170 * @since 2.5 |
|
171 * |
|
172 * Not Supported |
|
173 * |
|
174 */ |
|
175 CMsvOperation* ReplyL( TMsvId aDestination , TMsvPartList aPartList , TRequestStatus& aCompletionStatus ); |
|
176 |
|
177 /** |
|
178 * ForwardL. |
|
179 * @since 2.5 |
|
180 * |
|
181 * Not Supported |
|
182 * |
|
183 */ |
|
184 CMsvOperation* ForwardL( TMsvId aDestination , TMsvPartList aPartList , TRequestStatus& aCompletionStatus ); |
|
185 |
|
186 |
|
187 public: |
|
188 void HandleServerAppExit(TInt aReason); |
|
189 |
|
190 |
|
191 protected: |
|
192 /************************************* |
|
193 * |
|
194 * from CBaseMtm |
|
195 * |
|
196 **************************************/ |
|
197 void GetResourceFileName( TFileName& aFileName ) const; |
|
198 |
|
199 protected: |
|
200 CRightsObjectMtmUi( CBaseMtm& aBaseMtm , CRegisteredMtmDll& aRegisteredMtmDll ); |
|
201 void ConstructL(); |
|
202 |
|
203 private: |
|
204 void CheckMessageTypeL(); |
|
205 CMsvOperation* LaunchEditorApplicationL( TRequestStatus& aStatus , TMsvId aId , TBool aReadOnly ); |
|
206 void SetProgressSuccess( TPckgBuf<TMsvLocalOperationProgress>& aProgress , TMsvId aId ); |
|
207 CMsvOperation* CompletedOperationL( TRequestStatus& aObserverStatus ); |
|
208 TBool ShowQueryL( TDesC16& aFile ); |
|
209 TInt CheckTriggerTypeL( TDesC16& aFile ); |
|
210 private: |
|
211 TMessageType iType; |
|
212 CDocumentHandler* iDocHandler; |
|
213 RFs iFs; |
|
214 CEikProcess* iHostProcess; |
|
215 CAknLaunchAppService* iOpenService; |
|
216 }; |
|
217 |
|
218 #endif // RIGHTSOBJECTMTMUI_H |
|
219 |
|
220 // End of File |