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

Side by Side Diff: ios/chrome/browser/ui/webui/physical_web_ui.cc

Issue 2617243002: Remove ScopedVector from ios/. (Closed)
Patch Set: rebase Created 3 years, 11 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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 "ios/chrome/browser/ui/webui/physical_web_ui.h" 5 #include "ios/chrome/browser/ui/webui/physical_web_ui.h"
6 6
7 #include "base/macros.h" 7 #include "base/macros.h"
8 #include "base/memory/ptr_util.h"
8 #include "base/metrics/user_metrics.h" 9 #include "base/metrics/user_metrics.h"
9 #include "components/grit/components_resources.h" 10 #include "components/grit/components_resources.h"
10 #include "components/physical_web/data_source/physical_web_data_source.h" 11 #include "components/physical_web/data_source/physical_web_data_source.h"
11 #include "components/physical_web/webui/physical_web_base_message_handler.h" 12 #include "components/physical_web/webui/physical_web_base_message_handler.h"
12 #include "components/physical_web/webui/physical_web_ui_constants.h" 13 #include "components/physical_web/webui/physical_web_ui_constants.h"
13 #include "components/strings/grit/components_strings.h" 14 #include "components/strings/grit/components_strings.h"
14 #include "ios/chrome/browser/application_context.h" 15 #include "ios/chrome/browser/application_context.h"
15 #include "ios/chrome/browser/browser_state/chrome_browser_state.h" 16 #include "ios/chrome/browser/browser_state/chrome_browser_state.h"
16 #include "ios/chrome/browser/chrome_url_constants.h" 17 #include "ios/chrome/browser/chrome_url_constants.h"
17 #include "ios/web/public/web_ui_ios_data_source.h" 18 #include "ios/web/public/web_ui_ios_data_source.h"
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after
89 } // namespace 90 } // namespace
90 91
91 //////////////////////////////////////////////////////////////////////////////// 92 ////////////////////////////////////////////////////////////////////////////////
92 // 93 //
93 // PhysicalWebUI 94 // PhysicalWebUI
94 // 95 //
95 //////////////////////////////////////////////////////////////////////////////// 96 ////////////////////////////////////////////////////////////////////////////////
96 97
97 PhysicalWebUI::PhysicalWebUI(web::WebUIIOS* web_ui) 98 PhysicalWebUI::PhysicalWebUI(web::WebUIIOS* web_ui)
98 : web::WebUIIOSController(web_ui) { 99 : web::WebUIIOSController(web_ui) {
99 PhysicalWebDOMHandler* handler = new PhysicalWebDOMHandler(); 100 web_ui->AddMessageHandler(base::MakeUnique<PhysicalWebDOMHandler>());
100 web_ui->AddMessageHandler(handler);
101 101
102 web::WebUIIOSDataSource::Add(ios::ChromeBrowserState::FromWebUIIOS(web_ui), 102 web::WebUIIOSDataSource::Add(ios::ChromeBrowserState::FromWebUIIOS(web_ui),
103 CreatePhysicalWebUIDataSource()); 103 CreatePhysicalWebUIDataSource());
104 104
105 base::RecordAction(base::UserMetricsAction("PhysicalWeb.WebUI.Open")); 105 base::RecordAction(base::UserMetricsAction("PhysicalWeb.WebUI.Open"));
106 } 106 }
107 107
108 PhysicalWebUI::~PhysicalWebUI() {} 108 PhysicalWebUI::~PhysicalWebUI() {}
OLDNEW
« no previous file with comments | « ios/chrome/browser/ui/webui/omaha_ui.cc ('k') | ios/chrome/browser/ui/webui/popular_sites_internals_ui.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698