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

Side by Side Diff: chrome/renderer/chrome_render_thread_observer.cc

Issue 2651543007: Use explicit WebString conversions in remaining chrome/renderer files (Closed)
Patch Set: 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 (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/renderer/chrome_render_thread_observer.h" 5 #include "chrome/renderer/chrome_render_thread_observer.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <limits> 9 #include <limits>
10 #include <memory> 10 #include <memory>
(...skipping 245 matching lines...) Expand 10 before | Expand all | Expand 10 after
256 256
257 field_trial_syncer_.InitFieldTrialObserving(command_line, 257 field_trial_syncer_.InitFieldTrialObserving(command_line,
258 switches::kSingleProcess); 258 switches::kSingleProcess);
259 259
260 // chrome-native: is a scheme used for placeholder navigations that allow 260 // chrome-native: is a scheme used for placeholder navigations that allow
261 // UIs to be drawn with platform native widgets instead of HTML. These pages 261 // UIs to be drawn with platform native widgets instead of HTML. These pages
262 // should not be accessible, and should also be treated as empty documents 262 // should not be accessible, and should also be treated as empty documents
263 // that can commit synchronously. No code should be runnable in these pages, 263 // that can commit synchronously. No code should be runnable in these pages,
264 // so it should not need to access anything nor should it allow javascript 264 // so it should not need to access anything nor should it allow javascript
265 // URLs since it should never be visible to the user. 265 // URLs since it should never be visible to the user.
266 WebString native_scheme(base::ASCIIToUTF16(chrome::kChromeNativeScheme)); 266 WebString native_scheme(WebString::fromASCII(chrome::kChromeNativeScheme));
267 WebSecurityPolicy::registerURLSchemeAsDisplayIsolated(native_scheme); 267 WebSecurityPolicy::registerURLSchemeAsDisplayIsolated(native_scheme);
268 WebSecurityPolicy::registerURLSchemeAsEmptyDocument(native_scheme); 268 WebSecurityPolicy::registerURLSchemeAsEmptyDocument(native_scheme);
269 WebSecurityPolicy::registerURLSchemeAsNotAllowingJavascriptURLs( 269 WebSecurityPolicy::registerURLSchemeAsNotAllowingJavascriptURLs(
270 native_scheme); 270 native_scheme);
271 271
272 thread->GetInterfaceRegistry()->AddInterface( 272 thread->GetInterfaceRegistry()->AddInterface(
273 visited_link_slave_->GetBindCallback()); 273 visited_link_slave_->GetBindCallback());
274 } 274 }
275 275
276 ChromeRenderThreadObserver::~ChromeRenderThreadObserver() {} 276 ChromeRenderThreadObserver::~ChromeRenderThreadObserver() {}
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
332 void ChromeRenderThreadObserver::OnSetFieldTrialGroup( 332 void ChromeRenderThreadObserver::OnSetFieldTrialGroup(
333 const std::string& trial_name, 333 const std::string& trial_name,
334 const std::string& group_name) { 334 const std::string& group_name) {
335 field_trial_syncer_.OnSetFieldTrialGroup(trial_name, group_name); 335 field_trial_syncer_.OnSetFieldTrialGroup(trial_name, group_name);
336 } 336 }
337 337
338 const RendererContentSettingRules* 338 const RendererContentSettingRules*
339 ChromeRenderThreadObserver::content_setting_rules() const { 339 ChromeRenderThreadObserver::content_setting_rules() const {
340 return &content_setting_rules_; 340 return &content_setting_rules_;
341 } 341 }
OLDNEW
« no previous file with comments | « chrome/renderer/chrome_render_frame_observer.cc ('k') | chrome/renderer/content_settings_observer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698