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

Unified Diff: tools/android/loading/user_satisfied_lens.py

Issue 2613983002: Rename paint related lifecycle methods of FrameView (Closed)
Patch Set: Rebase on https://codereview.chromium.org/2615713004/ Created 3 years, 11 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tools/android/loading/report_unittest.py ('k') | tools/android/loading/user_satisfied_lens_unittest.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/android/loading/user_satisfied_lens.py
diff --git a/tools/android/loading/user_satisfied_lens.py b/tools/android/loading/user_satisfied_lens.py
index 1e4a485609dae426c281e88d352a5757c97dc734..2e0b4be7e0026056b39d714ad741f5e650bb371d 100644
--- a/tools/android/loading/user_satisfied_lens.py
+++ b/tools/android/loading/user_satisfied_lens.py
@@ -214,7 +214,7 @@ class FirstSignificantPaintLens(_FirstEventLens):
def _CalculateTimes(self, trace):
for cat in self._EVENT_CATEGORIES:
self._CheckCategory(trace.tracing_track, cat)
- sync_paint_times = []
+ paint_tree_times = []
layouts = [] # (layout item count, msec).
for e in trace.tracing_track.GetEvents():
if ('frame' in e.args and
@@ -222,19 +222,17 @@ class FirstSignificantPaintLens(_FirstEventLens):
continue
# If we don't know have a frame id, we assume it applies to all events.
- # TODO(mattcary): is this the right paint event? Check if synchronized
- # paints appear at the same time as the first*Paint events, above.
- if e.Matches('blink', 'FrameView::synchronizedPaint'):
- sync_paint_times.append(e.start_msec)
+ if e.Matches('blink', 'FrameView::paintTree'):
+ paint_tree_times.append(e.start_msec)
if ('counters' in e.args and
self._FIRST_LAYOUT_COUNTER in e.args['counters']):
layouts.append((e.args['counters'][self._FIRST_LAYOUT_COUNTER],
e.start_msec))
assert layouts, 'No layout events'
- assert sync_paint_times,'No sync paint times'
+ assert paint_tree_times,'No paintTree times'
layouts.sort(key=operator.itemgetter(0), reverse=True)
self._satisfied_msec = layouts[0][1]
- self._event_msec = min(t for t in sync_paint_times
+ self._event_msec = min(t for t in paint_tree_times
if t > self._satisfied_msec)
« no previous file with comments | « tools/android/loading/report_unittest.py ('k') | tools/android/loading/user_satisfied_lens_unittest.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698