diff options
| author | Matthias Melcher <fltk@matthiasm.com> | 2010-03-14 21:29:12 +0000 |
|---|---|---|
| committer | Matthias Melcher <fltk@matthiasm.com> | 2010-03-14 21:29:12 +0000 |
| commit | be17e1ccb642891b0b00a6e26d9c79272aed1d9e (patch) | |
| tree | bc2c191e05ae0b81ff0f0282d762b3bef4ab0d46 /src/Fl_Gl_Choice.cxx | |
| parent | 75b8da38135c8387e6c2eccd9db6e0202789d876 (diff) | |
Updated Fl_Device and Fl_Printer for Xcode
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@7267 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'src/Fl_Gl_Choice.cxx')
| -rw-r--r-- | src/Fl_Gl_Choice.cxx | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/src/Fl_Gl_Choice.cxx b/src/Fl_Gl_Choice.cxx index 75fc9dea8..479146ed7 100644 --- a/src/Fl_Gl_Choice.cxx +++ b/src/Fl_Gl_Choice.cxx @@ -38,6 +38,7 @@ # ifdef __APPLE__ # include <FL/Fl_Window.H> +# include <Carbon/Carbon.h> # endif # ifdef WIN32 @@ -317,12 +318,20 @@ GLContext fl_create_gl_context(Fl_Window* window, const Fl_Gl_Choice* g, int lay #if defined(__APPLE_COCOA__) #if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_5 - if (aglSetWindowRef != NULL) { +#if __LP64__ + // 64 bit version + aglSetWindowRef(context, MACwindowRef(window) ); +#else + // 32 bit version >= 10.5 + if (aglSetWindowRef != NULL) aglSetWindowRef(context, MACwindowRef(window) ); - } else + aglSetDrawable( context, GetWindowPort( MACwindowRef(window) ) ); #endif +#else + // 32 bit version < 10.5 aglSetDrawable( context, GetWindowPort( MACwindowRef(window) ) ); +#endif #else aglSetDrawable( context, GetWindowPort( fl_xid(window) ) ); |
