aboutsummaryrefslogtreecommitdiffstats
path: root/pugl/detail/mac.m
diff options
context:
space:
mode:
Diffstat (limited to 'pugl/detail/mac.m')
-rw-r--r--pugl/detail/mac.m20
1 files changed, 13 insertions, 7 deletions
diff --git a/pugl/detail/mac.m b/pugl/detail/mac.m
index 74b207a..3fa700e 100644
--- a/pugl/detail/mac.m
+++ b/pugl/detail/mac.m
@@ -842,20 +842,26 @@ puglWaitForEvent(PuglView* view)
return puglPollEvents(view->world, -1.0);
}
-PuglStatus
-puglProcessEvents(PuglView* view)
+PUGL_API PuglStatus
+puglDispatchEvents(PuglWorld* world)
{
for (NSEvent* ev = NULL;
- (ev = [view->impl->window nextEventMatchingMask:NSAnyEventMask
- untilDate:nil
- inMode:NSDefaultRunLoopMode
- dequeue:YES]);) {
- [view->world->impl->app sendEvent: ev];
+ (ev = [world->impl->app nextEventMatchingMask:NSAnyEventMask
+ untilDate:nil
+ inMode:NSDefaultRunLoopMode
+ dequeue:YES]);) {
+ [world->impl->app sendEvent: ev];
}
return PUGL_SUCCESS;
}
+PuglStatus
+puglProcessEvents(PuglView* view)
+{
+ return puglDispatchEvents(view->world);
+}
+
PuglGlFunc
puglGetProcAddress(const char *name)
{