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 #ifndef UI_VIEWS_MUS_WINDOW_TREE_HOST_MUS_H_ | 5 #ifndef UI_VIEWS_MUS_WINDOW_TREE_HOST_MUS_H_ |
6 #define UI_VIEWS_MUS_WINDOW_TREE_HOST_MUS_H_ | 6 #define UI_VIEWS_MUS_WINDOW_TREE_HOST_MUS_H_ |
7 | 7 |
8 #include "base/macros.h" | 8 #include "base/macros.h" |
9 #include "services/shell/public/cpp/connector.h" | |
10 #include "ui/aura/window_tree_host_platform.h" | 9 #include "ui/aura/window_tree_host_platform.h" |
11 #include "ui/views/mus/mus_export.h" | 10 #include "ui/views/mus/mus_export.h" |
12 | 11 |
13 class SkBitmap; | 12 class SkBitmap; |
14 | 13 |
15 namespace ui { | 14 namespace ui { |
16 class Window; | 15 class Window; |
17 } | 16 } |
18 | 17 |
19 namespace shell { | 18 namespace shell { |
20 class Connector; | 19 class Connector; |
21 } | 20 } |
22 | 21 |
23 namespace views { | 22 namespace views { |
24 | 23 |
25 class InputMethodMus; | 24 class InputMethodMUS; |
26 class NativeWidgetMus; | 25 class NativeWidgetMus; |
27 class PlatformWindowMus; | 26 class PlatformWindowMus; |
28 | 27 |
29 class VIEWS_MUS_EXPORT WindowTreeHostMus : public aura::WindowTreeHostPlatform { | 28 class VIEWS_MUS_EXPORT WindowTreeHostMus : public aura::WindowTreeHostPlatform { |
30 public: | 29 public: |
31 WindowTreeHostMus(NativeWidgetMus* native_widget, ui::Window* window); | 30 WindowTreeHostMus(NativeWidgetMus* native_widget, ui::Window* window); |
32 ~WindowTreeHostMus() override; | 31 ~WindowTreeHostMus() override; |
33 NativeWidgetMus* native_widget() { return native_widget_; } | 32 NativeWidgetMus* native_widget() { return native_widget_; } |
34 | 33 |
35 void InitInputMethod(shell::Connector* connector); | |
36 | |
37 private: | 34 private: |
38 // aura::WindowTreeHostPlatform: | 35 // aura::WindowTreeHostPlatform: |
39 void DispatchEvent(ui::Event* event) override; | 36 void DispatchEvent(ui::Event* event) override; |
40 void OnClosed() override; | 37 void OnClosed() override; |
41 void OnActivationChanged(bool active) override; | 38 void OnActivationChanged(bool active) override; |
42 void OnCloseRequest() override; | 39 void OnCloseRequest() override; |
43 | 40 |
44 NativeWidgetMus* native_widget_; | 41 NativeWidgetMus* native_widget_; |
45 std::unique_ptr<InputMethodMus> input_method_; | 42 std::unique_ptr<InputMethodMUS> input_method_; |
46 | 43 |
47 DISALLOW_COPY_AND_ASSIGN(WindowTreeHostMus); | 44 DISALLOW_COPY_AND_ASSIGN(WindowTreeHostMus); |
48 }; | 45 }; |
49 | 46 |
50 } // namespace views | 47 } // namespace views |
51 | 48 |
52 #endif // UI_VIEWS_MUS_WINDOW_TREE_HOST_MUS_H_ | 49 #endif // UI_VIEWS_MUS_WINDOW_TREE_HOST_MUS_H_ |
OLD | NEW |