OLD | NEW |
| (Empty) |
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 | |
3 // found in the LICENSE file. | |
4 | |
5 #ifndef MASH_WM_SHADOW_CONTROLLER_H_ | |
6 #define MASH_WM_SHADOW_CONTROLLER_H_ | |
7 | |
8 #include "base/macros.h" | |
9 #include "components/mus/public/cpp/window_observer.h" | |
10 #include "components/mus/public/cpp/window_tree_client_observer.h" | |
11 | |
12 namespace mus { | |
13 class WindowTreeClient; | |
14 } | |
15 | |
16 namespace mash { | |
17 namespace wm { | |
18 | |
19 class ShadowController : public mus::WindowTreeClientObserver, | |
20 public mus::WindowObserver { | |
21 public: | |
22 explicit ShadowController(mus::WindowTreeClient* window_tree); | |
23 ~ShadowController() override; | |
24 | |
25 private: | |
26 void SetActiveWindow(mus::Window* window); | |
27 | |
28 // mus::WindowTreeClientObserver: | |
29 void OnWindowTreeFocusChanged(mus::Window* gained_focus, | |
30 mus::Window* lost_focus) override; | |
31 | |
32 // mus::WindowObserver: | |
33 void OnWindowDestroying(mus::Window* window) override; | |
34 | |
35 mus::WindowTreeClient* window_tree_; | |
36 mus::Window* active_window_; | |
37 | |
38 DISALLOW_COPY_AND_ASSIGN(ShadowController); | |
39 }; | |
40 | |
41 } // namespace wm | |
42 } // namespace mash | |
43 | |
44 #endif // MASH_WM_SHADOW_CONTROLLER_H_ | |
OLD | NEW |