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 #include <stddef.h> | 5 #include <stddef.h> |
6 | 6 |
7 #include "base/memory/shared_memory_handle.h" | 7 #include "base/memory/shared_memory_handle.h" |
8 #include "cc/output/begin_frame_args.h" | 8 #include "cc/output/begin_frame_args.h" |
9 #include "cc/output/compositor_frame.h" | 9 #include "cc/output/compositor_frame.h" |
10 #include "cc/output/compositor_frame_ack.h" | 10 #include "cc/output/compositor_frame_ack.h" |
11 #include "content/common/content_export.h" | 11 #include "content/common/content_export.h" |
12 #include "content/common/content_param_traits.h" | 12 #include "content/common/content_param_traits.h" |
13 #include "content/common/input/did_overscroll_params.h" | 13 #include "content/common/input/did_overscroll_params.h" |
14 #include "content/common/input/input_event_ack_state.h" | 14 #include "content/common/input/input_event_ack_state.h" |
15 #include "ipc/ipc_message_macros.h" | 15 #include "ipc/ipc_message_macros.h" |
16 #include "third_party/WebKit/public/web/WebInputEvent.h" | 16 #include "third_party/WebKit/public/web/WebInputEvent.h" |
17 #include "ui/gfx/geometry/point.h" | 17 #include "ui/gfx/geometry/point.h" |
18 #include "ui/gfx/geometry/scroll_offset.h" | 18 #include "ui/gfx/geometry/scroll_offset.h" |
19 | 19 |
20 #ifndef CONTENT_COMMON_ANDROID_SYNC_COMPOSITOR_MESSAGES_H_ | 20 #ifndef CONTENT_COMMON_ANDROID_SYNC_COMPOSITOR_MESSAGES_H_ |
21 #define CONTENT_COMMON_ANDROID_SYNC_COMPOSITOR_MESSAGES_H_ | 21 #define CONTENT_COMMON_ANDROID_SYNC_COMPOSITOR_MESSAGES_H_ |
22 | 22 |
23 namespace content { | 23 namespace content { |
24 | 24 |
25 struct SyncCompositorCommonBrowserParams { | 25 struct SyncCompositorCommonBrowserParams { |
26 SyncCompositorCommonBrowserParams(); | 26 SyncCompositorCommonBrowserParams(); |
27 ~SyncCompositorCommonBrowserParams(); | 27 ~SyncCompositorCommonBrowserParams(); |
28 | 28 |
29 gfx::ScrollOffset root_scroll_offset; | |
30 bool update_root_scroll_offset; | |
31 bool begin_frame_source_paused; | 29 bool begin_frame_source_paused; |
32 }; | 30 }; |
33 | 31 |
34 struct SyncCompositorDemandDrawHwParams { | 32 struct SyncCompositorDemandDrawHwParams { |
35 SyncCompositorDemandDrawHwParams(); | 33 SyncCompositorDemandDrawHwParams(); |
36 SyncCompositorDemandDrawHwParams( | 34 SyncCompositorDemandDrawHwParams( |
37 const gfx::Size& surface_size, | 35 const gfx::Size& surface_size, |
38 const gfx::Transform& transform, | 36 const gfx::Transform& transform, |
39 const gfx::Rect& viewport, | 37 const gfx::Rect& viewport, |
40 const gfx::Rect& clip, | 38 const gfx::Rect& clip, |
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
87 | 85 |
88 #endif // CONTENT_COMMON_ANDROID_SYNC_COMPOSITOR_MESSAGES_H_ | 86 #endif // CONTENT_COMMON_ANDROID_SYNC_COMPOSITOR_MESSAGES_H_ |
89 | 87 |
90 // Multiply-included message file, hence no include guard. | 88 // Multiply-included message file, hence no include guard. |
91 | 89 |
92 #undef IPC_MESSAGE_EXPORT | 90 #undef IPC_MESSAGE_EXPORT |
93 #define IPC_MESSAGE_EXPORT CONTENT_EXPORT | 91 #define IPC_MESSAGE_EXPORT CONTENT_EXPORT |
94 #define IPC_MESSAGE_START SyncCompositorMsgStart | 92 #define IPC_MESSAGE_START SyncCompositorMsgStart |
95 | 93 |
96 IPC_STRUCT_TRAITS_BEGIN(content::SyncCompositorCommonBrowserParams) | 94 IPC_STRUCT_TRAITS_BEGIN(content::SyncCompositorCommonBrowserParams) |
97 IPC_STRUCT_TRAITS_MEMBER(root_scroll_offset) | |
98 IPC_STRUCT_TRAITS_MEMBER(update_root_scroll_offset) | |
99 IPC_STRUCT_TRAITS_MEMBER(begin_frame_source_paused) | 95 IPC_STRUCT_TRAITS_MEMBER(begin_frame_source_paused) |
100 IPC_STRUCT_TRAITS_END() | 96 IPC_STRUCT_TRAITS_END() |
101 | 97 |
102 IPC_STRUCT_TRAITS_BEGIN(content::SyncCompositorDemandDrawHwParams) | 98 IPC_STRUCT_TRAITS_BEGIN(content::SyncCompositorDemandDrawHwParams) |
103 IPC_STRUCT_TRAITS_MEMBER(surface_size) | 99 IPC_STRUCT_TRAITS_MEMBER(surface_size) |
104 IPC_STRUCT_TRAITS_MEMBER(transform) | 100 IPC_STRUCT_TRAITS_MEMBER(transform) |
105 IPC_STRUCT_TRAITS_MEMBER(viewport) | 101 IPC_STRUCT_TRAITS_MEMBER(viewport) |
106 IPC_STRUCT_TRAITS_MEMBER(clip) | 102 IPC_STRUCT_TRAITS_MEMBER(clip) |
107 IPC_STRUCT_TRAITS_MEMBER(viewport_rect_for_tile_priority) | 103 IPC_STRUCT_TRAITS_MEMBER(viewport_rect_for_tile_priority) |
108 IPC_STRUCT_TRAITS_MEMBER(transform_for_tile_priority) | 104 IPC_STRUCT_TRAITS_MEMBER(transform_for_tile_priority) |
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
183 gfx::Point /* anchor */, | 179 gfx::Point /* anchor */, |
184 content::SyncCompositorCommonRendererParams) | 180 content::SyncCompositorCommonRendererParams) |
185 | 181 |
186 IPC_MESSAGE_ROUTED1(SyncCompositorMsg_SetMemoryPolicy, | 182 IPC_MESSAGE_ROUTED1(SyncCompositorMsg_SetMemoryPolicy, |
187 uint32_t /* bytes_limit */); | 183 uint32_t /* bytes_limit */); |
188 | 184 |
189 IPC_MESSAGE_ROUTED2(SyncCompositorMsg_ReclaimResources, | 185 IPC_MESSAGE_ROUTED2(SyncCompositorMsg_ReclaimResources, |
190 uint32_t /* output_surface_id */, | 186 uint32_t /* output_surface_id */, |
191 cc::CompositorFrameAck); | 187 cc::CompositorFrameAck); |
192 | 188 |
| 189 IPC_MESSAGE_ROUTED1(SyncCompositorMsg_SetScroll, gfx::ScrollOffset); |
| 190 |
193 // ----------------------------------------------------------------------------- | 191 // ----------------------------------------------------------------------------- |
194 // Messages sent from the renderer to the browser. | 192 // Messages sent from the renderer to the browser. |
195 | 193 |
196 IPC_MESSAGE_ROUTED0(SyncCompositorHostMsg_OutputSurfaceCreated); | 194 IPC_MESSAGE_ROUTED0(SyncCompositorHostMsg_OutputSurfaceCreated); |
197 | 195 |
198 IPC_MESSAGE_ROUTED1(SyncCompositorHostMsg_UpdateState, | 196 IPC_MESSAGE_ROUTED1(SyncCompositorHostMsg_UpdateState, |
199 content::SyncCompositorCommonRendererParams) | 197 content::SyncCompositorCommonRendererParams) |
200 | 198 |
201 IPC_MESSAGE_ROUTED2(SyncCompositorHostMsg_OverScroll, | 199 IPC_MESSAGE_ROUTED2(SyncCompositorHostMsg_OverScroll, |
202 content::SyncCompositorCommonRendererParams, | 200 content::SyncCompositorCommonRendererParams, |
203 content::DidOverscrollParams) | 201 content::DidOverscrollParams) |
OLD | NEW |