home *** CD-ROM | disk | FTP | other *** search
/ Personal Computer World 1997 September / Personal_Computer_World_Sep_97.iso / DXRS / SLIPCW09.DXR / 00015_refreshprogramdetails.ls < prev    next >
Encoding:
Text File  |  1997-06-27  |  12.4 KB  |  218 lines

  1. on refreshprogramdetails
  2.   global DriveLtr, SLIdatabaselist, SLIchosenprogramdetails, SLImainmenuhilitenumber, SLImainmenutextnumber, SLIsunmenuhilitenumber, SLImainmenubacknumber, SLIsubmenubacknumber, SLIsubmenuhilitenumber, SLIsubmenutextnumber, SLIactiveprogramlist, SLIBackArrowNumber, SLIForwardArrowNumber, SLIsubmenubackshadownumber, SLIActionButton, SLICopyButton, SLItextboxframe, SLIInfoTabRect, SLIProcTabRect, SLIExtraTabRect, SLIpicturebox, SLITextBoxContents, SLITextFilesLoaded, SLIplatformcheckbox, SLIRunButtonList, SLIInstallButtonList, SLIActionList, SLIFullTextOptionBox, SLITextLoadOptionRect, SLIFullTextTick, SLIPictureBoxNumber, SLIAddressBoxNumber, SLIProductBoxNumber, SLIPlatformCheck01, SLIPlatformCheck02, SLIPlatformCheck03, SLIPlatformCheck04, SLIInstallButtonTextBox, SLIRunButtonTextBox, SLICopyWIthInstallTextBox, SLICopyWIthRunTextBox, SLIExecuteTextBox
  3.   set the loc of sprite SLIpicturebox to point(2000, 2000)
  4.   set the loc of sprite SLITextBoxContents to point(2000, 2000)
  5.   updateStage()
  6.   put EMPTY into field "productnamebox"
  7.   put EMPTY into field "addressbox"
  8.   put EMPTY into field "longtext"
  9.   put EMPTY into field "processreqtext"
  10.   put EMPTY into field "extrareqtext"
  11.   set contactinfo to EMPTY
  12.   set the text of member "temptext" to " "
  13.   set the picture of member "picturemember" to the picture of member "slidot"
  14.   set addressboxcontents to EMPTY
  15.   updateStage()
  16.   put the realname of SLIchosenprogramdetails after field "productnamebox"
  17.   if the version of SLIchosenprogramdetails > EMPTY then
  18.     put " (ver.  " & the version of SLIchosenprogramdetails & ")" after field "productnamebox"
  19.   end if
  20.   put the supplier of SLIchosenprogramdetails after contactinfo
  21.   if the supplier of SLIchosenprogramdetails > EMPTY then
  22.     put RETURN after contactinfo
  23.   end if
  24.   put the contactstreet of SLIchosenprogramdetails after contactinfo
  25.   if the contactstreet of SLIchosenprogramdetails > EMPTY then
  26.     put RETURN after contactinfo
  27.   end if
  28.   put the contacttown of SLIchosenprogramdetails after contactinfo
  29.   if the contacttown of SLIchosenprogramdetails > EMPTY then
  30.     put RETURN after contactinfo
  31.   end if
  32.   put the contactcounty of SLIchosenprogramdetails after contactinfo
  33.   if the contactcounty of SLIchosenprogramdetails > EMPTY then
  34.     put RETURN after contactinfo
  35.   end if
  36.   put the contactpostcode of SLIchosenprogramdetails after contactinfo
  37.   if the contactpostcode of SLIchosenprogramdetails > EMPTY then
  38.     put RETURN after contactinfo
  39.   end if
  40.   put the contactcountry of SLIchosenprogramdetails after contactinfo
  41.   if the contactcountry of SLIchosenprogramdetails > EMPTY then
  42.     put RETURN after contactinfo
  43.   end if
  44.   if the contacttelephone of SLIchosenprogramdetails > EMPTY then
  45.     put RETURN & "Tel: " & the contacttelephone of SLIchosenprogramdetails after contactinfo
  46.   end if
  47.   if the contactemail of SLIchosenprogramdetails > EMPTY then
  48.     put RETURN & "Email: " & the contactemail of SLIchosenprogramdetails after contactinfo
  49.   end if
  50.   if the webaddress of SLIchosenprogramdetails > EMPTY then
  51.     put RETURN & "Web Address: " & the webaddress of SLIchosenprogramdetails after contactinfo
  52.   end if
  53.   put contactinfo into field "addressbox"
  54.   set the rect of member "addressbox" to rect(0, 0, 300, 100)
  55.   set the textAlign of member "addressbox" to "left"
  56.   set the textSize of member "addressbox" to 12
  57.   set the textHeight of member "addressbox" to 16
  58.   if the ImageFile of SLIchosenprogramdetails > EMPTY then
  59.     set the picture of member "picturemember" to the picture of member the ImageFile of SLIchosenprogramdetails
  60.     set the regPoint of member "picturemember" to point(0, 0)
  61.     set the member of sprite SLIpicturebox to member "picturemember"
  62.     set the rect of sprite SLIpicturebox to the rect of member "picturemember"
  63.     set the loc of sprite SLIpicturebox to point(430, 39)
  64.   end if
  65.   set the textHeight of member "longtext" to 16
  66.   set the rect of member "longtext" to rect(0, 0, 425, 11 * the textHeight of member "longtext")
  67.   set the boxType of member "longtext" to #scroll
  68.   set the border of member "longtext" to 1
  69.   set the textAlign of member "longtext" to "left"
  70.   set the textSize of member "longtext" to 12
  71.   set the textHeight of member "processreqtext" to 16
  72.   set the rect of member "longtext" to rect(0, 0, 425, 11 * the textHeight of member "processreqtext")
  73.   set the boxType of member "processreqtext" to #fixed
  74.   set the border of member "processreqtext" to 1
  75.   set the textAlign of member "processreqtext" to "left"
  76.   set the textSize of member "processreqtext" to 12
  77.   set the textHeight of member "extrareqtext" to 16
  78.   set the rect of member "longtext" to rect(0, 0, 425, 11 * the textHeight of member "extrareqtext")
  79.   set the boxType of member "extrareqtext" to #fixed
  80.   set the border of member "extrareqtext" to 1
  81.   set the textAlign of member "extrareqtext" to "left"
  82.   set the textSize of member "extrareqtext" to 12
  83.   if the TextFile of SLIchosenprogramdetails > EMPTY then
  84.     if SLITextFilesLoaded = 1 then
  85.       set the loc of sprite SLIFullTextOptionBox to point(78, 325)
  86.       set the loc of sprite SLIFullTextTick to point(135, 321)
  87.       set the boxType of member "longtext" to #scroll
  88.       set the rect of member "longtext" to rect(0, 0, 437, 11 * the textHeight of member "longtext")
  89.       set opentextfile to FileIO(mnew, "read", DriveLtr & the TextFile of SLIchosenprogramdetails)
  90.       put "opentextfile = " & opentextfile
  91.       set thisFile to opentextfile(mReadFile)
  92.       opentextfile(mdispose)
  93.       put thisFile into field "longtext"
  94.       tidyuptext("longtext")
  95.       set the rect of sprite SLITextBoxContents to the rect of member "longtext"
  96.       set the member of sprite SLITextBoxContents to member "longtext"
  97.       set the loc of sprite SLITextBoxContents to point(172, 249)
  98.       set the member of sprite SLItextboxframe to member "infotab1"
  99.     else
  100.       set the loc of sprite SLIFullTextOptionBox to point(78, 325)
  101.       set the loc of sprite SLIFullTextTick to point(2000, 2000)
  102.       set the boxType of member "longtext" to #fixed
  103.       set the rect of member "longtext" to rect(0, 0, 453, 11 * the textHeight of member "longtext")
  104.       set substitutetext to the briefdescription of SLIchosenprogramdetails & RETURN & RETURN
  105.       put "More information is available by selecting " & QUOTE & "Import full text file" & QUOTE after substitutetext
  106.       put substitutetext into field "longtext"
  107.       set the rect of sprite SLITextBoxContents to the rect of member "longtext"
  108.       set the member of sprite SLITextBoxContents to member "longtext"
  109.       set the loc of sprite SLITextBoxContents to point(172, 249)
  110.       set the member of sprite SLItextboxframe to member "infotab1"
  111.     end if
  112.   else
  113.     set the loc of sprite SLIFullTextOptionBox to point(2000, 2000)
  114.     set the loc of sprite SLIFullTextTick to point(2000, 2000)
  115.     set the boxType of member "longtext" to #fixed
  116.     set the rect of member "longtext" to rect(0, 0, 453, 11 * the textHeight of member "longtext")
  117.     set substitutetext to the briefdescription of SLIchosenprogramdetails & RETURN & RETURN
  118.     put "No further information" after substitutetext
  119.     put substitutetext into field "longtext"
  120.     set the rect of sprite SLITextBoxContents to the rect of member "longtext"
  121.     set the member of sprite SLITextBoxContents to member "longtext"
  122.     set the loc of sprite SLITextBoxContents to point(172, 249)
  123.     set the member of sprite SLItextboxframe to member "infotab1"
  124.     updateStage()
  125.   end if
  126.   set the boxType of member "processreqtext" to #fixed
  127.   set the rect of member "processreqtext" to rect(0, 0, 453, 11 * the textHeight of member "processreqtext")
  128.   put the processreqs of SLIchosenprogramdetails into field "processreqtext"
  129.   set the boxType of member "extrareqtext" to #fixed
  130.   set the rect of member "extrareqtext" to rect(0, 0, 453, 11 * the textHeight of member "extrareqtext")
  131.   put the extrareqs of SLIchosenprogramdetails into field "extrareqtext"
  132.   set playinstcopyoption to the playinstcopy of SLIchosenprogramdetails
  133.   case playinstcopyoption of
  134.     "installs":
  135.       set SLIActionList to SLIInstallButtonList
  136.       set the loc of sprite SLIActionButton to point(230, 455)
  137.       set installfilesize to the installationsize of SLIchosenprogramdetails
  138.       set copyfilesize to the storedsize of SLIchosenprogramdetails
  139.       put EMPTY into field "actionbuttontextbox"
  140.       put EMPTY into field "copybuttontextbox"
  141.       put SLIInstallButtonTextBox & RETURN into field "actionbuttontextbox"
  142.       put RETURN & "Installation requires " & installfilesize & " Kb of disk space" & RETURN after field "actionbuttontextbox"
  143.       put RETURN & "Continue         Cancel" after field "actionbuttontextbox"
  144.       put SLICopyWIthInstallTextBox & RETURN into field "copybuttontextbox"
  145.       put RETURN & "Copying requires " & copyfilesize & " Kb of disk space" & RETURN after field "copybuttontextbox"
  146.       put RETURN & "Continue         Cancel" after field "copybuttontextbox"
  147.     "playable":
  148.       set SLIActionList to SLIRunButtonList
  149.       set the loc of sprite SLIActionButton to point(230, 455)
  150.       set installfilesize to the installationsize of SLIchosenprogramdetails
  151.       set copyfilesize to the storedsize of SLIchosenprogramdetails
  152.       put EMPTY into field "actionbuttontextbox"
  153.       put EMPTY into field "copybuttontextbox"
  154.       put SLIRunButtonTextBox & RETURN into field "actionbuttontextbox"
  155.       put RETURN & "Continue         Cancel" after field "actionbuttontextbox"
  156.       put SLICopyWIthRunTextBox & RETURN into field "copybuttontextbox"
  157.       put RETURN & "Installation requires " & copyfilesize & " Kb of disk space" & RETURN after field "copybuttontextbox"
  158.       put RETURN & "Continue         Cancel" after field "copybuttontextbox"
  159.     "copy only":
  160.       set the loc of sprite SLIActionButton to point(2000, 2000)
  161.       put EMPTY into field "copybuttontextbox"
  162.       put SLICopyWIthInstallTextBox & RETURN into field "copybuttontextbox"
  163.       put RETURN & "Copying requires " & copyfilesize & " Kb of disk space" & RETURN after field "copybuttontextbox"
  164.       put RETURN & "Continue         Cancel" after field "copybuttontextbox"
  165.   end case
  166.   set the member of sprite SLIActionButton to member getAt(SLIActionList, 1)
  167.   set thisplatform to the platform of SLIchosenprogramdetails
  168.   set dosloc to point(406, 439)
  169.   set w31loc to point(406, 455)
  170.   set w95loc to point(512, 439)
  171.   set wntloc to point(512, 455)
  172.   case thisplatform of
  173.     "DOS":
  174.       set the loc of sprite SLIPlatformCheck01 to dosloc
  175.       set the loc of sprite SLIPlatformCheck02 to point(2000, 2000)
  176.       set the loc of sprite SLIPlatformCheck03 to point(2000, 2000)
  177.       set the loc of sprite SLIPlatformCheck04 to point(2000, 2000)
  178.     "Windows 3.x":
  179.       set the loc of sprite SLIPlatformCheck01 to w31loc
  180.       set the loc of sprite SLIPlatformCheck02 to point(2000, 2000)
  181.       set the loc of sprite SLIPlatformCheck03 to point(2000, 2000)
  182.       set the loc of sprite SLIPlatformCheck04 to point(2000, 2000)
  183.     "Windows 95":
  184.       set the loc of sprite SLIPlatformCheck01 to w95loc
  185.       set the loc of sprite SLIPlatformCheck02 to point(2000, 2000)
  186.       set the loc of sprite SLIPlatformCheck03 to point(2000, 2000)
  187.       set the loc of sprite SLIPlatformCheck04 to point(2000, 2000)
  188.     "Windows 3.x and 95":
  189.       set the loc of sprite SLIPlatformCheck01 to w31loc
  190.       set the loc of sprite SLIPlatformCheck02 to w95loc
  191.       set the loc of sprite SLIPlatformCheck03 to point(2000, 2000)
  192.       set the loc of sprite SLIPlatformCheck04 to point(2000, 2000)
  193.     "Windows 95 and NT":
  194.       set the loc of sprite SLIPlatformCheck01 to w95loc
  195.       set the loc of sprite SLIPlatformCheck02 to wntloc
  196.       set the loc of sprite SLIPlatformCheck03 to point(2000, 2000)
  197.       set the loc of sprite SLIPlatformCheck04 to point(2000, 2000)
  198.     "Windows NT only":
  199.       set the loc of sprite SLIPlatformCheck01 to wntloc
  200.       set the loc of sprite SLIPlatformCheck02 to point(2000, 2000)
  201.       set the loc of sprite SLIPlatformCheck03 to point(2000, 2000)
  202.       set the loc of sprite SLIPlatformCheck04 to point(2000, 2000)
  203.     "OS2":
  204.       set the loc of sprite SLIPlatformCheck01 to point(2000, 2000)
  205.       set the loc of sprite SLIPlatformCheck02 to point(2000, 2000)
  206.       set the loc of sprite SLIPlatformCheck03 to point(2000, 2000)
  207.       set the loc of sprite SLIPlatformCheck04 to point(2000, 2000)
  208.   end case
  209.   set the loc of sprite 8 to point(170, 39)
  210.   set the loc of sprite 9 to point(170, 57)
  211.   cursor(4)
  212.   updateStage()
  213.   cursor(0)
  214.   updateStage()
  215.   cursor(-1)
  216.   updateStage()
  217. end
  218.