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

Side by Side Diff: chrome/browser/ui/webui/local_discovery/local_discovery_ui.cc

Issue 599653003: Remove old template html boilerplate (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@bydefault
Patch Set: fix android Created 6 years, 2 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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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/local_discovery/local_discovery_ui.h" 5 #include "chrome/browser/ui/webui/local_discovery/local_discovery_ui.h"
6 6
7 #include "chrome/browser/profiles/profile.h" 7 #include "chrome/browser/profiles/profile.h"
8 #include "chrome/browser/ui/browser.h" 8 #include "chrome/browser/ui/browser.h"
9 #include "chrome/browser/ui/browser_finder.h" 9 #include "chrome/browser/ui/browser_finder.h"
10 #include "chrome/browser/ui/webui/local_discovery/local_discovery_ui_handler.h" 10 #include "chrome/browser/ui/webui/local_discovery/local_discovery_ui_handler.h"
(...skipping 11 matching lines...) Expand all
22 content::WebUIDataSource* CreateLocalDiscoveryHTMLSource() { 22 content::WebUIDataSource* CreateLocalDiscoveryHTMLSource() {
23 content::WebUIDataSource* source = 23 content::WebUIDataSource* source =
24 content::WebUIDataSource::Create(chrome::kChromeUIDevicesHost); 24 content::WebUIDataSource::Create(chrome::kChromeUIDevicesHost);
25 25
26 source->SetDefaultResource(IDR_LOCAL_DISCOVERY_HTML); 26 source->SetDefaultResource(IDR_LOCAL_DISCOVERY_HTML);
27 source->AddResourcePath("local_discovery.css", IDR_LOCAL_DISCOVERY_CSS); 27 source->AddResourcePath("local_discovery.css", IDR_LOCAL_DISCOVERY_CSS);
28 source->AddResourcePath("local_discovery.js", IDR_LOCAL_DISCOVERY_JS); 28 source->AddResourcePath("local_discovery.js", IDR_LOCAL_DISCOVERY_JS);
29 source->AddResourcePath("device.png", IDR_LOCAL_DISCOVERY_DEVICE_PNG); 29 source->AddResourcePath("device.png", IDR_LOCAL_DISCOVERY_DEVICE_PNG);
30 source->AddResourcePath("printer.png", IDR_LOCAL_DISCOVERY_PRINTER_PNG); 30 source->AddResourcePath("printer.png", IDR_LOCAL_DISCOVERY_PRINTER_PNG);
31 31
32 source->SetUseJsonJSFormatV2();
33 source->AddLocalizedString("serviceRegister", 32 source->AddLocalizedString("serviceRegister",
34 IDS_LOCAL_DISCOVERY_SERVICE_REGISTER); 33 IDS_LOCAL_DISCOVERY_SERVICE_REGISTER);
35 source->AddLocalizedString("manageDevice", IDS_LOCAL_DISCOVERY_MANAGE_DEVICE); 34 source->AddLocalizedString("manageDevice", IDS_LOCAL_DISCOVERY_MANAGE_DEVICE);
36 35
37 source->AddLocalizedString("registerPrinterConfirmMessage", 36 source->AddLocalizedString("registerPrinterConfirmMessage",
38 IDS_LOCAL_DISCOVERY_REGISTER_PRINTER_CONFIRMATION); 37 IDS_LOCAL_DISCOVERY_REGISTER_PRINTER_CONFIRMATION);
39 source->AddLocalizedString("registerDeviceConfirmMessage", 38 source->AddLocalizedString("registerDeviceConfirmMessage",
40 IDS_LOCAL_DISCOVERY_REGISTER_DEVICE_CONFIRMATION); 39 IDS_LOCAL_DISCOVERY_REGISTER_DEVICE_CONFIRMATION);
41 source->AddLocalizedString("registerUser", 40 source->AddLocalizedString("registerUser",
42 IDS_LOCAL_DISCOVERY_REGISTER_USER); 41 IDS_LOCAL_DISCOVERY_REGISTER_USER);
(...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after
141 user_prefs::PrefRegistrySyncable* registry) { 140 user_prefs::PrefRegistrySyncable* registry) {
142 registry->RegisterBooleanPref( 141 registry->RegisterBooleanPref(
143 prefs::kLocalDiscoveryNotificationsEnabled, 142 prefs::kLocalDiscoveryNotificationsEnabled,
144 #if defined(OS_WIN) 143 #if defined(OS_WIN)
145 false, 144 false,
146 #else 145 #else
147 true, 146 true,
148 #endif 147 #endif
149 user_prefs::PrefRegistrySyncable::SYNCABLE_PREF); 148 user_prefs::PrefRegistrySyncable::SYNCABLE_PREF);
150 } 149 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/webui/identity_internals_ui.cc ('k') | chrome/browser/ui/webui/media/webrtc_logs_ui.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698