OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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_AURA_ROOT_WINDOW_HOST_DELEGATE_H_ | 5 #ifndef UI_AURA_ROOT_WINDOW_HOST_DELEGATE_H_ |
6 #define UI_AURA_ROOT_WINDOW_HOST_DELEGATE_H_ | 6 #define UI_AURA_ROOT_WINDOW_HOST_DELEGATE_H_ |
7 | 7 |
8 #include "ui/aura/aura_export.h" | 8 #include "ui/aura/aura_export.h" |
9 | 9 |
10 namespace gfx { | 10 namespace gfx { |
(...skipping 14 matching lines...) Expand all Loading... |
25 | 25 |
26 // A private interface used by RootWindowHost implementations to communicate | 26 // A private interface used by RootWindowHost implementations to communicate |
27 // with their owning RootWindow. | 27 // with their owning RootWindow. |
28 class AURA_EXPORT RootWindowHostDelegate { | 28 class AURA_EXPORT RootWindowHostDelegate { |
29 public: | 29 public: |
30 virtual bool OnHostKeyEvent(ui::KeyEvent* event) = 0; | 30 virtual bool OnHostKeyEvent(ui::KeyEvent* event) = 0; |
31 virtual bool OnHostMouseEvent(ui::MouseEvent* event) = 0; | 31 virtual bool OnHostMouseEvent(ui::MouseEvent* event) = 0; |
32 virtual bool OnHostScrollEvent(ui::ScrollEvent* event) = 0; | 32 virtual bool OnHostScrollEvent(ui::ScrollEvent* event) = 0; |
33 virtual bool OnHostTouchEvent(ui::TouchEvent* event) = 0; | 33 virtual bool OnHostTouchEvent(ui::TouchEvent* event) = 0; |
34 | 34 |
35 virtual void OnHostLostCapture() = 0; | 35 // Called when system focus is changed to another window. |
| 36 virtual void OnHostLostWindowCapture() = 0; |
| 37 |
| 38 // Called when the windowing system has mouse grab because it's performing a |
| 39 // window move on our behalf, but we should still paint as if we're active. |
| 40 virtual void OnHostLostMouseGrab() = 0; |
36 | 41 |
37 virtual void OnHostPaint() = 0; | 42 virtual void OnHostPaint() = 0; |
38 | 43 |
39 virtual void OnHostMoved(const gfx::Point& origin) = 0; | 44 virtual void OnHostMoved(const gfx::Point& origin) = 0; |
40 virtual void OnHostResized(const gfx::Size& size) = 0; | 45 virtual void OnHostResized(const gfx::Size& size) = 0; |
41 | 46 |
42 virtual float GetDeviceScaleFactor() = 0; | 47 virtual float GetDeviceScaleFactor() = 0; |
43 | 48 |
44 virtual RootWindow* AsRootWindow() = 0; | 49 virtual RootWindow* AsRootWindow() = 0; |
45 | 50 |
46 protected: | 51 protected: |
47 virtual ~RootWindowHostDelegate() {} | 52 virtual ~RootWindowHostDelegate() {} |
48 }; | 53 }; |
49 | 54 |
50 } // namespace aura | 55 } // namespace aura |
51 | 56 |
52 #endif // UI_AURA_ROOT_WINDOW_HOST_DELEGATE_H_ | 57 #endif // UI_AURA_ROOT_WINDOW_HOST_DELEGATE_H_ |
OLD | NEW |