summaryrefslogtreecommitdiff
path: root/hw/darwin/darwinEvents.c
diff options
context:
space:
mode:
authorKaleb Keithley <kaleb@freedesktop.org>2003-11-26 22:49:07 +0000
committerKaleb Keithley <kaleb@freedesktop.org>2003-11-26 22:49:07 +0000
commit0097b6fe2d1739e46e4e7726aaa481b6dc84870c (patch)
tree5e279fda13b69a02c684338ee803defbda33ab08 /hw/darwin/darwinEvents.c
parentc57959ad6a4c0f5329762f401fd7871ffb2ee90c (diff)
merge latest (4.3.99.16) from XFree86 (vendor) branch
Diffstat (limited to 'hw/darwin/darwinEvents.c')
-rw-r--r--hw/darwin/darwinEvents.c15
1 files changed, 8 insertions, 7 deletions
diff --git a/hw/darwin/darwinEvents.c b/hw/darwin/darwinEvents.c
index 72d7eff05..ba1ec8fc2 100644
--- a/hw/darwin/darwinEvents.c
+++ b/hw/darwin/darwinEvents.c
@@ -28,6 +28,7 @@ Except as contained in this notice, the name of The Open Group shall not be
used in advertising or otherwise to promote the sale, use or other dealings
in this Software without prior written authorization from The Open Group.
*/
+/* $XFree86: xc/programs/Xserver/hw/darwin/darwinEvents.c,v 1.5 2003/11/03 05:36:30 tsi Exp $ */
#define NEED_EVENTS
#include "X.h"
@@ -42,7 +43,6 @@ in this Software without prior written authorization from The Open Group.
#include "mipointer.h"
#include "darwin.h"
-#include "quartz/quartz.h"
#include <sys/types.h>
#include <sys/uio.h>
@@ -181,6 +181,7 @@ DarwinEQEnqueue(
const xEvent *e)
{
HWEventQueueType oldtail, newtail;
+ char byte = 0;
oldtail = darwinEventQueue.tail;
@@ -209,6 +210,9 @@ DarwinEQEnqueue(
// Update the tail after the event is prepared
darwinEventQueue.tail = newtail;
+
+ // Signal there is an event ready to handle
+ write(darwinEventWriteFD, &byte, 1);
}
@@ -253,7 +257,7 @@ void ProcessInputEvents(void)
// Empty the signaling pipe
x = sizeof(xe);
while (x == sizeof(xe)) {
- x = read(darwinEventFD, &xe, sizeof(xe));
+ x = read(darwinEventReadFD, &xe, sizeof(xe));
}
while (darwinEventQueue.head != darwinEventQueue.tail)
@@ -425,11 +429,8 @@ void ProcessInputEvents(void)
}
default:
- if (quartz) {
- QuartzProcessEvent(&xe);
- } else {
- ErrorF("Unknown X event caught: %d\n", xe.u.u.type);
- }
+ // Check for mode specific event
+ DarwinModeProcessEvent(&xe);
}
}
}