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

Unified Diff: chrome/browser/tab_contents/tab_contents.cc

Issue 6134011: Add UMA stats for blocking outdated plugins. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 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 | « 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/tab_contents/tab_contents.cc
diff --git a/chrome/browser/tab_contents/tab_contents.cc b/chrome/browser/tab_contents/tab_contents.cc
index 563279e72dd89e51a4664748d8cdefdec71d1c97..32bd04c24bd8d8bf56853b0e051328c728da5e35 100644
--- a/chrome/browser/tab_contents/tab_contents.cc
+++ b/chrome/browser/tab_contents/tab_contents.cc
@@ -251,6 +251,7 @@ class OutdatedPluginInfoBar : public ConfirmInfoBarDelegate {
tab_contents_(tab_contents),
name_(name),
update_url_(update_url) {
+ UserMetrics::RecordAction(UserMetricsAction("OutdatedPluginInfobar.Shown"));
tab_contents->AddInfoBar(this);
}
@@ -280,23 +281,31 @@ class OutdatedPluginInfoBar : public ConfirmInfoBarDelegate {
}
virtual bool Accept() {
+ UserMetrics::RecordAction(
+ UserMetricsAction("OutdatedPluginInfobar.Update"));
tab_contents_->OpenURL(update_url_, GURL(),
NEW_FOREGROUND_TAB, PageTransition::LINK);
return false;
}
virtual bool Cancel() {
+ UserMetrics::RecordAction(
+ UserMetricsAction("OutdatedPluginInfobar.AllowThisTime"));
tab_contents_->render_view_host()->LoadBlockedPlugins();
return true;
}
virtual bool LinkClicked(WindowOpenDisposition disposition) {
+ UserMetrics::RecordAction(
+ UserMetricsAction("OutdatedPluginInfobar.LearnMore"));
// TODO(bauerb): Navigate to a help page explaining why we disabled
// the plugin, once we have one.
return false;
}
virtual void InfoBarClosed() {
+ UserMetrics::RecordAction(
+ UserMetricsAction("OutdatedPluginInfobar.Closed"));
delete this;
}
« 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