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

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

Issue 2806863003: [Page Load Metrics] Structure PageLoadTiming. (Closed)
Patch Set: rebase Created 3 years, 8 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
Index: chrome/browser/page_load_metrics/observers/previews_page_load_metrics_observer.cc
diff --git a/chrome/browser/page_load_metrics/observers/previews_page_load_metrics_observer.cc b/chrome/browser/page_load_metrics/observers/previews_page_load_metrics_observer.cc
index be0b59a58f04c89539b47b1149e8fd82b4dfa20a..c30bbebe84993048c8a2ef25a772842ea3be5b32 100644
--- a/chrome/browser/page_load_metrics/observers/previews_page_load_metrics_observer.cc
+++ b/chrome/browser/page_load_metrics/observers/previews_page_load_metrics_observer.cc
@@ -64,56 +64,56 @@ void PreviewsPageLoadMetricsObserver::OnDomContentLoadedEventStart(
const page_load_metrics::PageLoadTiming& timing,
const page_load_metrics::PageLoadExtraInfo& info) {
if (!WasStartedInForegroundOptionalEventInForeground(
- timing.dom_content_loaded_event_start, info)) {
+ timing.document_timing.dom_content_loaded_event_start, info)) {
return;
}
PAGE_LOAD_HISTOGRAM(
internal::kHistogramOfflinePreviewsDOMContentLoadedEventFired,
- timing.dom_content_loaded_event_start.value());
+ timing.document_timing.dom_content_loaded_event_start.value());
}
void PreviewsPageLoadMetricsObserver::OnLoadEventStart(
const page_load_metrics::PageLoadTiming& timing,
const page_load_metrics::PageLoadExtraInfo& info) {
- if (!WasStartedInForegroundOptionalEventInForeground(timing.load_event_start,
- info)) {
+ if (!WasStartedInForegroundOptionalEventInForeground(
+ timing.document_timing.load_event_start, info)) {
return;
}
PAGE_LOAD_HISTOGRAM(internal::kHistogramOfflinePreviewsLoadEventFired,
- timing.load_event_start.value());
+ timing.document_timing.load_event_start.value());
}
void PreviewsPageLoadMetricsObserver::OnFirstLayout(
const page_load_metrics::PageLoadTiming& timing,
const page_load_metrics::PageLoadExtraInfo& info) {
- if (!WasStartedInForegroundOptionalEventInForeground(timing.first_layout,
- info)) {
+ if (!WasStartedInForegroundOptionalEventInForeground(
+ timing.document_timing.first_layout, info)) {
return;
}
PAGE_LOAD_HISTOGRAM(internal::kHistogramOfflinePreviewsFirstLayout,
- timing.first_layout.value());
+ timing.document_timing.first_layout.value());
}
void PreviewsPageLoadMetricsObserver::OnFirstContentfulPaint(
const page_load_metrics::PageLoadTiming& timing,
const page_load_metrics::PageLoadExtraInfo& info) {
if (!WasStartedInForegroundOptionalEventInForeground(
- timing.first_contentful_paint, info)) {
+ timing.paint_timing.first_contentful_paint, info)) {
return;
}
PAGE_LOAD_HISTOGRAM(internal::kHistogramOfflinePreviewsFirstContentfulPaint,
- timing.first_contentful_paint.value());
+ timing.paint_timing.first_contentful_paint.value());
}
void PreviewsPageLoadMetricsObserver::OnParseStart(
const page_load_metrics::PageLoadTiming& timing,
const page_load_metrics::PageLoadExtraInfo& info) {
- if (!WasStartedInForegroundOptionalEventInForeground(timing.parse_start,
- info)) {
+ if (!WasStartedInForegroundOptionalEventInForeground(
+ timing.parse_timing.parse_start, info)) {
return;
}
PAGE_LOAD_HISTOGRAM(internal::kHistogramOfflinePreviewsParseStart,
- timing.parse_start.value());
+ timing.parse_timing.parse_start.value());
}
bool PreviewsPageLoadMetricsObserver::IsOfflinePreview(

Powered by Google App Engine
This is Rietveld 408576698