aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--pugl/detail/mac.m4
-rw-r--r--pugl/detail/win.c4
-rw-r--r--pugl/detail/x11.c4
-rw-r--r--wscript4
4 files changed, 14 insertions, 2 deletions
diff --git a/pugl/detail/mac.m b/pugl/detail/mac.m
index a9f527f..e98f3e3 100644
--- a/pugl/detail/mac.m
+++ b/pugl/detail/mac.m
@@ -912,11 +912,13 @@ puglPollEvents(PuglWorld* world, const double timeout)
return PUGL_SUCCESS;
}
+#ifndef PUGL_DISABLE_DEPRECATED
PuglStatus
puglWaitForEvent(PuglView* view)
{
return puglPollEvents(view->world, -1.0);
}
+#endif
PUGL_API PuglStatus
puglDispatchEvents(PuglWorld* world)
@@ -932,11 +934,13 @@ puglDispatchEvents(PuglWorld* world)
return PUGL_SUCCESS;
}
+#ifndef PUGL_DISABLE_DEPRECATED
PuglStatus
puglProcessEvents(PuglView* view)
{
return puglDispatchEvents(view->world);
}
+#endif
double
puglGetTime(const PuglWorld* world)
diff --git a/pugl/detail/win.c b/pugl/detail/win.c
index 5a3dc43..36f76eb 100644
--- a/pugl/detail/win.c
+++ b/pugl/detail/win.c
@@ -726,12 +726,14 @@ puglRequestAttention(PuglView* view)
return PUGL_SUCCESS;
}
+#ifndef PUGL_DISABLE_DEPRECATED
PuglStatus
puglWaitForEvent(PuglView* PUGL_UNUSED(view))
{
WaitMessage();
return PUGL_SUCCESS;
}
+#endif
PUGL_API PuglStatus
puglDispatchEvents(PuglWorld* PUGL_UNUSED(world))
@@ -761,11 +763,13 @@ puglDispatchEvents(PuglWorld* PUGL_UNUSED(world))
return PUGL_SUCCESS;
}
+#ifndef PUGL_DISABLE_DEPRECATED
PuglStatus
puglProcessEvents(PuglView* view)
{
return puglDispatchEvents(view->world);
}
+#endif
LRESULT CALLBACK
wndProc(HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam)
diff --git a/pugl/detail/x11.c b/pugl/detail/x11.c
index 3531b12..729c8a1 100644
--- a/pugl/detail/x11.c
+++ b/pugl/detail/x11.c
@@ -586,6 +586,7 @@ puglRequestAttention(PuglView* view)
return PUGL_SUCCESS;
}
+#ifndef PUGL_DISABLE_DEPRECATED
PuglStatus
puglWaitForEvent(PuglView* view)
{
@@ -593,6 +594,7 @@ puglWaitForEvent(PuglView* view)
XPeekEvent(view->impl->display, &xevent);
return PUGL_SUCCESS;
}
+#endif
static void
mergeExposeEvents(PuglEvent* dst, const PuglEvent* src)
@@ -760,11 +762,13 @@ puglDispatchEvents(PuglWorld* world)
return PUGL_SUCCESS;
}
+#ifndef PUGL_DISABLE_DEPRECATED
PuglStatus
puglProcessEvents(PuglView* view)
{
return puglDispatchEvents(view->world);
}
+#endif
double
puglGetTime(const PuglWorld* world)
diff --git a/wscript b/wscript
index 9a3d5ea..0167d1f 100644
--- a/wscript
+++ b/wscript
@@ -180,14 +180,14 @@ def build(bld):
bld(features = 'c cshlib',
name = name,
target = 'pugl_' + name,
- cflags = ['-DPUGL_INTERNAL', '-DPUGL_SHARED'],
+ defines = ['PUGL_INTERNAL', 'PUGL_SHARED'],
**args)
if bld.env.BUILD_STATIC:
bld(features = 'c cstlib',
name = 'pugl_%s_static' % name,
target = 'pugl_' + name,
- cflags = ['-DPUGL_INTERNAL'],
+ defines = ['PUGL_INTERNAL', 'PUGL_DISABLE_DEPRECATED'],
**args)
def build_platform(platform, **kwargs):