diff options
Diffstat (limited to 'src/kernel/qeventloop_x11_glib.cpp')
-rw-r--r-- | src/kernel/qeventloop_x11_glib.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/kernel/qeventloop_x11_glib.cpp b/src/kernel/qeventloop_x11_glib.cpp index f19f02f1e..df607ce78 100644 --- a/src/kernel/qeventloop_x11_glib.cpp +++ b/src/kernel/qeventloop_x11_glib.cpp @@ -629,6 +629,10 @@ bool TQEventLoop::gsourceDispatch(GSource *gs) { bool TQEventLoop::hasPendingEvents() const { +#ifdef QT_THREAD_SUPPORT + TQMutexLocker locker( TQApplication::tqt_mutex ); +#endif // QT_THREAD_SUPPORT + extern uint qGlobalPostedEventsCount(); // from qapplication.cpp return ( qGlobalPostedEventsCount() || ( (tqt_is_gui_used && TQApplication::isGuiThread()) ? XPending( TQPaintDevice::x11AppDisplay() ) : 0)); } |