76 // --------------------------------------------------------------------------- |
77 // --------------------------------------------------------------------------- |
77 // CSisxSifPluginUiHandler::DisplayTextL() |
78 // CSisxSifPluginUiHandler::DisplayTextL() |
78 // --------------------------------------------------------------------------- |
79 // --------------------------------------------------------------------------- |
79 // |
80 // |
80 TBool CSisxSifPluginUiHandler::DisplayTextL( const Swi::CAppInfo& /*aAppInfo*/, |
81 TBool CSisxSifPluginUiHandler::DisplayTextL( const Swi::CAppInfo& /*aAppInfo*/, |
81 Swi::TFileTextOption /*aOption*/, const TDesC& /*aText*/ ) |
82 Swi::TFileTextOption aOption, const TDesC& aText ) |
82 { |
83 { |
83 FLOG( _L("CSisxSifPluginUiHandler::DisplayTextL") ); |
84 FLOG( _L("CSisxSifPluginUiHandler::DisplayTextL") ); |
84 |
85 TBool okToContinue = EFalse; |
85 return ETrue; |
86 |
|
87 switch( aOption ) |
|
88 { |
|
89 case Swi::EInstFileTextOptionContinue: |
|
90 ShowQuestionWithContinueL( aText ); |
|
91 okToContinue = ETrue; |
|
92 break; |
|
93 case Swi::EInstFileTextOptionSkipOneIfNo: |
|
94 okToContinue = ShowQuestionL( aText ); |
|
95 break; |
|
96 case Swi::EInstFileTextOptionAbortIfNo: |
|
97 case Swi::EInstFileTextOptionExitIfNo: |
|
98 okToContinue = ShowQuestionL( aText ); |
|
99 break; |
|
100 case Swi::EInstFileTextOptionForceAbort: |
|
101 ShowQuestionWithContinueL( aText ); |
|
102 break; |
|
103 default: |
|
104 break; |
|
105 } |
|
106 |
|
107 return okToContinue; |
86 } |
108 } |
87 |
109 |
88 // --------------------------------------------------------------------------- |
110 // --------------------------------------------------------------------------- |
89 // CSisxSifPluginUiHandler::DisplayErrorL() |
111 // CSisxSifPluginUiHandler::DisplayErrorL() |
90 // --------------------------------------------------------------------------- |
112 // --------------------------------------------------------------------------- |
91 // |
113 // |
92 void CSisxSifPluginUiHandler::DisplayErrorL( const Swi::CAppInfo& /*aAppInfo*/, |
114 void CSisxSifPluginUiHandler::DisplayErrorL( const Swi::CAppInfo& /*aAppInfo*/, |
93 Swi::TErrorDialog aType, const TDesC& aParam ) |
115 Swi::TErrorDialog aType, const TDesC& aParam ) |
94 { |
116 { |
95 FLOG( _L("CSisxSifPluginUiHandler::DisplayErrorL") ); |
117 FLOG( _L("CSisxSifPluginUiHandler::DisplayErrorL") ); |
96 SetDisplayErrorL( aType, aParam ); |
118 SetErrorSwiErrorL( aType, aParam ); |
97 } |
119 } |
98 |
120 |
99 // --------------------------------------------------------------------------- |
121 // --------------------------------------------------------------------------- |
100 // CSisxSifPluginUiHandler:: |
122 // CSisxSifPluginUiHandler::DisplayDependencyBreakL() |
101 // --------------------------------------------------------------------------- |
123 // --------------------------------------------------------------------------- |
102 // |
124 // |
103 TBool CSisxSifPluginUiHandler::DisplayDependencyBreakL( const Swi::CAppInfo& /*aAppInfo*/, |
125 TBool CSisxSifPluginUiHandler::DisplayDependencyBreakL( const Swi::CAppInfo& /*aAppInfo*/, |
104 const RPointerArray<TDesC>& /*aComponents*/ ) |
126 const RPointerArray<TDesC>& /*aComponents*/ ) |
105 { |
127 { |
106 FLOG( _L("CSisxSifPluginUiHandler::DisplayDependencyBreakL") ); |
128 FLOG( _L("CSisxSifPluginUiHandler::DisplayDependencyBreakL") ); |
107 |
129 TBool okToContinue = EFalse; |
108 return ETrue; |
130 |
|
131 // TODO: localized UI string needed |
|
132 _LIT( KText, "Removal may stop other applications working. Continue?" ); |
|
133 okToContinue = ShowQuestionL( KText ); |
|
134 |
|
135 return okToContinue; |
109 } |
136 } |
110 |
137 |
111 // --------------------------------------------------------------------------- |
138 // --------------------------------------------------------------------------- |
112 // CSisxSifPluginUiHandler::DisplayApplicationsInUseL() |
139 // CSisxSifPluginUiHandler::DisplayApplicationsInUseL() |
113 // --------------------------------------------------------------------------- |
140 // --------------------------------------------------------------------------- |
114 // |
141 // |
115 TBool CSisxSifPluginUiHandler::DisplayApplicationsInUseL( const Swi::CAppInfo& /*aAppInfo*/, |
142 TBool CSisxSifPluginUiHandler::DisplayApplicationsInUseL( const Swi::CAppInfo& /*aAppInfo*/, |
116 const RPointerArray<TDesC>& /*aAppNames*/ ) |
143 const RPointerArray<TDesC>& /*aAppNames*/ ) |
117 { |
144 { |
118 FLOG( _L("CSisxSifPluginUiHandler::DisplayApplicationsInUseL") ); |
145 FLOG( _L("CSisxSifPluginUiHandler::DisplayApplicationsInUseL") ); |
119 |
146 return ETrue; // silently accepted |
120 return ETrue; |
|
121 } |
147 } |
122 |
148 |
123 // --------------------------------------------------------------------------- |
149 // --------------------------------------------------------------------------- |
124 // CSisxSifPluginUiHandler::DisplayQuestionL() |
150 // CSisxSifPluginUiHandler::DisplayQuestionL() |
125 // --------------------------------------------------------------------------- |
151 // --------------------------------------------------------------------------- |
126 // |
152 // |
127 TBool CSisxSifPluginUiHandler::DisplayQuestionL( const Swi::CAppInfo& /*aAppInfo*/, |
153 TBool CSisxSifPluginUiHandler::DisplayQuestionL( const Swi::CAppInfo& /*aAppInfo*/, |
128 Swi::TQuestionDialog aQuestion, const TDesC& /*aDes*/ ) |
154 Swi::TQuestionDialog aQuestion, const TDesC& /*aDes*/ ) |
129 { |
155 { |
130 FLOG( _L("CSisxSifPluginUiHandler::DisplayQuestionL") ); |
156 FLOG( _L("CSisxSifPluginUiHandler::DisplayQuestionL") ); |
131 |
157 TBool okToContinue = EFalse; |
132 TBool result = ETrue; |
158 |
133 switch( aQuestion ) |
159 switch( aQuestion ) |
134 { |
160 { |
135 case Swi::EQuestionIncompatible: |
161 case Swi::EQuestionIncompatible: |
136 if( !iQuestionIncompatibleDisplayed ) |
162 if( !iQuestionIncompatibleDisplayed ) |
137 { |
163 { |
138 // TODO: show dialog |
164 _LIT( KText, "Application not compatible with phone. Continue anyway?" ); |
|
165 okToContinue = ShowQuestionL( KText ); |
139 iQuestionIncompatibleDisplayed = ETrue; |
166 iQuestionIncompatibleDisplayed = ETrue; |
140 } |
167 } |
141 break; |
168 else |
|
169 { |
|
170 okToContinue = ETrue; // already accepted once |
|
171 } |
|
172 break; |
|
173 |
142 case Swi::EQuestionOverwriteFile: |
174 case Swi::EQuestionOverwriteFile: |
143 default: |
175 default: |
144 // silently accepted |
176 okToContinue = ETrue; // silently accepted |
145 break; |
177 break; |
146 } |
178 } |
147 return result; |
179 |
|
180 return okToContinue; |
148 } |
181 } |
149 |
182 |
150 // --------------------------------------------------------------------------- |
183 // --------------------------------------------------------------------------- |
151 // CSisxSifPluginUiHandler::DisplayInstallL() |
184 // CSisxSifPluginUiHandler::DisplayInstallL() |
152 // --------------------------------------------------------------------------- |
185 // --------------------------------------------------------------------------- |
164 // --------------------------------------------------------------------------- |
197 // --------------------------------------------------------------------------- |
165 // CSisxSifPluginUiHandler::DisplayGrantCapabilitiesL() |
198 // CSisxSifPluginUiHandler::DisplayGrantCapabilitiesL() |
166 // --------------------------------------------------------------------------- |
199 // --------------------------------------------------------------------------- |
167 // |
200 // |
168 TBool CSisxSifPluginUiHandler::DisplayGrantCapabilitiesL( const Swi::CAppInfo& /*aAppInfo*/, |
201 TBool CSisxSifPluginUiHandler::DisplayGrantCapabilitiesL( const Swi::CAppInfo& /*aAppInfo*/, |
169 const TCapabilitySet& /*aCapabilitySet*/ ) |
202 const TCapabilitySet& aCapabilitySet ) |
170 { |
203 { |
171 FLOG( _L("CSisxSifPluginUiHandler::DisplayGrantCapabilitiesL") ); |
204 FLOG( _L("CSisxSifPluginUiHandler::DisplayGrantCapabilitiesL") ); |
172 |
205 TBool okToContinue = EFalse; |
173 return ETrue; |
206 |
|
207 okToContinue = iSifUi->ShowGrantCapabilitiesL( aCapabilitySet ); |
|
208 |
|
209 return okToContinue; |
174 } |
210 } |
175 |
211 |
176 // --------------------------------------------------------------------------- |
212 // --------------------------------------------------------------------------- |
177 // CSisxSifPluginUiHandler::DisplayLanguageL() |
213 // CSisxSifPluginUiHandler::DisplayLanguageL() |
178 // --------------------------------------------------------------------------- |
214 // --------------------------------------------------------------------------- |
467 // |
503 // |
468 void CSisxSifPluginUiHandler::DisplayFailedL( const CSisxSifPluginErrorHandler& aError ) |
504 void CSisxSifPluginUiHandler::DisplayFailedL( const CSisxSifPluginErrorHandler& aError ) |
469 { |
505 { |
470 FLOG_1( _L("CSisxSifPluginUiHandler::DisplayFailedL, error code %d"), aError.ErrorCode() ); |
506 FLOG_1( _L("CSisxSifPluginUiHandler::DisplayFailedL, error code %d"), aError.ErrorCode() ); |
471 |
507 |
472 // TODO: add error details |
508 CSifUiErrorInfo* errorInfo = CSifUiErrorInfo::NewLC( aError.ErrorCategory(), |
473 iSifUi->ShowFailedL( aError.ErrorCode(), aError.ErrorMessage() ); |
509 aError.ErrorCode(), aError.ExtendedErrorCode(), aError.ErrorMessage(), |
|
510 aError.ErrorMessageDetails() ); |
|
511 iSifUi->ShowFailedL( *errorInfo ); |
|
512 CleanupStack::PopAndDestroy( errorInfo ); |
474 } |
513 } |
475 |
514 |
476 // --------------------------------------------------------------------------- |
515 // --------------------------------------------------------------------------- |
477 // CSisxSifPluginUiHandler::CSisxSifPluginUiHandler() |
516 // CSisxSifPluginUiHandler::CSisxSifPluginUiHandler() |
478 // --------------------------------------------------------------------------- |
517 // --------------------------------------------------------------------------- |