aboutsummaryrefslogtreecommitdiffstats
path: root/pugl/detail
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2020-03-15 14:33:10 +0100
committerDavid Robillard <d@drobilla.net>2020-03-15 14:33:10 +0100
commit6cca4669d8afc3c92b1f1ecd5d40614f4c568ade (patch)
treeee619157ead0e2bc7bfdf4d7de05dd07a1f6e596 /pugl/detail
parentfb3baa801e449baa3dcee879557d94304dcd0509 (diff)
downloadpugl-6cca4669d8afc3c92b1f1ecd5d40614f4c568ade.tar.gz
pugl-6cca4669d8afc3c92b1f1ecd5d40614f4c568ade.tar.bz2
pugl-6cca4669d8afc3c92b1f1ecd5d40614f4c568ade.zip
X11: Only enter drawing context if an expose is pending
Diffstat (limited to 'pugl/detail')
-rw-r--r--pugl/detail/x11.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/pugl/detail/x11.c b/pugl/detail/x11.c
index 486e83b..7b83b38 100644
--- a/pugl/detail/x11.c
+++ b/pugl/detail/x11.c
@@ -814,10 +814,10 @@ puglDispatchEvents(PuglWorld* world)
PuglEvent* const expose = &view->impl->pendingExpose;
if (configure->type || expose->type) {
- view->backend->enter(view, &expose->expose);
+ view->backend->enter(view, expose->type ? &expose->expose : NULL);
view->eventFunc(view, configure);
view->eventFunc(view, expose);
- view->backend->leave(view, &expose->expose);
+ view->backend->leave(view, expose->type ? &expose->expose : NULL);
configure->type = 0;
expose->type = 0;