| 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 "ash/shell/content/client/shell_browser_main_parts.h" | 5 #include "ash/shell/content/client/shell_browser_main_parts.h" |
| 6 | 6 |
| 7 #include "ash/common/login_status.h" | 7 #include "ash/common/login_status.h" |
| 8 #include "ash/common/material_design/material_design_controller.h" | |
| 9 #include "ash/common/wm_shell.h" | 8 #include "ash/common/wm_shell.h" |
| 10 #include "ash/content/shell_content_state.h" | 9 #include "ash/content/shell_content_state.h" |
| 11 #include "ash/shell.h" | 10 #include "ash/shell.h" |
| 12 #include "ash/shell/content/shell_content_state_impl.h" | 11 #include "ash/shell/content/shell_content_state_impl.h" |
| 13 #include "ash/shell/example_app_list_presenter.h" | 12 #include "ash/shell/example_app_list_presenter.h" |
| 14 #include "ash/shell/shell_delegate_impl.h" | 13 #include "ash/shell/shell_delegate_impl.h" |
| 15 #include "ash/shell/window_watcher.h" | 14 #include "ash/shell/window_watcher.h" |
| 16 #include "ash/shell_init_params.h" | 15 #include "ash/shell_init_params.h" |
| 17 #include "base/bind.h" | 16 #include "base/bind.h" |
| 18 #include "base/command_line.h" | 17 #include "base/command_line.h" |
| (...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 93 ui::TouchFactory::SetTouchDeviceListFromCommandLine(); | 92 ui::TouchFactory::SetTouchDeviceListFromCommandLine(); |
| 94 #endif | 93 #endif |
| 95 } | 94 } |
| 96 | 95 |
| 97 void ShellBrowserMainParts::PostMainMessageLoopStart() { | 96 void ShellBrowserMainParts::PostMainMessageLoopStart() { |
| 98 chromeos::DBusThreadManager::Initialize( | 97 chromeos::DBusThreadManager::Initialize( |
| 99 chromeos::DBusThreadManager::PROCESS_ASH); | 98 chromeos::DBusThreadManager::PROCESS_ASH); |
| 100 } | 99 } |
| 101 | 100 |
| 102 void ShellBrowserMainParts::ToolkitInitialized() { | 101 void ShellBrowserMainParts::ToolkitInitialized() { |
| 103 ash::MaterialDesignController::Initialize(); | |
| 104 wm_state_.reset(new ::wm::WMState); | 102 wm_state_.reset(new ::wm::WMState); |
| 105 } | 103 } |
| 106 | 104 |
| 107 void ShellBrowserMainParts::PreMainMessageLoopRun() { | 105 void ShellBrowserMainParts::PreMainMessageLoopRun() { |
| 108 net_log_.reset(new content::ShellNetLog("ash_shell")); | 106 net_log_.reset(new content::ShellNetLog("ash_shell")); |
| 109 browser_context_.reset( | 107 browser_context_.reset( |
| 110 new content::ShellBrowserContext(false, net_log_.get())); | 108 new content::ShellBrowserContext(false, net_log_.get())); |
| 111 | 109 |
| 112 // A ViewsDelegate is required. | 110 // A ViewsDelegate is required. |
| 113 if (!views::ViewsDelegate::GetInstance()) | 111 if (!views::ViewsDelegate::GetInstance()) |
| (...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 171 browser_context_.reset(); | 169 browser_context_.reset(); |
| 172 } | 170 } |
| 173 | 171 |
| 174 bool ShellBrowserMainParts::MainMessageLoopRun(int* result_code) { | 172 bool ShellBrowserMainParts::MainMessageLoopRun(int* result_code) { |
| 175 base::RunLoop().Run(); | 173 base::RunLoop().Run(); |
| 176 return true; | 174 return true; |
| 177 } | 175 } |
| 178 | 176 |
| 179 } // namespace shell | 177 } // namespace shell |
| 180 } // namespace ash | 178 } // namespace ash |
| OLD | NEW |