home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 18 REXX / 18-REXX.zip / setmouse.zip / DEFMOUSE.CMD next >
OS/2 REXX Batch file  |  1993-08-28  |  1KB  |  36 lines

  1. /* rexx */
  2. /* Short procedure to reset mouse pointer to default                       */
  3. /* This file is in the public domain, but I'd appreciate it greatly if you */
  4. /* would leave this notice in...     Author:  Dann Lunsford                */
  5. /*                                            Vortex BBS (1:203/726)       */
  6. /*                                            21-Aug-1993                  */
  7.  
  8. arg key
  9.  
  10. if key == '' then
  11.   key = '1'
  12.  
  13. call rxfuncadd 'SysIni','REXXUTIL','SysIni'
  14. res = SysIni('USER','PM_SysPointer','ALL:','mouse')
  15. if res \= '' then
  16.    do
  17.       say "Error retrieving PM_SysPointer: Not set?"
  18.       exit
  19.    end
  20. do i=1 to mouse.0
  21.    if mouse.i \= key then iterate
  22.    say "Clearing mouse pointer " key
  23.    res = SysIni('USER','PM_SysPointer',key,'DELETE:')
  24.    if res \= '' then
  25.       do
  26.          say "Error restoring default mouse pointer for key" key
  27.          exit
  28.       end
  29.    else
  30.       do
  31.          say "Deleted mouse pointer for key " key
  32.          say "Reboot system for old pointer to take effect"
  33.          exit
  34.       end
  35. end
  36.