Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(89)

Side by Side Diff: Source/core/frame/FrameView.cpp

Issue 1294233004: Subtree caching implementation in blink-core (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 2436 matching lines...) Expand 10 before | Expand all | Expand 10 after
2447 if (LayoutView* view = layoutView()) { 2447 if (LayoutView* view = layoutView()) {
2448 TRACE_EVENT1("devtools.timeline", "UpdateLayerTree", "data", InspectorUp dateLayerTreeEvent::data(m_frame.get())); 2448 TRACE_EVENT1("devtools.timeline", "UpdateLayerTree", "data", InspectorUp dateLayerTreeEvent::data(m_frame.get()));
2449 2449
2450 // This was required for slimming paint v1 but is only temporarily 2450 // This was required for slimming paint v1 but is only temporarily
2451 // needed for slimming paint v2. 2451 // needed for slimming paint v2.
2452 view->compositor()->updateIfNeededRecursive(); 2452 view->compositor()->updateIfNeededRecursive();
2453 scrollContentsIfNeededRecursive(); 2453 scrollContentsIfNeededRecursive();
2454 2454
2455 ASSERT(lifecycle().state() >= DocumentLifecycle::CompositingClean); 2455 ASSERT(lifecycle().state() >= DocumentLifecycle::CompositingClean);
2456 2456
2457 if (phases == AllPhases) { 2457 if (phases == OnlyUpToCompositingCleanPlusScrolling)
2458 invalidateTreeIfNeededRecursive(); 2458 return;
2459 2459
2460 if (view->compositor()->inCompositingMode()) 2460 invalidateTreeIfNeededRecursive();
2461 scrollingCoordinator()->updateAfterCompositingChangeIfNeeded();
2462 2461
2463 updateCompositedSelectionIfNeeded(); 2462 if (view->compositor()->inCompositingMode())
2463 scrollingCoordinator()->updateAfterCompositingChangeIfNeeded();
2464 2464
2465 if (RuntimeEnabledFeatures::slimmingPaintV2Enabled()) { 2465 updateCompositedSelectionIfNeeded();
2466 paintForSlimmingPaintV2();
2467 compositeForSlimmingPaintV2();
2468 }
2469 2466
2470 if (RuntimeEnabledFeatures::frameTimingSupportEnabled()) 2467 if (RuntimeEnabledFeatures::slimmingPaintV2Enabled()) {
2471 updateFrameTimingRequestsIfNeeded(); 2468 paintForSlimmingPaintV2();
2469 if (phases == OnlyUpToPaintForSlimmingPaintV2Clean)
2470 return;
2471 compositeForSlimmingPaintV2();
2472 }
2472 2473
2473 ASSERT(!view->hasPendingSelection()); 2474 if (RuntimeEnabledFeatures::frameTimingSupportEnabled())
2474 ASSERT(lifecycle().state() == DocumentLifecycle::PaintInvalidationCl ean 2475 updateFrameTimingRequestsIfNeeded();
2475 || (RuntimeEnabledFeatures::slimmingPaintV2Enabled() && lifecycl e().state() == DocumentLifecycle::CompositingForSlimmingPaintV2Clean)); 2476
2476 } 2477 ASSERT(!view->hasPendingSelection());
2478 ASSERT(lifecycle().state() == DocumentLifecycle::PaintInvalidationClean
2479 || (RuntimeEnabledFeatures::slimmingPaintV2Enabled() && lifecycle(). state() == DocumentLifecycle::CompositingForSlimmingPaintV2Clean));
2477 } 2480 }
2478 } 2481 }
2479 2482
2480 void FrameView::paintForSlimmingPaintV2() 2483 void FrameView::paintForSlimmingPaintV2()
2481 { 2484 {
2482 ASSERT(RuntimeEnabledFeatures::slimmingPaintV2Enabled()); 2485 ASSERT(RuntimeEnabledFeatures::slimmingPaintV2Enabled());
2483 ASSERT(frame() == page()->mainFrame() || (!frame().tree().parent()->isLocalF rame())); 2486 ASSERT(frame() == page()->mainFrame() || (!frame().tree().parent()->isLocalF rame()));
2484 2487
2485 LayoutView* view = layoutView(); 2488 LayoutView* view = layoutView();
2486 ASSERT(view); 2489 ASSERT(view);
(...skipping 1471 matching lines...) Expand 10 before | Expand all | Expand 10 after
3958 3961
3959 if (!graphicsLayer) 3962 if (!graphicsLayer)
3960 return; 3963 return;
3961 3964
3962 DeprecatedPaintLayer::mapRectToPaintInvalidationBacking(localFrame->contentL ayoutObject(), paintInvalidationContainer, viewRect); 3965 DeprecatedPaintLayer::mapRectToPaintInvalidationBacking(localFrame->contentL ayoutObject(), paintInvalidationContainer, viewRect);
3963 3966
3964 graphicsLayerTimingRequests.add(graphicsLayer, Vector<std::pair<int64_t, Web Rect>>()).storedValue->value.append(std::make_pair(m_frame->frameID(), enclosing IntRect(viewRect))); 3967 graphicsLayerTimingRequests.add(graphicsLayer, Vector<std::pair<int64_t, Web Rect>>()).storedValue->value.append(std::make_pair(m_frame->frameID(), enclosing IntRect(viewRect)));
3965 } 3968 }
3966 3969
3967 } // namespace blink 3970 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698