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

Side by Side Diff: third_party/WebKit/Source/core/page/PageAnimator.cpp

Issue 2227293002: Add RAIL tracing category to Chrome tracing. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: add missing PaintTiming markers Created 4 years, 4 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "core/page/PageAnimator.h" 5 #include "core/page/PageAnimator.h"
6 6
7 #include "core/animation/DocumentAnimations.h" 7 #include "core/animation/DocumentAnimations.h"
8 #include "core/frame/FrameView.h" 8 #include "core/frame/FrameView.h"
9 #include "core/frame/LocalFrame.h" 9 #include "core/frame/LocalFrame.h"
10 #include "core/page/ChromeClient.h" 10 #include "core/page/ChromeClient.h"
(...skipping 27 matching lines...) Expand all
38 clock().updateTime(monotonicAnimationStartTime); 38 clock().updateTime(monotonicAnimationStartTime);
39 39
40 HeapVector<Member<Document>, 32> documents; 40 HeapVector<Member<Document>, 32> documents;
41 for (Frame* frame = m_page->mainFrame(); frame; frame = frame->tree().traver seNext()) { 41 for (Frame* frame = m_page->mainFrame(); frame; frame = frame->tree().traver seNext()) {
42 if (frame->isLocalFrame()) 42 if (frame->isLocalFrame())
43 documents.append(toLocalFrame(frame)->document()); 43 documents.append(toLocalFrame(frame)->document());
44 } 44 }
45 45
46 for (auto& document : documents) { 46 for (auto& document : documents) {
47 ScopedFrameBlamer frameBlamer(document->frame()); 47 ScopedFrameBlamer frameBlamer(document->frame());
48 TRACE_EVENT0("blink", "PageAnimator::serviceScriptedAnimations"); 48 TRACE_EVENT0("blink,rail", "PageAnimator::serviceScriptedAnimations");
49 DocumentAnimations::updateAnimationTimingForAnimationFrame(*document); 49 DocumentAnimations::updateAnimationTimingForAnimationFrame(*document);
50 if (document->view()) { 50 if (document->view()) {
51 if (document->view()->shouldThrottleRendering()) 51 if (document->view()->shouldThrottleRendering())
52 continue; 52 continue;
53 // Disallow throttling in case any script needs to do a synchronous 53 // Disallow throttling in case any script needs to do a synchronous
54 // lifecycle update in other frames which are throttled. 54 // lifecycle update in other frames which are throttled.
55 DocumentLifecycle::DisallowThrottlingScope noThrottlingScope(documen t->lifecycle()); 55 DocumentLifecycle::DisallowThrottlingScope noThrottlingScope(documen t->lifecycle());
56 if (ScrollableArea* scrollableArea = document->view()->getScrollable Area()) 56 if (ScrollableArea* scrollableArea = document->view()->getScrollable Area())
57 scrollableArea->serviceScrollAnimations(monotonicAnimationStartT ime); 57 scrollableArea->serviceScrollAnimations(monotonicAnimationStartT ime);
58 58
(...skipping 21 matching lines...) Expand all
80 } 80 }
81 81
82 void PageAnimator::updateAllLifecyclePhases(LocalFrame& rootFrame) 82 void PageAnimator::updateAllLifecyclePhases(LocalFrame& rootFrame)
83 { 83 {
84 FrameView* view = rootFrame.view(); 84 FrameView* view = rootFrame.view();
85 AutoReset<bool> servicing(&m_updatingLayoutAndStyleForPainting, true); 85 AutoReset<bool> servicing(&m_updatingLayoutAndStyleForPainting, true);
86 view->updateAllLifecyclePhases(); 86 view->updateAllLifecyclePhases();
87 } 87 }
88 88
89 } // namespace blink 89 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698