| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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/extensions/chrome_content_browser_client_extensions_par
t.h" | 5 #include "chrome/browser/extensions/chrome_content_browser_client_extensions_par
t.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 | 8 |
| 9 #include <set> | 9 #include <set> |
| 10 | 10 |
| (...skipping 668 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 679 content::RenderProcessHost* process, | 679 content::RenderProcessHost* process, |
| 680 Profile* profile) { | 680 Profile* profile) { |
| 681 if (!process) | 681 if (!process) |
| 682 return; | 682 return; |
| 683 DCHECK(profile); | 683 DCHECK(profile); |
| 684 if (ProcessMap::Get(profile)->Contains(process->GetID())) { | 684 if (ProcessMap::Get(profile)->Contains(process->GetID())) { |
| 685 command_line->AppendSwitch(switches::kExtensionProcess); | 685 command_line->AppendSwitch(switches::kExtensionProcess); |
| 686 #if defined(ENABLE_WEBRTC) | 686 #if defined(ENABLE_WEBRTC) |
| 687 command_line->AppendSwitch(::switches::kEnableWebRtcHWH264Encoding); | 687 command_line->AppendSwitch(::switches::kEnableWebRtcHWH264Encoding); |
| 688 #endif | 688 #endif |
| 689 if (base::CommandLine::ForCurrentProcess()->HasSwitch( | |
| 690 switches::kEnableMojoSerialService)) { | |
| 691 command_line->AppendSwitch(switches::kEnableMojoSerialService); | |
| 692 } | |
| 693 } | 689 } |
| 694 } | 690 } |
| 695 | 691 |
| 696 void ChromeContentBrowserClientExtensionsPart::ResourceDispatcherHostCreated() { | 692 void ChromeContentBrowserClientExtensionsPart::ResourceDispatcherHostCreated() { |
| 697 content::ResourceDispatcherHost::Get()->RegisterInterceptor( | 693 content::ResourceDispatcherHost::Get()->RegisterInterceptor( |
| 698 "Origin", kExtensionScheme, base::Bind(&OnHttpHeaderReceived)); | 694 "Origin", kExtensionScheme, base::Bind(&OnHttpHeaderReceived)); |
| 699 } | 695 } |
| 700 | 696 |
| 701 } // namespace extensions | 697 } // namespace extensions |
| OLD | NEW |