82 // |
82 // |
83 // |
83 // |
84 // Status : Approved |
84 // Status : Approved |
85 // ---------------------------------------------------------------------------- |
85 // ---------------------------------------------------------------------------- |
86 // |
86 // |
87 CSCPParamObject* CSCPHistoryPlugin::HandleEvent( TInt aID, CSCPParamObject& aParam ) |
87 CSCPParamObject* CSCPHistoryPlugin::HandleEvent(TInt aID, |
88 { |
88 CSCPParamObject& aParam) |
89 Dprint ( ( _L( "CSCPHistoryPlugin::HandleEvent()" ) ) ); |
89 { |
90 // Make the ParamObject for success ack, Delete later |
90 Dprint((_L("CSCPHistoryPlugin::HandleEvent()"))); |
91 CSCPParamObject* retParams = NULL; |
91 // Make the ParamObject for success ack, Delete later |
92 |
92 CSCPParamObject* retParams = NULL; |
93 TBool errRaised; |
93 |
94 errRaised = EFalse; |
94 TBool errRaised; |
95 |
95 errRaised = EFalse; |
96 TBool isInvalid = EFalse; |
96 |
97 |
97 TBool isInvalid = EFalse; |
98 if ( iFs == NULL ) |
98 |
99 { |
99 if (iFs == NULL) |
100 return NULL; // Eventhandler not available |
100 { |
101 } |
101 return NULL; // Eventhandler not available |
102 |
|
103 // Insert the default security code into the history-buffer if not there yet |
|
104 { |
|
105 TInt errSCF = SetConfigFile (); |
|
106 if (errSCF != KErrNone) |
|
107 { |
|
108 return NULL; |
|
109 } |
|
110 |
|
111 TInt historyItemCounter = 0; |
|
112 if ( GetHistoryItemCount( historyItemCounter ) != KErrNone ) |
|
113 { |
|
114 Dprint ( ( _L( "CSCPHistoryPlugin::HandleEvent historyItemCounter = %d" ), historyItemCounter ) ); |
|
115 // Hash the security code |
|
116 TBuf<KSCPPasscodeMaxLength> codeBuf; |
|
117 TBuf<KSCPMaxHashLength> hashBuf; |
|
118 |
|
119 codeBuf.Copy( KSCPDefaultEnchSecCode ); |
|
120 hashBuf.Zero(); |
|
121 |
|
122 iEventHandler->HashInput( codeBuf, hashBuf ); |
|
123 |
|
124 CSCPParamObject* historyObject = NULL; |
|
125 TRAPD( err, historyObject = CSCPParamObject::NewL() ); |
|
126 if ( err == KErrNone ) |
|
127 { |
|
128 historyObject->Set( KHistoryCounterParamID, 1 ); |
|
129 historyObject->Set( KHistoryItemParamBase, hashBuf ); |
|
130 |
|
131 TRAP_IGNORE( historyObject->WriteToFileL( iCfgFilenamepath, iFs ) ); |
|
132 } |
|
133 |
|
134 delete historyObject; |
|
135 } |
|
136 } |
|
137 |
|
138 |
|
139 // check for Case |
|
140 switch ( aID ) |
|
141 { |
|
142 |
|
143 case ( KSCPEventValidate ) : |
|
144 { |
|
145 // Obtain the paramValue |
|
146 Dprint ( ( _L( "CSCPHistoryPlugin::KSCPEventValidate" ) ) ); |
|
147 TInt passhistoryParamValue; |
|
148 passhistoryParamValue = GetHistoryCountParamValue(); |
|
149 Dprint ( ( _L( "CSCPHistoryPlugin::HandleEvent passhistoryParamValue = %d" ), passhistoryParamValue ) ); |
|
150 // if all required bounds are zero, there is nothing to do. |
|
151 if ( passhistoryParamValue != 0) |
|
152 { |
|
153 // Get the configFile's path. |
|
154 // If this fails, there is something badly wrong(Private folder is not there) |
|
155 TInt errSCF = SetConfigFile (); |
|
156 if (errSCF != KErrNone) |
|
157 { |
|
158 errRaised = ETrue; |
|
159 break; // Break out from Case |
|
160 } |
|
161 |
|
162 // Get the historyItemCount, If the err is raised, the file is not there |
|
163 // This will lead to KSCPEventPasswordChanged event and new history file will |
|
164 // be created |
|
165 TInt historyItemCounter; |
|
166 TInt errHC = GetHistoryItemCount( historyItemCounter ); |
|
167 Dprint ( ( _L( "CSCPHistoryPlugin::HandleEvent historyItemCounter = %d" ), historyItemCounter ) ); |
|
168 if (errHC != KErrNone) |
|
169 { |
|
170 errRaised = ETrue; |
|
171 break; // Break out from Case |
|
172 } |
|
173 |
|
174 // continue with the KSCPEventValidate Check |
|
175 |
|
176 // Get the password from the paramObject |
|
177 TBuf<KSCPPasscodeMaxLength> seccode; |
|
178 if ( aParam.Get( KSCPParamPassword, seccode ) != KErrNone ) |
|
179 { |
|
180 // Nothing to do anymore |
|
181 Dprint( (_L("CSCPHistoryPlugin::HandleEvent()\ |
|
182 ERROR: KSCPEventValidate/KSCPParamPassword is != KErrNone") )); |
|
183 errRaised = ETrue; |
|
184 break; // Break out from Case |
|
185 } |
|
186 |
|
187 // Hash the securitycode |
|
188 TBuf<KSCPPasscodeMaxLength> securityhash; |
|
189 iEventHandler->HashInput(seccode,securityhash); |
|
190 |
|
191 // get history |
|
192 CDesCArrayFlat* array = NULL; |
|
193 TInt errGH = KErrNone; |
|
194 |
|
195 array = new CDesCArrayFlat(1); |
|
196 if ( array != NULL ) |
|
197 { |
|
198 TRAPD( err2, errGH = GetHistoryArrayL( *array ) ); |
|
199 if ( err2 != KErrNone ) |
|
200 { |
|
201 errGH = err2; |
|
202 } |
|
203 } |
|
204 else |
|
205 { |
|
206 errGH = KErrNoMemory; |
|
207 } |
|
208 |
|
209 // If for some reason err is raised, break out |
|
210 // If the Historyonfig file get deleted on the fly ex |
|
211 if (errGH != KErrNone) |
|
212 { |
|
213 errRaised = ETrue; |
|
214 array->Reset(); |
|
215 delete array; |
|
216 break; // Break out from Case |
|
217 } |
|
218 TInt correction; |
|
219 correction = 0; |
|
220 |
|
221 if ( array->Count() >= passhistoryParamValue ) |
|
222 { |
|
223 correction = array->Count() - passhistoryParamValue; |
|
224 } |
102 } |
225 // check for match |
103 |
226 TBuf<KSCPPasscodeMaxLength> arrayItem; |
104 // check for Case |
227 |
105 switch (aID) |
228 // Set the historyobject |
106 { |
229 for (TInt i= 0 + correction; i < array->Count(); i++) |
107 |
230 { |
108 case (KSCPEventValidate): |
231 arrayItem = array->MdcaPoint(i); |
109 { |
232 if (arrayItem.Compare(securityhash) == KErrNone) |
110 // Obtain the paramValue |
233 { |
111 Dprint((_L("CSCPHistoryPlugin::KSCPEventValidate"))); |
234 // Get the filesystem for Resource |
112 TInt passhistoryParamValue; |
235 // If fail, bail out |
113 passhistoryParamValue = GetHistoryCountParamValue(); |
236 TInt errgGR = GetResource(); |
114 Dprint( |
237 if (errgGR != KErrNone) |
115 (_L( |
238 { |
116 "CSCPHistoryPlugin::HandleEvent passhistoryParamValue = %d"), passhistoryParamValue)); |
239 errRaised = ETrue; |
117 // if all required bounds are zero, there is nothing to do. |
240 break; // Break out from the For |
118 if (passhistoryParamValue != 0) |
241 } |
119 { |
242 |
120 // Get the configFile's path. |
243 // Prompt buf, iNote can show only 97 chars, |
121 // If this fails, there is something badly wrong(Private folder is not there) |
244 // without ... markings. |
122 TInt errSCF = SetConfigFile(); |
245 HBufC* hbuf = NULL; |
123 if (errSCF != KErrNone) |
246 |
124 { |
247 if ( passhistoryParamValue == 1 ) |
125 errRaised = ETrue; |
248 { |
126 break; // Break out from Case |
249 isInvalid = ETrue; |
127 } |
250 TRAP_IGNORE( |
128 |
251 hbuf = LoadAndFormatResL( R_SET_SEC_CODE_INFO_PREVIOUS ); |
129 // Get the historyItemCount, If the err is raised, the file is not there |
252 ); |
130 // This will lead to KSCPEventPasswordChanged event and new history file will |
253 } |
131 // be created |
254 else |
132 TInt historyItemCounter; |
255 { |
133 TInt errHC = GetHistoryItemCount(historyItemCounter); |
256 isInvalid = ETrue; |
134 Dprint( |
257 TRAP_IGNORE( |
135 (_L( |
258 hbuf = LoadAndFormatResL( |
136 "CSCPHistoryPlugin::HandleEvent historyItemCounter = %d"), historyItemCounter)); |
259 R_SET_SEC_CODE_INFO_CHECK, |
137 if (errHC != KErrNone) |
260 &passhistoryParamValue ); |
138 { |
261 ); |
139 errRaised = ETrue; |
262 } |
140 break; // Break out from Case |
|
141 } |
|
142 |
|
143 // continue with the KSCPEventValidate Check |
|
144 |
|
145 // Get the password from the paramObject |
|
146 TBuf<KSCPPasscodeMaxLength> seccode; |
|
147 if (aParam.Get(KSCPParamPassword, seccode) != KErrNone) |
|
148 { |
|
149 // Nothing to do anymore |
|
150 Dprint( |
|
151 (_L( |
|
152 "CSCPHistoryPlugin::HandleEvent()\ |
|
153 ERROR: KSCPEventValidate/KSCPParamPassword is != KErrNone"))); |
|
154 errRaised = ETrue; |
|
155 break; // Break out from Case |
|
156 } |
|
157 |
|
158 // Hash the securitycode |
|
159 TBuf<KSCPPasscodeMaxLength> securityhash; |
|
160 iEventHandler->HashInput(seccode, securityhash); |
|
161 |
|
162 // get history |
|
163 CDesCArrayFlat* array = NULL; |
|
164 TInt errGH = KErrNone; |
|
165 |
|
166 array = new CDesCArrayFlat(1); |
|
167 if (array != NULL) |
|
168 { |
|
169 TRAPD(err2, errGH = GetHistoryArrayL(*array)); |
|
170 if (err2 != KErrNone) |
|
171 { |
|
172 errGH = err2; |
|
173 } |
|
174 } |
|
175 else |
|
176 { |
|
177 errGH = KErrNoMemory; |
|
178 } |
|
179 |
|
180 // If for some reason err is raised, break out |
|
181 // If the Historyonfig file get deleted on the fly ex |
|
182 if (errGH != KErrNone) |
|
183 { |
|
184 errRaised = ETrue; |
|
185 array->Reset(); |
|
186 delete array; |
|
187 break; // Break out from Case |
|
188 } |
|
189 TInt correction; |
|
190 correction = 0; |
|
191 |
|
192 if (array->Count() >= passhistoryParamValue) |
|
193 { |
|
194 correction = array->Count() - passhistoryParamValue; |
|
195 } |
|
196 // check for match |
|
197 TBuf<KSCPPasscodeMaxLength> arrayItem; |
|
198 |
|
199 // Set the historyobject |
|
200 for (TInt i = 0 + correction; i < array->Count(); i++) |
|
201 { |
|
202 arrayItem = array->MdcaPoint(i); |
|
203 if (arrayItem.Compare(securityhash) == KErrNone) |
|
204 { |
|
205 // Get the filesystem for Resource |
|
206 // If fail, bail out |
|
207 TInt errgGR = GetResource(); |
|
208 if (errgGR != KErrNone) |
|
209 { |
|
210 errRaised = ETrue; |
|
211 break; // Break out from the For |
|
212 } |
|
213 |
|
214 // Prompt buf, iNote can show only 97 chars, |
|
215 // without ... markings. |
|
216 HBufC* hbuf = NULL; |
|
217 |
|
218 if (passhistoryParamValue == 1) |
|
219 { |
|
220 isInvalid = ETrue; |
|
221 TRAP_IGNORE ( |
|
222 hbuf = LoadAndFormatResL( R_SET_SEC_CODE_INFO_PREVIOUS ); |
|
223 ); |
|
224 } |
|
225 else |
|
226 { |
|
227 isInvalid = ETrue; |
|
228 TRAP_IGNORE( |
|
229 hbuf = LoadAndFormatResL( |
|
230 R_SET_SEC_CODE_INFO_CHECK, |
|
231 &passhistoryParamValue ); |
|
232 ); |
|
233 } |
263 |
234 |
264 if ( isInvalid ) |
235 if ( isInvalid ) |
265 { |
236 { |
266 // Create the result-object to return |
237 // Create the result-object to return |
267 TRAPD( err, retParams = CSCPParamObject::NewL() ); |
238 TRAPD( err, retParams = CSCPParamObject::NewL() ); |
268 |
239 |
269 if ( err == KErrNone ) |
240 if ( err == KErrNone ) |
270 { |
241 { |
271 retParams->Set( KSCPParamStatus, KErrSCPInvalidCode ); |
242 retParams->Set( KSCPParamStatus, KErrSCPInvalidCode ); |
272 retParams->Set( KSCPParamAction, KSCPActionShowUI ); |
243 retParams->Set( KSCPParamAction, KSCPActionShowUI ); |
273 retParams->Set( KSCPParamUIMode, KSCPUINote ); |
244 retParams->Set( KSCPParamUIMode, KSCPUINote ); |
274 |
245 |
275 if ( hbuf != NULL ) |
246 if ( hbuf != NULL ) |
276 { |
247 { |
277 TPtr ptr = hbuf->Des(); |
248 TPtr ptr = hbuf->Des(); |
278 retParams->Set( KSCPParamPromptText, ptr ); |
249 retParams->Set( KSCPParamPromptText, ptr ); |
279 delete hbuf; |
250 delete hbuf; |
280 } |
251 } |
281 } |
252 } |
282 |
253 |
283 break; |
254 break; |
284 } |
255 } |
285 |
256 |
286 } // End of compare IF |
257 } // End of compare IF |
287 } // End of For |
258 } // End of For |
288 |
259 |
289 // kill the local |
260 // kill the local |
290 array->Reset(); |
261 array->Reset(); |
291 delete array; |
262 delete array; |
292 |
263 |
293 } // passhistoryParamValue |
264 } // passhistoryParamValue |
294 else |
265 |
295 { |
266 else |
296 retParams = NULL; |
267 { |
297 } |
268 retParams = NULL; |
298 |
269 } |
299 break; |
270 |
300 } // end of KSCPEventValidate |
271 break; |
301 |
272 } // end of KSCPEventValidate |
|
273 |
302 // Someone has changed the Seccode and I need to include it to history |
274 // Someone has changed the Seccode and I need to include it to history |
303 case ( KSCPEventPasswordChanged ) : |
275 case ( KSCPEventPasswordChanged ) : |
304 { |
276 { |
305 // Get the configFile's path. |
277 // Get the configFile's path. |
306 Dprint ( ( _L( "CSCPHistoryPlugin::KSCPEventPasswordChanged" ) ) ); |
278 Dprint ( ( _L( "CSCPHistoryPlugin::KSCPEventPasswordChanged" ) ) ); |
307 TInt errSCF = SetConfigFile (); |
279 TInt errSCF = SetConfigFile (); |
308 if (errSCF != KErrNone) |
280 if (errSCF != KErrNone) |
309 { |
281 { |
310 errRaised = ETrue; |
282 errRaised = ETrue; |
311 break; // Break out from the case |
283 break; // Break out from the case |
312 } |
284 } |
313 |
285 |
314 // Get the password from the paramObject |
286 // Get the password from the paramObject |
315 TBuf<KSCPPasscodeMaxLength> securitycode; |
287 TBuf<KSCPPasscodeMaxLength> securitycode; |
316 if ( aParam.Get( KSCPParamPassword, securitycode ) != KErrNone ) |
288 if ( aParam.Get( KSCPParamPassword, securitycode ) != KErrNone ) |
317 { |
289 { |
318 // Nothing to do anymore |
290 // Nothing to do anymore |
319 Dprint( (_L("CSCPHistoryPlugin::HandleEvent()\ |
291 Dprint( (_L("CSCPHistoryPlugin::HandleEvent()\ |
320 ERROR: KSCPEventPasswordChanged/KSCPParamPassword is != KErrNone") )); |
292 ERROR: KSCPEventPasswordChanged/KSCPParamPassword is != KErrNone") )); |
321 errRaised = ETrue; |
293 errRaised = ETrue; |
322 break; // Break out from the Case |
294 break; // Break out from the Case |
323 } |
295 } |
324 |
296 |
325 // Hash the securitycode |
297 // Hash the securitycode |
326 TBuf<KSCPPasscodeMaxLength> securityhash; |
298 TBuf<KSCPPasscodeMaxLength> securityhash; |
327 iEventHandler->HashInput(securitycode,securityhash); |
299 iEventHandler->HashInput(securitycode,securityhash); |
328 |
300 |
329 // Get the historyItemCount, If error occures, File is not there yet, Make one |
301 // Get the historyItemCount, If error occures, File is not there yet, Make one |
330 TInt historyItemCounter; |
302 TInt historyItemCounter; |
331 TInt errHC = GetHistoryItemCount( historyItemCounter ); |
303 TInt errHC = GetHistoryItemCount( historyItemCounter ); |
332 Dprint ( ( _L( "CSCPHistoryPlugin::HandleEvent historyItemCounter = %d" ), historyItemCounter ) ); |
304 Dprint ( ( _L( "CSCPHistoryPlugin::HandleEvent historyItemCounter = %d" ), historyItemCounter ) ); |
333 if (errHC != KErrNone) |
305 if (errHC != KErrNone) |
334 { |
306 { |
335 // The file does not exist yet (should not happen) |
307 // The file does not exist yet (should not happen) |
336 // Make the ParamObject, Set the New historyData with count of 1 |
308 // Make the ParamObject, Set the New historyData with count of 1 |
337 CSCPParamObject* historyObject = NULL; |
309 CSCPParamObject* historyObject = NULL; |
338 TRAPD( err, historyObject = CSCPParamObject::NewL() ); |
310 TRAPD( err, historyObject = CSCPParamObject::NewL() ); |
339 if ( err == KErrNone ) |
311 if ( err == KErrNone ) |
340 { |
312 { |
341 historyObject->Set(KHistoryCounterParamID,1); |
313 historyObject->Set(KHistoryCounterParamID,1); |
342 historyObject->Set(KHistoryItemParamBase,securityhash ); |
314 historyObject->Set(KHistoryItemParamBase,securityhash ); |
343 |
315 |
344 TRAPD( errWC, historyObject->WriteToFileL( iCfgFilenamepath, iFs ) ); |
316 TRAPD( errWC, historyObject->WriteToFileL( iCfgFilenamepath, iFs ) ); |
345 if ( errWC != KErrNone ) |
317 if ( errWC != KErrNone ) |
346 { |
318 { |
347 Dprint( (_L("CSCPHistoryPlugin::HandleEvent(): WARNING:\ |
319 Dprint( (_L("CSCPHistoryPlugin::HandleEvent(): WARNING:\ |
348 failed to write plugin configuration: %d"), errWC )); |
320 failed to write plugin configuration: %d"), errWC )); |
349 errRaised = ETrue; |
321 errRaised = ETrue; |
350 break; // Break out from the Case |
322 break; // Break out from the Case |
351 } |
323 } |
352 delete historyObject; |
324 delete historyObject; |
353 } |
325 } |
354 } |
326 } |
355 // There are passwords avail. |
327 // There are passwords avail. |
356 else |
328 |
357 { |
329 else |
358 // Append the new passwords |
330 { |
359 TInt err = KErrNone; |
331 // Append the new passwords |
360 TRAPD( err2, err = AppendAndWriteSecurityCodeL( securityhash ) ); |
332 TInt err = KErrNone; |
361 if ( ( err != KErrNone ) || ( err2 != KErrNone ) ) |
333 TRAPD( err2, err = AppendAndWriteSecurityCodeL( securityhash ) ); |
362 { |
334 if ( ( err != KErrNone ) || ( err2 != KErrNone ) ) |
363 errRaised = ETrue; |
335 { |
364 break; // Break out from the Case |
336 errRaised = ETrue; |
365 } |
337 break; // Break out from the Case |
366 } |
338 } |
367 break; |
339 } |
368 } // end of KSCPEventPasswordChanged |
340 break; |
369 |
341 } // end of KSCPEventPasswordChanged |
370 case ( KSCPEventConfigurationQuery ): |
342 |
371 { |
343 case ( KSCPEventConfigurationQuery ): |
|
344 { |
372 Dprint ( ( _L( "CSCPHistoryPlugin::KSCPEventConfigurationQuery" ) ) ); |
345 Dprint ( ( _L( "CSCPHistoryPlugin::KSCPEventConfigurationQuery" ) ) ); |
373 TInt paramID = -1; |
346 TInt paramID = -1; |
374 // Get the ID from the paramObject |
347 // Get the ID from the paramObject |
375 if ( aParam.Get( KSCPParamID, paramID ) != KErrNone ) |
348 if ( aParam.Get( KSCPParamID, paramID ) != KErrNone ) |
376 { |
349 { |
377 // Nothing to do anymore |
350 // Nothing to do anymore |
378 break; |
351 break; |
379 } |
352 } |
380 |
353 |
381 // 1011 |
354 // 1011 |
382 if ( paramID == (RTerminalControl3rdPartySession::EPasscodeHistoryBuffer)) |
355 if ( paramID == (RTerminalControl3rdPartySession::EPasscodeHistoryBuffer)) |
383 { |
356 { |
384 // OK, we're interested, check that the value is valid |
357 // OK, we're interested, check that the value is valid |
385 TRAPD( err, retParams = CSCPParamObject::NewL() ); |
358 TRAPD( err, retParams = CSCPParamObject::NewL() ); |
386 if ( err != KErrNone ) |
359 if ( err != KErrNone ) |
387 { |
360 { |
388 break; // Nothing we can do |
361 break; // Nothing we can do |
389 } |
362 } |
390 |
363 |
391 // All of our params are TInts |
364 // All of our params are TInts |
392 TInt paramValue; |
365 TInt paramValue; |
393 if ( aParam.Get( KSCPParamValue, paramValue ) != KErrNone ) |
366 if ( aParam.Get( KSCPParamValue, paramValue ) != KErrNone ) |
394 { |
367 { |
395 retParams->Set( KSCPParamStatus, KErrGeneral ); |
368 retParams->Set( KSCPParamStatus, KErrGeneral ); |
396 break; |
369 break; |
397 } |
370 } |
398 |
371 |
399 TInt retStatus = KErrNone; |
372 TInt retStatus = KErrNone; |
400 switch ( paramID ) |
373 switch ( paramID ) |
401 { |
374 { |
402 |
375 |
403 case ( RTerminalControl3rdPartySession::EPasscodeHistoryBuffer ): |
376 case ( RTerminalControl3rdPartySession::EPasscodeHistoryBuffer ): |
404 { |
377 { |
405 // Bounds are be be |
378 // Bounds are be be |
406 if ( ( paramValue < KPasscodeHistoryBufferMinValue ) |
379 if ( ( paramValue < KPasscodeHistoryBufferMinValue ) |
407 || ( paramValue > KPasscodeHistoryBufferMaxValue ) ) |
380 || ( paramValue > KPasscodeHistoryBufferMaxValue ) ) |
408 { |
381 { |
409 // This is not a valid valuerange |
382 // This is not a valid valuerange |
410 retStatus = KErrArgument; |
383 retStatus = KErrArgument; |
411 } |
384 } |
412 |
385 |
413 break; |
386 break; |
414 } // end of case EPasscodeHistoryBuffer |
387 } // end of case EPasscodeHistoryBuffer |
415 } // end of switch ( paramID ) |
388 } // end of switch ( paramID ) |
416 |
389 |
417 retParams->Set( KSCPParamStatus, retStatus ); |
390 retParams->Set( KSCPParamStatus, retStatus ); |
418 } |
391 } |
419 else |
392 else |
420 { |
393 { |
421 retParams = NULL; |
394 retParams = NULL; |
422 } |
395 } |
423 |
396 |
424 break; |
397 break; |
425 } //End of KSCPEventConfigurationQuery Case |
398 } //End of KSCPEventConfigurationQuery Case |
426 |
399 |
427 |
400 |
428 case ( KSCPEventReset ): |
401 case ( KSCPEventReset ): |
429 { |
402 { |
430 Dprint ( ( _L( "CSCPHistoryPlugin::KSCPEventReset" ) ) ); |
403 Dprint ( ( _L( "CSCPHistoryPlugin::KSCPEventReset" ) ) ); |
431 // Reset the configuration for this plugin. |
404 // Reset the configuration for this plugin. |
432 TRAP_IGNORE( FlushConfigFileL() ); |
405 TRAP_IGNORE( FlushConfigFileL() ); |
433 |
406 |
434 break; |
407 break; |
435 } |
408 } |
436 |
409 |
437 } // End of switch ( aID ) |
410 } // End of switch ( aID ) |
438 |
411 |
439 // Check if Any errors were raised and handle it |
412 // Check if Any errors were raised and handle it |
440 if (errRaised) |
413 if (errRaised) |
441 { |
414 { |
442 if ( retParams != NULL ) |
415 if ( retParams != NULL ) |
443 { |
416 { |
444 delete retParams; |
417 delete retParams; |
445 } |
418 } |
446 retParams = NULL; |
419 retParams = NULL; |
447 } |
420 } |
448 |
421 |
449 return retParams; |
422 return retParams; |
450 } |
423 } |
451 |
424 |
452 // ---------------------------------------------------------------------------- |
425 // ---------------------------------------------------------------------------- |
453 // CSCPHistoryPlugin::SetEventHandler |
426 // CSCPHistoryPlugin::SetEventHandler |
454 // SetEventHandler |
427 // SetEventHandler |