Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(757)

Unified Diff: net/base/network_change_notifier_linux.cc

Issue 1306653003: Add connection type to NCN::MaxBandwidthChanged (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixes Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: net/base/network_change_notifier_linux.cc
diff --git a/net/base/network_change_notifier_linux.cc b/net/base/network_change_notifier_linux.cc
index 7e471726d9aaaa58b0ab9fc0582e320487f783a5..6588adc37f97bccc3d8217535f09c4c63d66832c 100644
--- a/net/base/network_change_notifier_linux.cc
+++ b/net/base/network_change_notifier_linux.cc
@@ -82,6 +82,14 @@ void NetworkChangeNotifierLinux::Thread::OnLinkChanged() {
if (last_type_ != GetCurrentConnectionType()) {
NetworkChangeNotifier::NotifyObserversOfConnectionTypeChange();
last_type_ = GetCurrentConnectionType();
+ double max_bandwidth =
+ last_type_ == CONNECTION_NONE
+ ? NetworkChangeNotifier::GetMaxBandwidthForConnectionSubtype(
+ SUBTYPE_NONE)
+ : NetworkChangeNotifier::GetMaxBandwidthForConnectionSubtype(
+ SUBTYPE_UNKNOWN);
pauljensen 2015/09/15 18:17:40 how about ReallyLongFunctionName(conditon ? SUBTYP
jkarlin 2015/09/16 12:12:22 Good idea. Done.
+ NetworkChangeNotifier::NotifyObserversOfMaxBandwidthChange(last_type_,
+ max_bandwidth);
}
}

Powered by Google App Engine
This is Rietveld 408576698