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

Unified Diff: ash/accelerators/accelerator_commands.cc

Issue 78763003: Record user actions for Ash accelerators. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: missing return Created 7 years 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 | ash/accelerators/accelerator_controller.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/accelerators/accelerator_commands.cc
diff --git a/ash/accelerators/accelerator_commands.cc b/ash/accelerators/accelerator_commands.cc
index 003562e2b5d562a68db79a9913ea6d105711a5a2..cfbba26a43995e34573215efa74121b2773e08bc 100644
--- a/ash/accelerators/accelerator_commands.cc
+++ b/ash/accelerators/accelerator_commands.cc
@@ -9,6 +9,7 @@
#include "ash/wm/window_cycle_controller.h"
#include "ash/wm/window_state.h"
#include "ash/wm/window_util.h"
+#include "content/public/browser/user_metrics.h"
namespace ash {
namespace accelerators {
@@ -25,8 +26,8 @@ bool ToggleMinimized() {
wm::WindowState* window_state = wm::GetWindowState(window);
if (!window_state->CanMinimize())
return false;
- ash::Shell::GetInstance()->delegate()->RecordUserMetricsAction(
- ash::UMA_MINIMIZE_PER_KEY);
+ content::RecordAction(
+ content::UserMetricsAction("Accel_Toggle_Minimized"));
window_state->Minimize();
return true;
}
@@ -35,6 +36,8 @@ void ToggleMaximized() {
wm::WindowState* window_state = wm::GetActiveWindowState();
if (!window_state)
return;
+ content::RecordAction(
+ content::UserMetricsAction("Accel_Toggle_Maximized"));
// Get out of fullscreen when in fullscreen mode.
if (window_state->IsFullscreen())
ToggleFullscreen();
« no previous file with comments | « no previous file | ash/accelerators/accelerator_controller.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698