gssettingsuis/Gs/GSApplication/Src/GSMainView.cpp
branchRCL_3
changeset 20 9941bcf99348
parent 13 23553eb4e470
child 25 3b47783fdf16
equal deleted inserted replaced
17:f392bfb21e08 20:9941bcf99348
   142 //
   142 //
   143 // ---------------------------------------------------------------------------
   143 // ---------------------------------------------------------------------------
   144 //
   144 //
   145 void CGSMainView::OpenLocalizedResourceFileL( const TDesC& aResourceFileName )
   145 void CGSMainView::OpenLocalizedResourceFileL( const TDesC& aResourceFileName )
   146     {
   146     {
   147     RFs fsSession;
   147     RFs &fsSession = CCoeEnv::Static()->FsSession();
   148     User::LeaveIfError( fsSession.Connect() );
       
   149     CleanupClosePushL( fsSession );
       
   150 
   148 
   151     // Find the resource file
   149     // Find the resource file
   152     TParse parse;
   150     TParse parse;
   153     parse.Set( aResourceFileName, &KDC_APP_RESOURCE_DIR, NULL );
   151     parse.Set( aResourceFileName, &KDC_APP_RESOURCE_DIR, NULL );
   154     TFileName fileName( parse.FullName() );
   152     TFileName fileName( parse.FullName() );
   156     // Get language of resource file
   154     // Get language of resource file
   157     BaflUtils::NearestLanguageFile( fsSession, fileName );
   155     BaflUtils::NearestLanguageFile( fsSession, fileName );
   158 
   156 
   159     // Open resource file
   157     // Open resource file
   160     iResourceLoader.OpenL( fileName );
   158     iResourceLoader.OpenL( fileName );
   161 
       
   162     CleanupStack::PopAndDestroy( &fsSession );
       
   163     }
   159     }
   164 
   160 
   165 
   161 
   166 // ---------------------------------------------------------------------------
   162 // ---------------------------------------------------------------------------
   167 // TUid CGSMainView::Id()
   163 // TUid CGSMainView::Id()