OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2009, 2010 Apple Inc. All rights reserved. | 2 * Copyright (C) 2009, 2010 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 2289 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2300 if (ScrollingCoordinator* scrollingCoordinator = this->scrollingCoordina
tor()) | 2300 if (ScrollingCoordinator* scrollingCoordinator = this->scrollingCoordina
tor()) |
2301 scrollingCoordinator->setLayerIsContainerForFixedPositionLayers(m_sc
rollLayer.get(), true); | 2301 scrollingCoordinator->setLayerIsContainerForFixedPositionLayers(m_sc
rollLayer.get(), true); |
2302 | 2302 |
2303 // Hook them up | 2303 // Hook them up |
2304 m_overflowControlsHostLayer->addChild(m_containerLayer.get()); | 2304 m_overflowControlsHostLayer->addChild(m_containerLayer.get()); |
2305 m_containerLayer->addChild(m_scrollLayer.get()); | 2305 m_containerLayer->addChild(m_scrollLayer.get()); |
2306 m_scrollLayer->addChild(m_rootContentLayer.get()); | 2306 m_scrollLayer->addChild(m_rootContentLayer.get()); |
2307 | 2307 |
2308 frameViewDidChangeSize(); | 2308 frameViewDidChangeSize(); |
2309 frameViewDidScroll(); | 2309 frameViewDidScroll(); |
| 2310 m_renderView->frameView()->layerForScrollingDidChange(); |
2310 } | 2311 } |
2311 | 2312 |
2312 // Check to see if we have to change the attachment | 2313 // Check to see if we have to change the attachment |
2313 if (m_rootLayerAttachment != RootLayerUnattached) | 2314 if (m_rootLayerAttachment != RootLayerUnattached) |
2314 detachRootLayer(); | 2315 detachRootLayer(); |
2315 | 2316 |
2316 attachRootLayer(expectedAttachment); | 2317 attachRootLayer(expectedAttachment); |
2317 } | 2318 } |
2318 | 2319 |
2319 void RenderLayerCompositor::destroyRootLayer() | 2320 void RenderLayerCompositor::destroyRootLayer() |
(...skipping 30 matching lines...) Expand all Loading... |
2350 | 2351 |
2351 if (m_layerForScrollCorner) { | 2352 if (m_layerForScrollCorner) { |
2352 m_layerForScrollCorner = nullptr; | 2353 m_layerForScrollCorner = nullptr; |
2353 m_renderView->frameView()->invalidateScrollCorner(m_renderView->frameVie
w()->scrollCornerRect()); | 2354 m_renderView->frameView()->invalidateScrollCorner(m_renderView->frameVie
w()->scrollCornerRect()); |
2354 } | 2355 } |
2355 | 2356 |
2356 if (m_overflowControlsHostLayer) { | 2357 if (m_overflowControlsHostLayer) { |
2357 m_overflowControlsHostLayer = nullptr; | 2358 m_overflowControlsHostLayer = nullptr; |
2358 m_containerLayer = nullptr; | 2359 m_containerLayer = nullptr; |
2359 m_scrollLayer = nullptr; | 2360 m_scrollLayer = nullptr; |
| 2361 m_renderView->frameView()->layerForScrollingDidChange(); |
2360 } | 2362 } |
2361 ASSERT(!m_scrollLayer); | 2363 ASSERT(!m_scrollLayer); |
2362 m_rootContentLayer = nullptr; | 2364 m_rootContentLayer = nullptr; |
2363 } | 2365 } |
2364 | 2366 |
2365 void RenderLayerCompositor::attachRootLayer(RootLayerAttachment attachment) | 2367 void RenderLayerCompositor::attachRootLayer(RootLayerAttachment attachment) |
2366 { | 2368 { |
2367 if (!m_rootContentLayer) | 2369 if (!m_rootContentLayer) |
2368 return; | 2370 return; |
2369 | 2371 |
(...skipping 234 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2604 } else if (graphicsLayer == m_scrollLayer.get()) { | 2606 } else if (graphicsLayer == m_scrollLayer.get()) { |
2605 name = "Frame Scrolling Layer"; | 2607 name = "Frame Scrolling Layer"; |
2606 } else { | 2608 } else { |
2607 ASSERT_NOT_REACHED(); | 2609 ASSERT_NOT_REACHED(); |
2608 } | 2610 } |
2609 | 2611 |
2610 return name; | 2612 return name; |
2611 } | 2613 } |
2612 | 2614 |
2613 } // namespace WebCore | 2615 } // namespace WebCore |
OLD | NEW |