From 2405ae24c1c01934f077999e9b9a35a7e88b797f Mon Sep 17 00:00:00 2001 From: "Jay Freeman (saurik)" Date: Wed, 22 Aug 2012 08:32:01 +0000 Subject: [PATCH] Fix headset button check, as reported by mringwal. --- Tweak.mm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Tweak.mm b/Tweak.mm index a99c7e9..c276eb0 100644 --- a/Tweak.mm +++ b/Tweak.mm @@ -351,7 +351,7 @@ static void VNCPointer(int buttons, int x, int y, rfbClientPtr client) { memset(&record, 0, sizeof(record)); - record.type = (buttons & 0x4) != 0 ? + record.type = (buttons & 0x10) != 0 ? GSEventTypeHeadsetButtonDown : GSEventTypeHeadsetButtonUp; @@ -366,7 +366,7 @@ static void VNCPointer(int buttons, int x, int y, rfbClientPtr client) { memset(&record, 0, sizeof(record)); - record.type = (buttons & 0x4) != 0 ? + record.type = (buttons & 0x04) != 0 ? GSEventTypeMenuButtonDown : GSEventTypeMenuButtonUp; @@ -381,7 +381,7 @@ static void VNCPointer(int buttons, int x, int y, rfbClientPtr client) { memset(&record, 0, sizeof(record)); - record.type = (buttons & 0x2) != 0 ? + record.type = (buttons & 0x02) != 0 ? GSEventTypeLockButtonDown : GSEventTypeLockButtonUp; -- 2.50.0