Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2633)

Unified Diff: cc/ipc/quads_struct_traits.cc

Issue 2541403002: cc mojo: Serialize/deserialize missed field in TextureDrawQuads (Closed)
Patch Set: Created 4 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « cc/ipc/quads_struct_traits.h ('k') | cc/ipc/struct_traits_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/ipc/quads_struct_traits.cc
diff --git a/cc/ipc/quads_struct_traits.cc b/cc/ipc/quads_struct_traits.cc
index 7e567f561ca8dac074ea884bfe451581fa65b7e7..6d649d587d4fce54569f11c5e53b7db4c514ee67 100644
--- a/cc/ipc/quads_struct_traits.cc
+++ b/cc/ipc/quads_struct_traits.cc
@@ -113,8 +113,15 @@ bool StructTraits<cc::mojom::TextureQuadStateDataView, cc::DrawQuad>::Read(
cc::mojom::TextureQuadStateDataView data,
cc::DrawQuad* out) {
cc::TextureDrawQuad* quad = static_cast<cc::TextureDrawQuad*>(out);
+
quad->resources.ids[cc::TextureDrawQuad::kResourceIdIndex] =
data.resource_id();
+ if (!data.ReadResourceSizeInPixels(
+ &quad->overlay_resources
+ .size_in_pixels[cc::TextureDrawQuad::kResourceIdIndex])) {
+ return false;
+ }
+
quad->resources.count = 1;
quad->premultiplied_alpha = data.premultiplied_alpha();
if (!data.ReadUvTopLeft(&quad->uv_top_left) ||
« no previous file with comments | « cc/ipc/quads_struct_traits.h ('k') | cc/ipc/struct_traits_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698