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

Unified Diff: components/zoom/page_zoom.cc

Issue 2771233002: Remove the wrapper functions content::RecordAction et al (Closed)
Patch Set: Rebased Created 3 years, 9 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 | « components/sync_sessions/sync_sessions_metrics.cc ('k') | content/browser/BUILD.gn » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/zoom/page_zoom.cc
diff --git a/components/zoom/page_zoom.cc b/components/zoom/page_zoom.cc
index bbd1a745ea725bd3d5ba690fc8e92aac1904699a..98dea1e6b2b4434a2d62d02f471ca13483554bff 100644
--- a/components/zoom/page_zoom.cc
+++ b/components/zoom/page_zoom.cc
@@ -9,12 +9,12 @@
#include <algorithm>
#include <cmath>
+#include "base/metrics/user_metrics.h"
#include "components/prefs/pref_service.h"
#include "components/zoom/page_zoom_constants.h"
#include "components/zoom/zoom_controller.h"
#include "content/public/browser/host_zoom_map.h"
#include "content/public/browser/render_view_host.h"
-#include "content/public/browser/user_metrics.h"
#include "content/public/browser/web_contents.h"
#include "content/public/common/page_zoom.h"
#include "content/public/common/renderer_preferences.h"
@@ -86,7 +86,7 @@ void PageZoom::Zoom(content::WebContents* web_contents,
if (zoom == content::PAGE_ZOOM_RESET) {
zoom_controller->SetZoomLevel(default_zoom_level);
web_contents->SetPageScale(1.f);
- content::RecordAction(UserMetricsAction("ZoomNormal"));
+ base::RecordAction(UserMetricsAction("ZoomNormal"));
return;
}
@@ -104,11 +104,11 @@ void PageZoom::Zoom(content::WebContents* web_contents,
continue;
if (zoom_level < current_zoom_level) {
zoom_controller->SetZoomLevel(zoom_level);
- content::RecordAction(UserMetricsAction("ZoomMinus"));
+ base::RecordAction(UserMetricsAction("ZoomMinus"));
return;
}
}
- content::RecordAction(UserMetricsAction("ZoomMinus_AtMinimum"));
+ base::RecordAction(UserMetricsAction("ZoomMinus_AtMinimum"));
} else {
// Iterate through the zoom levels in normal order to find the next
// higher level based on the current zoom level for this page.
@@ -119,11 +119,11 @@ void PageZoom::Zoom(content::WebContents* web_contents,
continue;
if (zoom_level > current_zoom_level) {
zoom_controller->SetZoomLevel(zoom_level);
- content::RecordAction(UserMetricsAction("ZoomPlus"));
+ base::RecordAction(UserMetricsAction("ZoomPlus"));
return;
}
}
- content::RecordAction(UserMetricsAction("ZoomPlus_AtMaximum"));
+ base::RecordAction(UserMetricsAction("ZoomPlus_AtMaximum"));
}
}
« no previous file with comments | « components/sync_sessions/sync_sessions_metrics.cc ('k') | content/browser/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698