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

Unified Diff: content/browser/renderer_host/render_process_host_impl.cc

Issue 289863005: [Mac] Maximise timer slack for background tabs (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Really rebase Created 6 years, 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « base/message_loop/timer_slack.h ('k') | content/child/child_thread.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/renderer_host/render_process_host_impl.cc
diff --git a/content/browser/renderer_host/render_process_host_impl.cc b/content/browser/renderer_host/render_process_host_impl.cc
index a9e8ab5577b3a83185d721a0eb6f64822dd87b9d..6c23369f246b82d3d4a036a5faf19e147783adfd 100644
--- a/content/browser/renderer_host/render_process_host_impl.cc
+++ b/content/browser/renderer_host/render_process_host_impl.cc
@@ -2013,16 +2013,19 @@ void RenderProcessHostImpl::SetBackgrounded(bool backgrounded) {
// is to not invoke the SetPriorityClass API if the dll is loaded.
if (GetModuleHandle(L"cbstext.dll"))
return;
+#endif // OS_WIN
- // Windows Vista+ has a fancy process backgrounding mode that can only be set
- // from within the process. So notify the child process of background state.
+ // Notify the child process of background state.
Send(new ChildProcessMsg_SetProcessBackgrounded(backgrounded));
-#else
+#if !defined(OS_WIN)
// Backgrounding may require elevated privileges not available to renderer
// processes, so control backgrounding from the process host.
+
+ // Windows Vista+ has a fancy process backgrounding mode that can only be set
+ // from within the process.
child_process_launcher_->SetProcessBackgrounded(backgrounded);
-#endif // OS_WIN
+#endif // !OS_WIN
}
void RenderProcessHostImpl::OnProcessLaunched() {
« no previous file with comments | « base/message_loop/timer_slack.h ('k') | content/child/child_thread.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698