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 SERVICES_UI_PUBLIC_CPP_WINDOW_TREE_CLIENT_OBSERVER_H_ | 5 #ifndef SERVICES_UI_PUBLIC_CPP_WINDOW_TREE_CLIENT_OBSERVER_H_ |
6 #define SERVICES_UI_PUBLIC_CPP_WINDOW_TREE_CLIENT_OBSERVER_H_ | 6 #define SERVICES_UI_PUBLIC_CPP_WINDOW_TREE_CLIENT_OBSERVER_H_ |
7 | 7 |
| 8 #include "services/ui/public/cpp/ui_export.h" |
| 9 |
8 namespace ui { | 10 namespace ui { |
9 | 11 |
10 class Window; | 12 class Window; |
11 class WindowTreeClient; | 13 class WindowTreeClient; |
12 | 14 |
13 class WindowTreeClientObserver { | 15 class UI_EXPORT WindowTreeClientObserver { |
14 public: | 16 public: |
15 virtual void OnWindowTreeFocusChanged(Window* gained_focus, | 17 virtual void OnWindowTreeFocusChanged(Window* gained_focus, |
16 Window* lost_focus) {} | 18 Window* lost_focus) {} |
17 | 19 |
18 // Called early on in the destructor of WindowTreeClient; before any windows | 20 // Called early on in the destructor of WindowTreeClient; before any windows |
19 // have been destroyed. | 21 // have been destroyed. |
20 virtual void OnWillDestroyClient(WindowTreeClient* client) {} | 22 virtual void OnWillDestroyClient(WindowTreeClient* client) {} |
21 | 23 |
22 // Called at the end of WindowTreeClient's destructor. At this point | 24 // Called at the end of WindowTreeClient's destructor. At this point |
23 // observers should drop all references to |client|. | 25 // observers should drop all references to |client|. |
24 virtual void OnDidDestroyClient(WindowTreeClient* client) {} | 26 virtual void OnDidDestroyClient(WindowTreeClient* client) {} |
25 | 27 |
26 protected: | 28 protected: |
27 virtual ~WindowTreeClientObserver() {} | 29 virtual ~WindowTreeClientObserver() {} |
28 }; | 30 }; |
29 | 31 |
30 } // namespace ui | 32 } // namespace ui |
31 | 33 |
32 #endif // SERVICES_UI_PUBLIC_CPP_WINDOW_TREE_CLIENT_OBSERVER_H_ | 34 #endif // SERVICES_UI_PUBLIC_CPP_WINDOW_TREE_CLIENT_OBSERVER_H_ |
OLD | NEW |