From 15f0ca6a2237e3bb4c1e071b22d9aae4db5a02e5 Mon Sep 17 00:00:00 2001 From: gbeauche <> Date: Tue, 22 Jun 2004 20:01:18 +0000 Subject: [PATCH] Force use of MacX mappings on MacOS X with Apple's X server. --- SheepShaver/src/Unix/video_x.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/SheepShaver/src/Unix/video_x.cpp b/SheepShaver/src/Unix/video_x.cpp index 81051f72..aa96318d 100644 --- a/SheepShaver/src/Unix/video_x.cpp +++ b/SheepShaver/src/Unix/video_x.cpp @@ -884,6 +884,12 @@ static void keycode_init(void) // Search for server vendor string, then read keycodes const char *vendor = ServerVendor(x_display); +#if (defined(__APPLE__) && defined(__MACH__)) + // Force use of MacX mappings on MacOS X with Apple's X server + int dummy; + if (XQueryExtension(x_display, "Apple-DRI", &dummy, &dummy, &dummy)) + vendor = "MacX"; +#endif bool vendor_found = false; char line[256]; while (fgets(line, 255, f)) {