Chromium Code Reviews| 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 f59222e82cc563a1671f46ebe64c28d6e0aa6cb4..504c19e5a3044a637b188d2dc6a1853f1b82c7d1 100644 |
| --- a/content/browser/renderer_host/render_process_host_impl.cc |
| +++ b/content/browser/renderer_host/render_process_host_impl.cc |
| @@ -1,4 +1,4 @@ |
| -// Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| +// Copyright 2012 The Chromium Authors. All rights reserved. |
| // Use of this source code is governed by a BSD-style license that can be |
| // found in the LICENSE file. |
| @@ -2221,14 +2221,15 @@ void RenderProcessHostImpl::SetBackgrounded(bool backgrounded) { |
| return; |
| #endif // OS_WIN |
| -#if defined(OS_WIN) |
| - // Same as below, but bound to an experiment (http://crbug.com/458594) |
| - // initially on Windows. Enabled by default in the asbence of field trials to |
| - // get coverage on the perf waterfall. |
| +#if defined(OS_WIN) || defined(OS_MACOSX) |
| + // Same as below, but bound to an experiment (http://crbug.com/458594 on |
| + // Windows, http://crbug.com/398103 on the Mac). Enabled by default in the |
| + // absence of field trials to get coverage on the perf waterfall. |
| base::FieldTrial* trial = |
| base::FieldTrialList::Find("BackgroundRendererProcesses"); |
| - if (!trial || trial->group_name() != "Disallow") |
| + if (!trial || !StartsWithASCII(trial->group_name(), "Disallow", false)) { |
|
gab
2015/05/11 17:20:12
Use case-sensitive? i.e. s/false/true?
Case-sensi
shrike
2015/05/12 23:44:19
Fixed. I wasn't actually sure what the right answe
|
| child_process_launcher_->SetProcessBackgrounded(backgrounded); |
| + } |
|
gab
2015/05/11 17:20:12
Why add the {}? It's still a single line condition
shrike
2015/05/12 23:44:19
Yes, that is true (the style guide says either is
|
| #else |
| // Control the background state from the browser process, otherwise the task |
| // telling the renderer to "unbackground" itself may be preempted by other |