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

Unified Diff: ppapi/proxy/compositor_resource.cc

Issue 1427543002: Modified old wait sync point functions to also accept new sync tokens. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Folded sync_point into sync_tokens Created 5 years, 2 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
Index: ppapi/proxy/compositor_resource.cc
diff --git a/ppapi/proxy/compositor_resource.cc b/ppapi/proxy/compositor_resource.cc
index 443d7a949e977bab3394e8e7c0fe181d02eed7ac..f15e4024f77e139ad8096262fe23d2074e4b0a28 100644
--- a/ppapi/proxy/compositor_resource.cc
+++ b/ppapi/proxy/compositor_resource.cc
@@ -36,7 +36,7 @@ CompositorResource::~CompositorResource() {
for (ReleaseCallbackMap::iterator it = release_callback_map_.begin();
it != release_callback_map_.end(); ++it) {
if (!it->second.is_null())
- it->second.Run(PP_ERROR_ABORTED, 0, false);
+ it->second.Run(PP_ERROR_ABORTED, gpu::SyncToken(), false);
}
}
@@ -126,12 +126,12 @@ void CompositorResource::OnPluginMsgCommitLayersReply(
void CompositorResource::OnPluginMsgReleaseResource(
const ResourceMessageReplyParams& params,
int32_t id,
- uint32_t sync_point,
+ const gpu::SyncToken& sync_token,
bool is_lost) {
ReleaseCallbackMap::iterator it = release_callback_map_.find(id);
DCHECK(it != release_callback_map_.end()) <<
"Can not found release_callback_ by id(" << id << ")!";
- it->second.Run(PP_OK, sync_point, is_lost);
+ it->second.Run(PP_OK, sync_token, is_lost);
release_callback_map_.erase(it);
}
@@ -140,7 +140,8 @@ void CompositorResource::ResetLayersInternal(bool is_aborted) {
it != layers_.end(); ++it) {
ReleaseCallback release_callback = (*it)->release_callback();
if (!release_callback.is_null()) {
- release_callback.Run(is_aborted ? PP_ERROR_ABORTED : PP_OK, 0, false);
+ release_callback.Run(is_aborted ? PP_ERROR_ABORTED : PP_OK,
+ gpu::SyncToken(), false);
(*it)->ResetReleaseCallback();
}
(*it)->Invalidate();

Powered by Google App Engine
This is Rietveld 408576698