|
1 /* |
|
2 * Copyright (c) 2003-2007 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 the CCertManUIViewAuthority class |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef CERTMANUIVIEWAUTHORITY_H |
|
20 #define CERTMANUIVIEWAUTHORITY_H |
|
21 |
|
22 // INCLUDES |
|
23 #include <aknview.h> |
|
24 #include <e32base.h> |
|
25 #include "Certmanuiviewid.h" |
|
26 |
|
27 // FORWARD DECLERATIONS |
|
28 class CCrCertificate; |
|
29 class CCertificate; |
|
30 class CX509Certificate; |
|
31 class CCertManUIContainerAuthority; |
|
32 |
|
33 // CLASS DECLARATION |
|
34 |
|
35 /** |
|
36 * CCertManUIViewAuthority view class. |
|
37 * |
|
38 * @lib certmanui.dll |
|
39 */ |
|
40 NONSHARABLE_CLASS( CCertManUIViewAuthority ): public CAknView |
|
41 { |
|
42 public: // functions |
|
43 |
|
44 /** |
|
45 * Destructor |
|
46 */ |
|
47 ~CCertManUIViewAuthority(); |
|
48 |
|
49 /** |
|
50 * NewL |
|
51 */ |
|
52 static class CCertManUIViewAuthority* NewL(const TRect& aRect, CCertManUIKeeper& aKeeper); |
|
53 |
|
54 /** |
|
55 * NewLC |
|
56 */ |
|
57 static class CCertManUIViewAuthority* NewLC(const TRect& aRect, CCertManUIKeeper& aKeeper); |
|
58 |
|
59 /** |
|
60 * Returns Authority view id |
|
61 */ |
|
62 TUid Id() const; |
|
63 |
|
64 /** |
|
65 * Handles ClientRectChange |
|
66 */ |
|
67 void HandleClientRectChange(); |
|
68 |
|
69 /** |
|
70 * Returns iContainerAuthority to be used in CertManUIContainerAuthority |
|
71 */ |
|
72 CCoeControl* Container(); |
|
73 |
|
74 /** |
|
75 * Handles Softkey and Options list commands |
|
76 */ |
|
77 void HandleCommandL(TInt aCommand); |
|
78 |
|
79 /** |
|
80 * Updates the view when opening it |
|
81 */ |
|
82 void DoActivateL(const TVwsViewId& aPrevViewId,TUid aCustomMessageId, |
|
83 const TDesC8& aCustomMessage); |
|
84 |
|
85 /** |
|
86 * Updates the menu bar |
|
87 */ |
|
88 void UpdateMenuBar(); |
|
89 |
|
90 /** |
|
91 * Updates cba |
|
92 */ |
|
93 void UpdateCba(TInt aCbaResourceId); |
|
94 |
|
95 public: // data |
|
96 |
|
97 /** |
|
98 * To get hold of CertManUIKeeper |
|
99 */ |
|
100 CCertManUIKeeper& iKeeper; |
|
101 |
|
102 /** |
|
103 * To get access to certificate list in authority view |
|
104 */ |
|
105 CCertManUIContainerAuthority* iContainerAuthority; |
|
106 |
|
107 /** |
|
108 * To store the position of the focus in the Authority view |
|
109 */ |
|
110 TInt iCurrentPosition; |
|
111 |
|
112 /** |
|
113 * Stores top item in the listbox |
|
114 */ |
|
115 TInt iTopItem; |
|
116 |
|
117 private: // functions |
|
118 |
|
119 /** |
|
120 * Constructor. |
|
121 */ |
|
122 CCertManUIViewAuthority(CCertManUIKeeper& aKeeper); |
|
123 |
|
124 /** |
|
125 * EPOC default constructor. |
|
126 */ |
|
127 void ConstructL(); |
|
128 |
|
129 |
|
130 /** |
|
131 * Saves focus position when closing view |
|
132 */ |
|
133 void DoDeactivate(); |
|
134 |
|
135 /** |
|
136 * Updates Options list with correct items depending on |
|
137 * whether the listbox is empty or if it has any marked items |
|
138 */ |
|
139 void DynInitMenuPaneL(TInt aResourceId,CEikMenuPane* aMenuPane); |
|
140 |
|
141 /** |
|
142 * Appends a field that has string from resources and string from CertManAPI |
|
143 * to the details view message body |
|
144 */ |
|
145 void DetailsFieldDynamicL(HBufC& aMessage, TPtrC aValue, |
|
146 TInt aResourceOne, TInt aResourceTwo); |
|
147 |
|
148 |
|
149 private: // Data |
|
150 |
|
151 /** |
|
152 * To get the certificate location |
|
153 */ |
|
154 TInt iCertificateLocation; |
|
155 }; |
|
156 |
|
157 #endif // CERTMANUIVIEWAUTHORITY_H |
|
158 |
|
159 // End of File |