OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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/gcm/gcm_internals_ui.h" | 5 #include "ios/chrome/browser/ui/webui/gcm/gcm_internals_ui.h" |
6 | 6 |
7 #include <vector> | 7 #include <vector> |
8 | 8 |
9 #include "base/bind.h" | 9 #include "base/bind.h" |
10 #include "base/bind_helpers.h" | 10 #include "base/bind_helpers.h" |
11 #include "base/macros.h" | 11 #include "base/macros.h" |
12 #include "base/memory/weak_ptr.h" | 12 #include "base/memory/weak_ptr.h" |
13 #include "base/values.h" | 13 #include "base/values.h" |
14 #include "components/gcm_driver/gcm_client.h" | 14 #include "components/gcm_driver/gcm_client.h" |
15 #include "components/gcm_driver/gcm_driver.h" | 15 #include "components/gcm_driver/gcm_driver.h" |
16 #include "components/gcm_driver/gcm_internals_constants.h" | 16 #include "components/gcm_driver/gcm_internals_constants.h" |
17 #include "components/gcm_driver/gcm_internals_helper.h" | 17 #include "components/gcm_driver/gcm_internals_helper.h" |
18 #include "components/gcm_driver/gcm_profile_service.h" | 18 #include "components/gcm_driver/gcm_profile_service.h" |
19 #include "grit/components_resources.h" | 19 #include "components/grit/components_resources.h" |
20 #include "ios/chrome/browser/browser_state/chrome_browser_state.h" | 20 #include "ios/chrome/browser/browser_state/chrome_browser_state.h" |
21 #include "ios/chrome/browser/chrome_url_constants.h" | 21 #include "ios/chrome/browser/chrome_url_constants.h" |
22 #include "ios/chrome/browser/services/gcm/ios_chrome_gcm_profile_service_factory
.h" | 22 #include "ios/chrome/browser/services/gcm/ios_chrome_gcm_profile_service_factory
.h" |
23 #include "ios/public/provider/web/web_ui_ios.h" | 23 #include "ios/public/provider/web/web_ui_ios.h" |
24 #include "ios/public/provider/web/web_ui_ios_message_handler.h" | 24 #include "ios/public/provider/web/web_ui_ios_message_handler.h" |
25 #include "ios/web/public/web_ui_ios_data_source.h" | 25 #include "ios/web/public/web_ui_ios_data_source.h" |
26 | 26 |
27 namespace { | 27 namespace { |
28 | 28 |
29 // Class acting as a controller of the chrome://gcm-internals WebUI. | 29 // Class acting as a controller of the chrome://gcm-internals WebUI. |
(...skipping 138 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
168 IDR_GCM_DRIVER_GCM_INTERNALS_JS); | 168 IDR_GCM_DRIVER_GCM_INTERNALS_JS); |
169 html_source->SetDefaultResource(IDR_GCM_DRIVER_GCM_INTERNALS_HTML); | 169 html_source->SetDefaultResource(IDR_GCM_DRIVER_GCM_INTERNALS_HTML); |
170 | 170 |
171 web::WebUIIOSDataSource::Add(ios::ChromeBrowserState::FromWebUIIOS(web_ui), | 171 web::WebUIIOSDataSource::Add(ios::ChromeBrowserState::FromWebUIIOS(web_ui), |
172 html_source); | 172 html_source); |
173 | 173 |
174 web_ui->AddMessageHandler(new GcmInternalsUIMessageHandler()); | 174 web_ui->AddMessageHandler(new GcmInternalsUIMessageHandler()); |
175 } | 175 } |
176 | 176 |
177 GCMInternalsUI::~GCMInternalsUI() {} | 177 GCMInternalsUI::~GCMInternalsUI() {} |
OLD | NEW |