Chromium Code Reviews| OLD | NEW |
|---|---|
| 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_content_renderer_client.h" | 5 #include "chrome/renderer/chrome_content_renderer_client.h" |
| 6 | 6 |
| 7 #include <memory> | 7 #include <memory> |
| 8 #include <utility> | 8 #include <utility> |
| 9 | 9 |
| 10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
| (...skipping 423 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 434 WebSecurityPolicy::addOriginTrustworthyWhiteList( | 434 WebSecurityPolicy::addOriginTrustworthyWhiteList( |
| 435 WebSecurityOrigin::create(origin)); | 435 WebSecurityOrigin::create(origin)); |
| 436 } | 436 } |
| 437 | 437 |
| 438 std::set<std::string> schemes; | 438 std::set<std::string> schemes; |
| 439 GetSchemesBypassingSecureContextCheckWhitelist(&schemes); | 439 GetSchemesBypassingSecureContextCheckWhitelist(&schemes); |
| 440 for (const std::string& scheme : schemes) { | 440 for (const std::string& scheme : schemes) { |
| 441 WebSecurityPolicy::addSchemeToBypassSecureContextWhitelist( | 441 WebSecurityPolicy::addSchemeToBypassSecureContextWhitelist( |
| 442 WebString::fromUTF8(scheme)); | 442 WebString::fromUTF8(scheme)); |
| 443 } | 443 } |
| 444 | |
| 445 #if defined(OS_CHROMEOS) | |
| 446 leak_detector_remote_client_.reset(new LeakDetectorRemoteClient()); | |
| 447 thread->AddObserver(leak_detector_remote_client_.get()); | |
|
sadrul
2016/08/08 20:20:06
I was going to comment that there isn't a correspo
| |
| 448 #endif | |
| 444 } | 449 } |
| 445 | 450 |
| 446 void ChromeContentRendererClient::RenderFrameCreated( | 451 void ChromeContentRendererClient::RenderFrameCreated( |
| 447 content::RenderFrame* render_frame) { | 452 content::RenderFrame* render_frame) { |
| 448 new ChromeRenderFrameObserver(render_frame); | 453 new ChromeRenderFrameObserver(render_frame); |
| 449 | 454 |
| 450 bool should_whitelist_for_content_settings = | 455 bool should_whitelist_for_content_settings = |
| 451 base::CommandLine::ForCurrentProcess()->HasSwitch( | 456 base::CommandLine::ForCurrentProcess()->HasSwitch( |
| 452 switches::kInstantProcess); | 457 switches::kInstantProcess); |
| 453 extensions::Dispatcher* ext_dispatcher = NULL; | 458 extensions::Dispatcher* ext_dispatcher = NULL; |
| (...skipping 920 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1374 // chrome.system.network.getNetworkInterfaces provides the same | 1379 // chrome.system.network.getNetworkInterfaces provides the same |
| 1375 // information. Also, the enforcement of sending and binding UDP is already done | 1380 // information. Also, the enforcement of sending and binding UDP is already done |
| 1376 // by chrome extension permission model. | 1381 // by chrome extension permission model. |
| 1377 bool ChromeContentRendererClient::ShouldEnforceWebRTCRoutingPreferences() { | 1382 bool ChromeContentRendererClient::ShouldEnforceWebRTCRoutingPreferences() { |
| 1378 #if defined(ENABLE_EXTENSIONS) | 1383 #if defined(ENABLE_EXTENSIONS) |
| 1379 return !IsStandaloneExtensionProcess(); | 1384 return !IsStandaloneExtensionProcess(); |
| 1380 #else | 1385 #else |
| 1381 return true; | 1386 return true; |
| 1382 #endif | 1387 #endif |
| 1383 } | 1388 } |
| OLD | NEW |