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

Unified Diff: chrome/browser/page_load_metrics/observers/document_write_page_load_metrics_observer.cc

Issue 2140443002: Add DocWrite.Block metric for NavigationToFirstContentfulPaint. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix formatting Created 4 years, 5 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/page_load_metrics/observers/document_write_page_load_metrics_observer.cc
diff --git a/chrome/browser/page_load_metrics/observers/document_write_page_load_metrics_observer.cc b/chrome/browser/page_load_metrics/observers/document_write_page_load_metrics_observer.cc
index 1fb91ed32081c5dfd22c5a8dfea0837e468c54c7..e9b54992953749fd657da326def12b5c6183031a 100644
--- a/chrome/browser/page_load_metrics/observers/document_write_page_load_metrics_observer.cc
+++ b/chrome/browser/page_load_metrics/observers/document_write_page_load_metrics_observer.cc
@@ -103,6 +103,9 @@ const char
[] = "PageLoad.Clients.DocWrite.Evaluator.ParseTiming."
"ParseBlockedOnScriptLoadFromDocumentWrite.Background";
+const char kHistogramDocWriteBlockFirstContentfulPaintImmediate[] =
+ "PageLoad.Clients.DocWrite.Block.PaintTiming."
+ "NavigationToFirstContentfulPaint";
const char kHistogramDocWriteBlockParseStartToFirstContentfulPaintImmediate[] =
"PageLoad.Clients.DocWrite.Block.PaintTiming."
"ParseStartToFirstContentfulPaint";
@@ -311,6 +314,9 @@ void DocumentWritePageLoadMetricsObserver::
if (WasStartedInForegroundOptionalEventInForeground(
timing.first_contentful_paint, info)) {
PAGE_LOAD_HISTOGRAM(
+ internal::kHistogramDocWriteBlockFirstContentfulPaintImmediate,
+ timing.first_contentful_paint.value());
+ PAGE_LOAD_HISTOGRAM(
internal::
kHistogramDocWriteBlockParseStartToFirstContentfulPaintImmediate,
timing.first_contentful_paint.value() - timing.parse_start.value());
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698