summaryrefslogtreecommitdiffstats
path: root/webkit/plugins/ppapi/ppb_graphics_2d_impl.cc
diff options
context:
space:
mode:
Diffstat (limited to 'webkit/plugins/ppapi/ppb_graphics_2d_impl.cc')
-rw-r--r--webkit/plugins/ppapi/ppb_graphics_2d_impl.cc7
1 files changed, 5 insertions, 2 deletions
diff --git a/webkit/plugins/ppapi/ppb_graphics_2d_impl.cc b/webkit/plugins/ppapi/ppb_graphics_2d_impl.cc
index caeef5c..027e8eb 100644
--- a/webkit/plugins/ppapi/ppb_graphics_2d_impl.cc
+++ b/webkit/plugins/ppapi/ppb_graphics_2d_impl.cc
@@ -33,6 +33,7 @@
using ppapi::thunk::EnterResourceNoLock;
using ppapi::thunk::PPB_ImageData_API;
+using ppapi::TrackedCallback;
namespace webkit {
namespace ppapi {
@@ -348,9 +349,11 @@ int32_t PPB_Graphics2D_Impl::Flush(PP_CompletionCallback callback) {
if (nothing_visible) {
// There's nothing visible to invalidate so just schedule the callback to
// execute in the next round of the message loop.
- ScheduleOffscreenCallback(FlushCallbackData(callback));
+ ScheduleOffscreenCallback(FlushCallbackData(
+ scoped_refptr<TrackedCallback>(new TrackedCallback(this, callback))));
} else {
- unpainted_flush_callback_.Set(callback);
+ unpainted_flush_callback_.Set(
+ scoped_refptr<TrackedCallback>(new TrackedCallback(this, callback)));
}
return PP_OK_COMPLETIONPENDING;
}