Chromium Code Reviews| 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 2594 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 2605 // sure |is_process_backgrounded_| reflects this platform's initial process | 2605 // sure |is_process_backgrounded_| reflects this platform's initial process |
| 2606 // state. | 2606 // state. |
| 2607 is_process_backgrounded_ = | 2607 is_process_backgrounded_ = |
| 2608 child_process_launcher_->GetProcess().IsProcessBackgrounded(); | 2608 child_process_launcher_->GetProcess().IsProcessBackgrounded(); |
| 2609 | 2609 |
| 2610 // Disable updating process priority on startup for now as it incorrectly | 2610 // Disable updating process priority on startup for now as it incorrectly |
| 2611 // results in backgrounding foreground navigations until their first commit | 2611 // results in backgrounding foreground navigations until their first commit |
| 2612 // is made. A better long term solution would be to be aware of the tab's | 2612 // is made. A better long term solution would be to be aware of the tab's |
| 2613 // visibility at this point. https://crbug.com/560446. | 2613 // visibility at this point. https://crbug.com/560446. |
| 2614 // Except on Android for now because of https://crbug.com/601184 :-(. | 2614 // Except on Android for now because of https://crbug.com/601184 :-(. |
| 2615 #if defined(OS_ANDROID) | 2615 // The exception also applies to Chrome OS: https://crbug.com/601023. |
| 2616 #if defined(OS_ANDROID) || defined(OS_CHROMEOS) | |
|
rjkroege
2016/04/18 17:06:07
I am not convinced that this is the right place fo
| |
| 2616 UpdateProcessPriority(); | 2617 UpdateProcessPriority(); |
| 2617 #endif | 2618 #endif |
| 2618 | 2619 |
| 2619 // Share histograms between the renderer and this process. | 2620 // Share histograms between the renderer and this process. |
| 2620 CreateSharedRendererHistogramAllocator(); | 2621 CreateSharedRendererHistogramAllocator(); |
| 2621 } | 2622 } |
| 2622 | 2623 |
| 2623 // NOTE: This needs to be before sending queued messages because | 2624 // NOTE: This needs to be before sending queued messages because |
| 2624 // ExtensionService uses this notification to initialize the renderer process | 2625 // ExtensionService uses this notification to initialize the renderer process |
| 2625 // with state that must be there before any JavaScript executes. | 2626 // with state that must be there before any JavaScript executes. |
| (...skipping 216 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 2842 | 2843 |
| 2843 // Skip widgets in other processes. | 2844 // Skip widgets in other processes. |
| 2844 if (rvh->GetProcess()->GetID() != GetID()) | 2845 if (rvh->GetProcess()->GetID() != GetID()) |
| 2845 continue; | 2846 continue; |
| 2846 | 2847 |
| 2847 rvh->OnWebkitPreferencesChanged(); | 2848 rvh->OnWebkitPreferencesChanged(); |
| 2848 } | 2849 } |
| 2849 } | 2850 } |
| 2850 | 2851 |
| 2851 } // namespace content | 2852 } // namespace content |
| OLD | NEW |