Johannes Schindelin, le Wed 27 Feb 2008 15:35:01 +0000, a écrit : > > Index: cocoa.m > > =================================================================== > > RCS file: /sources/qemu/qemu/cocoa.m,v > > retrieving revision 1.15 > > diff -u -p -r1.15 cocoa.m > > --- cocoa.m 22 Jan 2008 23:25:15 -0000 1.15 > > +++ cocoa.m 27 Feb 2008 14:42:02 -0000 > > @@ -40,7 +40,7 @@ > > #define cgrect(nsrect) (*(CGRect *)&(nsrect)) > > #define COCOA_MOUSE_EVENT \ > > if (isTabletEnabled) { \ > > - kbd_mouse_event((int)(p.x * 0x7FFF / screen.width), > > (int)((screen.height - p.y) * 0x7FFF / screen.height), 0, buttons); \ > > + kbd_mouse_event((int)(p.x * 0x7FFF / (screen.width - 1)), > > (int)((screen.height - p.y) * 0x7FFF / (screen.height - 1)), 0, buttons); \ > > Would it not be better to multiply with 0x8000 / screen.width? This > seems "more correct" to me.
No, because then you would not reach 0x7FFF: (1023 * 0x8000) / 1024 -> 0x7fe0 And then the guest does not reach 1023 (tested on windows). Samuel