262 SSPLOGGER_WRITE("Draw(): Waiting for CLF, bail out"); |
262 SSPLOGGER_WRITE("Draw(): Waiting for CLF, bail out"); |
263 SSPLOGGER_LEAVEFN("Draw()"); |
263 SSPLOGGER_LEAVEFN("Draw()"); |
264 return KErrNone; |
264 return KErrNone; |
265 } |
265 } |
266 // Make sure we have something to display |
266 // Make sure we have something to display |
267 if (iModel->NumberOfSlides() == 0) |
267 if (iModel->NumberOfSlides() == 0 && iIsLoadFinished ) |
268 { |
268 { |
|
269 iHost->RevertToDefaultSaver(); |
269 SSPLOGGER_WRITE("Draw(): Nothing to display, suspending"); |
270 SSPLOGGER_WRITE("Draw(): Nothing to display, suspending"); |
270 SSPLOGGER_LEAVEFN("Draw()"); |
271 SSPLOGGER_LEAVEFN("Draw()"); |
271 // iHost->Suspend( -1 ); // This place will be crashed when transform to default type |
272 // iHost->Suspend( -1 ); // This place will be crashed when transform to default type |
272 return KErrNotFound; |
273 return KErrNone; |
273 } |
274 } |
274 |
275 |
275 CSlideshowSlide* pSlide = iModel->NextSlide(EFalse); |
276 CSlideshowSlide* pSlide = iModel->NextSlide(EFalse); |
276 // get the status of the slide |
277 // get the status of the slide |
277 TInt status = iModel->SlideStatus(pSlide); // TInt decoded(1), decoding(2), not decoding(3),no slide (0) |
278 TInt status = iModel->SlideStatus(pSlide); // TInt decoded(1), decoding(2), not decoding(3),no slide (0) |
718 |
719 |
719 // Loads the slides into the model |
720 // Loads the slides into the model |
720 void CSlideshowPlugin::LoadSlidesL() |
721 void CSlideshowPlugin::LoadSlidesL() |
721 { |
722 { |
722 SSPLOGGER_ENTERFN("LoadSlidesL()"); |
723 SSPLOGGER_ENTERFN("LoadSlidesL()"); |
723 |
724 iIsLoadFinished = EFalse; |
724 // Based on settings, load predefined set or random slides |
725 // Based on settings, load predefined set or random slides |
725 if (iSettings->iSlideshowType == KSlideshowTypeRandom) |
726 if (iSettings->iSlideshowType == KSlideshowTypeRandom) |
726 { |
727 { |
727 LoadRandomSlidesL(); |
728 LoadRandomSlidesL(); |
728 } |
729 } |
729 else |
730 else |
730 { |
731 { |
731 LoadSlideSetL(); |
732 LoadSlideSetL(); |
732 } |
733 } |
733 |
734 iIsLoadFinished = ETrue; |
734 SSPLOGGER_LEAVEFN("LoadSlidesL()"); |
735 SSPLOGGER_LEAVEFN("LoadSlidesL()"); |
735 } |
736 } |
736 |
737 |
737 |
738 |
738 // Load filenames from settings file stored in skin server directory |
739 // Load filenames from settings file stored in skin server directory |