summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoraurel32 <aurel32@c046a42c-6fe2-441c-8c8c-71466251a162>2008-03-10 19:34:27 +0000
committeraurel32 <aurel32@c046a42c-6fe2-441c-8c8c-71466251a162>2008-03-10 19:34:27 +0000
commitb94ed5772eb31e8fad4b823351e8152839bf722a (patch)
treeb6e766ae37a53576dda2c285a16b831d36e54af3 /cocoa.m
parentGT64XXX: fix endianness issues: (diff)
downloadqemu-kvm-b94ed5772eb31e8fad4b823351e8152839bf722a.tar.gz
qemu-kvm-b94ed5772eb31e8fad4b823351e8152839bf722a.tar.bz2
qemu-kvm-b94ed5772eb31e8fad4b823351e8152839bf722a.zip
Let the USB tablet reach the far bottom and right pixels
(Samuel Thibault) git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4036 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'cocoa.m')
-rw-r--r--cocoa.m2
1 files changed, 1 insertions, 1 deletions
diff --git a/cocoa.m b/cocoa.m
index 8d3633616..fe139526a 100644
--- a/cocoa.m
+++ b/cocoa.m
@@ -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); \
} else if (isMouseGrabed) { \
kbd_mouse_event((int)[event deltaX], (int)[event deltaY], 0, buttons); \
} else { \