summaryrefslogtreecommitdiff
path: root/src/screen_xywh.cxx
diff options
context:
space:
mode:
authorMatthias Melcher <fltk@matthiasm.com>2009-12-06 22:21:55 +0000
committerMatthias Melcher <fltk@matthiasm.com>2009-12-06 22:21:55 +0000
commitb2cffc688ea7abbddabc9ed23deea1921f59ac9d (patch)
tree74a50bdb133fd6b5af7c785541bcc46e2e8e9c15 /src/screen_xywh.cxx
parent1ea4b4573538f2d53960dd8a4ef4f35480d2f5f7 (diff)
Moved OS X code base to the more moder Cocoa toolkit thanks to the awesome work of Manolo Gouy (STR #2221). This is a big one! I tested all test applications under 32-bit autoconf and Xcode, and a few apps under 64bit intel. No PPC testing was done. Please verify this patch if you have the machine!
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@6951 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'src/screen_xywh.cxx')
-rw-r--r--src/screen_xywh.cxx5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/screen_xywh.cxx b/src/screen_xywh.cxx
index 66f05778d..3ef2aa970 100644
--- a/src/screen_xywh.cxx
+++ b/src/screen_xywh.cxx
@@ -107,7 +107,11 @@ static void screen_init() {
#elif defined(__APPLE__)
XRectangle screens[16];
+extern int MACscreen_init(XRectangle screens[]);
static void screen_init() {
+#ifdef __APPLE_COCOA__
+ num_screens = MACscreen_init(screens);
+#else
GDHandle gd;
for (gd = GetDeviceList(), num_screens = 0; gd; gd = GetNextDevice(gd)) {
@@ -120,6 +124,7 @@ static void screen_init() {
num_screens ++;
if (num_screens >= 16) break;
}
+#endif
}
#elif HAVE_XINERAMA
# include <X11/extensions/Xinerama.h>