diff options
| author | Carl Hetherington <cth@carlh.net> | 2014-09-03 00:28:35 +0100 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2014-09-03 00:28:35 +0100 |
| commit | 6788ff5967508056d1321c16143bf72fa7cd4516 (patch) | |
| tree | 8fe76f1a8038e6bc0cb3ef07633568e5da43887f /src/lib | |
| parent | 0390c42a7fc648a116ac3fd0417eac92dfe79f6d (diff) | |
Speculative fix for Doremi certificate download on OS X.
The while (wxTheApp->Pending ()) wxTheApp->Dispatch() appears to
hang on OS X.
Diffstat (limited to 'src/lib')
| -rw-r--r-- | src/lib/ui_signaller.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/lib/ui_signaller.h b/src/lib/ui_signaller.h index 1d62547f6..ee4d230d4 100644 --- a/src/lib/ui_signaller.h +++ b/src/lib/ui_signaller.h @@ -54,8 +54,15 @@ public: } } + /* Do something next time the UI is idle */ + template <typename T> + void when_idle (T f) { + _service.post (f); + } + /** Call this in the UI when it is idle */ size_t ui_idle () { + /* This executes any functors that have been post()ed to _service */ return _service.poll (); } |
