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

Unified Diff: chrome/browser/interstitials/chrome_metrics_helper.cc

Issue 1365733005: Split captive portal metrics out of SSLErrorClassification (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Compiler error fix possibly for realsies 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/interstitials/chrome_metrics_helper.cc
diff --git a/chrome/browser/interstitials/chrome_metrics_helper.cc b/chrome/browser/interstitials/chrome_metrics_helper.cc
index c886e448d1dea7fc45755200c84c92080a056990..abda1aa30b948165a71ea6175f0ff2b65dc9d58a 100644
--- a/chrome/browser/interstitials/chrome_metrics_helper.cc
+++ b/chrome/browser/interstitials/chrome_metrics_helper.cc
@@ -7,6 +7,7 @@
#include "chrome/browser/browser_process.h"
#include "chrome/browser/history/history_service_factory.h"
#include "chrome/browser/profiles/profile.h"
+#include "chrome/browser/ssl/captive_portal_metrics_recorder.h"
#include "components/history/core/browser/history_service.h"
#include "components/rappor/rappor_service.h"
#include "content/public/browser/web_contents.h"
@@ -35,6 +36,18 @@ ChromeMetricsHelper::ChromeMetricsHelper(
ChromeMetricsHelper::~ChromeMetricsHelper() {}
+void ChromeMetricsHelper::StartRecordingCaptivePortalMetrics(bool overridable) {
+ captive_portal_recorder_.reset(
+ new CaptivePortalMetricsRecorder(web_contents_, overridable));
+}
+
+void ChromeMetricsHelper::RecordExtraShutdownMetrics() {
+ // The captive portal metrics should be recorded when the interstitial is
+ // closing (or destructing).
+ if (captive_portal_recorder_)
+ captive_portal_recorder_->RecordCaptivePortalUMAStatistics();
+}
+
void ChromeMetricsHelper::RecordExtraUserDecisionMetrics(
security_interstitials::MetricsHelper::Decision decision) {
#if defined(ENABLE_EXTENSIONS)
« no previous file with comments | « chrome/browser/interstitials/chrome_metrics_helper.h ('k') | chrome/browser/interstitials/security_interstitial_page.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698