https://bugs.webkit.org/show_bug.cgi?id=189689
Reviewed by Alex Christensen.
enclosingCompositorFlushingLayers() was added in r76196 but never used. Also use
a SetForScope<>.
* rendering/RenderLayerCompositor.cpp:
(WebCore::RenderLayerCompositor::flushPendingLayerChanges):
(WebCore::RenderLayerCompositor::enclosingCompositorFlushingLayers const): Deleted.
* rendering/RenderLayerCompositor.h:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@236149
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
+2018-09-18 Simon Fraser <simon.fraser@apple.com>
+
+ Remove the unused RenderLayerCompositor::enclosingCompositorFlushingLayers()
+ https://bugs.webkit.org/show_bug.cgi?id=189689
+
+ Reviewed by Alex Christensen.
+
+ enclosingCompositorFlushingLayers() was added in r76196 but never used. Also use
+ a SetForScope<>.
+
+ * rendering/RenderLayerCompositor.cpp:
+ (WebCore::RenderLayerCompositor::flushPendingLayerChanges):
+ (WebCore::RenderLayerCompositor::enclosingCompositorFlushingLayers const): Deleted.
+ * rendering/RenderLayerCompositor.h:
+
2018-09-18 Joseph Pecoraro <pecoraro@apple.com>
[macOS] Frequent leaks seen under WebCore::gpuIDForDisplayMask
2018-09-18 Joseph Pecoraro <pecoraro@apple.com>
[macOS] Frequent leaks seen under WebCore::gpuIDForDisplayMask
AnimationUpdateBlock animationUpdateBlock(&frameView.frame().animation());
ASSERT(!m_flushingLayers);
AnimationUpdateBlock animationUpdateBlock(&frameView.frame().animation());
ASSERT(!m_flushingLayers);
- m_flushingLayers = true;
+ {
+ SetForScope<bool> flushingLayersScope(m_flushingLayers, true);
- if (auto* rootLayer = rootGraphicsLayer()) {
- FloatRect visibleRect = visibleRectForLayerFlushing();
- LOG_WITH_STREAM(Compositing, stream << "\nRenderLayerCompositor " << this << " flushPendingLayerChanges (is root " << isFlushRoot << ") visible rect " << visibleRect);
- rootLayer->flushCompositingState(visibleRect);
+ if (auto* rootLayer = rootGraphicsLayer()) {
+ FloatRect visibleRect = visibleRectForLayerFlushing();
+ LOG_WITH_STREAM(Compositing, stream << "\nRenderLayerCompositor " << this << " flushPendingLayerChanges (is root " << isFlushRoot << ") visible rect " << visibleRect);
+ rootLayer->flushCompositingState(visibleRect);
+ }
+
+ ASSERT(m_flushingLayers);
-
- ASSERT(m_flushingLayers);
- m_flushingLayers = false;
updateScrollCoordinatedLayersAfterFlushIncludingSubframes();
updateScrollCoordinatedLayersAfterFlushIncludingSubframes();
-RenderLayerCompositor* RenderLayerCompositor::enclosingCompositorFlushingLayers() const
-{
- for (auto* frame = &m_renderView.frameView().frame(); frame; frame = frame->tree().parent()) {
- auto* compositor = frame->contentRenderer() ? &frame->contentRenderer()->compositor() : nullptr;
- if (compositor->isFlushingLayers())
- return compositor;
- }
-
- return nullptr;
-}
-
void RenderLayerCompositor::scheduleCompositingLayerUpdate()
{
if (!m_updateCompositingLayersTimer.isActive())
void RenderLayerCompositor::scheduleCompositingLayerUpdate()
{
if (!m_updateCompositingLayersTimer.isActive())
void scheduleLayerFlush(bool canThrottle);
void flushPendingLayerChanges(bool isFlushRoot = true);
void scheduleLayerFlush(bool canThrottle);
void flushPendingLayerChanges(bool isFlushRoot = true);
- // flushPendingLayerChanges() flushes the entire GraphicsLayer tree, which can cross frame boundaries.
- // This call returns the rootmost compositor that is being flushed (including self).
- RenderLayerCompositor* enclosingCompositorFlushingLayers() const;
-
// Called when the GraphicsLayer for the given RenderLayer has flushed changes inside of flushPendingLayerChanges().
void didFlushChangesForLayer(RenderLayer&, const GraphicsLayer*);
// Called when the GraphicsLayer for the given RenderLayer has flushed changes inside of flushPendingLayerChanges().
void didFlushChangesForLayer(RenderLayer&, const GraphicsLayer*);
void notifyIFramesOfCompositingChange();
void notifyIFramesOfCompositingChange();
- bool isFlushingLayers() const { return m_flushingLayers; }
void updateScrollCoordinatedLayersAfterFlushIncludingSubframes();
void updateScrollCoordinatedLayersAfterFlush();
void updateScrollCoordinatedLayersAfterFlushIncludingSubframes();
void updateScrollCoordinatedLayersAfterFlush();