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 COMPONENTS_NATIVE_VIEWPORT_NATIVE_VIEWPORT_IMPL_H_ | 5 #ifndef COMPONENTS_NATIVE_VIEWPORT_NATIVE_VIEWPORT_IMPL_H_ |
6 #define COMPONENTS_NATIVE_VIEWPORT_NATIVE_VIEWPORT_IMPL_H_ | 6 #define COMPONENTS_NATIVE_VIEWPORT_NATIVE_VIEWPORT_IMPL_H_ |
7 | 7 |
8 #include <set> | 8 #include <set> |
9 | 9 |
10 #include "base/macros.h" | 10 #include "base/macros.h" |
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
46 void Hide() override; | 46 void Hide() override; |
47 void Close() override; | 47 void Close() override; |
48 void SetSize(mojo::SizePtr size) override; | 48 void SetSize(mojo::SizePtr size) override; |
49 void GetContextProvider( | 49 void GetContextProvider( |
50 mojo::InterfaceRequest<mojo::ContextProvider> request) override; | 50 mojo::InterfaceRequest<mojo::ContextProvider> request) override; |
51 void SetEventDispatcher( | 51 void SetEventDispatcher( |
52 mojo::NativeViewportEventDispatcherPtr dispatcher) override; | 52 mojo::NativeViewportEventDispatcherPtr dispatcher) override; |
53 | 53 |
54 // PlatformViewport::Delegate implementation. | 54 // PlatformViewport::Delegate implementation. |
55 void OnMetricsChanged(mojo::ViewportMetricsPtr metrics) override; | 55 void OnMetricsChanged(mojo::ViewportMetricsPtr metrics) override; |
56 void OnAcceleratedWidgetAvailable(gfx::AcceleratedWidget widget) override; | 56 void OnAcceleratedWidgetAvailable(gfx::AcceleratedWidget widget, |
| 57 float device_pixel_ratio) override; |
57 void OnAcceleratedWidgetDestroyed() override; | 58 void OnAcceleratedWidgetDestroyed() override; |
58 bool OnEvent(mojo::EventPtr event) override; | 59 bool OnEvent(mojo::EventPtr event) override; |
59 void OnDestroyed() override; | 60 void OnDestroyed() override; |
60 | 61 |
61 // mojo::ErrorHandler implementation. | 62 // mojo::ErrorHandler implementation. |
62 void OnConnectionError() override; | 63 void OnConnectionError() override; |
63 | 64 |
64 private: | 65 private: |
65 // Callback when the dispatcher has processed a message we're waiting on | 66 // Callback when the dispatcher has processed a message we're waiting on |
66 // an ack from. |pointer_id| identifies the pointer the message was associated | 67 // an ack from. |pointer_id| identifies the pointer the message was associated |
(...skipping 14 matching lines...) Expand all Loading... |
81 std::set<int32> pointers_waiting_on_ack_; | 82 std::set<int32> pointers_waiting_on_ack_; |
82 | 83 |
83 base::WeakPtrFactory<NativeViewportImpl> weak_factory_; | 84 base::WeakPtrFactory<NativeViewportImpl> weak_factory_; |
84 | 85 |
85 DISALLOW_COPY_AND_ASSIGN(NativeViewportImpl); | 86 DISALLOW_COPY_AND_ASSIGN(NativeViewportImpl); |
86 }; | 87 }; |
87 | 88 |
88 } // namespace native_viewport | 89 } // namespace native_viewport |
89 | 90 |
90 #endif // COMPONENTS_NATIVE_VIEWPORT_NATIVE_VIEWPORT_IMPL_H_ | 91 #endif // COMPONENTS_NATIVE_VIEWPORT_NATIVE_VIEWPORT_IMPL_H_ |
OLD | NEW |