diff options
author | Jan-Arve Sæther <jan-arve.saether@nokia.com> | 2010-11-19 10:21:30 (GMT) |
---|---|---|
committer | Jan-Arve Sæther <jan-arve.saether@nokia.com> | 2010-11-19 10:21:30 (GMT) |
commit | ab13e9c099a505a821caaccc6ae252388e676083 (patch) | |
tree | 503fe8c32d30c0e408defc0d7c54d47eeb2d6cc0 /src/corelib/kernel/qeventdispatcher_glib.cpp | |
parent | 4258dd04e25c8831be9e8a7dc45b52d34782cb35 (diff) | |
parent | 72378ce571bcb88d0519a1b02d0e543b5237d613 (diff) | |
download | Qt-ab13e9c099a505a821caaccc6ae252388e676083.zip Qt-ab13e9c099a505a821caaccc6ae252388e676083.tar.gz Qt-ab13e9c099a505a821caaccc6ae252388e676083.tar.bz2 |
Merge branch '4.7' of scm.dev.nokia.troll.no:qt/qt-water-team into 4.7
Diffstat (limited to 'src/corelib/kernel/qeventdispatcher_glib.cpp')
-rw-r--r-- | src/corelib/kernel/qeventdispatcher_glib.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/corelib/kernel/qeventdispatcher_glib.cpp b/src/corelib/kernel/qeventdispatcher_glib.cpp index 8390275..6fa2707 100644 --- a/src/corelib/kernel/qeventdispatcher_glib.cpp +++ b/src/corelib/kernel/qeventdispatcher_glib.cpp @@ -311,6 +311,10 @@ QEventDispatcherGlibPrivate::QEventDispatcherGlibPrivate(GMainContext *context) } } +#if GLIB_CHECK_VERSION (2, 22, 0) + g_main_context_push_thread_default (mainContext); +#endif + // setup post event source postEventSource = reinterpret_cast<GPostEventSource *>(g_source_new(&postEventSourceFuncs, sizeof(GPostEventSource))); @@ -389,6 +393,9 @@ QEventDispatcherGlib::~QEventDispatcherGlib() d->postEventSource = 0; Q_ASSERT(d->mainContext != 0); +#if GLIB_CHECK_VERSION (2, 22, 0) + g_main_context_pop_thread_default (d->mainContext); +#endif g_main_context_unref(d->mainContext); d->mainContext = 0; } |