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

Side by Side Diff: Source/WebCore/rendering/RenderLayerBacking.h

Issue 10342008: Revert 114283 - Avoid using backing store for compositing layers that just need to clip (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/1123/
Patch Set: Created 8 years, 7 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2009, 2010, 2011 Apple Inc. All rights reserved. 2 * Copyright (C) 2009, 2010, 2011 Apple Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after
89 GraphicsLayer* parentForSublayers() const { return m_clippingLayer ? m_clipp ingLayer.get() : m_graphicsLayer.get(); } 89 GraphicsLayer* parentForSublayers() const { return m_clippingLayer ? m_clipp ingLayer.get() : m_graphicsLayer.get(); }
90 GraphicsLayer* childForSuperlayers() const { return m_ancestorClippingLayer ? m_ancestorClippingLayer.get() : m_graphicsLayer.get(); } 90 GraphicsLayer* childForSuperlayers() const { return m_ancestorClippingLayer ? m_ancestorClippingLayer.get() : m_graphicsLayer.get(); }
91 91
92 // RenderLayers with backing normally short-circuit paintLayer() because 92 // RenderLayers with backing normally short-circuit paintLayer() because
93 // their content is rendered via callbacks from GraphicsLayer. However, the document 93 // their content is rendered via callbacks from GraphicsLayer. However, the document
94 // layer is special, because it has a GraphicsLayer to act as a container fo r the GraphicsLayers 94 // layer is special, because it has a GraphicsLayer to act as a container fo r the GraphicsLayers
95 // for descendants, but its contents usually render into the window (in whic h case this returns true). 95 // for descendants, but its contents usually render into the window (in whic h case this returns true).
96 // This returns false for other layers, and when the document layer actually needs to paint into its backing store 96 // This returns false for other layers, and when the document layer actually needs to paint into its backing store
97 // for some reason. 97 // for some reason.
98 bool paintsIntoWindow() const; 98 bool paintsIntoWindow() const;
99
100 // Returns true for a composited layer that has no backing store of its own, so
101 // paints into some ancestor layer.
102 bool paintsIntoCompositedAncestor() const { return !m_requiresOwnBackingStor e; }
103
104 void setRequiresOwnBackingStore(bool flag) { m_requiresOwnBackingStore = fla g; }
105 99
106 void setContentsNeedDisplay(); 100 void setContentsNeedDisplay();
107 // r is in the coordinate space of the layer's render object 101 // r is in the coordinate space of the layer's render object
108 void setContentsNeedDisplayInRect(const IntRect&); 102 void setContentsNeedDisplayInRect(const IntRect&);
109 103
110 // Notification from the renderer that its content changed. 104 // Notification from the renderer that its content changed.
111 void contentChanged(ContentChangeType); 105 void contentChanged(ContentChangeType);
112 106
113 // Interface to start, finish, suspend and resume animations and transitions 107 // Interface to start, finish, suspend and resume animations and transitions
114 bool startTransition(double, CSSPropertyID, const RenderStyle* fromStyle, co nst RenderStyle* toStyle); 108 bool startTransition(double, CSSPropertyID, const RenderStyle* fromStyle, co nst RenderStyle* toStyle);
(...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after
235 229
236 OwnPtr<GraphicsLayer> m_layerForHorizontalScrollbar; 230 OwnPtr<GraphicsLayer> m_layerForHorizontalScrollbar;
237 OwnPtr<GraphicsLayer> m_layerForVerticalScrollbar; 231 OwnPtr<GraphicsLayer> m_layerForVerticalScrollbar;
238 OwnPtr<GraphicsLayer> m_layerForScrollCorner; 232 OwnPtr<GraphicsLayer> m_layerForScrollCorner;
239 233
240 IntRect m_compositedBounds; 234 IntRect m_compositedBounds;
241 235
242 bool m_artificiallyInflatedBounds; // bounds had to be made non-zero to make transform-origin work 236 bool m_artificiallyInflatedBounds; // bounds had to be made non-zero to make transform-origin work
243 bool m_isMainFrameRenderViewLayer; 237 bool m_isMainFrameRenderViewLayer;
244 bool m_usingTiledCacheLayer; 238 bool m_usingTiledCacheLayer;
245 bool m_requiresOwnBackingStore;
246 #if ENABLE(CSS_FILTERS) 239 #if ENABLE(CSS_FILTERS)
247 bool m_canCompositeFilters; 240 bool m_canCompositeFilters;
248 #endif 241 #endif
249 }; 242 };
250 243
251 } // namespace WebCore 244 } // namespace WebCore
252 245
253 #endif // USE(ACCELERATED_COMPOSITING) 246 #endif // USE(ACCELERATED_COMPOSITING)
254 247
255 #endif // RenderLayerBacking_h 248 #endif // RenderLayerBacking_h
OLDNEW
« no previous file with comments | « Source/WebCore/rendering/RenderLayer.cpp ('k') | Source/WebCore/rendering/RenderLayerBacking.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698