home *** CD-ROM | disk | FTP | other *** search
/ The Fred Fish Collection 1.5 / ffcollection-1-5-1992-11.iso / ff_disks / 300-399 / ff308.lzh / Vlt / rexx / vltmouse.rexx < prev    next >
OS/2 REXX Batch file  |  1990-01-18  |  754b  |  36 lines

  1. /* VLTMouse.rexx */
  2.  
  3. address VLT
  4. quitflag = 0
  5. y = 0
  6. x = 0
  7.  
  8. mp = openport(VLTMOUSE)
  9.  
  10. do forever
  11.    if quitflag = 1 then leave
  12.    t = waitpkt(VLTMOUSE)
  13.    do forever
  14.       p = getpkt(VLTMOUSE)
  15.       if c2d(p) = 0 then leave
  16.  
  17.       string = getarg(p)
  18.       t = reply(p, 0)
  19.       
  20.       parse var string y x yold xold ytot xtot
  21.  
  22.       'rev "D"'                /* Deselect all              */
  23.       'rev "K '||y - 1 - ytot||'"'    /* Jump from Top to line y      */
  24.       'rev "S S"'            /* Select this line               */
  25.       'rev "X revtemp"'            /* Save in env variable           */
  26.       str = getenv(revtemp)
  27.       str = request(50, 50, "Change this command?", str, , "Cancel", VLT)
  28.       if str ~= "" then "send ''"||str
  29.    end
  30. end
  31.  
  32. /* This example doesn't really ever: */
  33. exit
  34.  
  35.  
  36.