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

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

Issue 2452893002: sync compositor: Signal futures on channel shutdown (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
« no previous file with comments | « no previous file | content/browser/android/synchronous_compositor_browser_filter.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/android/synchronous_compositor_browser_filter.h
diff --git a/content/browser/android/synchronous_compositor_browser_filter.h b/content/browser/android/synchronous_compositor_browser_filter.h
index 43efc928e2b6a9067280f3ddcca32de714b2cd9b..097ff7268a6e24240e1f43f71dde13ac9f369b6f 100644
--- a/content/browser/android/synchronous_compositor_browser_filter.h
+++ b/content/browser/android/synchronous_compositor_browser_filter.h
@@ -41,6 +41,9 @@ class SynchronousCompositorBrowserFilter : public ui::WindowAndroidObserver,
// BrowserMessageFilter overrides.
bool OnMessageReceived(const IPC::Message& message) override;
+ void OnFilterAdded(IPC::Channel* channel) override;
+ void OnFilterRemoved() override;
+ void OnChannelClosing() override;
void SyncStateAfterVSync(ui::WindowAndroid* window_android,
SynchronousCompositorHost* compositor_host);
@@ -52,15 +55,17 @@ class SynchronousCompositorBrowserFilter : public ui::WindowAndroidObserver,
~SynchronousCompositorBrowserFilter() override;
bool ReceiveFrame(const IPC::Message& message);
+ void SignalAllFutures();
RenderProcessHost* const render_process_host_;
// For synchronizing renderer state after a vsync.
- ui::WindowAndroid* window_android_in_vsync_;
+ ui::WindowAndroid* window_android_in_vsync_ = nullptr;
std::vector<SynchronousCompositorHost*>
compositor_host_pending_renderer_state_;
- base::Lock future_map_lock_; // Protects |future_map_|.
+ base::Lock future_map_lock_; // Protects fields below.
+ bool filter_ready_ = false;
using FrameFutureQueue =
std::deque<scoped_refptr<SynchronousCompositor::FrameFuture>>;
// This object is per renderer process, so routing_id is unique.
« no previous file with comments | « no previous file | content/browser/android/synchronous_compositor_browser_filter.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698