80 iKywdTOC1View = NULL; |
80 iKywdTOC1View = NULL; |
81 iKywdTOC2View = NULL; |
81 iKywdTOC2View = NULL; |
82 iHtmlTopicView = NULL; |
82 iHtmlTopicView = NULL; |
83 iLegacyTopicView = NULL; |
83 iLegacyTopicView = NULL; |
84 iLegacyContextTopicView = NULL; |
84 iLegacyContextTopicView = NULL; |
|
85 iAppHelpsTOC1View = NULL; |
|
86 iAppHelpsTOC2View = NULL; |
85 |
87 |
86 SetDefaultViewL(*iTOC1View); |
88 SetDefaultViewL(*iTOC1View); |
87 |
89 |
88 iRuntimeWatcher = CCSXHRuntimeAppWatcher::NewL(); |
90 iRuntimeWatcher = CCSXHRuntimeAppWatcher::NewL(); |
89 iRuntimeWatcher->SetObserver( this ); |
91 iRuntimeWatcher->SetObserver( this ); |
165 else if(aViewID == KCSXHToc2ViewID && iTOC2View == NULL) |
167 else if(aViewID == KCSXHToc2ViewID && iTOC2View == NULL) |
166 { |
168 { |
167 iTOC2View = CCSXHGenericView::NewL(KCSXHToc2ViewID,R_TOPICLIST); |
169 iTOC2View = CCSXHGenericView::NewL(KCSXHToc2ViewID,R_TOPICLIST); |
168 AddViewL(iTOC2View); |
170 AddViewL(iTOC2View); |
169 } |
171 } |
|
172 else if(aViewID == KCSXHToc2AppHelpsViewID && iAppHelpsTOC2View == NULL) |
|
173 { |
|
174 iAppHelpsTOC2View = CCSXHGenericView::NewL(KCSXHToc2AppHelpsViewID,R_TOPICLIST); |
|
175 AddViewL(iAppHelpsTOC2View); |
|
176 } |
170 else if(aViewID == KCSXHKywdToc1ViewID && iKywdTOC1View == NULL) |
177 else if(aViewID == KCSXHKywdToc1ViewID && iKywdTOC1View == NULL) |
171 { |
178 { |
172 iKywdTOC1View = CCSXHGenericView::NewL(KCSXHKywdToc1ViewID,R_KYWDTOC1LIST); |
179 iKywdTOC1View = CCSXHGenericView::NewL(KCSXHKywdToc1ViewID,R_KYWDTOC1LIST); |
173 AddViewL(iKywdTOC1View); |
180 AddViewL(iKywdTOC1View); |
174 } |
181 } |
212 { |
219 { |
213 //View is already created update the softkeys to Options and Back |
220 //View is already created update the softkeys to Options and Back |
214 iHtmlTopicView->SetViewTypeL(CCSXHHtmlTopicView::EHtmlView); |
221 iHtmlTopicView->SetViewTypeL(CCSXHHtmlTopicView::EHtmlView); |
215 } |
222 } |
216 } |
223 } |
|
224 else if ( aViewID == KCSXHToc1AppHelpsViewID && !iAppHelpsTOC1View ) |
|
225 { |
|
226 iAppHelpsTOC1View = CCSXHGenericView::NewL( KCSXHToc1AppHelpsViewID, R_TOPICLIST ); |
|
227 AddViewL( iAppHelpsTOC1View ); |
|
228 } |
217 } |
229 } |
218 // -------------------------------------------------------------------------- |
230 // -------------------------------------------------------------------------- |
219 // Activates the view corresponding to the topic to be displayed |
231 // Activates the view corresponding to the topic to be displayed |
220 // It also sets for recreating the container dending on the view to be |
232 // It also sets for recreating the container dending on the view to be |
221 // activated, |
233 // activated, |
236 { |
248 { |
237 if(iKywdTOC2View) |
249 if(iKywdTOC2View) |
238 iKywdTOC2View->ResetContainer(); |
250 iKywdTOC2View->ResetContainer(); |
239 if(iTOC2View) |
251 if(iTOC2View) |
240 iTOC2View->ResetContainer(); |
252 iTOC2View->ResetContainer(); |
|
253 if (iAppHelpsTOC2View) |
|
254 iAppHelpsTOC2View->ResetContainer(); |
241 } |
255 } |
242 else if(viewId == KCSXHToc1ViewID || |
256 else if(viewId == KCSXHToc1ViewID || |
243 viewId == KCSXHContextHtmlTopicViewID || |
257 viewId == KCSXHContextHtmlTopicViewID || |
244 viewId == KCSXHContextLegacyTopicViewID ) |
258 viewId == KCSXHContextLegacyTopicViewID || |
|
259 viewId == KCSXHToc1AppHelpsViewID) |
245 { |
260 { |
246 if(iTOC2View) |
261 if(iTOC2View) |
247 iTOC2View->ResetContainer(); |
262 iTOC2View->ResetContainer(); |
|
263 if (iAppHelpsTOC2View) |
|
264 iAppHelpsTOC2View->ResetContainer(); |
248 } |
265 } |
249 /* else if(viewId == KCSXHKywdToc1ViewID) |
266 /* else if(viewId == KCSXHKywdToc1ViewID) |
250 { |
267 { |
251 doc->InitProgressBarL(); |
268 doc->InitProgressBarL(); |
252 } |
269 } |
329 |
346 |
330 //No topic avaliable, activate the TOC1 View & Pop a message |
347 //No topic avaliable, activate the TOC1 View & Pop a message |
331 doc->SetDisplayTopic(doc->GetHelpDataBase()->GetMainTopics()); |
348 doc->SetDisplayTopic(doc->GetHelpDataBase()->GetMainTopics()); |
332 ActivateDisplayTopicViewL(); |
349 ActivateDisplayTopicViewL(); |
333 |
350 |
334 HBufC* ErrorMessage = iCoeEnv->AllocReadResourceLC(R_TYPE_NO_HELP_TOPICS); |
351 // HBufC* ErrorMessage = iCoeEnv->AllocReadResourceLC(R_TYPE_NO_HELP_TOPICS); |
335 CAknGlobalNote* note = CAknGlobalNote::NewLC(); |
352 // CAknGlobalNote* note = CAknGlobalNote::NewLC(); |
336 note->ShowNoteL(EAknGlobalInformationNote, *ErrorMessage); |
353 // note->ShowNoteL(EAknGlobalInformationNote, *ErrorMessage); |
337 |
354 |
338 CleanupStack::PopAndDestroy(note); |
355 // CleanupStack::PopAndDestroy(note); |
339 CleanupStack::PopAndDestroy(ErrorMessage); |
356 // CleanupStack::PopAndDestroy(ErrorMessage); |
340 } |
357 } |
341 |
358 |
342 CCSXHAppUi* CCSXHAppUi::GetInstance() |
359 CCSXHAppUi* CCSXHAppUi::GetInstance() |
343 { |
360 { |
344 return iInstance; |
361 return iInstance; |
394 iKywdTOC1View->ResourceChangeHdl(aType); |
411 iKywdTOC1View->ResourceChangeHdl(aType); |
395 if(iKywdTOC2View) |
412 if(iKywdTOC2View) |
396 iKywdTOC2View->ResourceChangeHdl(aType); |
413 iKywdTOC2View->ResourceChangeHdl(aType); |
397 if(iTOC2View) |
414 if(iTOC2View) |
398 iTOC2View->ResourceChangeHdl(aType); |
415 iTOC2View->ResourceChangeHdl(aType); |
|
416 if (iAppHelpsTOC2View) |
|
417 iAppHelpsTOC2View->ResourceChangeHdl(aType); |
|
418 if (iAppHelpsTOC1View) |
|
419 iAppHelpsTOC1View->ResourceChangeHdl(aType); |
399 if(iHtmlTopicView) |
420 if(iHtmlTopicView) |
400 iHtmlTopicView->ResourceChangeHdl(aType); |
421 iHtmlTopicView->ResourceChangeHdl(aType); |
401 if(iLegacyTopicView) |
422 if(iLegacyTopicView) |
402 iLegacyTopicView->ResourceChangeHdl(aType); |
423 iLegacyTopicView->ResourceChangeHdl(aType); |
403 if(iLegacyContextTopicView) |
424 if(iLegacyContextTopicView) |
404 iLegacyContextTopicView->ResourceChangeHdl(aType); |
425 iLegacyContextTopicView->ResourceChangeHdl(aType); |
405 } |
426 } |
406 |
427 |
407 void CCSXHAppUi::RuntimeUpdateIndex() |
428 void CCSXHAppUi::RuntimeUpdateIndex() |
408 { |
429 { |
409 CAknNoteDialog* dlg = new ( ELeave ) CAknNoteDialog(); |
430 CAknNoteDialog* dlg = new CAknNoteDialog(); |
410 dlg->SetTimeout( CAknNoteDialog::EShortTimeout ); |
431 if (dlg != NULL) |
411 dlg->SetTone( CAknNoteDialog::ENoTone ); |
432 { |
412 dlg->ExecuteLD( R_CSHELP_INSTALL_UNINSTALL_NOTE ); |
433 dlg->SetTimeout( CAknNoteDialog::EShortTimeout ); |
|
434 dlg->SetTone( CAknNoteDialog::ENoTone ); |
|
435 TRAP_IGNORE(dlg->ExecuteLD(R_CSHELP_INSTALL_UNINSTALL_NOTE)); |
|
436 } |
413 } |
437 } |
414 |
438 |
415 |
439 |
416 #ifdef FF_HELP_TUTORIAL_MERGE |
440 #ifdef FF_HELP_TUTORIAL_MERGE |
417 // -------------------------------------------------------------------------- |
441 // -------------------------------------------------------------------------- |
435 |
459 |
436 // -------------------------------------------------------------------------- |
460 // -------------------------------------------------------------------------- |
437 // CCSXHAppUi::LoadTutorialService |
461 // CCSXHAppUi::LoadTutorialService |
438 // Load service handler and attach interest for using tutorial service command. |
462 // Load service handler and attach interest for using tutorial service command. |
439 // -------------------------------------------------------------------------- |
463 // -------------------------------------------------------------------------- |
440 void CCSXHAppUi::LoadTutorialService() |
464 void CCSXHAppUi::LoadTutorialServiceL() |
441 { |
465 { |
442 iServiceHandler = CAiwServiceHandler::NewL(); |
466 iServiceHandler = CAiwServiceHandler::NewL(); |
443 |
467 |
444 // Create AIW interest |
468 // Create AIW interest |
445 RCriteriaArray interest; |
469 RCriteriaArray interest; |