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

Unified Diff: chrome/browser/ui/webui/options/chromeos/internet_options_handler.cc

Issue 1043343002: Use networkingPrivate.startConnect (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@issue_430115_internet_options_cellular
Patch Set: Created 5 years, 9 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: chrome/browser/ui/webui/options/chromeos/internet_options_handler.cc
diff --git a/chrome/browser/ui/webui/options/chromeos/internet_options_handler.cc b/chrome/browser/ui/webui/options/chromeos/internet_options_handler.cc
index 84bbb1e3fc54dd0ebeb53200fda11d1f80f4003d..ef7a13bc5a1d61c74c2a9cce953c6c1b0c2ff003 100644
--- a/chrome/browser/ui/webui/options/chromeos/internet_options_handler.cc
+++ b/chrome/browser/ui/webui/options/chromeos/internet_options_handler.cc
@@ -91,10 +91,6 @@ const char kUpdateConnectionDataFunction[] =
const char kShowMorePlanInfoMessage[] = "showMorePlanInfo";
const char kSimOperationMessage[] = "simOperation";
-// TODO(stevenjb): Replace these with the matching networkingPrivate methods.
-// crbug.com/279351.
-const char kStartConnectMessage[] = "startConnect";
-
// TODO(stevenjb): Deprecate this once we handle events in the JS.
const char kSetNetworkGuidMessage[] = "setNetworkGuid";
@@ -266,11 +262,6 @@ void InternetOptionsHandler::RegisterMessages() {
web_ui()->RegisterMessageCallback(kSetNetworkGuidMessage,
base::Bind(&InternetOptionsHandler::SetNetworkGuidCallback,
base::Unretained(this)));
-
- // networkingPrivate methods
- web_ui()->RegisterMessageCallback(kStartConnectMessage,
- base::Bind(&InternetOptionsHandler::StartConnectCallback,
- base::Unretained(this)));
}
void InternetOptionsHandler::OnExtensionLoaded(
@@ -352,23 +343,6 @@ void InternetOptionsHandler::SetNetworkGuidCallback(
details_guid_ = guid;
}
-
-////////////////////////////////////////////////////////////////////////////////
-// networkingPrivate implementation methods. TODO(stevenjb): Use the
-// networkingPrivate API directly in the settings JS and deprecate these
-// methods. crbug.com/279351.
-
-void InternetOptionsHandler::StartConnectCallback(const base::ListValue* args) {
- std::string guid;
- if (!args->GetString(0, &guid)) {
- NOTREACHED();
- return;
- }
- std::string service_path = ServicePathFromGuid(guid);
- if (!service_path.empty())
- ui::NetworkConnect::Get()->ConnectToNetwork(service_path);
-}
-
////////////////////////////////////////////////////////////////////////////////
void InternetOptionsHandler::UpdateVPNProviders() {

Powered by Google App Engine
This is Rietveld 408576698