| 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 "chrome/browser/ui/views/chrome_browser_main_extra_parts_views.h" | 5 #include "chrome/browser/ui/views/chrome_browser_main_extra_parts_views.h" |
| 6 | 6 |
| 7 #include "chrome/browser/ui/views/chrome_constrained_window_views_client.h" | 7 #include "chrome/browser/ui/views/chrome_constrained_window_views_client.h" |
| 8 #include "chrome/browser/ui/views/chrome_views_delegate.h" | 8 #include "chrome/browser/ui/views/chrome_views_delegate.h" |
| 9 #include "components/constrained_window/constrained_window_views.h" | 9 #include "components/constrained_window/constrained_window_views.h" |
| 10 | 10 |
| (...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 49 void ChromeBrowserMainExtraPartsViews::PreProfileInit() { | 49 void ChromeBrowserMainExtraPartsViews::PreProfileInit() { |
| 50 #if defined(USE_AURA) | 50 #if defined(USE_AURA) |
| 51 content::MojoShellConnection* mojo_shell_connection = | 51 content::MojoShellConnection* mojo_shell_connection = |
| 52 content::MojoShellConnection::GetForProcess(); | 52 content::MojoShellConnection::GetForProcess(); |
| 53 if (mojo_shell_connection && shell::ShellIsRemote()) { | 53 if (mojo_shell_connection && shell::ShellIsRemote()) { |
| 54 input_device_client_.reset(new ui::InputDeviceClient()); | 54 input_device_client_.reset(new ui::InputDeviceClient()); |
| 55 ui::mojom::InputDeviceServerPtr server; | 55 ui::mojom::InputDeviceServerPtr server; |
| 56 mojo_shell_connection->GetConnector()->ConnectToInterface("mojo:ui", | 56 mojo_shell_connection->GetConnector()->ConnectToInterface("mojo:ui", |
| 57 &server); | 57 &server); |
| 58 input_device_client_->Connect(std::move(server)); | 58 input_device_client_->Connect(std::move(server)); |
| 59 | |
| 60 window_manager_connection_ = views::WindowManagerConnection::Create( | |
| 61 mojo_shell_connection->GetConnector(), | |
| 62 mojo_shell_connection->GetIdentity()); | |
| 63 } | 59 } |
| 64 #endif // defined(USE_AURA) | 60 #endif // defined(USE_AURA) |
| 65 ChromeBrowserMainExtraParts::PreProfileInit(); | 61 ChromeBrowserMainExtraParts::PreProfileInit(); |
| 66 } | 62 } |
| OLD | NEW |