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

Unified Diff: cc/trees/proxy_impl.h

Issue 2757373002: Fixing flakiness of TextureLayerChangeInvisibleMailboxTest (Closed)
Patch Set: Invalidate on DidLose Created 3 years, 8 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: cc/trees/proxy_impl.h
diff --git a/cc/trees/proxy_impl.h b/cc/trees/proxy_impl.h
index a0482ea2ff89449a7c97249c20c24457d919c318..fb0e9f7e51d3ef34c1c0a4582cb1b9660b198f48 100644
--- a/cc/trees/proxy_impl.h
+++ b/cc/trees/proxy_impl.h
@@ -34,7 +34,8 @@ class CC_EXPORT ProxyImpl : public NON_EXPORTED_BASE(LayerTreeHostImplClient),
BrowserControlsState current,
bool animate);
void InitializeCompositorFrameSinkOnImpl(
- CompositorFrameSink* compositor_frame_sink);
+ CompositorFrameSink* compositor_frame_sink,
+ base::WeakPtr<ProxyMain> compositor_frame_sink_weak_ptr);
void InitializeMutatorOnImpl(std::unique_ptr<LayerTreeMutator> mutator);
void MainThreadHasStoppedFlingingOnImpl();
void SetInputThrottledUntilCommitOnImpl(bool is_throttled);
@@ -147,6 +148,10 @@ class CC_EXPORT ProxyImpl : public NON_EXPORTED_BASE(LayerTreeHostImplClient),
// Used to post tasks to ProxyMain on the main thread.
base::WeakPtr<ProxyMain> proxy_main_weak_ptr_;
+ // A weak pointer to ProxyMain that is invalidated when CompositorFrameSink is
+ // released.
+ base::WeakPtr<ProxyMain> compositor_frame_sink_weak_ptr_;
+
DISALLOW_COPY_AND_ASSIGN(ProxyImpl);
};

Powered by Google App Engine
This is Rietveld 408576698