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

Side by Side Diff: Source/core/rendering/RenderObjectChildList.cpp

Issue 478433002: Avoid RenderObject::paintInvalidationForWholeRenderer() if possible (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: TestExpectations 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « Source/core/rendering/RenderObject.cpp ('k') | Source/core/rendering/RenderProgress.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2009, 2010 Apple Inc. All rights reserved. 2 * Copyright (C) 2009, 2010 Apple Inc. All rights reserved.
3 * Copyright (C) Research In Motion Limited 2010. All rights reserved. 3 * Copyright (C) Research In Motion Limited 2010. All rights reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
66 // FIXME: We should not be allowing paint invalidation during layout. cr bug.com/336250 66 // FIXME: We should not be allowing paint invalidation during layout. cr bug.com/336250
67 AllowPaintInvalidationScope scoper(owner->frameView()); 67 AllowPaintInvalidationScope scoper(owner->frameView());
68 68
69 // So that we'll get the appropriate dirty bit set (either that a normal flow child got yanked or 69 // So that we'll get the appropriate dirty bit set (either that a normal flow child got yanked or
70 // that a positioned child got yanked). We also issue paint invalidation s, so that the area exposed when the child 70 // that a positioned child got yanked). We also issue paint invalidation s, so that the area exposed when the child
71 // disappears gets paint invalidated properly. 71 // disappears gets paint invalidated properly.
72 if (!owner->documentBeingDestroyed() && notifyRenderer && oldChild->ever HadLayout()) { 72 if (!owner->documentBeingDestroyed() && notifyRenderer && oldChild->ever HadLayout()) {
73 oldChild->setNeedsLayoutAndPrefWidthsRecalcAndFullPaintInvalidation( ); 73 oldChild->setNeedsLayoutAndPrefWidthsRecalcAndFullPaintInvalidation( );
74 // We only issue paint invalidations for |oldChild| if we have a Ren derLayer as its visual overflow may not be tracked by its parent. 74 // We only issue paint invalidations for |oldChild| if we have a Ren derLayer as its visual overflow may not be tracked by its parent.
75 if (oldChild->isBody()) 75 if (oldChild->isBody())
76 owner->view()->paintInvalidationForWholeRenderer(); 76 owner->view()->invalidatePaintForWholeRenderer();
77 else 77 else
78 oldChild->paintInvalidationForWholeRenderer(); 78 oldChild->invalidatePaintForWholeRenderer();
79 } 79 }
80 } 80 }
81 81
82 // If we have a line box wrapper, delete it. 82 // If we have a line box wrapper, delete it.
83 if (oldChild->isBox()) 83 if (oldChild->isBox())
84 toRenderBox(oldChild)->deleteLineBoxWrapper(); 84 toRenderBox(oldChild)->deleteLineBoxWrapper();
85 85
86 // If oldChild is the start or end of the selection, then clear the selectio n to 86 // If oldChild is the start or end of the selection, then clear the selectio n to
87 // avoid problems of invalid pointers. 87 // avoid problems of invalid pointers.
88 // FIXME: The FrameSelection should be responsible for this when it 88 // FIXME: The FrameSelection should be responsible for this when it
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after
166 166
167 newChild->setNeedsLayoutAndPrefWidthsRecalcAndFullPaintInvalidation(); 167 newChild->setNeedsLayoutAndPrefWidthsRecalcAndFullPaintInvalidation();
168 if (!owner->normalChildNeedsLayout()) 168 if (!owner->normalChildNeedsLayout())
169 owner->setChildNeedsLayout(); // We may supply the static position for a n absolute positioned child. 169 owner->setChildNeedsLayout(); // We may supply the static position for a n absolute positioned child.
170 170
171 if (AXObjectCache* cache = owner->document().axObjectCache()) 171 if (AXObjectCache* cache = owner->document().axObjectCache())
172 cache->childrenChanged(owner); 172 cache->childrenChanged(owner);
173 } 173 }
174 174
175 } // namespace blink 175 } // namespace blink
OLDNEW
« no previous file with comments | « Source/core/rendering/RenderObject.cpp ('k') | Source/core/rendering/RenderProgress.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698