OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 1998, 1999 Torben Weis <weis@kde.org> | 2 * Copyright (C) 1998, 1999 Torben Weis <weis@kde.org> |
3 * 1999 Lars Knoll <knoll@kde.org> | 3 * 1999 Lars Knoll <knoll@kde.org> |
4 * 1999 Antti Koivisto <koivisto@kde.org> | 4 * 1999 Antti Koivisto <koivisto@kde.org> |
5 * 2000 Dirk Mueller <mueller@kde.org> | 5 * 2000 Dirk Mueller <mueller@kde.org> |
6 * Copyright (C) 2004, 2005, 2006, 2007, 2008 Apple Inc. All rights reserved. | 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008 Apple Inc. All rights reserved. |
7 * (C) 2006 Graham Dennis (graham.dennis@gmail.com) | 7 * (C) 2006 Graham Dennis (graham.dennis@gmail.com) |
8 * (C) 2006 Alexey Proskuryakov (ap@nypop.com) | 8 * (C) 2006 Alexey Proskuryakov (ap@nypop.com) |
9 * Copyright (C) 2009 Google Inc. All rights reserved. | 9 * Copyright (C) 2009 Google Inc. All rights reserved. |
10 * | 10 * |
(...skipping 2520 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2531 updateWidgetPositions(); | 2531 updateWidgetPositions(); |
2532 } | 2532 } |
2533 | 2533 |
2534 void FrameView::updateLayoutAndStyleForPainting() | 2534 void FrameView::updateLayoutAndStyleForPainting() |
2535 { | 2535 { |
2536 // Updating layout can run script, which can tear down the FrameView. | 2536 // Updating layout can run script, which can tear down the FrameView. |
2537 RefPtrWillBeRawPtr<FrameView> protector(this); | 2537 RefPtrWillBeRawPtr<FrameView> protector(this); |
2538 | 2538 |
2539 updateLayoutAndStyleIfNeededRecursive(); | 2539 updateLayoutAndStyleIfNeededRecursive(); |
2540 | 2540 |
2541 updateWidgetPositionsIfNeeded(); | |
2542 | |
2543 RenderView* view = renderView(); | 2541 RenderView* view = renderView(); |
2544 if (view) { | 2542 if (view) { |
2545 TRACE_EVENT_INSTANT1(TRACE_DISABLED_BY_DEFAULT("devtools.timeline"), "Up
dateLayerTree", "frame", m_frame.get()); | 2543 TRACE_EVENT_INSTANT1(TRACE_DISABLED_BY_DEFAULT("devtools.timeline"), "Up
dateLayerTree", "frame", m_frame.get()); |
2546 // FIXME(361045): remove InspectorInstrumentation calls once DevTools Ti
meline migrates to tracing. | 2544 // FIXME(361045): remove InspectorInstrumentation calls once DevTools Ti
meline migrates to tracing. |
2547 InspectorInstrumentation::willUpdateLayerTree(m_frame.get()); | 2545 InspectorInstrumentation::willUpdateLayerTree(m_frame.get()); |
2548 | 2546 |
2549 view->compositor()->updateIfNeededRecursive(); | 2547 view->compositor()->updateIfNeededRecursive(); |
2550 | 2548 |
2551 if (view->compositor()->inCompositingMode() && m_frame->isLocalRoot()) | 2549 if (view->compositor()->inCompositingMode() && m_frame->isLocalRoot()) |
2552 m_frame->page()->scrollingCoordinator()->updateAfterCompositingChang
eIfNeeded(); | 2550 m_frame->page()->scrollingCoordinator()->updateAfterCompositingChang
eIfNeeded(); |
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2604 layout(); | 2602 layout(); |
2605 } | 2603 } |
2606 | 2604 |
2607 // These asserts ensure that parent frames are clean, when child frames fini
shed updating layout and style. | 2605 // These asserts ensure that parent frames are clean, when child frames fini
shed updating layout and style. |
2608 ASSERT(!needsLayout()); | 2606 ASSERT(!needsLayout()); |
2609 ASSERT(!m_frame->document()->hasSVGFilterElementsRequiringLayerUpdate()); | 2607 ASSERT(!m_frame->document()->hasSVGFilterElementsRequiringLayerUpdate()); |
2610 #if ENABLE(ASSERT) | 2608 #if ENABLE(ASSERT) |
2611 m_frame->document()->renderView()->assertRendererLaidOut(); | 2609 m_frame->document()->renderView()->assertRendererLaidOut(); |
2612 #endif | 2610 #endif |
2613 | 2611 |
| 2612 updateWidgetPositionsIfNeeded(); |
2614 } | 2613 } |
2615 | 2614 |
2616 void FrameView::invalidateTreeIfNeededRecursive() | 2615 void FrameView::invalidateTreeIfNeededRecursive() |
2617 { | 2616 { |
2618 // FIXME: We should be more aggressive at cutting tree traversals. | 2617 // FIXME: We should be more aggressive at cutting tree traversals. |
2619 lifecycle().advanceTo(DocumentLifecycle::InPaintInvalidation); | 2618 lifecycle().advanceTo(DocumentLifecycle::InPaintInvalidation); |
2620 invalidateTreeIfNeeded(); | 2619 invalidateTreeIfNeeded(); |
2621 lifecycle().advanceTo(DocumentLifecycle::PaintInvalidationClean); | 2620 lifecycle().advanceTo(DocumentLifecycle::PaintInvalidationClean); |
2622 | 2621 |
2623 for (Frame* child = m_frame->tree().firstChild(); child; child = child->tree
().nextSibling()) { | 2622 for (Frame* child = m_frame->tree().firstChild(); child; child = child->tree
().nextSibling()) { |
(...skipping 1334 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3958 return; | 3957 return; |
3959 | 3958 |
3960 ScrollableArea::setScrollOrigin(origin); | 3959 ScrollableArea::setScrollOrigin(origin); |
3961 | 3960 |
3962 // Update if the scroll origin changes, since our position will be different
if the content size did not change. | 3961 // Update if the scroll origin changes, since our position will be different
if the content size did not change. |
3963 if (updatePositionAtAll && updatePositionSynchronously) | 3962 if (updatePositionAtAll && updatePositionSynchronously) |
3964 updateScrollbars(scrollOffsetDouble()); | 3963 updateScrollbars(scrollOffsetDouble()); |
3965 } | 3964 } |
3966 | 3965 |
3967 } // namespace blink | 3966 } // namespace blink |
OLD | NEW |