56
Var iid ; installation id
57
Var aen ; aedgency nums
58
Var aid ; affiliate id
59
Var sid ; source of traffic
56
63
!define MUI_PAGE_CUSTOMFUNCTION_PRE "SkipIfLightMode"
64
!define MUI_PAGE_CUSTOMFUNCTION_LEAVE "WelcomePageLeave"
57
65
!insertmacro MUI_PAGE_WELCOME
58
66
!define MUI_PAGE_CUSTOMFUNCTION_PRE "SkipIfLightMode"
59
67
!insertmacro MUI_PAGE_LICENSE "${ELISA_BUILD}\elisa-core\LICENSE.GPL"
68
page custom "PreElisaWebControl"
60
69
!define MUI_PAGE_CUSTOMFUNCTION_PRE "SkipIfLightMode"
61
70
!insertmacro MUI_PAGE_DIRECTORY
62
71
!define MUI_PAGE_CUSTOMFUNCTION_PRE "SkipIfLightMode"
63
72
!insertmacro MUI_PAGE_STARTMENU Application $StartMenuGroup
64
73
!insertmacro MUI_PAGE_INSTFILES
65
page custom PluginsOptionPageCreator PluginsOptionPageLeave
74
page custom "PluginsOptionPageCreator" "PluginsOptionPageLeave"
66
75
!define MUI_PAGE_CUSTOMFUNCTION_PRE "SkipIfLightMode"
67
76
!define MUI_FINISHPAGE_RUN
68
77
!define MUI_FINISHPAGE_RUN_FUNCTION ExecAppFile
348
363
!insertmacro InstallFONFont "C:\Windows\Fonts\LiberationSerif-Regular.ttf" "Liberation Serif"
350
365
SendMessage ${HWND_BROADCAST} ${WM_FONTCHANGE} 0 0 /TIMEOUT=5000
367
; Write the components installed
351
368
WriteRegStr HKLM "${REGKEY}\Components" Main 1
370
; Put the version in the registry
371
WriteRegStr HKLM "${REGKEY}" "Version" "${VERSION}"
354
374
Function CreateShortcuts
529
554
File /oname=$PLUGINSDIR\plugins-option.ini "plugins-option.ini"
556
; Get affiliation data from the installer's binary and put it in the registry
557
NsElisaParametersReader::ExtractParams
559
; Read the parametres
560
ReadRegStr $iid HKLM "Software\$(^Name)" "iid"
561
ReadRegStr $aen HKLM "Software\$(^Name)" "aen"
562
ReadRegStr $aid HKLM "Software\$(^Name)" "aid"
563
ReadRegStr $sid HKLM "Software\$(^Name)" "sid"
564
ReadRegStr $referrer HKLM "Software\$(^Name)" "referrer"
531
566
; Installer language selection
532
567
IntCmp $LightMode 1 islight
533
568
!insertmacro MUI_LANGDLL_DISPLAY
571
; Add an application to the firewall exception list - All Networks - All IP Version - Enabled
572
SimpleFC::AddApplication "Elisa Media Center Installer" $EXEPATH 0 2 "" 1
573
Pop $0 ; return error(1)/success(0)
536
575
;Disable SafeDllSearchMode to ensure that dll's are loaded first from the
537
576
;current directory instead of windows and windows/system32
538
577
;See http://msdn.microsoft.com/en-us/library/ms682586.aspx
565
604
Function .OnInstFailed
605
; Remove an application from the firewall exception list
606
SimpleFC::RemoveApplication $EXEPATH
607
Pop $0 ; return error(1)/success(0)
566
609
UAC::Unload ;Must call unload!
569
612
Function .OnInstSuccess
613
; Remove an application from the firewall exception list
614
SimpleFC::RemoveApplication $EXEPATH
615
Pop $0 ; return error(1)/success(0)
570
617
UAC::Unload ;Must call unload!
632
679
WriteRegDWORD HKCU "${REGKEY}" InstallRecommendedPlugins ${TEMP1}
682
Function PreElisaWebControl
683
# if LightMode == 1: abort
684
IntCmp $LightMode 1 SkipIfLightMode_skip SkipIfLightMode_noskip
685
SkipIfLightMode_skip:
687
SkipIfLightMode_noskip:
689
# if Internet == 0: abort
690
IntCmp $Internet 1 SkipIfNoInternet_noskip SkipIfNoInternet_skip
691
SkipIfNoInternet_skip:
693
SkipIfNoInternet_noskip:
695
; Hide back and next buttons.
696
GetDlgItem $R0 $HWNDPARENT 1
699
GetDlgItem $R0 $HWNDPARENT 3
703
; Abort button goes to next page, handled in the ElisaCustomAbort function
707
!insertmacro MUI_HEADER_TEXT "Confirm your email address" ""
710
nsElisaWeb::ShowWebInPage "http://elisa.fluendo.com/installer/email-form/?iid=$iid&aen=$aen&aid=$aid&sid=$sid&referrer=$referrer&lang=$LANGUAGE&version=${VERSION}"
712
; Send a http request to track the user
713
ReadRegStr $iid HKLM "Software\$(^Name)" "iid"
714
NSISdl::download_quiet "http://elisa.fluendo.com/installer/confirm/?iid=$iid&arrived_installation"
716
; Show back and next buttons.
717
GetDlgItem $R0 $HWNDPARENT 1
720
GetDlgItem $R0 $HWNDPARENT 3
724
; Restore the abort button functionality
729
Function ElisaCustomAbort
730
StrCmp $R8 1 0 End ; if $R8 == 0: abort else: page jump +1
731
MessageBox MB_YESNO "$(^CancelRegistration)" IDYES GotoNextPage IDNO StayHere
733
; Send a http request to track the user
734
ReadRegStr $iid HKLM "Software\$(^Name)" "iid"
735
NSISdl::download_quiet "http://elisa.fluendo.com/installer/confirm/?iid=$iid&cancel_quit"
740
; Send a http request to track the user
741
ReadRegStr $iid HKLM "Software\$(^Name)" "iid"
742
NSISdl::download_quiet "http://elisa.fluendo.com/installer/confirm/?iid=$iid&cancel_back"
746
; Remove an application from the firewall exception list
747
SimpleFC::RemoveApplication $EXEPATH
748
Pop $0 ; return error(1)/success(0)
750
UAC::Unload ; Must call unload!
636
753
# Installer Language Strings
637
754
LangString ^UninstallLink ${LANG_ENGLISH} "Uninstall $(^Name)"
651
768
LangString ^CheckingSystemForUpdates ${LANG_SPANISH} "Actualizando su sistema..."
652
769
LangString ^CheckingSystemForUpdates ${LANG_CATALAN} "S'est� actualitzant el sistema..."
653
770
LangString ^CheckingSystemForUpdates ${LANG_GERMAN} "F�hre Systemaktualisierung durch"
772
LangString ^CancelRegistration ${LANG_ENGLISH} "Are you sure you want to quit the registration process?"
773
LangString ^CancelRegistration ${LANG_FRENCH} "�tes-vous s�r de vouloir annuller le processus d'enregistrement?"
774
LangString ^CancelRegistration ${LANG_SPANISH} "�Est� seguro que quiere cancelar el proceso de registro?"
775
LangString ^CancelRegistration ${LANG_CATALAN} "Esteu segur que voleu cancel�lar el proc�s de registre?"
776
LangString ^CancelRegistration ${LANG_GERMAN} " Sind Sie sicher, dass sie die Registrierung beenden wollen?"