Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "config.h" | 5 #include "config.h" |
| 6 #include "core/rendering/compositing/CompositingReasonFinder.h" | 6 #include "core/rendering/compositing/CompositingReasonFinder.h" |
| 7 | 7 |
| 8 #include "CSSPropertyNames.h" | 8 #include "CSSPropertyNames.h" |
| 9 #include "HTMLNames.h" | 9 #include "HTMLNames.h" |
| 10 #include "core/frame/FrameView.h" | 10 #include "core/frame/FrameView.h" |
| (...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 135 | 135 |
| 136 return renderer->hasFilter(); | 136 return renderer->hasFilter(); |
| 137 } | 137 } |
| 138 | 138 |
| 139 CompositingReasons CompositingReasonFinder::nonStyleDeterminedDirectReasons(cons t RenderLayer* layer, bool* needToRecomputeCompositingRequirements) const | 139 CompositingReasons CompositingReasonFinder::nonStyleDeterminedDirectReasons(cons t RenderLayer* layer, bool* needToRecomputeCompositingRequirements) const |
| 140 { | 140 { |
| 141 CompositingReasons directReasons = CompositingReasonNone; | 141 CompositingReasons directReasons = CompositingReasonNone; |
| 142 RenderObject* renderer = layer->renderer(); | 142 RenderObject* renderer = layer->renderer(); |
| 143 | 143 |
| 144 if (hasOverflowScrollTrigger()) { | 144 if (hasOverflowScrollTrigger()) { |
| 145 if (layer->isUnclippedDescendant()) | 145 // IsUnclippedDescendant is only actually stale during the chicken/egg c ode path. |
| 146 // FIXME: Use ancestorDependentProperties().isUnclippedDescendant to ASS ERT that | |
| 147 // this value isn't stale. | |
|
Ian Vollick
2014/06/01 19:25:36
What would you think of using the disabler here?
abarth-chromium
2014/06/01 19:49:36
There isn't a disabler for this ASSERT because it'
| |
| 148 if (layer->potentiallyStaleIsUnclippedDescendant()) | |
| 146 directReasons |= CompositingReasonOutOfFlowClipping; | 149 directReasons |= CompositingReasonOutOfFlowClipping; |
| 147 | 150 |
| 148 if (layer->scrollParent()) | 151 if (layer->scrollParent()) |
| 149 directReasons |= CompositingReasonOverflowScrollingParent; | 152 directReasons |= CompositingReasonOverflowScrollingParent; |
| 150 | 153 |
| 151 if (layer->needsCompositedScrolling()) | 154 if (layer->needsCompositedScrolling()) |
| 152 directReasons |= CompositingReasonOverflowScrollingTouch; | 155 directReasons |= CompositingReasonOverflowScrollingTouch; |
| 153 } | 156 } |
| 154 | 157 |
| 155 if (requiresCompositingForPositionSticky(renderer, layer)) | 158 if (requiresCompositingForPositionSticky(renderer, layer)) |
| (...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 257 if (viewportConstrainedNotCompositedReason) | 260 if (viewportConstrainedNotCompositedReason) |
| 258 *viewportConstrainedNotCompositedReason = RenderLayer::NotCompos itedForBoundsOutOfView; | 261 *viewportConstrainedNotCompositedReason = RenderLayer::NotCompos itedForBoundsOutOfView; |
| 259 return false; | 262 return false; |
| 260 } | 263 } |
| 261 } | 264 } |
| 262 | 265 |
| 263 return true; | 266 return true; |
| 264 } | 267 } |
| 265 | 268 |
| 266 } | 269 } |
| OLD | NEW |