summaryrefslogtreecommitdiffstats
path: root/x11vnc/macosxCG.c
diff options
context:
space:
mode:
Diffstat (limited to 'x11vnc/macosxCG.c')
-rw-r--r--x11vnc/macosxCG.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/x11vnc/macosxCG.c b/x11vnc/macosxCG.c
index 4f1fd0a..a465493 100644
--- a/x11vnc/macosxCG.c
+++ b/x11vnc/macosxCG.c
@@ -87,7 +87,9 @@ int dragum(void) {
CGPoint loc;
CGDirectDisplayID displayID2 = kCGDirectMainDisplay;
+#ifdef X11VNC_MACOSX_USE_GETMAINDEVICE
(void) GetMainDevice();
+#endif
for (i=0; i< 50; i++) {
usleep(1000*100);
@@ -140,7 +142,9 @@ void macosxCG_init(void) {
#endif
displayID = kCGDirectMainDisplay;
+#ifdef X11VNC_MACOSX_USE_GETMAINDEVICE
(void) GetMainDevice();
+#endif
CGSetLocalEventsSuppressionInterval(0.0);
CGSetLocalEventsFilterDuringSupressionState(