Mercurial > pidgin.yaz
comparison pidgin/win32/nsis/pidgin-installer.nsi @ 16542:e96a4756734a
Remove unused strings cruft from the installer that were left over from when it dealt with the GTK+ theme (It seems like I already did this before). Also, make installing GTK+ optional if it is already installed.
author | Daniel Atallah <daniel.atallah@gmail.com> |
---|---|
date | Fri, 27 Apr 2007 21:53:20 +0000 |
parents | ff2cd3f29f9b |
children | 9b7ed8da299d |
comparison
equal
deleted
inserted
replaced
16541:b33f5b606573 | 16542:e96a4756734a |
---|---|
324 ;-------------------------------- | 324 ;-------------------------------- |
325 ;GTK+ Runtime Install Section | 325 ;GTK+ Runtime Install Section |
326 | 326 |
327 !ifdef WITH_GTK | 327 !ifdef WITH_GTK |
328 Section $(GTK_SECTION_TITLE) SecGtk | 328 Section $(GTK_SECTION_TITLE) SecGtk |
329 SectionIn 1 RO | |
330 | 329 |
331 Call CheckUserInstallRights | 330 Call CheckUserInstallRights |
332 Pop $R1 | 331 Pop $R1 |
333 | 332 |
334 SetOutPath $TEMP | 333 SetOutPath $TEMP |
1063 ; Bad version. If hklm ver and we have hkcu or no rights.. return no gtk | 1062 ; Bad version. If hklm ver and we have hkcu or no rights.. return no gtk |
1064 StrCmp $1 "NONE" no_gtk ; if no rights.. can't upgrade | 1063 StrCmp $1 "NONE" no_gtk ; if no rights.. can't upgrade |
1065 StrCmp $1 "HKCU" 0 +2 ; if HKLM can upgrade.. | 1064 StrCmp $1 "HKCU" 0 +2 ; if HKLM can upgrade.. |
1066 StrCmp $2 "HKLM" no_gtk ; have hkcu rights.. if found hklm ver can't upgrade.. | 1065 StrCmp $2 "HKLM" no_gtk ; have hkcu rights.. if found hklm ver can't upgrade.. |
1067 Push $2 | 1066 Push $2 |
1068 IntCmp $3 1 +3 | 1067 IntCmp $3 1 +3 |
1069 Push "1" ; Optional Upgrade | 1068 Push "1" ; Optional Upgrade |
1070 Goto done | 1069 Goto done |
1071 Push "2" ; Mandatory Upgrade | 1070 Push "2" ; Mandatory Upgrade |
1072 Goto done | 1071 Goto done |
1073 | 1072 |
1074 good_version: | 1073 good_version: |
1075 StrCmp $2 "HKLM" have_hklm_gtk have_hkcu_gtk | 1074 StrCmp $2 "HKLM" have_hklm_gtk have_hkcu_gtk |
1076 have_hkcu_gtk: | 1075 have_hkcu_gtk: |
1077 ; Have HKCU version | 1076 ; Have HKCU version |
1093 Goto done | 1092 Goto done |
1094 | 1093 |
1095 done: | 1094 done: |
1096 ; The top two items on the stack are what we want to return | 1095 ; The top two items on the stack are what we want to return |
1097 Exch 4 | 1096 Exch 4 |
1097 Pop $1 | |
1098 Exch 4 | |
1098 Pop $0 | 1099 Pop $0 |
1099 Exch 4 | |
1100 Pop $3 | 1100 Pop $3 |
1101 Pop $2 | 1101 Pop $2 |
1102 Pop $1 | |
1103 FunctionEnd | 1102 FunctionEnd |
1104 | 1103 |
1105 | 1104 |
1106 !macro RunCheckMacro UN | 1105 !macro RunCheckMacro UN |
1107 Function ${UN}RunCheck | 1106 Function ${UN}RunCheck |
1197 ${GetParent} $SMPROGRAMS $R2 | 1196 ${GetParent} $SMPROGRAMS $R2 |
1198 ${GetParent} $R2 $R2 | 1197 ${GetParent} $R2 $R2 |
1199 StrCpy $INSTDIR "$R2\Pidgin" | 1198 StrCpy $INSTDIR "$R2\Pidgin" |
1200 | 1199 |
1201 instdir_done: | 1200 instdir_done: |
1201 ;LogSet on | |
1202 Pop $R0 | 1202 Pop $R0 |
1203 FunctionEnd | 1203 FunctionEnd |
1204 | 1204 |
1205 Function un.onInit | 1205 Function un.onInit |
1206 Call un.RunCheck | 1206 Call un.RunCheck |
1273 FunctionEnd | 1273 FunctionEnd |
1274 | 1274 |
1275 ; Page enter and exit functions.. | 1275 ; Page enter and exit functions.. |
1276 | 1276 |
1277 Function preWelcomePage | 1277 Function preWelcomePage |
1278 Push R0 | 1278 Push $R0 |
1279 | 1279 |
1280 !ifndef WITH_GTK | 1280 !ifndef WITH_GTK |
1281 ; If this installer dosn't have GTK, check whether we need it. | 1281 ; If this installer dosn't have GTK, check whether we need it. |
1282 ; We do this here an not in .onInit because language change in | 1282 ; We do this here an not in .onInit because language change in |
1283 ; .onInit doesn't take effect until it is finished. | 1283 ; .onInit doesn't take effect until it is finished. |
1290 Quit | 1290 Quit |
1291 | 1291 |
1292 done: | 1292 done: |
1293 | 1293 |
1294 !else | 1294 !else |
1295 Push R1 | 1295 Push $R1 |
1296 Push $R2 | |
1297 | |
1298 ; Make the GTK+ Section RO if it is required. | |
1299 Call DoWeNeedGtk | |
1300 Pop $R0 | |
1301 Pop $R2 | |
1302 IntCmp $R0 1 gtk_not_mandatory gtk_not_mandatory | |
1303 !insertmacro SetSectionFlag ${SecGtk} ${SF_RO} | |
1304 gtk_not_mandatory: | |
1296 | 1305 |
1297 ; If on Win95/98/ME warn them that the GTK+ version wont work | 1306 ; If on Win95/98/ME warn them that the GTK+ version wont work |
1298 Call GetWindowsVersion | 1307 Call GetWindowsVersion |
1299 Pop $R1 | 1308 Pop $R1 |
1300 StrCmp $R1 "95" win_ver_bad | 1309 StrCmp $R1 "95" win_ver_bad |
1302 StrCmp $R1 "ME" win_ver_bad | 1311 StrCmp $R1 "ME" win_ver_bad |
1303 Goto done | 1312 Goto done |
1304 | 1313 |
1305 win_ver_bad: | 1314 win_ver_bad: |
1306 !insertmacro UnselectSection ${SecGtk} | 1315 !insertmacro UnselectSection ${SecGtk} |
1307 !insertmacro SetSectionFlag ${SecGtkNone} ${SF_RO} | 1316 !insertmacro SetSectionFlag ${SecGtk} ${SF_RO} |
1308 !insertmacro UnselectSection ${SecGtkNone} | |
1309 !insertmacro SetSectionFlag ${SecGtkWimp} ${SF_RO} | |
1310 !insertmacro UnselectSection ${SecGtkWimp} | |
1311 !insertmacro SetSectionFlag ${SecGtkBluecurve} ${SF_RO} | |
1312 !insertmacro UnselectSection ${SecGtkBluecurve} | |
1313 !insertmacro SetSectionFlag ${SecGtkLighthouseblue} ${SF_RO} | |
1314 !insertmacro UnselectSection ${SecGtkLighthouseblue} | |
1315 MessageBox MB_OK $(GTK_WINDOWS_INCOMPATIBLE) /SD IDOK | 1317 MessageBox MB_OK $(GTK_WINDOWS_INCOMPATIBLE) /SD IDOK |
1316 Call DoWeNeedGtk | |
1317 Pop $R0 | |
1318 Pop $R1 | |
1319 IntCmp $R0 1 done done ; Upgrade isn't optional - abort if we don't have a suitable version | 1318 IntCmp $R0 1 done done ; Upgrade isn't optional - abort if we don't have a suitable version |
1320 Quit | 1319 Quit |
1321 | 1320 |
1322 done: | 1321 done: |
1322 Pop $R2 | |
1323 Pop $R1 | 1323 Pop $R1 |
1324 !endif | 1324 !endif |
1325 Pop $R0 | 1325 Pop $R0 |
1326 FunctionEnd | 1326 FunctionEnd |
1327 | 1327 |