| 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 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 84 #include "platform/ScriptForbiddenScope.h" | 84 #include "platform/ScriptForbiddenScope.h" |
| 85 #include "platform/TraceEvent.h" | 85 #include "platform/TraceEvent.h" |
| 86 #include "platform/TracedValue.h" | 86 #include "platform/TracedValue.h" |
| 87 #include "platform/fonts/FontCache.h" | 87 #include "platform/fonts/FontCache.h" |
| 88 #include "platform/geometry/DoubleRect.h" | 88 #include "platform/geometry/DoubleRect.h" |
| 89 #include "platform/geometry/FloatRect.h" | 89 #include "platform/geometry/FloatRect.h" |
| 90 #include "platform/geometry/LayoutRect.h" | 90 #include "platform/geometry/LayoutRect.h" |
| 91 #include "platform/graphics/GraphicsContext.h" | 91 #include "platform/graphics/GraphicsContext.h" |
| 92 #include "platform/graphics/GraphicsLayer.h" | 92 #include "platform/graphics/GraphicsLayer.h" |
| 93 #include "platform/graphics/GraphicsLayerDebugInfo.h" | 93 #include "platform/graphics/GraphicsLayerDebugInfo.h" |
| 94 #include "platform/graphics/GraphicsScreen.h" |
| 94 #include "platform/graphics/paint/CullRect.h" | 95 #include "platform/graphics/paint/CullRect.h" |
| 95 #include "platform/graphics/paint/PaintController.h" | 96 #include "platform/graphics/paint/PaintController.h" |
| 96 #include "platform/scheduler/CancellableTaskFactory.h" | 97 #include "platform/scheduler/CancellableTaskFactory.h" |
| 97 #include "platform/scroll/ScrollAnimatorBase.h" | 98 #include "platform/scroll/ScrollAnimatorBase.h" |
| 98 #include "platform/text/TextStream.h" | 99 #include "platform/text/TextStream.h" |
| 99 #include "public/platform/WebDisplayItemList.h" | 100 #include "public/platform/WebDisplayItemList.h" |
| 100 #include "public/platform/WebFrameScheduler.h" | 101 #include "public/platform/WebFrameScheduler.h" |
| 101 #include "wtf/CurrentTime.h" | 102 #include "wtf/CurrentTime.h" |
| 102 #include "wtf/StdLibExtras.h" | 103 #include "wtf/StdLibExtras.h" |
| 103 #include "wtf/TemporaryChange.h" | 104 #include "wtf/TemporaryChange.h" |
| (...skipping 2254 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2358 if (phases == AllPhases) | 2359 if (phases == AllPhases) |
| 2359 isUpdatingAllLifecyclePhasesScope.emplace(m_isUpdatingAllLifecyclePhases
, true); | 2360 isUpdatingAllLifecyclePhasesScope.emplace(m_isUpdatingAllLifecyclePhases
, true); |
| 2360 | 2361 |
| 2361 // This must be called from the root frame, since it recurses down, not up. | 2362 // This must be called from the root frame, since it recurses down, not up. |
| 2362 // Otherwise the lifecycles of the frames might be out of sync. | 2363 // Otherwise the lifecycles of the frames might be out of sync. |
| 2363 ASSERT(m_frame->isLocalRoot()); | 2364 ASSERT(m_frame->isLocalRoot()); |
| 2364 | 2365 |
| 2365 // Updating layout can run script, which can tear down the FrameView. | 2366 // Updating layout can run script, which can tear down the FrameView. |
| 2366 RefPtrWillBeRawPtr<FrameView> protector(this); | 2367 RefPtrWillBeRawPtr<FrameView> protector(this); |
| 2367 | 2368 |
| 2369 uintptr_t previousId = setCurrentScreenId(Page::screenId(page())); |
| 2370 fflush(stderr); |
| 2371 |
| 2368 updateStyleAndLayoutIfNeededRecursive(); | 2372 updateStyleAndLayoutIfNeededRecursive(); |
| 2369 ASSERT(lifecycle().state() >= DocumentLifecycle::LayoutClean); | 2373 ASSERT(lifecycle().state() >= DocumentLifecycle::LayoutClean); |
| 2370 | 2374 |
| 2371 if (phases == OnlyUpToLayoutClean) { | 2375 if (phases == OnlyUpToLayoutClean) { |
| 2372 updateViewportIntersectionsForSubtree(); | 2376 updateViewportIntersectionsForSubtree(); |
| 2377 setCurrentScreenId(previousId); |
| 2378 fflush(stderr); |
| 2373 return; | 2379 return; |
| 2374 } | 2380 } |
| 2375 | 2381 |
| 2376 if (LayoutView* view = layoutView()) { | 2382 if (LayoutView* view = layoutView()) { |
| 2377 { | 2383 { |
| 2378 TRACE_EVENT1("devtools.timeline", "UpdateLayerTree", "data", Inspect
orUpdateLayerTreeEvent::data(m_frame.get())); | 2384 TRACE_EVENT1("devtools.timeline", "UpdateLayerTree", "data", Inspect
orUpdateLayerTreeEvent::data(m_frame.get())); |
| 2379 | 2385 |
| 2380 // This was required for slimming paint v1 but is only temporarily | 2386 // This was required for slimming paint v1 but is only temporarily |
| 2381 // needed for slimming paint v2. | 2387 // needed for slimming paint v2. |
| 2382 view->compositor()->updateIfNeededRecursive(); | 2388 view->compositor()->updateIfNeededRecursive(); |
| (...skipping 24 matching lines...) Expand all Loading... |
| 2407 if (RuntimeEnabledFeatures::slimmingPaintV2Enabled()) | 2413 if (RuntimeEnabledFeatures::slimmingPaintV2Enabled()) |
| 2408 pushPaintArtifactToCompositor(); | 2414 pushPaintArtifactToCompositor(); |
| 2409 | 2415 |
| 2410 ASSERT(!view->hasPendingSelection()); | 2416 ASSERT(!view->hasPendingSelection()); |
| 2411 ASSERT(lifecycle().state() == DocumentLifecycle::PaintInvalidationCl
ean | 2417 ASSERT(lifecycle().state() == DocumentLifecycle::PaintInvalidationCl
ean |
| 2412 || (RuntimeEnabledFeatures::slimmingPaintSynchronizedPaintingEna
bled() && lifecycle().state() == DocumentLifecycle::PaintClean)); | 2418 || (RuntimeEnabledFeatures::slimmingPaintSynchronizedPaintingEna
bled() && lifecycle().state() == DocumentLifecycle::PaintClean)); |
| 2413 } | 2419 } |
| 2414 } | 2420 } |
| 2415 | 2421 |
| 2416 updateViewportIntersectionsForSubtree(); | 2422 updateViewportIntersectionsForSubtree(); |
| 2423 setCurrentScreenId(previousId); |
| 2424 fflush(stderr); |
| 2417 } | 2425 } |
| 2418 | 2426 |
| 2419 void FrameView::updatePaintProperties() | 2427 void FrameView::updatePaintProperties() |
| 2420 { | 2428 { |
| 2421 ASSERT(RuntimeEnabledFeatures::slimmingPaintV2Enabled()); | 2429 ASSERT(RuntimeEnabledFeatures::slimmingPaintV2Enabled()); |
| 2422 | 2430 |
| 2423 forAllNonThrottledFrameViews([](FrameView& frameView) { frameView.lifecycle(
).advanceTo(DocumentLifecycle::InUpdatePaintProperties); }); | 2431 forAllNonThrottledFrameViews([](FrameView& frameView) { frameView.lifecycle(
).advanceTo(DocumentLifecycle::InUpdatePaintProperties); }); |
| 2424 PaintPropertyTreeBuilder().buildPropertyTrees(*this); | 2432 PaintPropertyTreeBuilder().buildPropertyTrees(*this); |
| 2425 forAllNonThrottledFrameViews([](FrameView& frameView) { frameView.lifecycle(
).advanceTo(DocumentLifecycle::UpdatePaintPropertiesClean); }); | 2433 forAllNonThrottledFrameViews([](FrameView& frameView) { frameView.lifecycle(
).advanceTo(DocumentLifecycle::UpdatePaintPropertiesClean); }); |
| 2426 } | 2434 } |
| (...skipping 1581 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4008 return m_hiddenForThrottling && m_crossOriginForThrottling; | 4016 return m_hiddenForThrottling && m_crossOriginForThrottling; |
| 4009 } | 4017 } |
| 4010 | 4018 |
| 4011 LayoutBox& FrameView::boxForScrollControlPaintInvalidation() const | 4019 LayoutBox& FrameView::boxForScrollControlPaintInvalidation() const |
| 4012 { | 4020 { |
| 4013 ASSERT(layoutView()); | 4021 ASSERT(layoutView()); |
| 4014 return *layoutView(); | 4022 return *layoutView(); |
| 4015 } | 4023 } |
| 4016 | 4024 |
| 4017 } // namespace blink | 4025 } // namespace blink |
| OLD | NEW |