| 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 "core/frame/FrameView.h" | 8 #include "core/frame/FrameView.h" |
| 9 #include "core/frame/Settings.h" | 9 #include "core/frame/Settings.h" |
| 10 #include "core/page/Page.h" | 10 #include "core/page/Page.h" |
| (...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 119 | 119 |
| 120 CompositingReasons CompositingReasonFinder::nonStyleDeterminedDirectReasons(cons
t RenderLayer* layer) const | 120 CompositingReasons CompositingReasonFinder::nonStyleDeterminedDirectReasons(cons
t RenderLayer* layer) const |
| 121 { | 121 { |
| 122 CompositingReasons directReasons = CompositingReasonNone; | 122 CompositingReasons directReasons = CompositingReasonNone; |
| 123 RenderObject* renderer = layer->renderer(); | 123 RenderObject* renderer = layer->renderer(); |
| 124 | 124 |
| 125 if (hasOverflowScrollTrigger()) { | 125 if (hasOverflowScrollTrigger()) { |
| 126 // IsUnclippedDescendant is only actually stale during the chicken/egg c
ode path. | 126 // IsUnclippedDescendant is only actually stale during the chicken/egg c
ode path. |
| 127 // FIXME: Use compositingInputs().isUnclippedDescendant to ASSERT that | 127 // FIXME: Use compositingInputs().isUnclippedDescendant to ASSERT that |
| 128 // this value isn't stale. | 128 // this value isn't stale. |
| 129 if (layer->potentiallyStaleIsUnclippedDescendant()) | 129 if (layer->compositingInputs().isUnclippedDescendant) |
| 130 directReasons |= CompositingReasonOutOfFlowClipping; | 130 directReasons |= CompositingReasonOutOfFlowClipping; |
| 131 | 131 |
| 132 if (layer->scrollParent()) | 132 if (layer->scrollParent()) |
| 133 directReasons |= CompositingReasonOverflowScrollingParent; | 133 directReasons |= CompositingReasonOverflowScrollingParent; |
| 134 | 134 |
| 135 if (layer->needsCompositedScrolling()) | 135 if (layer->needsCompositedScrolling()) |
| 136 directReasons |= CompositingReasonOverflowScrollingTouch; | 136 directReasons |= CompositingReasonOverflowScrollingTouch; |
| 137 } | 137 } |
| 138 | 138 |
| 139 if (requiresCompositingForPositionFixed(renderer, layer, 0)) | 139 if (requiresCompositingForPositionFixed(renderer, layer, 0)) |
| (...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 227 if (viewportConstrainedNotCompositedReason) | 227 if (viewportConstrainedNotCompositedReason) |
| 228 *viewportConstrainedNotCompositedReason = RenderLayer::NotCompos
itedForBoundsOutOfView; | 228 *viewportConstrainedNotCompositedReason = RenderLayer::NotCompos
itedForBoundsOutOfView; |
| 229 return false; | 229 return false; |
| 230 } | 230 } |
| 231 } | 231 } |
| 232 | 232 |
| 233 return true; | 233 return true; |
| 234 } | 234 } |
| 235 | 235 |
| 236 } | 236 } |
| OLD | NEW |