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

Unified Diff: ppapi/thunk/ppb_graphics_2d_thunk.cc

Issue 1881603002: Added SetLayerTransform to PPAPI (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Added Graphics2D 1.2 to histograms Created 4 years, 8 months 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 | « ppapi/thunk/ppb_graphics_2d_api.h ('k') | tools/metrics/histograms/histograms.xml » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ppapi/thunk/ppb_graphics_2d_thunk.cc
diff --git a/ppapi/thunk/ppb_graphics_2d_thunk.cc b/ppapi/thunk/ppb_graphics_2d_thunk.cc
index 527b0aa80cc700e35195aa233305bbb3883f09e7..af7349f3c4a8513d1881c4ea7cf1fa55c4d0b3ce 100644
--- a/ppapi/thunk/ppb_graphics_2d_thunk.cc
+++ b/ppapi/thunk/ppb_graphics_2d_thunk.cc
@@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-// From ppb_graphics_2d.idl modified Wed Jan 27 17:10:16 2016.
+// From ppb_graphics_2d.idl modified Fri Apr 15 15:37:20 2016.
#include <stdint.h>
#include <string.h>
@@ -102,6 +102,17 @@ float GetScale(PP_Resource resource) {
return enter.object()->GetScale();
}
+PP_Bool SetLayerTransform(PP_Resource resource,
+ float scale,
+ const struct PP_Point* origin,
+ const struct PP_Point* translate) {
+ VLOG(4) << "PPB_Graphics2D::SetLayerTransform()";
+ EnterResource<PPB_Graphics2D_API> enter(resource, true);
+ if (enter.failed())
+ return PP_FALSE;
+ return enter.object()->SetLayerTransform(scale, origin, translate);
+}
+
const PPB_Graphics2D_1_0 g_ppb_graphics2d_thunk_1_0 = {
&Create, &IsGraphics2D, &Describe, &PaintImageData,
&Scroll, &ReplaceContents, &Flush};
@@ -110,6 +121,11 @@ const PPB_Graphics2D_1_1 g_ppb_graphics2d_thunk_1_1 = {
&Create, &IsGraphics2D, &Describe, &PaintImageData, &Scroll,
&ReplaceContents, &Flush, &SetScale, &GetScale};
+const PPB_Graphics2D_1_2 g_ppb_graphics2d_thunk_1_2 = {
+ &Create, &IsGraphics2D, &Describe, &PaintImageData,
+ &Scroll, &ReplaceContents, &Flush, &SetScale,
+ &GetScale, &SetLayerTransform};
+
} // namespace
PPAPI_THUNK_EXPORT const PPB_Graphics2D_1_0* GetPPB_Graphics2D_1_0_Thunk() {
@@ -120,5 +136,9 @@ PPAPI_THUNK_EXPORT const PPB_Graphics2D_1_1* GetPPB_Graphics2D_1_1_Thunk() {
return &g_ppb_graphics2d_thunk_1_1;
}
+PPAPI_THUNK_EXPORT const PPB_Graphics2D_1_2* GetPPB_Graphics2D_1_2_Thunk() {
+ return &g_ppb_graphics2d_thunk_1_2;
+}
+
} // namespace thunk
} // namespace ppapi
« no previous file with comments | « ppapi/thunk/ppb_graphics_2d_api.h ('k') | tools/metrics/histograms/histograms.xml » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698