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 #ifndef MOJO_SERVICES_VIEW_MANAGER_NODE_DELEGATE_H_ | 5 #ifndef MOJO_SERVICES_VIEW_MANAGER_NODE_DELEGATE_H_ |
6 #define MOJO_SERVICES_VIEW_MANAGER_NODE_DELEGATE_H_ | 6 #define MOJO_SERVICES_VIEW_MANAGER_NODE_DELEGATE_H_ |
7 | 7 |
8 #include "mojo/services/view_manager/view_manager_export.h" | 8 #include "mojo/services/view_manager/view_manager_export.h" |
9 | 9 |
10 namespace ui { | 10 namespace ui { |
11 class Event; | 11 class Event; |
12 } | 12 } |
13 | 13 |
14 namespace gfx { | 14 namespace gfx { |
15 class Rect; | 15 class Rect; |
16 } | 16 } |
17 | 17 |
18 namespace mojo { | 18 namespace mojo { |
19 namespace view_manager { | |
20 namespace service { | 19 namespace service { |
21 | 20 |
22 class Node; | 21 class Node; |
23 class View; | 22 class View; |
24 | 23 |
25 class MOJO_VIEW_MANAGER_EXPORT NodeDelegate { | 24 class MOJO_VIEW_MANAGER_EXPORT NodeDelegate { |
26 public: | 25 public: |
27 // Invoked at the end of the Node's destructor (after it has been removed from | 26 // Invoked at the end of the Node's destructor (after it has been removed from |
28 // the hierarchy and its active view has been reset). | 27 // the hierarchy and its active view has been reset). |
29 virtual void OnNodeDestroyed(const Node* node) = 0; | 28 virtual void OnNodeDestroyed(const Node* node) = 0; |
(...skipping 14 matching lines...) Expand all Loading... |
44 | 43 |
45 // Invoked when an input event is received by the View at this node. | 44 // Invoked when an input event is received by the View at this node. |
46 virtual void OnViewInputEvent(const View* view, | 45 virtual void OnViewInputEvent(const View* view, |
47 const ui::Event* event) = 0; | 46 const ui::Event* event) = 0; |
48 | 47 |
49 protected: | 48 protected: |
50 virtual ~NodeDelegate() {} | 49 virtual ~NodeDelegate() {} |
51 }; | 50 }; |
52 | 51 |
53 } // namespace service | 52 } // namespace service |
54 } // namespace view_manager | |
55 } // namespace mojo | 53 } // namespace mojo |
56 | 54 |
57 #endif // MOJO_SERVICES_VIEW_MANAGER_NODE_DELEGATE_H_ | 55 #endif // MOJO_SERVICES_VIEW_MANAGER_NODE_DELEGATE_H_ |
OLD | NEW |