summaryrefslogtreecommitdiff
path: root/src/periodic.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/periodic.c')
-rw-r--r--src/periodic.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/periodic.c b/src/periodic.c
index ab3b66e6..eb4fb98d 100644
--- a/src/periodic.c
+++ b/src/periodic.c
@@ -65,7 +65,6 @@ iBool dispatchCommands_Periodic(iPeriodic *d) {
65 d->lastPostTime = now; 65 d->lastPostTime = now;
66 iBool wasPosted = iFalse; 66 iBool wasPosted = iFalse;
67 lock_Mutex(d->mutex); 67 lock_Mutex(d->mutex);
68 setCurrent_Root(&get_Window()->root);
69 iConstForEach(Array, i, &d->commands.values) { 68 iConstForEach(Array, i, &d->commands.values) {
70 const iPeriodicCommand *pc = i.value; 69 const iPeriodicCommand *pc = i.value;
71 const SDL_UserEvent ev = { 70 const SDL_UserEvent ev = {
@@ -74,6 +73,7 @@ iBool dispatchCommands_Periodic(iPeriodic *d) {
74 .data1 = (void *) cstr_String(&pc->command) 73 .data1 = (void *) cstr_String(&pc->command)
75 }; 74 };
76 iAssert(isInstance_Object(pc->context, &Class_Widget)); 75 iAssert(isInstance_Object(pc->context, &Class_Widget));
76 setCurrent_Root(findRoot_Window(get_Window(), pc->context));
77 dispatchEvent_Widget(pc->context, (const SDL_Event *) &ev); 77 dispatchEvent_Widget(pc->context, (const SDL_Event *) &ev);
78 wasPosted = iTrue; 78 wasPosted = iTrue;
79 } 79 }