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

Unified Diff: ppapi/tests/test_graphics_2d.cc

Issue 4310002: Make PPAPI headers compile with C compilers (gcc on Linux & Mac and MSVS on W... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 10 years, 1 month 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/tests/test_c_includes.c ('k') | ppapi/tests/test_image_data.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ppapi/tests/test_graphics_2d.cc
===================================================================
--- ppapi/tests/test_graphics_2d.cc (revision 65116)
+++ ppapi/tests/test_graphics_2d.cc (working copy)
@@ -9,6 +9,7 @@
#include "ppapi/c/dev/ppb_testing_dev.h"
#include "ppapi/c/pp_errors.h"
#include "ppapi/c/ppb_graphics_2d.h"
+#include "ppapi/cpp/common.h"
#include "ppapi/cpp/completion_callback.h"
#include "ppapi/cpp/graphics_2d.h"
#include "ppapi/cpp/image_data.h"
@@ -68,9 +69,10 @@
bool TestGraphics2D::ReadImageData(const pp::Graphics2D& dc,
pp::ImageData* image,
const pp::Point& top_left) const {
- return testing_interface_->ReadImageData(dc.pp_resource(),
- image->pp_resource(),
- &top_left.pp_point());
+ return pp::PPBoolToBool(testing_interface_->ReadImageData(
+ dc.pp_resource(),
+ image->pp_resource(),
+ &top_left.pp_point()));
}
bool TestGraphics2D::IsDCUniformColor(const pp::Graphics2D& dc,
@@ -181,7 +183,7 @@
// Describe.
PP_Size size;
- bool opaque;
+ PP_Bool opaque;
graphics_2d_interface_->Describe(image.pp_resource(), &size, &opaque);
graphics_2d_interface_->Describe(null_context.pp_resource(),
&size, &opaque);
@@ -248,12 +250,12 @@
size.width = 16;
size.height = -16;
ASSERT_FALSE(!!graphics_2d_interface_->Create(
- pp::Module::Get()->pp_module(), &size, false));
+ pp::Module::Get()->pp_module(), &size, PP_FALSE));
size.width = -16;
size.height = 16;
ASSERT_FALSE(!!graphics_2d_interface_->Create(
- pp::Module::Get()->pp_module(), &size, false));
+ pp::Module::Get()->pp_module(), &size, PP_FALSE));
return "";
}
@@ -296,11 +298,11 @@
PP_Size size;
size.width = -1;
size.height = -1;
- bool is_always_opaque = true;
+ PP_Bool is_always_opaque = PP_TRUE;
if (!graphics_2d_interface_->Describe(dc.pp_resource(), &size,
&is_always_opaque))
return "Describe failed";
- if (size.width != w || size.height != h || is_always_opaque != false)
+ if (size.width != w || size.height != h || is_always_opaque != PP_FALSE)
return "Mismatch of data.";
return "";
« no previous file with comments | « ppapi/tests/test_c_includes.c ('k') | ppapi/tests/test_image_data.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698