OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 "services/window_manager/window_manager_app.h" | 5 #include "services/window_manager/window_manager_app.h" |
6 | 6 |
7 #include "base/message_loop/message_loop.h" | 7 #include "base/message_loop/message_loop.h" |
8 #include "base/stl_util.h" | 8 #include "base/stl_util.h" |
9 #include "mojo/converters/geometry/geometry_type_converters.h" | 9 #include "mojo/converters/geometry/geometry_type_converters.h" |
10 #include "mojo/converters/input_events/input_events_type_converters.h" | 10 #include "mojo/converters/input_events/input_events_type_converters.h" |
(...skipping 353 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
364 mojo::ScopedMessagePipeHandle window_manager_pipe) { | 364 mojo::ScopedMessagePipeHandle window_manager_pipe) { |
365 // TODO(sky): pass in |connection_id| for validation. | 365 // TODO(sky): pass in |connection_id| for validation. |
366 WindowManagerImpl* wm = new WindowManagerImpl(this, true); | 366 WindowManagerImpl* wm = new WindowManagerImpl(this, true); |
367 wm->Bind(window_manager_pipe.Pass()); | 367 wm->Bind(window_manager_pipe.Pass()); |
368 // WindowManagerImpl is deleted when the connection has an error, or from our | 368 // WindowManagerImpl is deleted when the connection has an error, or from our |
369 // destructor. | 369 // destructor. |
370 } | 370 } |
371 | 371 |
372 void WindowManagerApp::SetViewManagerClient( | 372 void WindowManagerApp::SetViewManagerClient( |
373 mojo::ScopedMessagePipeHandle view_manager_client_request) { | 373 mojo::ScopedMessagePipeHandle view_manager_client_request) { |
374 view_manager_client_ = | 374 view_manager_client_.reset( |
375 mojo::ViewManagerClientFactory::WeakBindViewManagerToPipe( | 375 mojo::ViewManagerClientFactory::WeakBindViewManagerToPipe( |
376 mojo::MakeRequest<mojo::ViewManagerClient>( | 376 mojo::MakeRequest<mojo::ViewManagerClient>( |
377 view_manager_client_request.Pass()), | 377 view_manager_client_request.Pass()), |
378 view_manager_service_.Pass(), shell_, this).Pass(); | 378 view_manager_service_.Pass(), shell_, this)); |
379 } | 379 } |
380 | 380 |
381 } // namespace window_manager | 381 } // namespace window_manager |
OLD | NEW |