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

Unified Diff: content/browser/android/synchronous_compositor_browser_filter.cc

Issue 2458743002: Switching to base::Optional<CompositorFrame> in Android's synchronous compositor IPC messages (Closed)
Patch Set: Created 4 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: content/browser/android/synchronous_compositor_browser_filter.cc
diff --git a/content/browser/android/synchronous_compositor_browser_filter.cc b/content/browser/android/synchronous_compositor_browser_filter.cc
index d1a7b9f9c9873fd7c0e646256f5d12e43d0be213..87f9240df76864d3d2ea4b1f242eace5e20c7346 100644
--- a/content/browser/android/synchronous_compositor_browser_filter.cc
+++ b/content/browser/android/synchronous_compositor_browser_filter.cc
@@ -81,7 +81,8 @@ bool SynchronousCompositorBrowserFilter::ReceiveFrame(
auto frame_ptr = base::MakeUnique<SynchronousCompositor::Frame>();
frame_ptr->compositor_frame_sink_id = std::get<0>(param);
cc::CompositorFrame& compositor_frame = std::get<1>(param);
- if (compositor_frame.delegated_frame_data) {
+ bool has_swapped = std::get<2>(param);
+ if (has_swapped) {
frame_ptr->frame.reset(new cc::CompositorFrame);
*frame_ptr->frame = std::move(compositor_frame);
}

Powered by Google App Engine
This is Rietveld 408576698