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

Side by Side Diff: third_party/WebKit/Source/core/layout/LayoutBlock.cpp

Issue 2529293012: Invalidate paint properties on paint offset changes (Closed)
Patch Set: Fix transform underinvalidation, skip several spinvalidation skips Created 4 years 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) 1999 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) 3 * (C) 1999 Antti Koivisto (koivisto@kde.org)
4 * (C) 2007 David Smith (catfish.man@gmail.com) 4 * (C) 2007 David Smith (catfish.man@gmail.com)
5 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. 5 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc.
6 * All rights reserved. 6 * All rights reserved.
7 * Copyright (C) Research In Motion Limited 2010. All rights reserved. 7 * Copyright (C) Research In Motion Limited 2010. All rights reserved.
8 * 8 *
9 * This library is free software; you can redistribute it and/or 9 * This library is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU Library General Public 10 * modify it under the terms of the GNU Library General Public
(...skipping 238 matching lines...) Expand 10 before | Expand all | Expand 10 after
249 249
250 void LayoutBlock::updateFromStyle() { 250 void LayoutBlock::updateFromStyle() {
251 LayoutBox::updateFromStyle(); 251 LayoutBox::updateFromStyle();
252 252
253 bool shouldClipOverflow = 253 bool shouldClipOverflow =
254 !styleRef().isOverflowVisible() && allowsOverflowClip(); 254 !styleRef().isOverflowVisible() && allowsOverflowClip();
255 if (shouldClipOverflow != hasOverflowClip()) { 255 if (shouldClipOverflow != hasOverflowClip()) {
256 if (!shouldClipOverflow) 256 if (!shouldClipOverflow)
257 getScrollableArea()->invalidateAllStickyConstraints(); 257 getScrollableArea()->invalidateAllStickyConstraints();
258 setMayNeedPaintInvalidationSubtree(); 258 setMayNeedPaintInvalidationSubtree();
259 if (RuntimeEnabledFeatures::slimmingPaintInvalidationEnabled()) {
260 // The overflow clip paint property depends on whether overflow clip is
261 // present so we need to update paint properties if this changes.
262 setNeedsPaintPropertyUpdate();
263 }
259 } 264 }
260 setHasOverflowClip(shouldClipOverflow); 265 setHasOverflowClip(shouldClipOverflow);
261 } 266 }
262 267
263 bool LayoutBlock::allowsOverflowClip() const { 268 bool LayoutBlock::allowsOverflowClip() const {
264 // If overflow has been propagated to the viewport, it has no effect here. 269 // If overflow has been propagated to the viewport, it has no effect here.
265 return node() != document().viewportDefiningElement(); 270 return node() != document().viewportDefiningElement();
266 } 271 }
267 272
268 void LayoutBlock::addChildBeforeDescendant(LayoutObject* newChild, 273 void LayoutBlock::addChildBeforeDescendant(LayoutObject* newChild,
(...skipping 1930 matching lines...) Expand 10 before | Expand all | Expand 10 after
2199 } 2204 }
2200 2205
2201 return availableHeight; 2206 return availableHeight;
2202 } 2207 }
2203 2208
2204 bool LayoutBlock::hasDefiniteLogicalHeight() const { 2209 bool LayoutBlock::hasDefiniteLogicalHeight() const {
2205 return availableLogicalHeightForPercentageComputation() != LayoutUnit(-1); 2210 return availableLogicalHeightForPercentageComputation() != LayoutUnit(-1);
2206 } 2211 }
2207 2212
2208 } // namespace blink 2213 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/frame/FrameView.cpp ('k') | third_party/WebKit/Source/core/layout/LayoutBox.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698