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

Side by Side Diff: chrome/browser/ui/webui/chromeos/choose_mobile_network_ui.cc

Issue 1865213004: Convert //chrome/browser/ui from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 years, 8 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/ui/webui/chromeos/choose_mobile_network_ui.h" 5 #include "chrome/browser/ui/webui/chromeos/choose_mobile_network_ui.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <set> 9 #include <set>
10 #include <string> 10 #include <string>
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after
81 return chromeos::NetworkHandler::Get()->network_device_handler(); 81 return chromeos::NetworkHandler::Get()->network_device_handler();
82 } 82 }
83 83
84 chromeos::NetworkStateHandler* GetNetworkStateHandler() { 84 chromeos::NetworkStateHandler* GetNetworkStateHandler() {
85 return chromeos::NetworkHandler::Get()->network_state_handler(); 85 return chromeos::NetworkHandler::Get()->network_state_handler();
86 } 86 }
87 87
88 void NetworkOperationErrorCallback( 88 void NetworkOperationErrorCallback(
89 const std::string& operation_name, 89 const std::string& operation_name,
90 const std::string& error_name, 90 const std::string& error_name,
91 scoped_ptr<base::DictionaryValue> error_data) { 91 std::unique_ptr<base::DictionaryValue> error_data) {
92 NET_LOG_ERROR("Operation failed: " + error_name, operation_name); 92 NET_LOG_ERROR("Operation failed: " + error_name, operation_name);
93 } 93 }
94 94
95 class ChooseMobileNetworkHandler 95 class ChooseMobileNetworkHandler
96 : public WebUIMessageHandler, 96 : public WebUIMessageHandler,
97 public NetworkStateHandlerObserver { 97 public NetworkStateHandlerObserver {
98 public: 98 public:
99 ChooseMobileNetworkHandler(); 99 ChooseMobileNetworkHandler();
100 ~ChooseMobileNetworkHandler() override; 100 ~ChooseMobileNetworkHandler() override;
101 101
(...skipping 165 matching lines...) Expand 10 before | Expand all | Expand 10 after
267 : WebUIController(web_ui) { 267 : WebUIController(web_ui) {
268 ChooseMobileNetworkHandler* handler = new ChooseMobileNetworkHandler(); 268 ChooseMobileNetworkHandler* handler = new ChooseMobileNetworkHandler();
269 web_ui->AddMessageHandler(handler); 269 web_ui->AddMessageHandler(handler);
270 // Set up the "chrome://choose-mobile-network" source. 270 // Set up the "chrome://choose-mobile-network" source.
271 Profile* profile = Profile::FromWebUI(web_ui); 271 Profile* profile = Profile::FromWebUI(web_ui);
272 content::WebUIDataSource::Add( 272 content::WebUIDataSource::Add(
273 profile, CreateChooseMobileNetworkUIHTMLSource()); 273 profile, CreateChooseMobileNetworkUIHTMLSource());
274 } 274 }
275 275
276 } // namespace chromeos 276 } // namespace chromeos
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698