Update to Chromium revision 140240.

git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@701 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
This commit is contained in:
Marshall Greenblatt
2012-06-21 20:35:13 +00:00
parent 93e1f9722b
commit c56def5569
15 changed files with 82 additions and 75 deletions

View File

@ -167,8 +167,8 @@ void CefProcessUIThread::Init() {
// Create a network change notifier before starting the IO & File threads.
network_change_notifier_.reset(net::NetworkChangeNotifier::Create());
// Add a listener for OnOnlineStateChanged to notify WebKit of changes.
net::NetworkChangeNotifier::AddOnlineStateObserver(this);
// Add a listener for OnConnectionTypeChanged to notify WebKit of changes.
net::NetworkChangeNotifier::AddConnectionTypeObserver(this);
// Initialize WebKit with the current state.
WebKit::WebNetworkStateNotifier::setOnLine(
@ -191,7 +191,7 @@ void CefProcessUIThread::CleanUp() {
webkit_init_ = NULL;
// Release the network change notifier after all other threads end.
net::NetworkChangeNotifier::RemoveOnlineStateObserver(this);
net::NetworkChangeNotifier::RemoveConnectionTypeObserver(this);
network_change_notifier_.reset();
PlatformCleanUp();
@ -199,8 +199,10 @@ void CefProcessUIThread::CleanUp() {
_Context->CleanupResourceBundle();
}
void CefProcessUIThread::OnOnlineStateChanged(bool online) {
void CefProcessUIThread::OnConnectionTypeChanged(
net::NetworkChangeNotifier::ConnectionType type) {
DCHECK(CefThread::CurrentlyOn(CefThread::UI));
WebKit::WebNetworkStateNotifier::setOnLine(online);
WebKit::WebNetworkStateNotifier::setOnLine(
type != net::NetworkChangeNotifier::CONNECTION_NONE);
}