| 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/sync_internals/sync_internals_ui.h" | 5 #include "ios/chrome/browser/ui/webui/sync_internals/sync_internals_ui.h" | 
| 6 | 6 | 
|  | 7 #include "base/memory/ptr_util.h" | 
| 7 #include "components/grit/components_resources.h" | 8 #include "components/grit/components_resources.h" | 
| 8 #include "components/sync/driver/about_sync_util.h" | 9 #include "components/sync/driver/about_sync_util.h" | 
| 9 #include "ios/chrome/browser/browser_state/chrome_browser_state.h" | 10 #include "ios/chrome/browser/browser_state/chrome_browser_state.h" | 
| 10 #include "ios/chrome/browser/chrome_url_constants.h" | 11 #include "ios/chrome/browser/chrome_url_constants.h" | 
| 11 #include "ios/chrome/browser/ui/webui/sync_internals/sync_internals_message_hand
    ler.h" | 12 #include "ios/chrome/browser/ui/webui/sync_internals/sync_internals_message_hand
    ler.h" | 
| 12 #include "ios/web/public/web_ui_ios_data_source.h" | 13 #include "ios/web/public/web_ui_ios_data_source.h" | 
| 13 #include "ios/web/public/webui/web_ui_ios.h" | 14 #include "ios/web/public/webui/web_ui_ios.h" | 
| 14 | 15 | 
| 15 namespace { | 16 namespace { | 
| 16 | 17 | 
| (...skipping 25 matching lines...) Expand all  Loading... | 
| 42   source->SetDefaultResource(IDR_SYNC_DRIVER_SYNC_INTERNALS_INDEX_HTML); | 43   source->SetDefaultResource(IDR_SYNC_DRIVER_SYNC_INTERNALS_INDEX_HTML); | 
| 43   return source; | 44   return source; | 
| 44 } | 45 } | 
| 45 | 46 | 
| 46 }  // namespace | 47 }  // namespace | 
| 47 | 48 | 
| 48 SyncInternalsUI::SyncInternalsUI(web::WebUIIOS* web_ui) | 49 SyncInternalsUI::SyncInternalsUI(web::WebUIIOS* web_ui) | 
| 49     : web::WebUIIOSController(web_ui) { | 50     : web::WebUIIOSController(web_ui) { | 
| 50   web::WebUIIOSDataSource::Add(ios::ChromeBrowserState::FromWebUIIOS(web_ui), | 51   web::WebUIIOSDataSource::Add(ios::ChromeBrowserState::FromWebUIIOS(web_ui), | 
| 51                                CreateSyncInternalsHTMLSource()); | 52                                CreateSyncInternalsHTMLSource()); | 
| 52   web_ui->AddMessageHandler(new SyncInternalsMessageHandler); | 53   web_ui->AddMessageHandler(base::MakeUnique<SyncInternalsMessageHandler>()); | 
| 53 } | 54 } | 
| 54 | 55 | 
| 55 SyncInternalsUI::~SyncInternalsUI() {} | 56 SyncInternalsUI::~SyncInternalsUI() {} | 
| OLD | NEW | 
|---|