home *** CD-ROM | disk | FTP | other *** search
/ The Weather Channel - Everything Weather / TheWeatherChannel-EverythingWeather-Win31.iso / twcia / sky / sky.dxr / 00028.ls < prev    next >
Encoding:
Text File  |  1995-08-22  |  1.0 KB  |  37 lines

  1. on mouseDown
  2.   global passWord
  3.   set index to the mouseWord
  4.   set article to the castNum of sprite the clickOn
  5.   if the controlDown or the optionDown then
  6.     colorSet(article, index)
  7.   end if
  8.   if the foreColor of word index of field article <> 249 then
  9.     exit
  10.   end if
  11.   repeat with start = index down to 1
  12.     if the foreColor of word start of field article = 255 then
  13.       exit repeat
  14.     end if
  15.     if (word start of field article contains ",") or (word start of field article contains ".") then
  16.       if start <> index then
  17.         exit repeat
  18.       end if
  19.     end if
  20.   end repeat
  21.   repeat with end = index to the maxinteger
  22.     if the foreColor of word end of field article = 255 then
  23.       exit repeat
  24.     end if
  25.     if (word end of field article contains ",") or (word end of field article contains ".") then
  26.       set end to end + 1
  27.       exit repeat
  28.     end if
  29.   end repeat
  30.   set passWord to word start + 1 to end - 1 of field article
  31.   set x to offset(RETURN, passWord)
  32.   if x then
  33.     put " " into char x of passWord
  34.   end if
  35.   showSearch()
  36. end
  37.