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/compositor/browser_compositor_view_private_mac.h

Issue 447113004: Fix crash in GotAcceleratedIOSurfaceFrame (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 4 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/compositor/browser_compositor_view_private_mac.h
diff --git a/content/browser/compositor/browser_compositor_view_private_mac.h b/content/browser/compositor/browser_compositor_view_private_mac.h
index e84fc9c001b1d9917fbd90a045566626d05297bf..e36142ac637892bb02b62a0589bca2151b453b1b 100644
--- a/content/browser/compositor/browser_compositor_view_private_mac.h
+++ b/content/browser/compositor/browser_compositor_view_private_mac.h
@@ -49,7 +49,8 @@ class BrowserCompositorViewMacInternal
private:
// CompositingIOSurfaceLayerClient implementation:
virtual bool AcceleratedLayerShouldAckImmediately() const OVERRIDE;
- virtual void AcceleratedLayerDidDrawFrame(bool succeeded) OVERRIDE;
+ virtual void AcceleratedLayerDidDrawFrame() OVERRIDE;
+ virtual void AcceleratedLayerHitError() OVERRIDE;
void GotAcceleratedCAContextFrame(
CAContextID ca_context_id, gfx::Size pixel_size, float scale_factor);
@@ -57,6 +58,16 @@ private:
void GotAcceleratedIOSurfaceFrame(
IOSurfaceID io_surface_id, gfx::Size pixel_size, float scale_factor);
+ // Remove a layer from the heirarchy and destroy it. Because the accelerated
+ // layer types may be replaced by a layer of the same type, the layer to
+ // destroy is parameterized, and, if it is the current layer, the current
+ // layer is reset.
+ void DestroyCAContextLayer(
+ base::scoped_nsobject<CALayerHost> ca_context_layer);
+ void DestroyIOSurfaceLayer(
+ base::scoped_nsobject<CompositingIOSurfaceLayer> io_surface_layer);
+ void DestroySoftwareLayer();
+
// The client of the BrowserCompositorViewMac that is using this as its
// internals.
BrowserCompositorViewMacClient* client_;

Powered by Google App Engine
This is Rietveld 408576698