equal
deleted
inserted
replaced
150 // |
150 // |
151 EXPORT_C void CGSParentPlugin::OpenLocalizedResourceFileL( |
151 EXPORT_C void CGSParentPlugin::OpenLocalizedResourceFileL( |
152 const TDesC& aResourceFileName, |
152 const TDesC& aResourceFileName, |
153 RConeResourceLoader& aResourceLoader ) |
153 RConeResourceLoader& aResourceLoader ) |
154 { |
154 { |
155 RFs fsSession; |
155 RFs &fsSession = CCoeEnv::Static()->FsSession(); |
156 User::LeaveIfError( fsSession.Connect() ); |
|
157 |
156 |
158 // Find the resource file: |
157 // Find the resource file: |
159 TParse parse; |
158 TParse parse; |
160 parse.Set( aResourceFileName, &KDC_RESOURCE_FILES_DIR, NULL ); |
159 parse.Set( aResourceFileName, &KDC_RESOURCE_FILES_DIR, NULL ); |
161 TFileName fileName( parse.FullName() ); |
160 TFileName fileName( parse.FullName() ); |
163 // Get language of resource file: |
162 // Get language of resource file: |
164 BaflUtils::NearestLanguageFile( fsSession, fileName ); |
163 BaflUtils::NearestLanguageFile( fsSession, fileName ); |
165 |
164 |
166 // Open resource file: |
165 // Open resource file: |
167 aResourceLoader.OpenL( fileName ); |
166 aResourceLoader.OpenL( fileName ); |
168 |
|
169 // If leave occurs before this, close is called automatically when the |
|
170 // thread exits. |
|
171 fsSession.Close(); |
|
172 } |
167 } |
173 |
168 |
174 |
169 |
175 // --------------------------------------------------------------------------- |
170 // --------------------------------------------------------------------------- |
176 // CGSParentPlugin::DoActivateL() |
171 // CGSParentPlugin::DoActivateL() |