| OLD | NEW |
| 1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 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 // Represents the browser side of the browser <--> renderer communication | 5 // Represents the browser side of the browser <--> renderer communication |
| 6 // channel. There will be one RenderProcessHost per renderer process. | 6 // channel. There will be one RenderProcessHost per renderer process. |
| 7 | 7 |
| 8 #include "content/browser/renderer_host/render_process_host_impl.h" | 8 #include "content/browser/renderer_host/render_process_host_impl.h" |
| 9 | 9 |
| 10 #include <algorithm> | 10 #include <algorithm> |
| (...skipping 2595 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2606 } | 2606 } |
| 2607 | 2607 |
| 2608 #if defined(ENABLE_WEBRTC) | 2608 #if defined(ENABLE_WEBRTC) |
| 2609 if (WebRTCInternals::GetInstance()->IsAudioDebugRecordingsEnabled()) { | 2609 if (WebRTCInternals::GetInstance()->IsAudioDebugRecordingsEnabled()) { |
| 2610 EnableAudioDebugRecordings( | 2610 EnableAudioDebugRecordings( |
| 2611 WebRTCInternals::GetInstance()->GetAudioDebugRecordingsFilePath()); | 2611 WebRTCInternals::GetInstance()->GetAudioDebugRecordingsFilePath()); |
| 2612 } | 2612 } |
| 2613 #endif | 2613 #endif |
| 2614 } | 2614 } |
| 2615 | 2615 |
| 2616 void RenderProcessHostImpl::OnProcessLaunchFailed() { | 2616 void RenderProcessHostImpl::OnProcessLaunchFailed(int error_code) { |
| 2617 // If this object will be destructed soon, then observers have already been | 2617 // If this object will be destructed soon, then observers have already been |
| 2618 // sent a RenderProcessHostDestroyed notification, and we must observe our | 2618 // sent a RenderProcessHostDestroyed notification, and we must observe our |
| 2619 // contract that says that will be the last call. | 2619 // contract that says that will be the last call. |
| 2620 if (deleting_soon_) | 2620 if (deleting_soon_) |
| 2621 return; | 2621 return; |
| 2622 | 2622 |
| 2623 // TODO(wfh): Fill in the real error code here see crbug.com/526198. | 2623 RendererClosedDetails details{base::TERMINATION_STATUS_LAUNCH_FAILED, |
| 2624 RendererClosedDetails details{base::TERMINATION_STATUS_LAUNCH_FAILED, -1}; | 2624 error_code}; |
| 2625 ProcessDied(true, &details); | 2625 ProcessDied(true, &details); |
| 2626 } | 2626 } |
| 2627 | 2627 |
| 2628 scoped_refptr<AudioRendererHost> RenderProcessHostImpl::audio_renderer_host() | 2628 scoped_refptr<AudioRendererHost> RenderProcessHostImpl::audio_renderer_host() |
| 2629 const { | 2629 const { |
| 2630 return audio_renderer_host_; | 2630 return audio_renderer_host_; |
| 2631 } | 2631 } |
| 2632 | 2632 |
| 2633 void RenderProcessHostImpl::OnUserMetricsRecordAction( | 2633 void RenderProcessHostImpl::OnUserMetricsRecordAction( |
| 2634 const std::string& action) { | 2634 const std::string& action) { |
| (...skipping 162 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2797 | 2797 |
| 2798 // Skip widgets in other processes. | 2798 // Skip widgets in other processes. |
| 2799 if (rvh->GetProcess()->GetID() != GetID()) | 2799 if (rvh->GetProcess()->GetID() != GetID()) |
| 2800 continue; | 2800 continue; |
| 2801 | 2801 |
| 2802 rvh->OnWebkitPreferencesChanged(); | 2802 rvh->OnWebkitPreferencesChanged(); |
| 2803 } | 2803 } |
| 2804 } | 2804 } |
| 2805 | 2805 |
| 2806 } // namespace content | 2806 } // namespace content |
| OLD | NEW |