diff --git a/Wiiload Installer/ReadMe.txt b/Wiiload Installer/ReadMe.txt new file mode 100644 index 00000000..d113ecbb --- /dev/null +++ b/Wiiload Installer/ReadMe.txt @@ -0,0 +1,26 @@ +;Wiiload - Easy Setup for Dummys! [Installer for windows.] + +;Copyright 2009 NeoRame + +;This program is free software: you can redistribute it and/or modify +;it under the terms of the GNU General Public License as published by +;the Free Software Foundation, either version 3 of the License, or +;(at your option) any later version. + +;This program is distributed in the hope that it will be useful, +;but WITHOUT ANY WARRANTY; without even the implied warranty of +;MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +;GNU General Public License for more details. + +;You should have received a copy of the GNU General Public License +;along with this program. If not, see http://www.gnu.org/licenses/gpl-3.0.html. + + + +For compiling use NSIS 2.xx and compile the *.nsi +http://nsis.sourceforge.net/Download + + + +Installer created by NeoRame, #gui-usbloader-chat abjects.net +Wiiload 0.4 coded by dhewg, #wiidev efnet diff --git a/Wiiload Installer/source/IPPage.ini b/Wiiload Installer/source/IPPage.ini new file mode 100644 index 00000000..f4333326 --- /dev/null +++ b/Wiiload Installer/source/IPPage.ini @@ -0,0 +1,97 @@ +[Settings] +NumFields=11 += +BackEnabled=0 + +[Field 1] +Type=GroupBox +Left=0 +Right=-1 +Top=0 +Bottom=-9 +Text="Please Enter your Wii IP address" + +[Field 2] +Type=Label +Text=*NOTE* You can find your Wii IP address when you press the Home button\r\n in your Homebrew Channel. +Left=20 +Right=-20 +Top=44 +Bottom=60 + +[Field 3] +Type=Text +MaxLen=3 +Flags=ONLY_NUMBERS +Left=100 +Right=120 +Top=25 +Bottom=36 + +[Field 4] +Type=Text +MaxLen=3 +Flags=ONLY_NUMBERS +Left=125 +Right=145 +Top=25 +Bottom=36 + +[Field 5] +Type=Text +MaxLen=3 +Flags=ONLY_NUMBERS +Left=150 +Right=170 +Top=25 +Bottom=36 + +[Field 6] +Type=Text +MaxLen=3 +Flags=ONLY_NUMBERS +Left=175 +Right=195 +Top=25 +Bottom=36 + +[Field 7] +Type=Label +Text=. +Left=122 +Right=124 +Top=27 +Bottom=35 + +[Field 8] +Type=Label +Text=. +Left=147 +Right=150 +Top=27 +Bottom=35 + +[Field 9] +Type=Label +Text=. +Left=172 +Right=174 +Top=27 +Bottom=35 + +[Field 10] +Type=Label +Text=IP: +Left=88 +Right=96 +Top=27 +Bottom=35 + +[Field 11] +Type=Unknown +Text=Unknown +Left=0 +Right=0 +Top=0 +Bottom=0 + diff --git a/Wiiload Installer/source/InstallerConfig.nsh b/Wiiload Installer/source/InstallerConfig.nsh new file mode 100644 index 00000000..927f5e7c --- /dev/null +++ b/Wiiload Installer/source/InstallerConfig.nsh @@ -0,0 +1,29 @@ +;Website: http://code.google.com/p/usbloader-gui/ + +;Copyright 2009 NeoRame + +;This program is free software: you can redistribute it and/or modify +;it under the terms of the GNU General Public License as published by +;the Free Software Foundation, either version 3 of the License, or +;(at your option) any later version. + +;This program is distributed in the hope that it will be useful, +;but WITHOUT ANY WARRANTY; without even the implied warranty of +;MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +;GNU General Public License for more details. + +;You should have received a copy of the GNU General Public License +;along with this program. If not, see http://www.gnu.org/licenses/gpl-3.0.html. + + +;== Basic Information. Basic information about the portable app +!define NAME "Wiiload" +!define NAME2 "Wiiload" +!define SHORTNAME "Wiiload" +!define VERSION "1.00.0.0" +!define SHORTVERSION "1.0" +!define FILENAME "${NAME}_${SHORTVERSION}_Installer" +!define URL "http://code.google.com/p/usbloader-gui/" +!define TEAM "Team USB Loader GX" +!define INSTALLERLANGUAGE "ENGLISH" ;one of the NSIS pre-defined languages supported: English, French, Italian, German, Japanese, SimpChinese + diff --git a/Wiiload Installer/source/Wiiload.bmp b/Wiiload Installer/source/Wiiload.bmp new file mode 100644 index 00000000..42c6e882 Binary files /dev/null and b/Wiiload Installer/source/Wiiload.bmp differ diff --git a/Wiiload Installer/source/Wiiload.nsi b/Wiiload Installer/source/Wiiload.nsi new file mode 100644 index 00000000..6b72ff51 --- /dev/null +++ b/Wiiload Installer/source/Wiiload.nsi @@ -0,0 +1,258 @@ +;Website: http://code.google.com/p/usbloader-gui/ + +;Copyright 2009 NeoRame + +;This program is free software: you can redistribute it and/or modify +;it under the terms of the GNU General Public License as published by +;the Free Software Foundation, either version 3 of the License, or +;(at your option) any later version. + +;This program is distributed in the hope that it will be useful, +;but WITHOUT ANY WARRANTY; without even the implied warranty of +;MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +;GNU General Public License for more details. + +;You should have received a copy of the GNU General Public License +;along with this program. If not, see http://www.gnu.org/licenses/gpl-3.0.html. + + +!define TEMP2 $R1 ;Temp variable +!define TEMP3 $R2 ;Temp variable +!define TEMP4 $R3 ;Temp variable +!define TEMP5 $R4 ;Temp variable + +!include "InstallOptions.nsh" +!include "LogicLib.nsh" +!include InstallerConfig.nsh +!define SHCNE_ASSOCCHANGED 0x08000000 +!define SHCNF_IDLIST 0 + +;=== Program Details +Name "${NAME2}" +OutFile "..\${FILENAME}.exe" +InstallDir "$PROGRAMFILES\${NAME}" +Caption "${NAME2} Installer" +VIProductVersion "${VERSION}" +VIAddVersionKey ProductName "${NAME2}" +VIAddVersionKey Comments "For more informations please visit http://code.google.com/p/usbloader-gui/" +VIAddVersionKey CompanyName "${TEAM}" +VIAddVersionKey LegalCopyright "${TEAM}" +VIAddVersionKey FileDescription "${NAME2}" +VIAddVersionKey FileVersion "${VERSION}" +VIAddVersionKey ProductVersion "${VERSION}" +VIAddVersionKey InternalName "${NAME}" +VIAddVersionKey LegalTrademarks "${NAME2} installer created by ${TEAM}." +VIAddVersionKey OriginalFilename "${FILENAME}.exe" + +;=== Runtime Switches +SetCompressor /SOLID lzma +CRCCheck on +AutoCloseWindow True +ShowInstDetails nevershow +ShowUnInstDetails nevershow + +;=== Include Modern UI +!include "MUI.nsh" + +;=== General +;Get installation folder from registry if available +InstallDirRegKey HKCU "Software\${NAME}" "" + +;=== Interface Settings +!define MUI_ABORTWARNING + +;===Language Selection Dialog Settings + ;Remember the installer language + !define MUI_LANGDLL_REGISTRY_ROOT "HKCU" + !define MUI_LANGDLL_REGISTRY_KEY "Software\${NAME}" + !define MUI_LANGDLL_REGISTRY_VALUENAME "Installer Language" + +;=== Program Icon +Icon "files\${NAME}.ico" + + +;=== Icon & Style === +!define MUI_ICON "files\${NAME}.ico" + BrandingText "${NAME2} - Easy Setup for Dummys!" +!define MUI_WELCOMEFINISHPAGE_BITMAP ${NAME}.bmp +!insertmacro MUI_PAGE_WELCOME + Page custom SetCustom ValidateCustom ": Enter IP" ;Custom page. InstallOptions gets called in SetCustom. +!insertmacro MUI_PAGE_INSTFILES +!insertmacro MUI_PAGE_FINISH + +;=== Languages +!insertmacro MUI_LANGUAGE "ENGLISH" ;first language is the default language + +;Things that need to be extracted on startup (keep these lines before ;any File command!) +;Use ReserveFile for your own InstallOptions INI files too! +ReserveFile "${NSISDIR}\Plugins\InstallOptions.dll" +ReserveFile "IPPage.ini" + +;=====Install Section +Section "Components" + + ;Get Install Options dialog user input + ReadINIStr ${TEMP2} "$PLUGINSDIR\IPPage.ini" "Field 3" "State" + ReadINIStr ${TEMP3} "$PLUGINSDIR\IPPage.ini" "Field 4" "State" + ReadINIStr ${TEMP4} "$PLUGINSDIR\IPPage.ini" "Field 5" "State" + ReadINIStr ${TEMP5} "$PLUGINSDIR\IPPage.ini" "Field 6" "State" + + ; App Install + SetOutPath $SYSDIR + File /r "Files\${NAME}.exe" + + SetOutPath $INSTDIR + File /r "Files\*.ico" + CreateDirectory "$SMPROGRAMS\${NAME}" + WriteUninstaller $INSTDIR\Uninstall.exe + CreateShortCut "$SMPROGRAMS\${NAME}\Uninstall.lnk" "$INSTDIR\Uninstall.exe" + WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${NAME}" "DisplayName" "${NAME}" + WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${NAME}" "DisplayVersion" "${VERSION}" + WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${NAME}" "Publisher" "${TEAM}" + WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${NAME}" "URLInfoAbout" "${URL}" + WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${NAME}" "DisplayIcon" "$INSTDIR\${NAME}.ico" + WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${NAME}" "UninstallString" '"$INSTDIR\Uninstall.exe"' + + ;=== WIILOAD TCP Stuff + ; include for some of the windows messages defines + !include "winmessages.nsh" + ; HKLM (all users) vs HKCU (current user) defines + !define env_hklm 'HKLM "SYSTEM\CurrentControlSet\Control\Session Manager\Environment"' + !define env_hkcu 'HKCU "Environment"' + ; set variable + WriteRegExpandStr ${env_hkcu} WIILOAD tcp:${TEMP2}.${TEMP3}.${TEMP4}.${TEMP5} + ; make sure windows knows about the change + SendMessage ${HWND_BROADCAST} ${WM_WININICHANGE} 0 "STR:Environment" /TIMEOUT=5000 + + ;=== Context Menu (Send to Wii) + WriteRegStr HKCR ".dol" "" "" + WriteRegStr HKCR ".dol\DefaultIcon" "" "$PROGRAMFILES\${NAME}\DOL.ico" + WriteRegStr HKCR ".dol\shell\Send to Wii\command" "" `c:\windows\system32\wiiload.exe "%1"` + WriteRegStr HKCR ".elf" "" "" + WriteRegStr HKCR ".elf\DefaultIcon" "" "$PROGRAMFILES\${NAME}\ELF.ico" + WriteRegStr HKCR ".elf\shell\Send to Wii\command" "" `c:\windows\system32\wiiload.exe "%1"` + WriteRegStr HKCR ".wad" "" "" + WriteRegStr HKCR ".wad\DefaultIcon" "" "$PROGRAMFILES\${NAME}\WAD.ico" + WriteRegStr HKCR ".wad\shell\Send to Wii\command" "" `c:\windows\system32\wiiload.exe "%1"` + + Delete $exedir\.ini + Call RefreshShellIcons + +SectionEnd + +;=== Functions +Function .onInit + + ;Extract InstallOptions files + ;$PLUGINSDIR will automatically be removed when the installer closes + InitPluginsDir + File /oname=$PLUGINSDIR\IPPage.ini "IPPage.ini" + +FunctionEnd + + +Function SetCustom + + ;Display the InstallOptions dialog + InstallOptions::dialog "$PLUGINSDIR\IPPage.ini" + +FunctionEnd + +; Textbfields Input check +Function ValidateCustom + + !insertmacro INSTALLOPTIONS_READ ${TEMP2} "IPPage.ini" "Field 3" "State" + StrCmp ${TEMP2} "" 0 +3 + MessageBox MB_ICONEXCLAMATION|MB_OK "Please enter your Wii IP." + Abort + !insertmacro INSTALLOPTIONS_READ ${TEMP3} "IPPage.ini" "Field 4" "State" + StrCmp ${TEMP3} "" 0 +3 + MessageBox MB_ICONEXCLAMATION|MB_OK "Please enter your Wii IP." + Abort + !insertmacro INSTALLOPTIONS_READ ${TEMP4} "IPPage.ini" "Field 5" "State" + StrCmp ${TEMP4} "" 0 +3 + MessageBox MB_ICONEXCLAMATION|MB_OK "Please enter your Wii IP." + Abort + !insertmacro INSTALLOPTIONS_READ ${TEMP5} "IPPage.ini" "Field 6" "State" + StrCmp ${TEMP5} "" 0 +3 + MessageBox MB_ICONEXCLAMATION|MB_OK "Please enter your Wii IP." + Abort + +FunctionEnd + +; Funtion Icon refresh +Function RefreshShellIcons + + ; By jerome tremblay - april 2003 + System::Call 'shell32.dll::SHChangeNotify(i, i, i, i) v \ + (${SHCNE_ASSOCCHANGED}, ${SHCNF_IDLIST}, 0, 0)' + +FunctionEnd + + +;=== Uninstaller Section === + +;=== Unistall Functions +Function un.onInit + + !insertmacro MUI_UNGETLANGUAGE + +FunctionEnd + +; Funtion Icon refresh +Function Un.RefreshShellIcons + + ; By jerome tremblay - april 2003 + System::Call 'shell32.dll::SHChangeNotify(i, i, i, i) v \ + (${SHCNE_ASSOCCHANGED}, ${SHCNF_IDLIST}, 0, 0)' + +FunctionEnd + +; Messagebox Done! +Function un.onUninstSuccess + + MessageBox MB_OK "${NAME} uninstalled successfully." + +FunctionEnd + +;=== Uninstaller +Section "Uninstall" + + ; delete App and his stuff + Delete "$SMPROGRAMS\${NAME}\Uninstall.lnk" + Delete "$INSTDIR\*.*" + Delete "$SYSDIR\${NAME}.exe" + RMDir "$SMPROGRAMS\${NAME}" + RMDir $INSTDIR + SetAutoClose true + DeleteRegKey HKEY_LOCAL_MACHINE "SOFTWARE\${NAME}" + DeleteRegKey HKEY_LOCAL_MACHINE "SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\${NAME}" + DeleteRegKey /ifempty HKCU "Software\${NAME}" + +;=== WIILOAD TCP Uninstall Stuff + ; delete variable + DeleteRegValue ${env_hkcu} WIILOAD + ; make sure windows knows about the change + SendMessage ${HWND_BROADCAST} ${WM_WININICHANGE} 0 "STR:Environment" /TIMEOUT=5000 + + ; delete RegKeys + DeleteRegkey HKCR ".dol\shell\Send to Wii\command" + DeleteRegkey HKCR ".dol\shell\Send to Wii" + DeleteRegkey HKCR ".dol\DefaultIcon" + DeleteRegkey HKCR ".dol\shell" + DeleteRegkey HKCR ".dol" + DeleteRegkey HKCR ".elf\shell\Send to Wii\command" + DeleteRegkey HKCR ".elf\shell\Send to Wii" + DeleteRegkey HKCR ".elf\DefaultIcon" + DeleteRegkey HKCR ".elf\shell" + DeleteRegkey HKCR ".elf" + DeleteRegkey HKCR ".wad\shell\Send to Wii\command" + DeleteRegkey HKCR ".wad\shell\Send to Wii" + DeleteRegkey HKCR ".wad\DefaultIcon" + DeleteRegkey HKCR ".wad\shell" + DeleteRegkey HKCR ".wad" + + ; Icon refresh + Call Un.RefreshShellIcons + +SectionEnd \ No newline at end of file diff --git a/Wiiload Installer/source/files/DOL.ico b/Wiiload Installer/source/files/DOL.ico new file mode 100644 index 00000000..e88456ae Binary files /dev/null and b/Wiiload Installer/source/files/DOL.ico differ diff --git a/Wiiload Installer/source/files/ELF.ico b/Wiiload Installer/source/files/ELF.ico new file mode 100644 index 00000000..c94a0092 Binary files /dev/null and b/Wiiload Installer/source/files/ELF.ico differ diff --git a/Wiiload Installer/source/files/WAD.ico b/Wiiload Installer/source/files/WAD.ico new file mode 100644 index 00000000..0af5392d Binary files /dev/null and b/Wiiload Installer/source/files/WAD.ico differ diff --git a/Wiiload Installer/source/files/Wiiload.ico b/Wiiload Installer/source/files/Wiiload.ico new file mode 100644 index 00000000..00153115 Binary files /dev/null and b/Wiiload Installer/source/files/Wiiload.ico differ diff --git a/Wiiload Installer/source/files/wiiload.exe b/Wiiload Installer/source/files/wiiload.exe new file mode 100644 index 00000000..0060a441 Binary files /dev/null and b/Wiiload Installer/source/files/wiiload.exe differ