2776 iRomInstaller = ChspsRomInstaller::NewL( *this, iFsSession ); |
2776 iRomInstaller = ChspsRomInstaller::NewL( *this, iFsSession ); |
2777 #ifdef HSPS_LOG_ACTIVE |
2777 #ifdef HSPS_LOG_ACTIVE |
2778 iRomInstaller->SetLogBus( iLogBus ); |
2778 iRomInstaller->SetLogBus( iLogBus ); |
2779 #endif |
2779 #endif |
2780 |
2780 |
2781 RPointerArray<HBufC> pluginFolders; |
2781 iRomInstaller->InstallL(); |
2782 CleanupClosePushL( pluginFolders ); |
2782 |
2783 |
|
2784 // Find UDA and ROM widgets to be installed |
|
2785 iRomInstaller->FindInstallationFilesL( pluginFolders ); |
|
2786 |
|
2787 // Install the manifest files |
|
2788 for( TInt index=0; index < pluginFolders.Count(); index++ ) |
|
2789 { |
|
2790 TPtrC namePtr( pluginFolders[index]->Des() ); |
|
2791 #ifdef HSPS_LOG_ACTIVE |
|
2792 iLogBus->LogText( _L( "ChspsThemeServer::InstallWidgetsL(): - installing configuration: %S" ), &namePtr ); |
|
2793 #endif |
|
2794 |
|
2795 // Synchronous method |
|
2796 ThspsServiceCompletedMessage ret = iRomInstaller->InstallThemeL( namePtr ); |
|
2797 if ( ret != EhspsInstallThemeSuccess ) |
|
2798 { |
|
2799 #ifdef HSPS_LOG_ACTIVE |
|
2800 iLogBus->LogText( _L( "ChspsThemeServer::InstallWidgetsL(): - installation failed: %S" ), &namePtr ); |
|
2801 #endif |
|
2802 // User::Leave( KErrAbort ); |
|
2803 } |
|
2804 } |
|
2805 |
|
2806 if ( pluginFolders.Count() == 0 ) |
|
2807 { |
|
2808 #ifdef HSPS_LOG_ACTIVE |
|
2809 iLogBus->LogText( _L( "ChspsThemeServer::InstallWidgetsL(): - mandatory plugins were not found!" ) ); |
|
2810 #endif |
|
2811 // Mandatory plugins were missing |
|
2812 User::Leave( KErrCorrupt ); |
|
2813 } |
|
2814 |
|
2815 pluginFolders.ResetAndDestroy(); |
|
2816 CleanupStack::PopAndDestroy( 1, &pluginFolders ); |
|
2817 |
|
2818 // The ROM installer is not needed anymore and therefore it can be released |
|
2819 delete iRomInstaller; |
2783 delete iRomInstaller; |
2820 iRomInstaller = 0; |
2784 iRomInstaller = 0; |
2821 |
2785 |
2822 // Force updating of the header cache |
2786 // Force updating of the header cache |
2823 ThspsRepositoryInfo info( EhspsCacheUpdate ); |
2787 ThspsRepositoryInfo info( EhspsCacheUpdate ); |