home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #31 / NN_1992_31.iso / spool / comp / sys / amiga / programm / 17899 < prev    next >
Encoding:
Internet Message Format  |  1992-12-29  |  1.1 KB

  1. Path: sparky!uunet!spool.mu.edu!olivea!apple!netcomsv!terapin!paulk
  2. From: paulk@terapin.com (Paul Kienitz)
  3. Newsgroups: comp.sys.amiga.programmer
  4. Subject: Re: LockIBase
  5. Message-ID: <paulk.2z9x@terapin.com>
  6. Date: 29 Dec 92 00:22:35 GMT
  7. References: <JTP.92Dec27193513@laphroaig.cs.hut.fi>
  8. Organization: BBS
  9. Lines: 15
  10.  
  11. > Well suppose one would want to write a commodity to activate the
  12. > window under the mouse pointer on keypress.
  13.  
  14. That is a tricky one.  What DMouse does is try WhichLayer() on each
  15. screen in turn until it finds the right screen.  Then there's further
  16. trouble because the coordinates in the input event do not match the
  17. X/Y coordinates of the screen itself, and translating them gets real
  18. obscure when you have e.g. PAL and NTSC mixed together.  I ended up
  19. working around this in my personal DMouse variant by grabbing the
  20. MouseX and MouseY fields of the screen itself, so it activates the
  21. window where the mouse was as of the PREVIOUS input event instead of
  22. the current one.
  23.  
  24. Does anyone know a way (preferably forward-compatible) to convert
  25. arbitrary input event coordinates to screen coordinates?
  26.