aboutsummaryrefslogtreecommitdiffstats
path: root/pugl
diff options
context:
space:
mode:
Diffstat (limited to 'pugl')
-rw-r--r--pugl/pugl_internal.h18
-rw-r--r--pugl/pugl_osx.m18
-rw-r--r--pugl/pugl_win.c18
-rw-r--r--pugl/pugl_x11.c18
4 files changed, 18 insertions, 54 deletions
diff --git a/pugl/pugl_internal.h b/pugl/pugl_internal.h
index ac31b65..312329d 100644
--- a/pugl/pugl_internal.h
+++ b/pugl/pugl_internal.h
@@ -197,6 +197,24 @@ puglGetSize(PuglView* view, int* width, int* height)
*height = view->height;
}
+void*
+puglGetContext(PuglView* view)
+{
+ return view->backend->getContext(view);
+}
+
+void
+puglEnterContext(PuglView* view, bool drawing)
+{
+ view->backend->enter(view, drawing);
+}
+
+void
+puglLeaveContext(PuglView* view, bool drawing)
+{
+ view->backend->leave(view, drawing);
+}
+
void
puglIgnoreKeyRepeat(PuglView* view, bool ignore)
{
diff --git a/pugl/pugl_osx.m b/pugl/pugl_osx.m
index 9db9d87..30eb84d 100644
--- a/pugl/pugl_osx.m
+++ b/pugl/pugl_osx.m
@@ -724,18 +724,6 @@ puglInitInternals(void)
return (PuglInternals*)calloc(1, sizeof(PuglInternals));
}
-void
-puglEnterContext(PuglView* view, bool drawing)
-{
- view->backend->enter(view, drawing);
-}
-
-void
-puglLeaveContext(PuglView* view, bool drawing)
-{
- view->backend->leave(view, drawing);
-}
-
static NSLayoutConstraint*
puglConstraint(id item, NSLayoutAttribute attribute, float constant)
{
@@ -951,12 +939,6 @@ puglGetNativeWindow(PuglView* view)
return (PuglNativeWindow)view->impl->glview;
}
-void*
-puglGetContext(PuglView* view)
-{
- return view->backend->getContext(view);
-}
-
// Backend
static int
diff --git a/pugl/pugl_win.c b/pugl/pugl_win.c
index d3bea51..799850e 100644
--- a/pugl/pugl_win.c
+++ b/pugl/pugl_win.c
@@ -82,18 +82,6 @@ puglInitInternals(void)
return impl;
}
-void
-puglEnterContext(PuglView* view, bool drawing)
-{
- view->backend->enter(view, drawing);
-}
-
-void
-puglLeaveContext(PuglView* view, bool drawing)
-{
- view->backend->leave(view, drawing);
-}
-
int
puglCreateWindow(PuglView* view, const char* title)
{
@@ -705,9 +693,3 @@ puglGetNativeWindow(PuglView* view)
{
return (PuglNativeWindow)view->impl->hwnd;
}
-
-void*
-puglGetContext(PuglView* view)
-{
- return view->backend->getContext(view);
-}
diff --git a/pugl/pugl_x11.c b/pugl/pugl_x11.c
index e249ea6..d9620e1 100644
--- a/pugl/pugl_x11.c
+++ b/pugl/pugl_x11.c
@@ -67,18 +67,6 @@ puglInitInternals(void)
return (PuglInternals*)calloc(1, sizeof(PuglInternals));
}
-void
-puglEnterContext(PuglView* view, bool drawing)
-{
- view->backend->enter(view, drawing);
-}
-
-void
-puglLeaveContext(PuglView* view, bool drawing)
-{
- view->backend->leave(view, drawing);
-}
-
int
puglCreateWindow(PuglView* view, const char* title)
{
@@ -605,9 +593,3 @@ puglGetNativeWindow(PuglView* view)
{
return (PuglNativeWindow)view->impl->win;
}
-
-void*
-puglGetContext(PuglView* view)
-{
- return view->backend->getContext(view);
-}