|
1 /* |
|
2 * Copyright (c) 2010 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: Implementation of CSifUi class. |
|
15 * |
|
16 */ |
|
17 |
|
18 #include "sifui.h" // CSifUi |
|
19 #include "sifuiprivate.h" // CSifUiPrivate |
|
20 #include "sifuierrorinfo.h" // CSifUiErrorInfo |
|
21 |
|
22 |
|
23 // ======== MEMBER FUNCTIONS ======== |
|
24 |
|
25 // --------------------------------------------------------------------------- |
|
26 // CSifUi::NewLC() |
|
27 // --------------------------------------------------------------------------- |
|
28 // |
|
29 EXPORT_C CSifUi* CSifUi::NewLC() |
|
30 { |
|
31 CSifUi* self = new( ELeave ) CSifUi(); |
|
32 CleanupStack::PushL( self ); |
|
33 self->ConstructL(); |
|
34 return self; |
|
35 } |
|
36 |
|
37 // --------------------------------------------------------------------------- |
|
38 // CSifUi::NewL() |
|
39 // --------------------------------------------------------------------------- |
|
40 // |
|
41 EXPORT_C CSifUi* CSifUi::NewL() |
|
42 { |
|
43 CSifUi* self = CSifUi::NewLC(); |
|
44 CleanupStack::Pop( self ); |
|
45 return self; |
|
46 } |
|
47 |
|
48 // --------------------------------------------------------------------------- |
|
49 // CSifUi::~CSifUi() |
|
50 // --------------------------------------------------------------------------- |
|
51 // |
|
52 CSifUi::~CSifUi() |
|
53 { |
|
54 delete iPrivate; |
|
55 } |
|
56 |
|
57 // --------------------------------------------------------------------------- |
|
58 // CSifUi::ShowPreparingL() |
|
59 // --------------------------------------------------------------------------- |
|
60 // |
|
61 EXPORT_C void CSifUi::ShowPreparingL() |
|
62 { |
|
63 iPrivate->ShowPreparingL(); |
|
64 } |
|
65 |
|
66 // --------------------------------------------------------------------------- |
|
67 // CSifUi::SetMemorySelectionL() |
|
68 // --------------------------------------------------------------------------- |
|
69 // |
|
70 EXPORT_C void CSifUi::SetMemorySelectionL( const RArray<TInt>& aDriveNumbers ) |
|
71 { |
|
72 iPrivate->SetMemorySelectionL( aDriveNumbers ); |
|
73 } |
|
74 |
|
75 // --------------------------------------------------------------------------- |
|
76 // CSifUi::SetCertificateInfoL() |
|
77 // --------------------------------------------------------------------------- |
|
78 // |
|
79 EXPORT_C void CSifUi::SetCertificateInfoL( |
|
80 const RPointerArray<CSifUiCertificateInfo>& aCertificates ) |
|
81 { |
|
82 iPrivate->SetCertificateInfoL( aCertificates ); |
|
83 } |
|
84 |
|
85 // --------------------------------------------------------------------------- |
|
86 // CSifUi::ShowConfirmationL() |
|
87 // --------------------------------------------------------------------------- |
|
88 // |
|
89 EXPORT_C TBool CSifUi::ShowConfirmationL( const CSifUiAppInfo& aAppInfo ) |
|
90 { |
|
91 return iPrivate->ShowConfirmationL( aAppInfo ); |
|
92 } |
|
93 |
|
94 // --------------------------------------------------------------------------- |
|
95 // CSifUi::SelectedDrive() |
|
96 // --------------------------------------------------------------------------- |
|
97 // |
|
98 EXPORT_C TInt CSifUi::SelectedDrive( TInt& aDriveNumber ) |
|
99 { |
|
100 return iPrivate->SelectedDrive( aDriveNumber ); |
|
101 } |
|
102 |
|
103 // --------------------------------------------------------------------------- |
|
104 // CSifUi::ShowProgressL() |
|
105 // --------------------------------------------------------------------------- |
|
106 // |
|
107 EXPORT_C void CSifUi::ShowProgressL( const CSifUiAppInfo& aAppInfo, |
|
108 TInt aProgressBarFinalValue, TInstallingPhase aPhase ) |
|
109 { |
|
110 iPrivate->ShowProgressL( aAppInfo, aProgressBarFinalValue, aPhase ); |
|
111 } |
|
112 |
|
113 // --------------------------------------------------------------------------- |
|
114 // CSifUi::IncreaseProgressBarValueL() |
|
115 // --------------------------------------------------------------------------- |
|
116 // |
|
117 EXPORT_C void CSifUi::IncreaseProgressBarValueL( TInt aNewValue ) |
|
118 { |
|
119 iPrivate->IncreaseProgressBarValueL( aNewValue ); |
|
120 } |
|
121 |
|
122 // --------------------------------------------------------------------------- |
|
123 // CSifUi::IsCancelled() |
|
124 // --------------------------------------------------------------------------- |
|
125 // |
|
126 EXPORT_C TBool CSifUi::IsCancelled() |
|
127 { |
|
128 return iPrivate->IsCancelled(); |
|
129 } |
|
130 |
|
131 // --------------------------------------------------------------------------- |
|
132 // CSifUi::ShowCompleteL() |
|
133 // --------------------------------------------------------------------------- |
|
134 // |
|
135 EXPORT_C void CSifUi::ShowCompleteL() |
|
136 { |
|
137 iPrivate->ShowCompleteL(); |
|
138 } |
|
139 |
|
140 // --------------------------------------------------------------------------- |
|
141 // CSifUi::ShowFailedL() |
|
142 // --------------------------------------------------------------------------- |
|
143 // |
|
144 EXPORT_C void CSifUi::ShowFailedL( const CSifUiErrorInfo& aErrorInfo ) |
|
145 { |
|
146 iPrivate->ShowFailedL( aErrorInfo ); |
|
147 } |
|
148 |
|
149 // --------------------------------------------------------------------------- |
|
150 // CSifUi::SetButtonVisible() |
|
151 // --------------------------------------------------------------------------- |
|
152 // |
|
153 EXPORT_C void CSifUi::SetButtonVisible( TOptionalButton aButton, TBool aIsVisible ) |
|
154 { |
|
155 iPrivate->SetButtonVisible( aButton, aIsVisible ); |
|
156 } |
|
157 |
|
158 // --------------------------------------------------------------------------- |
|
159 // CSifUi::ShowGrantCapabilitiesL() |
|
160 // --------------------------------------------------------------------------- |
|
161 // |
|
162 EXPORT_C TBool CSifUi::ShowGrantCapabilitiesL( const TCapabilitySet& aCapabilities ) |
|
163 { |
|
164 return iPrivate->ShowGrantCapabilitiesL( aCapabilities ); |
|
165 } |
|
166 |
|
167 // --------------------------------------------------------------------------- |
|
168 // CSifUi::ShowSelectLanguageL() |
|
169 // --------------------------------------------------------------------------- |
|
170 // |
|
171 EXPORT_C TInt CSifUi::ShowSelectLanguageL( const RArray<TLanguage>& aLanguages ) |
|
172 { |
|
173 return iPrivate->ShowSelectLanguageL( aLanguages ); |
|
174 } |
|
175 |
|
176 // --------------------------------------------------------------------------- |
|
177 // CSifUi::ShowSelectOptionsL() |
|
178 // --------------------------------------------------------------------------- |
|
179 // |
|
180 EXPORT_C TBool CSifUi::ShowSelectOptionsL( const MDesCArray& aSelectableItems, |
|
181 RArray<TInt>& aSelectedIndexes ) |
|
182 { |
|
183 return iPrivate->ShowSelectOptionsL( aSelectableItems, aSelectedIndexes ); |
|
184 } |
|
185 |
|
186 |
|
187 // --------------------------------------------------------------------------- |
|
188 // DEPRECATED: CSifUi::ShowFailedL() |
|
189 // --------------------------------------------------------------------------- |
|
190 // |
|
191 // TODO: This function is deprecated, remove it completely. |
|
192 EXPORT_C void CSifUi::ShowFailedL( TInt /*aErrorCode*/, const TDesC& /*aErrorMessage*/, |
|
193 const TDesC& /*aErrorDetails*/ ) |
|
194 { |
|
195 User::Invariant(); |
|
196 } |
|
197 |
|
198 // --------------------------------------------------------------------------- |
|
199 // DEPRECATED: CSifUi::ShowSingleSelectionL() |
|
200 // --------------------------------------------------------------------------- |
|
201 // |
|
202 EXPORT_C TBool CSifUi::ShowSingleSelectionL( const TDesC& /*aTitle*/, |
|
203 const MDesCArray& /*aSelectableItems*/, TInt& /*aSelectedIndex*/ ) |
|
204 { |
|
205 User::Invariant(); |
|
206 return EFalse; // for compiler |
|
207 } |
|
208 |
|
209 // --------------------------------------------------------------------------- |
|
210 // DEPRECATED: CSifUi::ShowMultiSelectionL() |
|
211 // --------------------------------------------------------------------------- |
|
212 // |
|
213 EXPORT_C TBool CSifUi::ShowMultiSelectionL( const TDesC& /*aTitle*/, |
|
214 const MDesCArray& /*aSelectableItems*/, RArray<TInt>& /*aSelectedIndexes*/ ) |
|
215 { |
|
216 User::Invariant(); |
|
217 return EFalse; // for compiler |
|
218 } |
|
219 |
|
220 |
|
221 // --------------------------------------------------------------------------- |
|
222 // CSifUi::CSifUi() |
|
223 // --------------------------------------------------------------------------- |
|
224 // |
|
225 CSifUi::CSifUi() |
|
226 { |
|
227 } |
|
228 |
|
229 // --------------------------------------------------------------------------- |
|
230 // CSifUi::ConstructL() |
|
231 // --------------------------------------------------------------------------- |
|
232 // |
|
233 void CSifUi::ConstructL() |
|
234 { |
|
235 iPrivate = CSifUiPrivate::NewL(); |
|
236 } |
|
237 |
|
238 |
|
239 |