| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 <map> | 5 #include <map> |
| 6 #include <memory> | 6 #include <memory> |
| 7 #include <vector> | 7 #include <vector> |
| 8 | 8 |
| 9 #include "base/bind.h" | 9 #include "base/bind.h" |
| 10 #include "base/macros.h" | 10 #include "base/macros.h" |
| (...skipping 25 matching lines...) Expand all Loading... |
| 36 | 36 |
| 37 void DestroyWindowTreeHost() { window_tree_host_.reset(); } | 37 void DestroyWindowTreeHost() { window_tree_host_.reset(); } |
| 38 | 38 |
| 39 private: | 39 private: |
| 40 // aura::WindowTreeClientDelegate: | 40 // aura::WindowTreeClientDelegate: |
| 41 void OnEmbed( | 41 void OnEmbed( |
| 42 std::unique_ptr<aura::WindowTreeHostMus> window_tree_host) override { | 42 std::unique_ptr<aura::WindowTreeHostMus> window_tree_host) override { |
| 43 window_tree_host_ = std::move(window_tree_host); | 43 window_tree_host_ = std::move(window_tree_host); |
| 44 run_loop_.Quit(); | 44 run_loop_.Quit(); |
| 45 } | 45 } |
| 46 void OnEmbedRootDestroyed(aura::Window* root) override {} | 46 void OnEmbedRootDestroyed( |
| 47 aura::WindowTreeHostMus* window_tree_host) override {} |
| 47 void OnLostConnection(aura::WindowTreeClient* client) override {} | 48 void OnLostConnection(aura::WindowTreeClient* client) override {} |
| 48 void OnPointerEventObserved(const ui::PointerEvent& event, | 49 void OnPointerEventObserved(const ui::PointerEvent& event, |
| 49 aura::Window* target) override {} | 50 aura::Window* target) override {} |
| 50 aura::client::CaptureClient* GetCaptureClient() override { | 51 aura::client::CaptureClient* GetCaptureClient() override { |
| 51 return wm_state_.capture_controller(); | 52 return wm_state_.capture_controller(); |
| 52 } | 53 } |
| 53 aura::PropertyConverter* GetPropertyConverter() override { | 54 aura::PropertyConverter* GetPropertyConverter() override { |
| 54 return &property_converter_; | 55 return &property_converter_; |
| 55 } | 56 } |
| 56 | 57 |
| (...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 111 client.Embed(child_window, std::move(tree_client), 0u, base::Bind(&OnEmbed)); | 112 client.Embed(child_window, std::move(tree_client), 0u, base::Bind(&OnEmbed)); |
| 112 aura::WindowTreeClient child_client(connector(), &window_tree_delegate, | 113 aura::WindowTreeClient child_client(connector(), &window_tree_delegate, |
| 113 nullptr, std::move(tree_client_request)); | 114 nullptr, std::move(tree_client_request)); |
| 114 window_tree_delegate.WaitForEmbed(); | 115 window_tree_delegate.WaitForEmbed(); |
| 115 ASSERT_TRUE(!child_client.GetRoots().empty()); | 116 ASSERT_TRUE(!child_client.GetRoots().empty()); |
| 116 window_tree_delegate.DestroyWindowTreeHost(); | 117 window_tree_delegate.DestroyWindowTreeHost(); |
| 117 } | 118 } |
| 118 | 119 |
| 119 } // namespace mus | 120 } // namespace mus |
| 120 } // namespace ash | 121 } // namespace ash |
| OLD | NEW |