home *** CD-ROM | disk | FTP | other *** search
/ Computer Music Interactif 7 / cd.iso / pc / PC / Demos / GroovMak / data1.cab / Program_Executable_Files / Media / OpenS.dxr / 00062.ls < prev    next >
Encoding:
Text File  |  1999-09-17  |  1.4 KB  |  50 lines

  1. on mouseDown
  2.   repeat while the mouseDown
  3.     set the memberNum of sprite the clickOn to the number of member "Hcd"
  4.     updateStage()
  5.   end repeat
  6. end
  7.  
  8. on mouseUp
  9.   global gCD, gPathSynth
  10.   cursor(4)
  11.   set the memberNum of sprite the clickOn to the number of member "cd"
  12.   updateStage()
  13.   if (DirectoryToList(gCD) = []) or (DirectoryToList(gCD) = VOID) then
  14.     put EMPTY into field "fieldElencoSynthCD"
  15.     openWin("Message")
  16.     tell window "Message"
  17.       go("2")
  18.     end tell
  19.   else
  20.     put EMPTY into field "fieldElencoSynthCD"
  21.     set tList to DirectoryToList(gCD & "Library\Song\")
  22.     if getPos(tList, "Song22\") and getPos(tList, "Song44\") then
  23.       set gVers to "1.1"
  24.     else
  25.       set gVers to "1.2"
  26.     end if
  27.     case gVers of
  28.       "1.1":
  29.         set gPathSynth to gCD & "Library\Synth\Synth44\"
  30.       "1.2":
  31.         set gPathSynth to gCD & "Library\Synth\"
  32.     end case
  33.     set tList to DirectoryToList(gPathSynth)
  34.     if tList = [] then
  35.       openWin("Message")
  36.       tell window "Message"
  37.         go("14")
  38.       end tell
  39.     else
  40.       repeat with i = 1 to count(tList)
  41.         put chars(getAt(tList, i), 1, length(getAt(tList, i)) - 1) & RETURN after field "fieldElencoSynthCD"
  42.       end repeat
  43.       set the textFont of member "fieldElencoSynthCD" to "IK10"
  44.       set the foreColor of member "fieldElencoSynthCD" to 0
  45.     end if
  46.   end if
  47.   set the scrollTop of member "fieldElencoSynthCD" to 0
  48.   cursor(-1)
  49. end
  50.