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

Unified Diff: chrome/browser/autofill/autofill_metrics.h

Issue 7740070: Add metrics to measure time elapsed between form load and form submission with or without Autofill. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix tests Created 9 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/autofill/autofill_metrics.h
diff --git a/chrome/browser/autofill/autofill_metrics.h b/chrome/browser/autofill/autofill_metrics.h
index 6e316e1a1f98ca3ac9847d71c5c922290ec21278..41d1351e93dc268ef5adb1326447d79905627f53 100644
--- a/chrome/browser/autofill/autofill_metrics.h
+++ b/chrome/browser/autofill/autofill_metrics.h
@@ -12,6 +12,10 @@
#include "base/basictypes.h"
#include "chrome/browser/autofill/field_types.h"
+namespace base {
+class TimeDelta;
+}
+
class AutofillMetrics {
public:
enum InfoBarMetric {
@@ -116,10 +120,6 @@ class AutofillMetrics {
NUM_USER_HAPPINESS_METRICS
};
- // TODO(isherman): Add histograms to measure time elapsed between form load
- // form submission, comparing autofilled and non-autofilled forms. So that we
- // are measuring apples to apples, restrict just to fillable forms.
-
AutofillMetrics();
virtual ~AutofillMetrics();
@@ -144,6 +144,28 @@ class AutofillMetrics {
virtual void LogUserHappinessMetric(UserHappinessMetric metric) const;
+ // This should be called when a form that has been Autofilled is submitted.
+ // |duration| should be the time elapsed between form load and submission.
+ virtual void LogFormFillDurationFromLoadWithAutofill(
+ const base::TimeDelta& duration) const;
+
+ // This should be called when a fillable form that has not been Autofilled is
+ // submitted. |duration| should be the time elapsed between form load and
+ // submission.
+ virtual void LogFormFillDurationFromLoadWithoutAutofill(
+ const base::TimeDelta& duration) const;
+
+ // This should be called when a form that has been Autofilled is submitted.
+ // |duration| should be the time elapsed between the initial form interaction
+ // and submission.
+ virtual void LogFormFillDurationFromInteractionWithAutofill(
+ const base::TimeDelta& duration) const;
+
+ // This should be called when a fillable form that has not been Autofilled is
+ // submitted. |duration| should be the time elapsed between the initial form
+ // interaction and submission.
+ virtual void LogFormFillDurationFromInteractionWithoutAutofill(
+ const base::TimeDelta& duration) const;
// This should be called each time a page containing forms is loaded.
virtual void LogIsAutofillEnabledAtPageLoad(bool enabled) const;

Powered by Google App Engine
This is Rietveld 408576698