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

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

Issue 830743003: Directly inline shared WebUI CSS declarations into the security and supervised user interstitials. (Closed) Base URL: https://chromium.googlesource.com/chromium/src@master
Patch Set: review Created 5 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 (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/proxy_settings_ui.h" 5 #include "chrome/browser/ui/webui/chromeos/proxy_settings_ui.h"
6 6
7 #include "base/memory/ref_counted_memory.h" 7 #include "base/memory/ref_counted_memory.h"
8 #include "base/memory/scoped_ptr.h" 8 #include "base/memory/scoped_ptr.h"
9 #include "base/values.h" 9 #include "base/values.h"
10 #include "chrome/browser/chromeos/system/input_device_settings.h" 10 #include "chrome/browser/chromeos/system/input_device_settings.h"
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
60 60
61 std::string ProxySettingsHTMLSource::GetSource() const { 61 std::string ProxySettingsHTMLSource::GetSource() const {
62 return chrome::kChromeUIProxySettingsHost; 62 return chrome::kChromeUIProxySettingsHost;
63 } 63 }
64 64
65 void ProxySettingsHTMLSource::StartDataRequest( 65 void ProxySettingsHTMLSource::StartDataRequest(
66 const std::string& path, 66 const std::string& path,
67 int render_process_id, 67 int render_process_id,
68 int render_frame_id, 68 int render_frame_id,
69 const content::URLDataSource::GotDataCallback& callback) { 69 const content::URLDataSource::GotDataCallback& callback) {
70 webui::SetFontAndTextDirection(localized_strings_.get()); 70 webui::SetTextDirection(localized_strings_.get());
71 71
72 static const base::StringPiece html( 72 static const base::StringPiece html(
73 ResourceBundle::GetSharedInstance().GetRawDataResource( 73 ResourceBundle::GetSharedInstance().GetRawDataResource(
74 IDR_PROXY_SETTINGS_HTML)); 74 IDR_PROXY_SETTINGS_HTML));
75 std::string full_html = webui::GetI18nTemplateHtml( 75 std::string full_html = webui::GetI18nTemplateHtml(
76 html, localized_strings_.get()); 76 html, localized_strings_.get());
77 77
78 callback.Run(base::RefCountedString::TakeString(&full_html)); 78 callback.Run(base::RefCountedString::TakeString(&full_html));
79 } 79 }
80 80
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
122 if (!initialized_handlers_) { 122 if (!initialized_handlers_) {
123 core_handler_->InitializeHandler(); 123 core_handler_->InitializeHandler();
124 proxy_handler_->InitializeHandler(); 124 proxy_handler_->InitializeHandler();
125 initialized_handlers_ = true; 125 initialized_handlers_ = true;
126 } 126 }
127 core_handler_->InitializePage(); 127 core_handler_->InitializePage();
128 proxy_handler_->InitializePage(); 128 proxy_handler_->InitializePage();
129 } 129 }
130 130
131 } // namespace chromeos 131 } // namespace chromeos
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698