Chromium Code Reviews| Index: content/browser/child_process_launcher.cc |
| diff --git a/content/browser/child_process_launcher.cc b/content/browser/child_process_launcher.cc |
| index 92a3b0e78fe265556e83dffefe4b08d7d26d56ae..76c31cba3a3777e7f3a01d025b15220c04b46b5a 100644 |
| --- a/content/browser/child_process_launcher.cc |
| +++ b/content/browser/child_process_launcher.cc |
| @@ -38,8 +38,10 @@ |
| #include "content/public/common/sandbox_init.h" |
| #include "sandbox/win/src/sandbox_types.h" |
| #elif defined(OS_MACOSX) |
| +#include "base/feature_list.h" |
| #include "content/browser/bootstrap_sandbox_manager_mac.h" |
| #include "content/browser/mach_broker_mac.h" |
| +#include "content/public/common/content_features.h" |
| #include "sandbox/mac/bootstrap_sandbox.h" |
| #include "sandbox/mac/pre_exec_delegate.h" |
| #elif defined(OS_ANDROID) |
| @@ -385,7 +387,12 @@ void SetProcessBackgroundedOnLauncherThread(base::Process process, |
| bool background) { |
| DCHECK_CURRENTLY_ON(BrowserThread::PROCESS_LAUNCHER); |
| if (process.CanBackgroundProcesses()) { |
| +#if defined(OS_MACOSX) |
| + if (base::FeatureList::IsEnabled(features::kMacBackgroundInactiveTabs)) |
|
shrike
2016/10/31 17:26:05
Is this the only place you need to check for the e
lgrey
2016/10/31 19:22:02
Moved to CanBackgroundProcesses and moved the feat
|
| + process.SetProcessBackgrounded(MachBroker::GetInstance(), background); |
| +#else |
| process.SetProcessBackgrounded(background); |
| +#endif // defined(OS_MACOSX) |
| } |
| #if defined(OS_ANDROID) |
| SetChildProcessInForeground(process.Handle(), !background); |