home *** CD-ROM | disk | FTP | other *** search
/ Castle Explorer / DKMMCAST.iso / pc / dksetup / dkgen.inc < prev    next >
Text File  |  1996-08-27  |  37KB  |  931 lines

  1. '^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  2. '
  3. '   DKGEN.INC
  4. '
  5. '^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  6. ' See the change history in DKSETUP.MST for more recent changes.
  7. '
  8. '25/06/96 Added the extra ini settinigs into the InstallQTW function.
  9. '27/02/96 Added the InstallQTW function.
  10. '25/01/96 Change the EndCommonInstall and HandleRestart SUB's to Functions to
  11. '         utilise return values. So the user does NOT get the 'You must restart
  12. '         windows' warning AND THEN the 'Successful install' dialog box.
  13. '25/01/96 Change path checking to look for Max of 8 chars first.
  14. '08/08/95 Test for Norton Anti Virus
  15. '03/08/95 const for uninstall and min register added
  16. '07/07/95 Correct so unregisters use of ctl3d
  17. '01/06/95 No choice about adding icons to progman
  18. '?/05/95  If bundle with sampler need to test for cirrus driver - put into mst file
  19. '12/03/95 Alternative function added, readme icon has shortened name
  20.  
  21. '$INCLUDE 'setupapi.inc'
  22. '$INCLUDE 'msdetect.inc'
  23. '$INCLUDE 'dklang.inc'
  24.  
  25. '   Defines unlikely to change
  26. CONST APPLICATION_MENU_FILE     = "custmenu.exe"
  27. CONST INI_FILE_SOURCE = "AppPath" ' OR  "WinPath"
  28. CONST EDITOR_EXE        = "write.exe "
  29. CONST SAMPLER_PATH      = "SAMPLER"
  30. CONST SAMPLER_EXE_FILE  = "sampler.exe"
  31. CONST SAMPLER_INI_FILE  = "sampler.ini"
  32. CONST SAMPLER_BINARIES_SECTION_NAME = "SAMPBIN"
  33. CONST SAMPLER_README_FILE = "SREADME.WRI"
  34.  
  35. CONST SOURCE_BINARIES_SUBDIR = "DKCODE"
  36. CONST SOURCE_SETUP_SUBDIR = "DKSETUP"
  37. CONST SETUP_INF_FILENAME = "SETUP.INF"
  38. CONST CUIDLL_FILENAME = "mscuistf.dll"
  39. CONST SETUP_INI_BINARIES_SECTION_NAME = "BIN"
  40. CONST SETUP_INI_SH_BINARIES_SECTION_NAME = "BIN Shared"
  41. CONST SETUP_INI_WING_BINARIES_NAME = "WinG Runtime"
  42. CONST SETUP_INI_WING32_BINARIES_NAME = "WinG32"
  43. CONST SETUP_INI_ACM_SECTION_NAME = "ACM Drivers"
  44. CONST SETUP_INI_FONTS_SECTION_NAME = "Fonts"
  45.  
  46. 'unin, min register
  47. CONST UNINSTALL_EXE_FILE = "UNINSTAL.exe"
  48. CONST DKREG_INI_DIR = "\MMAPP"
  49. CONST DKREG_INI_PATH = "\MMAPP\MMAPP.ini"
  50. CONST WIN_INI_ENTRY = "path"
  51.  
  52. CONST PRODUCT_INI_DIR_SECTION_NAME = "Directory"
  53. CONST PRODUCT_INI_DIR_ENTRY_NAME = "Data"
  54.  
  55. CONST MINIMUM_DISK_SPACE = 2048 ' For Minimum install
  56.  
  57. ' Procs
  58. CONST PROC_HELP = "FHelpDlgProc"
  59.  
  60. DECLARE FUNCTION ExitWindowsExec LIB "USER.EXE" (szEXE$, szParams$) AS INTEGER
  61. DECLARE FUNCTION GetActiveWindow    lib "User" () as integer
  62. DECLARE FUNCTION SetWindowPos       lib "User" (hwnd as integer, hwnd as integer, i as integer, i as integer, i as integer, i as integer, w as integer) as integer
  63.  
  64. DECLARE FUNCTION Ctl3dRegister LIB "CTL3D.DLL" (hInst%) AS INTEGER
  65. DECLARE FUNCTION Ctl3dUnregister LIB "CTL3D.DLL" (hInst%) AS INTEGER
  66. DECLARE FUNCTION Ctl3dAutoSubClass LIB "CTL3D.DLL" (hInst%) AS INTEGER
  67.  
  68. DECLARE FUNCTION OnWin3x LIB "setuphlp.DLL" AS INTEGER
  69. DECLARE FUNCTION VflatdPresent LIB "setuphlp.DLL" AS INTEGER
  70. DECLARE FUNCTION GetRealSystemDir LIB "setuphlp.DLL" (szDir$,cbBuf%) AS INTEGER
  71. DECLARE FUNCTION RestartWindows LIB "setuphlp.DLL" AS INTEGER
  72. DECLARE FUNCTION IsWin32FileNewer LIB "setuphlp.DLL" (szOrig$,szNew$) AS INTEGER
  73. DECLARE SUB RenameFilePlease LIB "setuphlp.DLL" (szOrig$,szNew$)
  74.  
  75. DECLARE FUNCTION FIsVGA LIB "mscuistf.dll" AS INTEGER
  76. DECLARE FUNCTION FIs256Colour LIB "colors.dll" AS INTEGER
  77. DECLARE FUNCTION Welcome() AS INTEGER
  78. DECLARE FUNCTION TestSystem() AS INTEGER
  79. DECLARE FUNCTION GetDiskSpaceNeeded(drive%) AS LONG
  80. DECLARE SUB Initialise(prodName$, defInstallPath$, msgCaption$)
  81. DECLARE SUB DeInitialise()
  82. DECLARE SUB AskQuit()
  83. DECLARE SUB BadPath()
  84. DECLARE SUB NetworkDrive()
  85. DECLARE SUB UpdateIndeoAVIDrivers()
  86. DECLARE SUB UpdateWinGDrivers()
  87. 'DECLARE SUB UpdateProgramManager(prodName$, appExeFile$, appPengeFile$, readmeFile$, readmeStr$, onCDROM%)
  88. 'DECLARE SUB UpdateProgramManagerAlt(prodName$, readmeName$, appExeFile$, appPengeFile$, readmeFile$, readmeStr$, onCDROM%)
  89. DECLARE FUNCTION MakePath (szDir$, szFile$) AS STRING
  90. DECLARE FUNCTION GetRealWindowsSysDir AS STRING
  91. DECLARE SUB UpdateWinG32 (szOrig$)
  92. DECLARE SUB InitCommonInstall()
  93. DECLARE FUNCTION LicenseAgreement() AS INTEGER
  94. DECLARE FUNCTION Win32sRequiredDLG() AS INTEGER
  95. DECLARE FUNCTION UpdateADPCMDrivers() AS INTEGER
  96. DECLARE FUNCTION EndCommonInstall( AppReadmeFile$, InRoot%, szEditorExe$ ) AS INTEGER
  97. DECLARE FUNCTION HandleRestart() AS INTEGER
  98. DECLARE FUNCTION InstallQTW() As Integer
  99. DECLARE FUNCTION OnWindowsNT LIB "INIUPD.DLL" AS INTEGER
  100. 'DECLARE FUNCTION MailmanDlgProc LIB "COLOURS.DLL" AS INTEGER
  101.  
  102. '  SetWindowPos() flags
  103. const SWP_NOSIZE         = &H0001
  104. const SWP_NOMOVE         = &H0002
  105. const SWP_NOACTIVATE     = &H0010
  106. const SWP_SHOWWINDOW     = &H0040
  107. const SWP_HIDEWINDOW     = &H0080
  108. const HWND_TOP       = (0)
  109. const HWND_BOTTOM    = (1)
  110. const HWND_TOPMOST   = (-1)
  111. const HWND_NOTOPMOST = (-2)
  112.  
  113.  
  114. 'Dialog Box ID's
  115. CONST DLG_ABORT                       =100
  116. CONST DLG_ADDSYSTEMSOFT               =101
  117. CONST DLG_ADPCMHELP                   =102
  118. CONST DLG_AWFULMACHINE                =103
  119. CONST DLG_BADEXIT                     =110
  120. CONST DLG_BADVGA                      =111
  121. CONST DLG_BADPATH                     =112
  122. CONST DLG_BILLBOARD                   =113
  123. CONST DLG_CUSTOM                      =120
  124. CONST DLG_CUSTOMHELP                  =121
  125. CONST DLG_DESTPATH                    =130
  126. CONST DLG_DEVELOPER                     =133
  127. CONST DLG_DONEVIDEO                   =131
  128. CONST DLG_DONENOVIDEO                 =132
  129. CONST DLG_EXITFAILNOTENH              =140
  130. CONST DLG_EXITFAILNOTINTEL            =141
  131. CONST DLG_EXITFAILNOTWIN31            =142
  132. CONST DLG_EXITFAILRUNAPP              =143
  133. CONST DLG_FREECELLINST                =150
  134. CONST DLG_INSTALLQTW                  =180
  135. CONST DLG_LICENSE                     =210
  136. CONST DLG_MAILMAN                     =220
  137. CONST DLG_NOSPACE                     =230
  138. CONST DLG_NEEDS31                     =231
  139. CONST DLG_NOMOUSE                     =232
  140. CONST DLG_NOT256                      =233
  141. CONST DLG_NOSYSSOFT                   =234
  142. CONST DLG_NODISKSPACE                 =235
  143. CONST DLG_NEEDSWIN32S                 =236
  144. CONST DLG_NETWORKDRIVE                =237
  145. CONST DLG_PATHHELP                    =240
  146. CONST DLG_POORMACHINE                 =241
  147. CONST DLG_PROGMANGROUP                =242
  148. CONST DLG_PROGMANGRP                  =243
  149. CONST DLG_QUIT                        =250
  150. CONST DLG_SPEED                       =270
  151. CONST DLG_SUCCESS                     =271
  152. CONST DLG_URKADPCM                    =290
  153. CONST DLG_WELCOME                     =310
  154. CONST DLG_WELHELP                     =311
  155. CONST DLG_WRONGADPCM                  =312
  156. CONST DLG_WHIZZHELP                   =313
  157. 'Bitmap ID
  158. CONST IDB_BITMAP                      =1000
  159.  
  160. ' Error messages
  161. CONST ERR_OK = 100
  162. CONST ERR_EXITFAIL = 101
  163. CONST ERR_WINVERFAIL = 102
  164. CONST ERR_NODISKSPACE = 103
  165.  
  166. ' Navigation messages
  167. CONST NAV_FORWARD = 0
  168. CONST NAV_BACK = 1
  169. CONST NAV_EXIT = 2
  170. CONST NAV_RUN = 3
  171.  
  172.  
  173. GLOBAL szDirectCommand As String
  174. GLOBAL szWinPath As String
  175. GLOBAL szWinSysPath As String
  176. GLOBAL szWinDrive As String
  177. GLOBAL szSrcSetupPath As String
  178. GLOBAL szSrcBinPath As String
  179. GLOBAL szDestPath As String
  180. GLOBAL szOldDestPath As String
  181. GLOBAL szPengePath As String
  182. GLOBAL szINFPath As String
  183. GLOBAL szAppINIPath As String
  184. GLOBAL szMsgCaption As String
  185. GLOBAL szButton As String
  186. GLOBAL szMinimalInstall As String
  187. GLOBAL szAddPMItem As String
  188. GLOBAL szExpressCustomChoice As String
  189. GLOBAL szMMappPath As String
  190. GLOBAL szInstExePath As String
  191. GLOBAL szInstExeDate As String
  192. GLOBAL szCdExePath As String
  193. GLOBAL szCdExeDate As String
  194. GLOBAL szCopyright As String
  195. GLOBAL szFullSampPath As String
  196. GLOBAL szSampINIPath As String
  197. GLOBAL szSampData As String
  198. GLOBAL szSampVersion As String
  199. GLOBAL szMsacmPriority1 As String
  200. GLOBAL szMsacmPriority2 As String
  201. GLOBAL szMsacmPriority3 As String
  202. GLOBAL bInstalledWin32s As Integer
  203. GLOBAL APPLICATION_INI_FILE As String
  204. GLOBAL APPLICATION_EXE_FILE As String
  205. GLOBAL APPLICATION_PENGE_FILE As String
  206. GLOBAL szDKRegIni As String ' MMAPP.INI
  207.  
  208. GLOBAL fPreviousMode As Integer
  209. GLOBAL fWillNotFit As Integer
  210. GLOBAL fSystemUpdated As Integer
  211. GLOBAL hDlg As Integer
  212. GLOBAL dButton As Integer
  213. GLOBAL dWinDrive As Integer
  214. GLOBAL dDestDrive As Integer
  215. GLOBAL dCursor As Integer
  216. GLOBAL hwndSetup As Integer
  217. GLOBAL OS_Windows95 As Integer
  218. GLOBAL bscrunged As Integer
  219. GLOBAL szErrorCode As String
  220. GLOBAL szReply As String
  221.  
  222. GLOBAL WinVer As Integer
  223. GLOBAL Ver As String
  224. GLOBAL szSystem32Path As String
  225.  
  226. GLOBAL  numcolours As Integer
  227. GLOBAL strnumcol As String
  228.  
  229. ' This file needs the above globals etc for it's functions
  230. '$INCLUDE 'product.inc' 'Defines which change for every product
  231.  
  232. '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
  233. Sub InitCommonInstall() STATIC
  234. '    AddToBillboardList CUIDLL_FILENAME, DLG_MAILMAN, "MailmanDlgProc", 2500
  235.     AddToBillboardList "colors.dll", DLG_MAILMAN, "MailmanDlgProc", 25
  236.     numcolours=FIs256Colour()
  237. strnumcol=STR$(numcolours)
  238. 'dButton = DoMsgBox( strnumcol, szMsgCaption$, MB_OK+MB_TASKMODAL+MB_ICONHAND)
  239.     if numcolours<16 then  ' The 16 referes to the Bits per pixel and not 16 colours. That would be 8
  240. '        AddToBillboardList "Colors.dll", DLG_MAILMAN, "ColoursDlgProc", 25
  241.         AddToBillboardList "colors.dll", DLG_MAILMAN, "ColorsDlgProc", 25
  242.    endif
  243.     SetCopyGaugePosition -1, 150
  244. End Sub
  245.  
  246.  
  247. ''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
  248. Function EndCommonInstall( AppReadmeFile$, InRoot%, szEditorExe$ ) STATIC AS INTEGER
  249.  
  250.     if RestartListEmpty = 0 or fSystemUpdated = 1 or bInstalledWin32s = 1 then
  251.         hDlg = DLG_DONEVIDEO
  252.     else
  253.         hDlg = DLG_DONENOVIDEO
  254.     end if
  255.  
  256. QuitLoop:
  257.     szButton = UIStartDlg(CUIDLL_FILENAME, hDlg, "FInfoDlgProc", 0, "")
  258.     select case szButton
  259.     case "REACTIVATE"
  260.         goto QuitLoop
  261.     case "CONTINUE"     'Read me
  262.         if inRoot% = 1 then
  263.             szReadMe$ = MakePath( mid$(szSrcSetupPath, 1, (len(szSrcSetupPath) - len(SOURCE_SETUP_SUBDIR))-1), appReadmeFile$)
  264.         else
  265.             szReadMe$ = MakePath(szSrcBinPath, appReadmeFile$)
  266.         end if
  267.         if szEditorExe$ = "write.exe " then
  268.             run szEditorExe$ + szReadMe$, nowait
  269.         else
  270.             run szEditorExe$ + szReadMe$
  271.         end if
  272.         goto QuitLoop
  273.     case "BACK"     'Restart Windows
  274.         if HandleRestart = 0 then
  275.             dButton = DoMsgBox( STR_SYSMESSAGE, szMsgCaption$, MB_OK+MB_TASKMODAL+MB_ICONHAND)
  276.             EndCommonInstall = NAV_EXIT
  277.         else
  278.             EndCommonInstall = NAV_FORWARD
  279.         end if
  280.     case "EXIT" , "CANCEL"         'Return to Windows
  281.         if hDlg = DLG_DONEVIDEO then
  282.             dButton = DoMsgBox( STR_SYSMESSAGE, szMsgCaption$, MB_OK+MB_TASKMODAL+MB_ICONHAND)
  283.             EndCommonInstall = NAV_EXIT
  284.         else
  285.             EndCommonInstall = NAV_FORWARD
  286.         end if
  287.     end select
  288.  
  289.     UIPop 1
  290. End Function
  291.  
  292.  
  293. '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
  294. Sub Initialise(prodName$, defInstallPath$, msgCaption$) STATIC
  295.  
  296. 'numcolours=FIs256Colour()
  297. 'strnumcol=STR$(numcolours)
  298. 'dButton = DoMsgBox( strnumcol, szMsgCaption$, MB_OK+MB_TASKMODAL+MB_ICONHAND)
  299.  
  300.     ret% = Ctl3dRegister(HinstFrame())
  301.     ret% = Ctl3dAutoSubClass(HinstFrame())
  302.  
  303.     szMsgCaption$ = msgCaption$
  304.  
  305.     cursor% = ShowWaitCursor()
  306.  
  307.     ClearCopyList
  308.     szWinSysPath = ucase$(GetWindowsSysDir ())
  309.     szWinPath = ucase$(GetWindowsDir ())
  310.     dWinDrive = asc(mid$((szWinPath), 1,1)) - asc("A")+1
  311.     szWinDrive = mid$(szWinPath, 1,1)
  312.  
  313.     szSrcSetupPath = ucase$(GetSymbolValue ("STF_SRCDIR"))
  314.     szSrcBinPath = mid$(szSrcSetupPath, 1, (len(szSrcSetupPath) - len(SOURCE_SETUP_SUBDIR))-1) + SOURCE_BINARIES_SUBDIR
  315.     szDestPath = szWinDrive + ":" + defInstallPath$
  316.  
  317. '+++
  318. '$IFDEF WITH_FULL_SAMPLER
  319.     szFullSampPath = szWinDrive + ":" + "\DKMM\" + SAMPLER_PATH
  320. '$ENDIF
  321. '---
  322.  
  323.     SetTitle szMsgCaption$
  324.     SetBitmap CUIDLL_FILENAME, IDB_BITMAP
  325.     szCopyright = STR_COPYRIGHT + "     Setup " + STR_VERSION
  326.     SetAbout prodName$, szCopyright
  327.  
  328.     fPreviousMode = SetBeepingMode (1)
  329.     fPreviousMode = SetDecompMode (1)
  330.     fPreviousMode = SetSilentMode (0)
  331.  
  332.     szINFPath = ucase$(GetSymbolValue("STF_SRCINFPATH"))
  333.     if szINFPath = "" then
  334.         szINFPath = ucase$(GetSymbolValue("STF_CWDDIR")) + SETUP_INF_FILENAME
  335.     end if
  336.     ReadInfFile szINFPath
  337.  
  338.     szExpressCustomChoice = "EXPRESS"
  339.     szMinimalInstall = "OFF"
  340. '    szAddPMItem = "ON"
  341.  
  342.     fSystemUpdated = 0
  343.     bInstalledWin32s = 0
  344.  
  345.     ' Set up Application file names
  346.     APPLICATION_INI_FILE = APP_SHORTNAME + ".INI"
  347.     APPLICATION_EXE_FILE = APP_SHORTNAME + ".EXE"
  348.     APPLICATION_PENGE_FILE = APP_SHORTNAME + ".PNG"
  349.  
  350.     RestoreCursor(cursor%)
  351. End Sub
  352.  
  353.  
  354. '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
  355. Sub DeInitialise() STATIC
  356.     ret% = Ctl3dUnregister(HinstFrame())
  357. End Sub
  358.  
  359.  
  360. '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
  361. Sub AskQuit() STATIC
  362. begin:
  363.     szButton = UIStartDlg(CUIDLL_FILENAME, DLG_QUIT, "FQuitDlgProc", 0, "")
  364.     select case szButton
  365.     case "REACTIVATE"
  366.         goto begin
  367.     case "EXIT" , "CANCEL"
  368.         error STFQUIT
  369.     case "CONTINUE"
  370.         UIPop 1
  371.     end select
  372. End Sub
  373.  
  374.  
  375. '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
  376. Sub BadPath() STATIC
  377. begin:
  378.     szButton = UIStartDlg(CUIDLL_FILENAME, DLG_BADPATH, "FInfo0DlgProc", 0, "")
  379.     select case szButton
  380.     case "REACTIVATE"
  381.         goto begin
  382.     end select
  383.     UIPop 1
  384. End Sub
  385.  
  386.  
  387.  
  388. ''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
  389. Sub NetworkDrive() STATIC
  390. begin:
  391.     szButton = UIStartDlg(CUIDLL_FILENAME, DLG_NETWORKDRIVE, "FInfo0DlgProc", 0, "")
  392.     select case szButton
  393.     case "REACTIVATE"
  394.         goto begin
  395.     end select
  396.     UIPop 1
  397. End Sub
  398.  
  399. ''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
  400. Function LicenseAgreement() STATIC As Integer
  401. begin:
  402.     szButton = UIStartDlg( CUIDLL_FILENAME, DLG_LICENSE, "FInfoDlgProc", 0, "" )
  403.     select case szButton
  404.     case "CONTINUE"
  405.         UIPop 1
  406.         LicenseAgreement = NAV_FORWARD
  407.     case "EXIT" , "CANCEL"
  408.         LicenseAgreement = NAV_EXIT
  409.     end select
  410. End Function
  411.  
  412. ''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
  413. Function Welcome() STATIC As Integer
  414. begin:
  415.     szButton = UIStartDlg(CUIDLL_FILENAME, DLG_WELCOME, "FInfoDlgProc", DLG_WELHELP, PROC_HELP)
  416.     select case szButton
  417.     case "REACTIVATE"
  418.         goto begin
  419.     case "CONTINUE"
  420.         UIPop 1
  421.         Welcome = NAV_FORWARD
  422.     case "EXIT" , "CANCEL"
  423.         AskQuit
  424.         goto begin
  425.     end select
  426. End Function
  427.  
  428. ''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
  429. Function TestSystem() STATIC As Integer
  430.  
  431. TestNortonAntiVirus:
  432.     szWinString$ = GetIniKeyString( "win.ini", "windows", "load")
  433.     ret% = instr( szWinString,"NAV\navtsrw.exe" )
  434.     if ret% <> 0  then
  435.         dButton = DoMsgBox(STR_NAV, szMsgCaption$, MB_OK)
  436.     endif
  437.  
  438. TestWinVer:
  439.     if GetWindowsMajorVersion() < 3 or (GetWindowsMajorVersion() = 3 and GetWindowsMinorVersion() < 10) then
  440.         TestWinVerDlgLoop:
  441.             szButton = UIStartDlg (CUIDLL_FILENAME, DLG_NEED31, "FInfoDlgProc", DLG_AWFULMACHINE, PROC_HELP)
  442.             select case szButton
  443.             case "EXIT" , "CANCEL"
  444.                 goto TestWinVerDlgLoop
  445.             end select
  446.     end if
  447.  
  448.     ' Check for Win 95
  449.     OS_Windows95 = 0
  450.  
  451.     WinVer=GetWindowsMajorVersion * 100 + GetWindowsMinorVersion
  452.     Ver$=str$(WinVer)
  453. '        dButton = DoMsgBox(ver$, szMsgCaption$, MB_OK+MB_TASKMODAL+MB_ICONINFORMATION)
  454.     if ((GetWindowsMajorVersion * 100 + GetWindowsMinorVersion) > 350) THEN
  455.         OS_Windows95 = 1
  456. '****************************************************************************************************************************************
  457. '****************************************************************************************************************************************
  458. 'For debugging...
  459. '        dButton = DoMsgBox("This is windows 95", szMsgCaption$, MB_OK+MB_TASKMODAL+MB_ICONINFORMATION)
  460. '****************************************************************************************************************************************
  461. '****************************************************************************************************************************************
  462.     endif
  463.  
  464.      IF OnWindowsNT () THEN
  465.         if ((GetWindowsMajorVersion * 100 + GetWindowsMinorVersion) > 309) THEN
  466.             OS_Windows95 = 1
  467. '****************************************************************************************************************************************
  468. '****************************************************************************************************************************************
  469. 'For debugging...
  470. '        dButton = DoMsgBox("This is windows 95", szMsgCaption$, MB_OK+MB_TASKMODAL+MB_ICONINFORMATION)
  471. '****************************************************************************************************************************************
  472. '****************************************************************************************************************************************
  473.         endif
  474.     endif
  475.  
  476. TestVGA:
  477.     if GetScreenWidth () < 640 or GetScreenHeight () < 480 then
  478.         TestVGADlgLoop:
  479.             szButton = UIStartDlg (CUIDLL_FILENAME, DLG_BADVGA, "FInfoDlgProc", DLG_AWFULMACHINE, PROC_HELP)
  480.             select case szButton
  481.             case "REACTIVATE"
  482.                 goto TestVGADlgLoop
  483.             case "BACK"
  484.                 UIPop 1
  485.                 TestSystem = NAV_BACK
  486.                 goto back
  487.             case "CONTINUE"
  488.                 TestSystem = NAV_FORWARD
  489.                 UIPop 1
  490.                 goto TestMouse
  491.             case "EXIT" , "CANCEL"
  492.                 AskQuit
  493.                 goto TestVGADlgLoop
  494.             end select
  495.         end if
  496.  
  497. TestMouse:
  498.     if HasMouseInstalled() = false then
  499.     TestMouseDlgLoop:
  500.         szButton = UIStartDlg (CUIDLL_FILENAME, DLG_NOMOUSE, "FInfoDlgProc", DLG_AWFULMACHINE, PROC_HELP)
  501.         select case szButton
  502.         case "REACTIVATE"
  503.             goto TestMouseDlgLoop
  504.         case "BACK"
  505.             UIPop 1
  506.             TestSystem = NAV_BACK
  507.         case "CONTINUE"
  508.             TestSystem = NAV_FORWARD
  509.             UIPop 1
  510.             goto TestColour
  511.         case "EXIT" , "CANCEL"
  512.             AskQuit
  513.             goto TestMouseDlgLoop
  514.         end select
  515.     end if
  516.  
  517. TestColour:
  518.     if FIs256Colour() < 8 then  ' The 8 refers to the number of Bits per pixel...
  519.     TestColourDlgLoop:
  520.         szButton = UIStartDlg (CUIDLL_FILENAME, DLG_NOT256, "FInfoDlgProc", DLG_POORMACHINE, PROC_HELP)
  521.         select case szButton
  522.         case "REACTIVATE"
  523.             goto TestColourDlgLoop
  524.         case "BACK"
  525.             UIPop 1
  526.             TestSystem = NAV_BACK
  527.             goto back
  528.         case "CONTINUE"
  529.             UIPop 1
  530.             TestSystem = NAV_FORWARD
  531.         case "EXIT" , "CANCEL"
  532.             AskQuit
  533.             goto TestColourDlgLoop
  534.         end select
  535.     end if
  536.  
  537. back:
  538. End Function
  539.  
  540.  
  541. ''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
  542. '**
  543. '** Purpose:
  544. '**     Appends a file name to the end of a directory path,
  545. '**     inserting a backslash character as needed.
  546. '** Arguments:
  547. '**     szDir$  - full directory path (with optional ending "\")
  548. '**     szFile$ - filename to append to directory
  549. '** Returns:
  550. '**     Resulting fully qualified path name.
  551. '*************************************************************************
  552. FUNCTION MakePath (szDir$, szFile$) STATIC AS STRING
  553.     IF szDir$ = "" THEN
  554.         MakePath = szFile$
  555.     ELSEIF szFile$ = "" THEN
  556.         MakePath = szDir$
  557.     ELSEIF MID$(szDir$, LEN(szDir$), 1) = "\" THEN
  558.         MakePath = szDir$ + szFile$
  559.     ELSE
  560.         MakePath = szDir$ + "\" + szFile$
  561.     END IF
  562. END FUNCTION
  563.  
  564.  
  565.  
  566. '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
  567. Function HandleRestart() STATIC AS INTEGER
  568.     ' Check there are system files to install AND check if Windows v3.1 or greater
  569.     if RestartListEmpty = 0 and GetWindowsMajorVersion >= 3 and GetWindowsMajorVersion >= 1 then
  570.         dButton = DoMsgBox(STR_EXIT, szMsgCaption$, MB_OK+MB_TASKMODAL+MB_ICONINFORMATION)
  571.         tryagain:
  572.         if ExitExecRestart = 1 then
  573.             ' Exit failed
  574.             dButton = DoMsgBox(STR_EXITFAIL, szMsgCaption$, MB_OK+MB_TASKMODAL+MB_ICONSTOP)
  575.             goto tryagain
  576.         end if
  577.     end if
  578.  
  579.     HandleRestart = 1
  580.  
  581.     if RestartListEmpty = 1 then ' Empty, but we have to reboot
  582.         dummy% = ExitWindowsExec(MakePath(szDestPath, "_msrstrt.exe"), "")
  583.         if dummy% = 0 then
  584.             HandleRestart = 0
  585.         end if
  586.     end if
  587.  
  588. End Function
  589.  
  590. ''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
  591. 'Sub UpdateProgramManager(prodName$, appExeFile$, appPengeFile$, readmeFile$, readmeStr$, onCDROM%) STATIC
  592. 'Dim szReadmeTitle As String
  593. 'Dim szInf As String
  594. '
  595. '    if onCDROM% = 1 then    'sampler
  596. '        CreateProgmanGroup STR_COMPANYNAME, "", cmoNone
  597. '        ShowProgmanGroup   STR_COMPANYNAME, 1, cmoNone
  598. '        szReadmeTitle = prodName$ + " " + readmeStr$
  599. '
  600. '        szInf = MakePath( mid$(szSrcSetupPath, 1, (len(szSrcSetupPath) - len(SOURCE_SETUP_SUBDIR))-1), appExeFile$)
  601. '        CreateProgmanItem STR_COMPANYNAME, prodName$, szInf, MakePath(szDestPath, "sampler.ico"), cmoOverwrite
  602. ''        CreateProgmanItem STR_COMPANYNAME, szReadmeTitle, "notepad.exe " + MakePath( mid$(szSrcSetupPath, 1, (len(szSrcSetupPath) - len(SOURCE_SETUP_SUBDIR))-1), readmeFile$), "", cmoOverwrite
  603. '    else
  604. '        if szAddPMItem = "ON" then
  605. '            CreateProgmanGroup STR_COMPANYNAME, "", cmoNone
  606. '            ShowProgmanGroup   STR_COMPANYNAME, 1, cmoNone
  607. '            szReadmeTitle = prodName$ + " " + readmeStr$
  608. '            if szMinimalInstall = "ON" then
  609. '                szInf = MakePath(szSrcBinPath, appExeFile$) + " " + MakePath(szSrcBinPath, appPengeFile$)
  610. '                CreateProgmanItem STR_COMPANYNAME, prodName$, szInf, szInf, cmoOverwrite
  611. '                CreateProgmanItem STR_COMPANYNAME, szReadmeTitle, "notepad.exe " + MakePath(szSrcBinPath, readmeFile$), "", cmoOverwrite
  612. '            else
  613. '                szInf = MakePath(szDestPath, appExeFile$) + " " + MakePath(szDestPath, appPengeFile$)
  614. '                CreateProgmanItem STR_COMPANYNAME, prodName$, szInf, szInf, cmoOverwrite
  615. '                CreateProgmanItem STR_COMPANYNAME, szReadmeTitle, "notepad.exe " + MakePath(szDestPath, readmeFile$), "", cmoOverwrite
  616. '            end if
  617. '        end if
  618. '    end if
  619. '
  620. 'End Sub
  621.  
  622.  
  623. ''''''''''''''''''''''''''''''''''''''''''''
  624.  
  625. '' Alternative function for french stowaway
  626. '' Readme icon has shortened name
  627. 'Sub UpdateProgramManagerAlt(prodName$, readmeName$, appExeFile$, appPengeFile$, readmeFile$, readmeStr$, onCDROM%) STATIC
  628. 'Dim szReadmeTitle As String
  629. 'Dim szInf As String
  630. '
  631. '    if onCDROM% = 1 then    'sampler
  632. '        CreateProgmanGroup STR_COMPANYNAME, "", cmoNone
  633. '        ShowProgmanGroup   STR_COMPANYNAME, 1, cmoNone
  634. '        szReadmeTitle = readmeName$ + " " + readmeStr$
  635. '
  636. '        szInf = MakePath( mid$(szSrcSetupPath, 1, (len(szSrcSetupPath) - len(SOURCE_SETUP_SUBDIR))-1), appExeFile$)
  637. '        CreateProgmanItem STR_COMPANYNAME, prodName$, szInf, MakePath(szDestPath, "sampler.ico"), cmoOverwrite
  638. ''        CreateProgmanItem STR_COMPANYNAME, szReadmeTitle, "notepad.exe " + MakePath( mid$(szSrcSetupPath, 1, (len(szSrcSetupPath) - len(SOURCE_SETUP_SUBDIR))-1), readmeFile$), "", cmoOverwrite
  639. '   else
  640. '        if szAddPMItem = "ON" then
  641. '            CreateProgmanGroup STR_COMPANYNAME, "", cmoNone
  642. '            ShowProgmanGroup   STR_COMPANYNAME, 1, cmoNone
  643. '            szReadmeTitle = readmeName$ + " " + readmeStr$
  644. '            if szMinimalInstall = "ON" then
  645. '                szInf = MakePath(szSrcBinPath, appExeFile$) + " " + MakePath(szSrcBinPath, appPengeFile$)
  646. '                CreateProgmanItem STR_COMPANYNAME, prodName$, szInf, szInf, cmoOverwrite
  647. '                CreateProgmanItem STR_COMPANYNAME, szReadmeTitle, "notepad.exe " + MakePath(szSrcBinPath, readmeFile$), "", cmoOverwrite
  648. '            else
  649. '                szInf = MakePath(szDestPath, appExeFile$) + " " + MakePath(szDestPath, appPengeFile$)
  650. '                CreateProgmanItem STR_COMPANYNAME, prodName$, szInf, szInf, cmoOverwrite
  651. '                CreateProgmanItem STR_COMPANYNAME, szReadmeTitle, "notepad.exe " + MakePath(szDestPath, readmeFile$), "", cmoOverwrite
  652. '            end if
  653. '        end if
  654. '    end if
  655. '
  656. 'End Sub
  657.  
  658.  
  659.  
  660. '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
  661. Function GetDiskSpaceNeeded( drive% ) STATIC As Long
  662. Dim dDummy As Long
  663.  
  664.     cursor% = ShowWaitCursor()
  665.  
  666.     SetSymbolValue "ExtraSpace", ""
  667.     SetSymbolValue "Needed", ""
  668.     SetSymbolValue "Cost", ""
  669.  
  670.     'Drives A - Z
  671.     for i% = 1 to 26
  672.         AddListItem "ExtraSpace", ""
  673.     next i%
  674.  
  675.     ReplaceListItem "ExtraSpace", dWinDrive, str$(MINIMUM_DISK_SPACE)    '2K for the INI file
  676.  
  677.     dDummy = GetCopyListCost("ExtraSpace","Needed","Cost")
  678.  
  679.     GetDiskSpaceNeeded = val(GetListItem ("Needed", drive))
  680.  
  681.     RemoveSymbol "Needed"
  682.     RemoveSymbol "Cost"
  683.     RemoveSymbol "ExtraSpace"
  684.  
  685.     RestoreCursor(cursor%)
  686. End Function
  687.  
  688.  
  689.  
  690. ''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
  691. Sub UpdateIndeoAVIDrivers() STATIC
  692. Dim szWMDriver As String
  693. Dim szACMDriver As String
  694.  
  695.  
  696.     ' Dont update VFW on Win 95. It is already there.
  697.     IF OS_Windows95 = 0 then
  698.  
  699.         szWMDriver = GetIniKeyString(MakePath(szWinPath,"system.ini"), "drivers", "WaveMapper")
  700.  
  701.         if not(szWMDriver = "msacm.drv") then
  702.             fSystemUpdated = 1
  703.         end if
  704.  
  705.  
  706.         if VflatdPresent() = 0 then
  707.             CreateSysIniKeyValue szWinPath + "system.ini", "386Enh", "device", "dva.386", cmoOverwrite
  708.             fSystemUpdated = 1
  709.         end if
  710.         CreateIniKeyValue szWinPath + "system.ini", "Drivers", "VIDC.IV32", "ir32.dll", cmoOverwrite
  711.         CreateIniKeyValue szWinPath + "system.ini", "Drivers", "VIDC.IV31", "ir32.dll", cmoOverwrite
  712.         CreateIniKeyValue szWinPath + "system.ini", "Drivers", "VIDC.RT21", "ir21.dll", cmoOverwrite
  713.         CreateIniKeyValue szWinPath + "system.ini", "Drivers", "VIDC.YVU9", "iyvu9.dll", cmoOverwrite
  714.         CreateIniKeyValue szWinPath + "system.ini", "Drivers", "VIDC.CVID", "iccvid.drv", cmoOverwrite
  715.         CreateIniKeyValue szWinPath + "system.ini", "Drivers", "VIDC.MSVC", "msvidc.drv", cmoOverwrite
  716.         CreateIniKeyValue szWinPath + "system.ini", "Drivers", "VIDC.MRLE", "MSRLE.drv", cmoOverwrite
  717.         CreateIniKeyValue szWinPath + "WIN.INI", "mci extensions", "avi", "AVIVideo", cmoOverwrite
  718.         CreateIniKeyValue szWinPath + "system.ini", "mci", "AVIVideo", "mciavi.drv", cmoOverwrite
  719.         CreateIniKeyValue szWinPath + "control.ini", "drivers.desc", "ir21.dll", "Intel Indeo(TM) Video R2.1", cmoOverwrite
  720.  
  721.     END IF
  722.  
  723. End Sub
  724.  
  725. '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
  726. Sub UpdateWinGDrivers() STATIC
  727. Dim szDest As String
  728. Dim szDest1 As String
  729. Dim szDest2 As String
  730.  
  731.     ' only use DVA on Windows 3.x
  732.     if OnWin3x() = 1 then
  733.         AddSectionFilesToCopyList "dva", szSrcBinPath, szWinSysPath
  734.         if VflatdPresent() = 0 then
  735.             ' Taken out the path in the following device=dva.386 system.ini entry
  736.             CreateSysIniKeyValue szWinPath + "system.ini", "386Enh", "device", "dva.386", cmoOverwrite
  737.             fSystemUpdated = 1
  738.         end if
  739.     end if
  740.  
  741.     szDest = GetRealWindowsSysDir
  742.     szDest1 = MakePath(szDest,"wing32.dll")
  743.     szDest2 = MakePath(szDest,"wing32.xxx")
  744.     RenameFilePlease szDest1, szDest2
  745.  
  746.     UpdateWinG32 GetRealWindowsSysDir()
  747. End Sub
  748.  
  749. '''''''''''''''''''''''''''''''''''''''''''''''''
  750.  
  751. FUNCTION GetRealWindowsSysDir STATIC AS STRING
  752.     szBuf$ = string$(260, 32)
  753.     cbBuf% = GetRealSystemDir(szBuf$, 260)
  754.     IF cbBuf% = 0 THEN
  755.         ERROR STFERR
  756.     ELSE
  757.         IF cbBuf% > 259 THEN
  758.             res% = DoMsgBox("Buffer Overflow", "MS-Setup Error", MB_ICONHAND+MB_OK)
  759.             ERROR STFERR
  760.         END IF
  761.         szBuf$ = RTRIM$(szBuf$)
  762.         IF MID$(szBuf$, 1, 1) = "\" THEN
  763.             szBuf$ = MID$(CURDIR$, 1, 2) + szBuf$
  764.         ELSEIF MID$(szBuf$, 2, 1) <> ":" THEN
  765.             szBuf$ = MID$(CURDIR$, 1, 3) + szBuf$
  766.         END IF
  767.         IF MID$(szBuf$, LEN(szBuf$), 1) <> "\" THEN
  768.             szBuf$ = szBuf$ + "\"
  769.         END IF
  770.         GetRealWindowsSysDir = szBuf$
  771.     END IF
  772.  
  773.     szBuf$ = ""
  774. END FUNCTION
  775.  
  776. '''''''''''''''''''''''''''''''''''''''''''''''''
  777.  
  778. SUB UpdateWinG32 (szOrig$) STATIC
  779.     '
  780.     ' Here we check the version ourselves of wing32.dll, since
  781.     ' we can't get version checking for Win32 apps from Win16
  782.     '
  783.     FileNew$ = MakePath(szOrig$, "wing32.dll")
  784.     FileOrig$ = MakePath(szOrig$, "wing32.xxx")
  785.     IF IsWin32FileNewer( FileOrig$, FileNew$ ) THEN
  786.         RemoveFile FileOrig$, cmoForce
  787.     ELSE
  788.         RemoveFile FileNew$, cmoForce       ' get rid of new file
  789.         RenameFilePlease FileOrig$,FileNew$ ' put back old file
  790.     END IF
  791. END SUB
  792.  
  793. '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
  794. Function UpdateADPCMDrivers() STATIC As Integer
  795. Dim szWMDriver As String
  796. Dim szACMDriver As String
  797. Dim fUpdate As Integer
  798.  
  799.     '   Dont update ADPCM on Win 95. It is already there.
  800.     If OS_Windows95 = 0 then
  801.  
  802.     ' Check WaveMapper driver
  803.     szWMDriver = GetIniKeyString(MakePath(szWinPath,"system.ini"), "drivers", "WaveMapper")
  804.     szACMDriver = GetIniKeyString (MakePath(szWinPath, "system.ini"), "MSACM", "Install")
  805.  
  806.     if not(szWMDriver = "msacm.drv") then
  807.     ' Isn't installed so...
  808.  
  809.         ' If NO ADPCM drivers are installed so...
  810.         if (szWMDriver = "") then
  811.             ' Display a dialog saying "there are no ADPCM drivers on your system..."
  812.             fUpdate = 1
  813.         else
  814.             ' There is a different adpcm driver in there so warn about compatibility
  815.         loop1:
  816.             szButton = UIStartDlg(CUIDLL_FILENAME, DLG_URKADPCM, "FInfoDlgProc", DLG_ADPCMHELP, PROC_HELP)
  817.             select case szButton
  818.             case "REACTIVATE"
  819.                 goto loop1
  820.             case "EXIT" , "CANCEL"
  821.                 AskQuit
  822.                 goto loop1
  823.             case "CONTINUE"     ' YES
  824.                 UpdateADPCMDrivers = NAV_FORWARD
  825.                 UIPop 1
  826.                 fUpdate = 1
  827. '            case "CANCEL"       ' NO
  828. '                UIPop 1
  829. '                fUpdate = 0
  830.             case "BACK"
  831.                 UIPop 1
  832.                 UpdateADPCMDrivers = NAV_BACK
  833.                 goto back
  834.             end select
  835.         end if
  836.  
  837.  
  838.         if fUpdate = 1 then
  839.             CreateIniKeyValue szWinPath + "system.ini", "Drivers", "WaveMapper", "msacm.drv", cmoOverwrite
  840.             CreateIniKeyValue szWinPath + "system.ini", "Drivers", "MSACM.msadpcm", "msadpcm.acm", cmoOverwrite
  841.             CreateIniKeyValue szWinPath + "system.ini", "Drivers", "MSACM.imaadpcm", "imaadpcm.acm", cmoOverwrite
  842.             CreateIniKeyValue szWinPath + "control.ini", "drivers.desc", "msacm.drv", "Microsoft Sound Mapper V2.00", cmoOverwrite
  843.             CreateIniKeyValue szWinPath + "control.ini", "drivers.desc", "msadpcm.acm", "Microsoft ADPCM Codec V2.00", cmoOverwrite
  844.             CreateIniKeyValue szWinPath + "control.ini", "drivers.desc", "imaadpcm.acm", "Microsoft IMA ADPCM Codec V2.00", cmoOverwrite
  845.  
  846.             szMsacmPriority1 = GetIniKeyString(szWinPath + "MSACM.INI","PRIORITY","PRIORITY1")
  847.             szMsacmPriority2 = GetIniKeyString(szWinPath + "MSACM.INI","PRIORITY","PRIORITY2")
  848.             szMsacmPriority3 = GetIniKeyString(szWinPath + "MSACM.INI","PRIORITY","PRIORITY3")
  849.  
  850.             if mid$( szMsacmPriority1, 1, 1 ) = "0" then
  851.                 szMsacmPriority1 = "1" + mid$( szMsacmPriority1, 2, len(szMsacmPriority1)-1 )
  852.                 CreateIniKeyValue szWinPath + "msacm.ini", "PRIORITY", "PRIORITY1", szMsacmPriority1, cmoOverwrite
  853.             endif
  854.  
  855.             if mid$( szMsacmPriority2, 1, 1 ) = "0" then
  856.                 szMsacmPriority2 = "1" + mid$( szMsacmPriority2, 2, len(szMsacmPriority2)-1 )
  857.                 CreateIniKeyValue szWinPath + "msacm.ini", "PRIORITY", "PRIORITY2", szMsacmPriority2, cmoOverwrite
  858.             endif
  859.  
  860.             if mid$( szMsacmPriority3, 1, 1 ) = "0" then
  861.                 szMsacmPriority3 = "1" + mid$( szMsacmPriority3, 2, len(szMsacmPriority3)-1 )
  862.                 CreateIniKeyValue szWinPath + "msacm.ini", "PRIORITY", "PRIORITY3", szMsacmPriority3, cmoOverwrite
  863.             endif
  864.  
  865.             fSystemUpdated = 1
  866.         else
  867.         noSysSoftware:
  868.             ' No install warning
  869.             szButton = UIStartDlg(CUIDLL_FILENAME, DLG_NOSYSSOFT, "FInfoDlgProc", 0, "")
  870.             select case szButton
  871.             case "REACTIVATE"
  872.                 goto noSysSoftware
  873.             case "EXIT" , "CANCEL"
  874.                 AskQuit
  875.                 goto noSysSoftware
  876.             case "CONTINUE"
  877.                 UIPop 1
  878.             case "BACK"
  879.                 UIPop 1
  880.                 goto loop1
  881.             end select
  882.         end if
  883.  
  884.     end if
  885. back:
  886.     END IF
  887. End Function
  888.  
  889. '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
  890. Function InstallQTW() STATIC As Integer
  891.  
  892. begin:
  893.     szButton = UIStartDlg( CUIDLL_FILENAME, DLG_INSTALLQTW, "FInfoDlgProc", 0, "" )
  894.     select case szButton
  895.     case "REACTIVATE"
  896.         goto begin
  897.     case "CONTINUE" ' Yes Install QTW
  898.         '
  899.         'Put in the New Dialogue here... (If you do not know what you are doing then can you please do as we say!!!)
  900.         dButton = DoMsgBox(STR_QTWMSG1+STR_QTWMSG2+STR_QTWMSG3, szMsgCaption$, MB_OK+MB_TASKMODAL+MB_ICONINFORMATION)
  901.         '
  902.         IF OS_Windows95 = 1 then
  903.             ' Install the 32 bit version on Windows 95
  904. '***************************************************************************************************************************************
  905.             'Enter the code to disable the lip sync thing... 32 bit...
  906.             CreateIniKeyValue szWinPath + "Qtw.ini", "Sound 32", "DisableAutoRateAdjust", "1", cmoOverwrite
  907. '***************************************************************************************************************************************
  908.             Run ( MakePath( szSrcBinPath, "qt32inst.exe" ) )
  909.         Else
  910.             ' Else Install the 16 bit version
  911. '***************************************************************************************************************************************
  912.             'Enter the code to disable the lip sync thing... 16 bit...
  913.             CreateIniKeyValue szWinPath + "Qtw.ini", "Sound", "DisableAutoRateAdjust", "1", cmoOverwrite
  914. '***************************************************************************************************************************************
  915.             Run ( MakePath( szSrcBinPath, "qt16inst.exe" ) )
  916.         END IF
  917.  
  918.         UIPop 1
  919.         InstallQTW = NAV_FORWARD
  920.  
  921.     case "BACK"     ' No Don't Install QTW
  922.         UIPop 1
  923.         InstallQTW = NAV_BACK
  924.     case "EXIT" , "CANCEL"
  925.         AskQuit
  926.         goto begin
  927.     end select
  928.  
  929. End Function
  930.  
  931. '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''