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 2420 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
2431 ASSERT(lifecycle().state() >= DocumentLifecycle::CompositingClean); | 2431 ASSERT(lifecycle().state() >= DocumentLifecycle::CompositingClean); |
2432 | 2432 |
2433 if (phases == AllPhases) { | 2433 if (phases == AllPhases) { |
2434 invalidateTreeIfNeededRecursive(); | 2434 invalidateTreeIfNeededRecursive(); |
2435 | 2435 |
2436 if (view->compositor()->inCompositingMode()) | 2436 if (view->compositor()->inCompositingMode()) |
2437 scrollingCoordinator()->updateAfterCompositingChangeIfNeeded(); | 2437 scrollingCoordinator()->updateAfterCompositingChangeIfNeeded(); |
2438 | 2438 |
2439 updateCompositedSelectionIfNeeded(); | 2439 updateCompositedSelectionIfNeeded(); |
2440 | 2440 |
2441 if (RuntimeEnabledFeatures::slimmingPaintV2Enabled()) | |
2442 calculatePaintProperties(); | |
2443 | |
2441 if (RuntimeEnabledFeatures::slimmingPaintSynchronizedPaintingEnabled ()) { | 2444 if (RuntimeEnabledFeatures::slimmingPaintSynchronizedPaintingEnabled ()) { |
2442 synchronizedPaint(interestRect); | 2445 synchronizedPaint(interestRect); |
2443 if (RuntimeEnabledFeatures::slimmingPaintV2Enabled()) | 2446 if (RuntimeEnabledFeatures::slimmingPaintV2Enabled()) |
2444 compositeForSlimmingPaintV2(); | 2447 compositeForSlimmingPaintV2(); |
2445 } | 2448 } |
2446 | 2449 |
2447 if (RuntimeEnabledFeatures::frameTimingSupportEnabled()) | 2450 if (RuntimeEnabledFeatures::frameTimingSupportEnabled()) |
2448 updateFrameTimingRequestsIfNeeded(); | 2451 updateFrameTimingRequestsIfNeeded(); |
2449 | 2452 |
2450 ASSERT(!view->hasPendingSelection()); | 2453 ASSERT(!view->hasPendingSelection()); |
2451 ASSERT(lifecycle().state() == DocumentLifecycle::PaintInvalidationCl ean | 2454 ASSERT(lifecycle().state() == DocumentLifecycle::PaintInvalidationCl ean |
2452 || (RuntimeEnabledFeatures::slimmingPaintV2Enabled() && lifecycl e().state() == DocumentLifecycle::CompositingForSlimmingPaintV2Clean) | 2455 || (RuntimeEnabledFeatures::slimmingPaintV2Enabled() && lifecycl e().state() == DocumentLifecycle::CompositingForSlimmingPaintV2Clean) |
2453 || (RuntimeEnabledFeatures::slimmingPaintSynchronizedPaintingEna bled() && lifecycle().state() == DocumentLifecycle::PaintClean)); | 2456 || (RuntimeEnabledFeatures::slimmingPaintSynchronizedPaintingEna bled() && lifecycle().state() == DocumentLifecycle::PaintClean)); |
2454 } | 2457 } |
2455 } | 2458 } |
2456 } | 2459 } |
2457 | 2460 |
2461 void FrameView::calculatePaintProperties() | |
esprehn
2015/10/01 09:05:07
recalcPaintProperties would match the verbage we u
| |
2462 { | |
2463 ASSERT(RuntimeEnabledFeatures::slimmingPaintV2Enabled()); | |
2464 | |
2465 lifecycle().advanceTo(DocumentLifecycle::InCalcPaintProps); | |
2466 // TODO(pdr): Calculate the paint properties by walking the layout tree. | |
esprehn
2015/10/01 09:00:08
That design doc is very light on details, how will
| |
2467 lifecycle().advanceTo(DocumentLifecycle::CalcPaintPropsClean); | |
2468 } | |
2469 | |
2458 void FrameView::synchronizedPaint(const LayoutRect& interestRect) | 2470 void FrameView::synchronizedPaint(const LayoutRect& interestRect) |
2459 { | 2471 { |
2460 ASSERT(RuntimeEnabledFeatures::slimmingPaintSynchronizedPaintingEnabled()); | 2472 ASSERT(RuntimeEnabledFeatures::slimmingPaintSynchronizedPaintingEnabled()); |
2461 ASSERT(frame() == page()->mainFrame() || (!frame().tree().parent()->isLocalF rame())); | 2473 ASSERT(frame() == page()->mainFrame() || (!frame().tree().parent()->isLocalF rame())); |
2462 | 2474 |
2463 LayoutView* view = layoutView(); | 2475 LayoutView* view = layoutView(); |
2464 ASSERT(view); | 2476 ASSERT(view); |
2465 // TODO(chrishtr): figure out if there can be any GraphicsLayer above this o ne that draws content. | 2477 // TODO(chrishtr): figure out if there can be any GraphicsLayer above this o ne that draws content. |
2466 GraphicsLayer* rootGraphicsLayer = view->layer()->graphicsLayerBacking(); | 2478 GraphicsLayer* rootGraphicsLayer = view->layer()->graphicsLayerBacking(); |
2467 lifecycle().advanceTo(DocumentLifecycle::InPaint); | 2479 lifecycle().advanceTo(DocumentLifecycle::InPaint); |
(...skipping 1465 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
3933 | 3945 |
3934 if (!graphicsLayer) | 3946 if (!graphicsLayer) |
3935 return; | 3947 return; |
3936 | 3948 |
3937 DeprecatedPaintLayer::mapRectToPaintInvalidationBacking(localFrame->contentL ayoutObject(), paintInvalidationContainer, viewRect); | 3949 DeprecatedPaintLayer::mapRectToPaintInvalidationBacking(localFrame->contentL ayoutObject(), paintInvalidationContainer, viewRect); |
3938 | 3950 |
3939 graphicsLayerTimingRequests.add(graphicsLayer, Vector<std::pair<int64_t, Web Rect>>()).storedValue->value.append(std::make_pair(m_frame->frameID(), enclosing IntRect(viewRect))); | 3951 graphicsLayerTimingRequests.add(graphicsLayer, Vector<std::pair<int64_t, Web Rect>>()).storedValue->value.append(std::make_pair(m_frame->frameID(), enclosing IntRect(viewRect))); |
3940 } | 3952 } |
3941 | 3953 |
3942 } // namespace blink | 3954 } // namespace blink |
OLD | NEW |