OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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 #include "content/browser/browser_main_loop.h" | 5 #include "content/browser/browser_main_loop.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 | 8 |
9 #include <string> | 9 #include <string> |
10 #include <utility> | 10 #include <utility> |
(...skipping 1268 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1279 factory = BrowserGpuChannelHostFactory::instance(); | 1279 factory = BrowserGpuChannelHostFactory::instance(); |
1280 } | 1280 } |
1281 DCHECK(factory); | 1281 DCHECK(factory); |
1282 ImageTransportFactory::Initialize(); | 1282 ImageTransportFactory::Initialize(); |
1283 ImageTransportFactory::GetInstance()->SetGpuChannelEstablishFactory(factory); | 1283 ImageTransportFactory::GetInstance()->SetGpuChannelEstablishFactory(factory); |
1284 #if defined(USE_AURA) | 1284 #if defined(USE_AURA) |
1285 bool use_mus_in_renderer = base::CommandLine::ForCurrentProcess()->HasSwitch( | 1285 bool use_mus_in_renderer = base::CommandLine::ForCurrentProcess()->HasSwitch( |
1286 switches::kUseMusInRenderer); | 1286 switches::kUseMusInRenderer); |
1287 if (aura::Env::GetInstance() && !use_mus_in_renderer) { | 1287 if (aura::Env::GetInstance() && !use_mus_in_renderer) { |
1288 aura::Env::GetInstance()->set_context_factory(GetContextFactory()); | 1288 aura::Env::GetInstance()->set_context_factory(GetContextFactory()); |
| 1289 aura::Env::GetInstance()->set_context_factory_private( |
| 1290 GetContextFactoryPrivate()); |
1289 } | 1291 } |
1290 #endif // defined(USE_AURA) | 1292 #endif // defined(USE_AURA) |
1291 #endif // defined(OS_ANDROID) | 1293 #endif // defined(OS_ANDROID) |
1292 | 1294 |
1293 // Enable the GpuMemoryBuffer dump provider with IO thread affinity. Note that | 1295 // Enable the GpuMemoryBuffer dump provider with IO thread affinity. Note that |
1294 // unregistration happens on the IO thread (See | 1296 // unregistration happens on the IO thread (See |
1295 // BrowserProcessSubThread::IOThreadPreCleanUp). | 1297 // BrowserProcessSubThread::IOThreadPreCleanUp). |
1296 base::trace_event::MemoryDumpManager::GetInstance()->RegisterDumpProvider( | 1298 base::trace_event::MemoryDumpManager::GetInstance()->RegisterDumpProvider( |
1297 BrowserGpuMemoryBufferManager::current(), "BrowserGpuMemoryBufferManager", | 1299 BrowserGpuMemoryBufferManager::current(), "BrowserGpuMemoryBufferManager", |
1298 io_thread_->task_runner()); | 1300 io_thread_->task_runner()); |
(...skipping 310 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1609 if (!audio_manager_) { | 1611 if (!audio_manager_) { |
1610 audio_thread_ = base::MakeUnique<AudioDeviceThread>(); | 1612 audio_thread_ = base::MakeUnique<AudioDeviceThread>(); |
1611 audio_manager_ = media::AudioManager::Create( | 1613 audio_manager_ = media::AudioManager::Create( |
1612 audio_thread_->GetTaskRunner(), audio_thread_->worker_task_runner(), | 1614 audio_thread_->GetTaskRunner(), audio_thread_->worker_task_runner(), |
1613 MediaInternals::GetInstance()); | 1615 MediaInternals::GetInstance()); |
1614 } | 1616 } |
1615 CHECK(audio_manager_); | 1617 CHECK(audio_manager_); |
1616 } | 1618 } |
1617 | 1619 |
1618 } // namespace content | 1620 } // namespace content |
OLD | NEW |