diff --git a/packages/delphiXE/heidisql.dpr b/packages/delphiXE/heidisql.dpr index 9a71e344..ee015a63 100644 --- a/packages/delphiXE/heidisql.dpr +++ b/packages/delphiXE/heidisql.dpr @@ -47,6 +47,8 @@ uses {$R ..\..\res\manifest.RES} {$R ..\..\res\updater.RES} +var + AppLanguage: String; begin // Use MySQL standard format for date/time variables: YYYY-MM-DD HH:MM:SS // Be aware that Delphi internally converts the slashes in ShortDateFormat to the DateSeparator @@ -61,6 +63,8 @@ begin AppSettings.Free; Application.Terminate; end else begin + AppLanguage := AppSettings.ReadString(asAppLanguage); + UseLanguage(AppLanguage); Application.Initialize; Application.Title := APPNAME; Application.UpdateFormatSettings := False; diff --git a/source/helpers.pas b/source/helpers.pas index fda76b32..311c9e7a 100644 --- a/source/helpers.pas +++ b/source/helpers.pas @@ -172,7 +172,7 @@ type asFieldEditorSet, asFieldNullBackground, asGroupTreeObjects, asDisplayObjectSizeColumn, asSQLfile, asActionShortcut1, asActionShortcut2, asHighlighterForeground, asHighlighterBackground, asHighlighterStyle, asListColWidths, asListColsVisible, asListColPositions, asListColSort, asSessionFolder, - asRecentFilter, asDateTimeEditorCursorPos); + asRecentFilter, asDateTimeEditorCursorPos, asAppLanguage); TAppSetting = record Name: String; Session: Boolean; @@ -3113,6 +3113,7 @@ begin InitSetting(asSessionFolder, 'Folder', 0, False); InitSetting(asRecentFilter, '%s', 0, False, '', True); InitSetting(asDateTimeEditorCursorPos, 'DateTimeEditor_CursorPos_Type%s', 0); + InitSetting(asAppLanguage, 'Language', 0, False, ''); end;