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 1559 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1570 | 1570 |
1571 #if defined(USE_X11) | 1571 #if defined(USE_X11) |
1572 if (!gfx::GetXDisplay()) { | 1572 if (!gfx::GetXDisplay()) { |
1573 LOG(ERROR) << "Unable to open X display."; | 1573 LOG(ERROR) << "Unable to open X display."; |
1574 return false; | 1574 return false; |
1575 } | 1575 } |
1576 #endif | 1576 #endif |
1577 | 1577 |
1578 // Env creates the compositor. Aura widgets need the compositor to be created | 1578 // Env creates the compositor. Aura widgets need the compositor to be created |
1579 // before they can be initialized by the browser. | 1579 // before they can be initialized by the browser. |
1580 env_ = aura::Env::CreateInstance(); | 1580 env_ = aura::Env::CreateInstance(parameters_.env_mode); |
1581 #endif // defined(USE_AURA) | 1581 #endif // defined(USE_AURA) |
1582 | 1582 |
1583 if (parts_) | 1583 if (parts_) |
1584 parts_->ToolkitInitialized(); | 1584 parts_->ToolkitInitialized(); |
1585 | 1585 |
1586 return true; | 1586 return true; |
1587 } | 1587 } |
1588 | 1588 |
1589 void BrowserMainLoop::MainMessageLoopRun() { | 1589 void BrowserMainLoop::MainMessageLoopRun() { |
1590 #if defined(OS_ANDROID) | 1590 #if defined(OS_ANDROID) |
(...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1701 if (!audio_manager_) { | 1701 if (!audio_manager_) { |
1702 audio_thread_ = base::MakeUnique<AudioDeviceThread>(); | 1702 audio_thread_ = base::MakeUnique<AudioDeviceThread>(); |
1703 audio_manager_ = media::AudioManager::Create( | 1703 audio_manager_ = media::AudioManager::Create( |
1704 audio_thread_->GetTaskRunner(), audio_thread_->worker_task_runner(), | 1704 audio_thread_->GetTaskRunner(), audio_thread_->worker_task_runner(), |
1705 MediaInternals::GetInstance()); | 1705 MediaInternals::GetInstance()); |
1706 } | 1706 } |
1707 CHECK(audio_manager_); | 1707 CHECK(audio_manager_); |
1708 } | 1708 } |
1709 | 1709 |
1710 } // namespace content | 1710 } // namespace content |
OLD | NEW |