| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2011 Apple Inc. All rights reserved. | 2 * Copyright (C) 2011 Apple Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
| 8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
| 9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
| 10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
| (...skipping 141 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 152 } | 152 } |
| 153 | 153 |
| 154 void ScrollingCoordinator::updateLayerPositionConstraint(RenderLayer* layer) | 154 void ScrollingCoordinator::updateLayerPositionConstraint(RenderLayer* layer) |
| 155 { | 155 { |
| 156 ASSERT(layer->backing()); | 156 ASSERT(layer->backing()); |
| 157 RenderLayerBacking* backing = layer->backing(); | 157 RenderLayerBacking* backing = layer->backing(); |
| 158 GraphicsLayer* mainLayer = backing->childForSuperlayers(); | 158 GraphicsLayer* mainLayer = backing->childForSuperlayers(); |
| 159 | 159 |
| 160 // Avoid unnecessary commits | 160 // Avoid unnecessary commits |
| 161 clearPositionConstraintExceptForLayer(backing->ancestorClippingLayer(), main
Layer); | 161 clearPositionConstraintExceptForLayer(backing->ancestorClippingLayer(), main
Layer); |
| 162 clearPositionConstraintExceptForLayer(backing->contentsContainmentLayer(), m
ainLayer); | |
| 163 clearPositionConstraintExceptForLayer(backing->graphicsLayer(), mainLayer); | 162 clearPositionConstraintExceptForLayer(backing->graphicsLayer(), mainLayer); |
| 164 | 163 |
| 165 if (WebLayer* scrollableLayer = scrollingWebLayerForGraphicsLayer(mainLayer)
) | 164 if (WebLayer* scrollableLayer = scrollingWebLayerForGraphicsLayer(mainLayer)
) |
| 166 scrollableLayer->setPositionConstraint(computePositionConstraint(layer))
; | 165 scrollableLayer->setPositionConstraint(computePositionConstraint(layer))
; |
| 167 } | 166 } |
| 168 | 167 |
| 169 void ScrollingCoordinator::willDestroyScrollableArea(ScrollableArea* scrollableA
rea) | 168 void ScrollingCoordinator::willDestroyScrollableArea(ScrollableArea* scrollableA
rea) |
| 170 { | 169 { |
| 171 removeWebScrollbarLayer(scrollableArea, HorizontalScrollbar); | 170 removeWebScrollbarLayer(scrollableArea, HorizontalScrollbar); |
| 172 removeWebScrollbarLayer(scrollableArea, VerticalScrollbar); | 171 removeWebScrollbarLayer(scrollableArea, VerticalScrollbar); |
| (...skipping 461 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 634 stringBuilder.resize(stringBuilder.length() - 2); | 633 stringBuilder.resize(stringBuilder.length() - 2); |
| 635 return stringBuilder.toString(); | 634 return stringBuilder.toString(); |
| 636 } | 635 } |
| 637 | 636 |
| 638 String ScrollingCoordinator::mainThreadScrollingReasonsAsText() const | 637 String ScrollingCoordinator::mainThreadScrollingReasonsAsText() const |
| 639 { | 638 { |
| 640 return mainThreadScrollingReasonsAsText(mainThreadScrollingReasons()); | 639 return mainThreadScrollingReasonsAsText(mainThreadScrollingReasons()); |
| 641 } | 640 } |
| 642 | 641 |
| 643 } // namespace WebCore | 642 } // namespace WebCore |
| OLD | NEW |