aboutsummaryrefslogtreecommitdiffstats
path: root/unicode/src/base/ULanguage.pas
diff options
context:
space:
mode:
authortobigun <tobigun@b956fd51-792f-4845-bead-9b4dfca2ff2c>2009-07-23 21:38:29 +0000
committertobigun <tobigun@b956fd51-792f-4845-bead-9b4dfca2ff2c>2009-07-23 21:38:29 +0000
commit25e06fe0c8c6c6091653f5ff0d524e1022a98551 (patch)
treecf891f53e2344ed952c7933d123d03d6d052a9e7 /unicode/src/base/ULanguage.pas
parentb5ddc6c8de90632ac8cbd9c2c1d3eb30534d66cb (diff)
downloadusdx-25e06fe0c8c6c6091653f5ff0d524e1022a98551.tar.gz
usdx-25e06fe0c8c6c6091653f5ff0d524e1022a98551.tar.xz
usdx-25e06fe0c8c6c6091653f5ff0d524e1022a98551.zip
- language files converted to UTF-8 WITH BOM (!!!)
- replaced TIniFile with TUnicodeMemIniFile in ULanguage as neither TIniFile nor TMemIniFile are capabable of handling the UTF-8 BOM correctly (for example the first section name that is preceded by a BOM is ignored and hence the whole section is ignored) git-svn-id: svn://svn.code.sf.net/p/ultrastardx/svn/branches/experimental@1914 b956fd51-792f-4845-bead-9b4dfca2ff2c
Diffstat (limited to '')
-rw-r--r--unicode/src/base/ULanguage.pas4
1 files changed, 2 insertions, 2 deletions
diff --git a/unicode/src/base/ULanguage.pas b/unicode/src/base/ULanguage.pas
index 3dd5a9e0..02615fed 100644
--- a/unicode/src/base/ULanguage.pas
+++ b/unicode/src/base/ULanguage.pas
@@ -161,12 +161,12 @@ end;
*}
procedure TLanguage.ChangeLanguage(const Language: AnsiString);
var
- IniFile: TIniFile;
+ IniFile: TUnicodeMemIniFile;
E: integer; // entry
S: TStringList;
begin
SetLength(Entry, 0);
- IniFile := TIniFile.Create(LanguagesPath.Append(Language + '.ini').ToNative);
+ IniFile := TUnicodeMemIniFile.Create(LanguagesPath.Append(Language + '.ini'));
S := TStringList.Create;
IniFile.ReadSectionValues('Text', S);