Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commita61ed4a

Browse files
committed
Does not select a language for install if current Windows ANSI code page is not 1251
1 parent67f6078 commita61ed4a

File tree

1 file changed

+28
-9
lines changed

1 file changed

+28
-9
lines changed

‎nsis/postgresql.nsi

Lines changed: 28 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@
2626
!include"StrContains.nsh"
2727
!insertmacro VersionCompare
2828
;--------------------------------
29+
!define LANGFILE_LANGDLL_FMT"%ENGNAME%"; or %NATIVEASCIINAME%, %NATIVENAME% can also be used but it will display ? in some cases.
2930
;General
3031
Name"${PRODUCT_NAME} ${PRODUCT_VERSION}"
3132
OutFile"${BUILD_DIR}\installers\${PRODUCT_NAME}_${PG_DEF_VERSION}_${PG_INS_SUFFIX}"
@@ -201,6 +202,7 @@ Page custom nsDialogMore nsDialogsMorePageLeave
201202
!insertmacro MUI_LANGUAGE"English";first language is the default language
202203
!insertmacro MUI_LANGUAGE"Russian"
203204

205+
204206
!include translates.nsi
205207

206208
!ifndef myLicenseFile_ru
@@ -2115,6 +2117,16 @@ FunctionEnd
21152117
!insertmacro GetUIId "un."
21162118
*/
21172119

2120+
!macro GetUIId UN
2121+
Function${UN}GetUIId
2122+
;System::Call 'kernel32::GetSystemDefaultLCID() i.r10'
2123+
System::Call'kernel32::GetACP() i.r10'
2124+
Push$R0
2125+
FunctionEnd
2126+
!macroend
2127+
!insertmacro GetUIId""
2128+
!insertmacro GetUIId"un."
2129+
21182130
Function .onInit
21192131
Call CheckWindowsVersion
21202132
Call SetDefaultTcpPort
@@ -2130,20 +2142,23 @@ ${EndIf}
21302142

21312143

21322144
;SectionSetFlags ${secClient} ${SF_RO}
2133-
/* Call GetUIId
2145+
Call GetUIId
21342146
pop$R0
2135-
${if} $R0 == "1049"
2147+
${if}$R0=="1251"
21362148
!define MUI_LANGDLL_ALLLANGUAGES
21372149
!insertmacro MUI_LANGDLL_DISPLAY;select language
2150+
${else}
2151+
StrCpy$LANGUAGE${LANG_ENGLISH}
21382152
${endif}
2139-
*/
2153+
2154+
/*
21402155
CheckLang::CheckLang "0419"
21412156
pop $R0
21422157
${if} $R0 == "1"
21432158
!define MUI_LANGDLL_ALLLANGUAGES
21442159
!insertmacro MUI_LANGDLL_DISPLAY ;select language
21452160
${endif}
2146-
2161+
*/
21472162

21482163

21492164
StrCpy$PG_OLD_DIR""
@@ -2437,17 +2452,21 @@ Function nsDialogsMorePageLeave
24372452
FunctionEnd
24382453

24392454
Function un.onInit
2455+
/*
24402456
CheckLang::CheckLang "0419"
24412457
pop $R0
24422458
${if} $R0 == "1"
24432459
!insertmacro MUI_LANGDLL_DISPLAY ;select language
24442460
${endif}
2445-
2446-
/*Call un.GetUIId
2461+
*/
2462+
Call un.GetUIId
24472463
pop$R0
2448-
${if} $R0 == "1049"
2464+
${if}$R0=="1251"
24492465
;!define MUI_LANGDLL_ALLLANGUAGES
24502466
!insertmacro MUI_LANGDLL_DISPLAY;select language
2451-
${endif}*/
2467+
${else}
2468+
StrCpy$LANGUAGE${LANG_ENGLISH}
24522469

2453-
FunctionEnd
2470+
${endif}
2471+
2472+
FunctionEnd

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp