summaryrefslogtreecommitdiffstats
path: root/src/network/bearer
diff options
context:
space:
mode:
authorQt Continuous Integration System <qt-info@nokia.com>2011-05-17 23:11:22 (GMT)
committerQt Continuous Integration System <qt-info@nokia.com>2011-05-17 23:11:22 (GMT)
commit2c07b5d2cba8d8e499bd0861eefef12d4e00d99a (patch)
tree3e6b31daecfe217b355fa973f2f122da8468c0ac /src/network/bearer
parentcb2980a09aefcc207eacb500d5a3c74f064859dd (diff)
parent3773fcb78db02a2577c89f755c07c2c7dbf0de74 (diff)
downloadQt-2c07b5d2cba8d8e499bd0861eefef12d4e00d99a.zip
Qt-2c07b5d2cba8d8e499bd0861eefef12d4e00d99a.tar.gz
Qt-2c07b5d2cba8d8e499bd0861eefef12d4e00d99a.tar.bz2
Merge branch 'qt-4.8-from-4.7' of scm.dev.nokia.troll.no:qt/qt-integration into master-integration
* 'qt-4.8-from-4.7' of scm.dev.nokia.troll.no:qt/qt-integration: (55 commits) Fix thread safety regression of QNetworkConfigurationManager Fix instability in QNetworkConfigurationManager autotest Support word selection list with predictive text from splitview Fix softkey icon positioning in S60 5.3 QDeclarativeMouseArea: block context menu events ListViews loses items if all visible items are removed. Make TextEdit word selection more natural. Clear confusion between QMainWindow and QMainWindowLayout. Fix for rounded corners bug in QMenu Compile QWidgetPrivate::setParent_sys might be using null pointer Ensure the TextEdit cursor delegate is repositioned on mouse events. Don't crash on an invalid replacementStart from an input method. Fix incorrect hardware address on systems without getifaddrs() Enable multisampling on Symbian if hw supports it Fix QtCoreu.def file error Introduce platform extension to QGraphicsSystem Fix Symbian/WinsCW build break Prevent crash in OpenGL engine when scaling images / pixmaps. emit QNetWorkAccessManager::finished on QNetworkReply::abort() ...
Diffstat (limited to 'src/network/bearer')
-rw-r--r--src/network/bearer/qnetworkconfigmanager_p.cpp17
-rw-r--r--src/network/bearer/qnetworkconfigmanager_p.h2
2 files changed, 14 insertions, 5 deletions
diff --git a/src/network/bearer/qnetworkconfigmanager_p.cpp b/src/network/bearer/qnetworkconfigmanager_p.cpp
index e9b6703..42fc49d 100644
--- a/src/network/bearer/qnetworkconfigmanager_p.cpp
+++ b/src/network/bearer/qnetworkconfigmanager_p.cpp
@@ -385,8 +385,6 @@ void QNetworkConfigurationManagerPrivate::updateConfigurations()
this, SLOT(configurationRemoved(QNetworkConfigurationPrivatePointer)));
connect(engine, SIGNAL(configurationChanged(QNetworkConfigurationPrivatePointer)),
this, SLOT(configurationChanged(QNetworkConfigurationPrivatePointer)));
-
- QMetaObject::invokeMethod(engine, "initialize");
}
}
@@ -410,8 +408,19 @@ void QNetworkConfigurationManagerPrivate::updateConfigurations()
startPolling();
}
- if (firstUpdate)
+ if (firstUpdate) {
firstUpdate = false;
+ QList<QBearerEngine*> enginesToInitialize = sessionEngines; //shallow copy the list in case it is modified when we unlock mutex
+ Qt::ConnectionType connectionType;
+ if (QCoreApplicationPrivate::mainThread() == QThread::currentThread())
+ connectionType = Qt::DirectConnection;
+ else
+ connectionType = Qt::BlockingQueuedConnection;
+ locker.unlock();
+ foreach (QBearerEngine* engine, enginesToInitialize) {
+ QMetaObject::invokeMethod(engine, "initialize", connectionType);
+ }
+ }
}
void QNetworkConfigurationManagerPrivate::performAsyncConfigurationUpdate()
@@ -479,7 +488,7 @@ void QNetworkConfigurationManagerPrivate::enablePolling()
++forcedPolling;
if (forcedPolling == 1)
- startPolling();
+ QMetaObject::invokeMethod(this, "startPolling");
}
void QNetworkConfigurationManagerPrivate::disablePolling()
diff --git a/src/network/bearer/qnetworkconfigmanager_p.h b/src/network/bearer/qnetworkconfigmanager_p.h
index abc4b9b..45d6a75 100644
--- a/src/network/bearer/qnetworkconfigmanager_p.h
+++ b/src/network/bearer/qnetworkconfigmanager_p.h
@@ -107,7 +107,7 @@ private Q_SLOTS:
void pollEngines();
private:
- void startPolling();
+ Q_INVOKABLE void startPolling();
QTimer *pollTimer;
private: