summaryrefslogtreecommitdiffstats
path: root/generic/tkStubInit.c
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2020-09-06 17:08:12 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2020-09-06 17:08:12 (GMT)
commit9d1abea3325f5bcc2d822d4b23d742e517855593 (patch)
treeeb720826deb9111b171c987882e563abd250eec9 /generic/tkStubInit.c
parente04db4716d431f93bff03c37a5e5b21d264dc846 (diff)
parent57cb5d1b7215c1c676e7213748bcd65096f52af3 (diff)
downloadtk-9d1abea3325f5bcc2d822d4b23d742e517855593.zip
tk-9d1abea3325f5bcc2d822d4b23d742e517855593.tar.gz
tk-9d1abea3325f5bcc2d822d4b23d742e517855593.tar.bz2
Tk_MacOSXGetCGContextForDrawable() doesn't replace TkMacOSXGetDrawablePort(), since TkMacOSXGetDrawablePort() is a useless function always returning NULL
No longer export Tk_MacOSXGetCGContextForDrawable as public symbol (wait doing that until 8.7)
Diffstat (limited to 'generic/tkStubInit.c')
-rw-r--r--generic/tkStubInit.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/generic/tkStubInit.c b/generic/tkStubInit.c
index 59c7d0e..a82903f 100644
--- a/generic/tkStubInit.c
+++ b/generic/tkStubInit.c
@@ -24,6 +24,7 @@
#if defined(MAC_OSX_TK)
/* we could have used _TKMACINT */
#include "tkMacOSXInt.h"
+#include "tkMacOSXPrivate.h"
#endif
/* TODO: These ought to come in some other way */
@@ -57,7 +58,14 @@ MODULE_SCOPE const TkStubs tkStubs;
#define TkpTestsendCmd_ TkpTestsendCmd
#define TkGenWMConfigureEvent_ TkGenWMConfigureEvent
#define TkGenerateActivateEvents_ TkGenerateActivateEvents
-#define Tk_MacOSXGetNSWindowForDrawable TkMacOSXDrawable
+
+#if defined(MAC_OSX_TK)
+# define Tk_MacOSXGetNSWindowForDrawable TkMacOSXDrawable
+# define Tk_MacOSXGetCGContextForDrawable GetCGContextForDrawable
+static void *GetCGContextForDrawable(Drawable d) {
+ return TkMacOSXGetCGContextForDrawable(d);
+}
+#endif
#ifdef _WIN32