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

Unified Diff: chrome/browser/ui/views/tabs/tab.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
Index: chrome/browser/ui/views/tabs/tab.cc
diff --git a/chrome/browser/ui/views/tabs/tab.cc b/chrome/browser/ui/views/tabs/tab.cc
index a029c04b97aeea7186e68359aca3ccaf3eae24c7..2ffdb637649a0ae160fef1571625e00f30de891b 100644
--- a/chrome/browser/ui/views/tabs/tab.cc
+++ b/chrome/browser/ui/views/tabs/tab.cc
@@ -11,6 +11,7 @@
#include "base/command_line.h"
#include "base/debug/alias.h"
#include "base/macros.h"
+#include "base/metrics/user_metrics.h"
#include "base/strings/utf_string_conversions.h"
#include "build/build_config.h"
#include "cc/paint/paint_shader.h"
@@ -33,7 +34,6 @@
#include "chrome/grit/theme_resources.h"
#include "components/grit/components_scaled_resources.h"
#include "components/strings/grit/components_strings.h"
-#include "content/public/browser/user_metrics.h"
#include "content/public/common/url_constants.h"
#include "third_party/skia/include/effects/SkGradientShader.h"
#include "third_party/skia/include/pathops/SkPathOps.h"
@@ -765,13 +765,13 @@ void Tab::AnimationEnded(const gfx::Animation* animation) {
void Tab::ButtonPressed(views::Button* sender, const ui::Event& event) {
if (!alert_indicator_button_ || !alert_indicator_button_->visible())
- content::RecordAction(UserMetricsAction("CloseTab_NoAlertIndicator"));
+ base::RecordAction(UserMetricsAction("CloseTab_NoAlertIndicator"));
else if (alert_indicator_button_->enabled())
- content::RecordAction(UserMetricsAction("CloseTab_MuteToggleAvailable"));
+ base::RecordAction(UserMetricsAction("CloseTab_MuteToggleAvailable"));
else if (data_.alert_state == TabAlertState::AUDIO_PLAYING)
- content::RecordAction(UserMetricsAction("CloseTab_AudioIndicator"));
+ base::RecordAction(UserMetricsAction("CloseTab_AudioIndicator"));
else
- content::RecordAction(UserMetricsAction("CloseTab_RecordingIndicator"));
+ base::RecordAction(UserMetricsAction("CloseTab_RecordingIndicator"));
const CloseTabSource source =
(event.type() == ui::ET_MOUSE_RELEASED &&
@@ -962,11 +962,11 @@ bool Tab::OnMousePressed(const ui::MouseEvent& event) {
}
} else if (!IsSelected()) {
controller_->SelectTab(this);
- content::RecordAction(UserMetricsAction("SwitchTab_Click"));
+ base::RecordAction(UserMetricsAction("SwitchTab_Click"));
}
} else if (!IsSelected()) {
controller_->SelectTab(this);
- content::RecordAction(UserMetricsAction("SwitchTab_Click"));
+ base::RecordAction(UserMetricsAction("SwitchTab_Click"));
}
ui::MouseEvent cloned_event(event_in_parent, parent(),
static_cast<View*>(this));
@@ -1015,7 +1015,7 @@ void Tab::OnMouseReleased(const ui::MouseEvent& event) {
if (alert_indicator_button_ && alert_indicator_button_->visible() &&
alert_indicator_button_->bounds().Contains(event.location())) {
- content::RecordAction(UserMetricsAction("TabAlertIndicator_Clicked"));
+ base::RecordAction(UserMetricsAction("TabAlertIndicator_Clicked"));
}
}
}
« no previous file with comments | « chrome/browser/ui/views/tabs/stacked_tab_strip_layout.cc ('k') | chrome/browser/ui/views/tabs/tab_drag_controller.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698