1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef ASH_MULTI_PROFILE_UMA_H_
6 #define ASH_MULTI_PROFILE_UMA_H_
8 #include "ash/ash_export.h"
9 #include "base/basictypes.h"
13 // Records UMA statistics for multiprofile actions.
14 // Note: There is also an action to switch profile windows from the
15 // browser frame that is recorded by the "Profile.OpenMethod" metric.
16 class ASH_EXPORT MultiProfileUMA
{
18 // Keep these enums up to date with tools/metrics/histograms/histograms.xml.
20 SESSION_SINGLE_USER_MODE
= 0,
21 SESSION_SIDE_BY_SIDE_MODE
,
22 SESSION_SEPARATE_DESKTOP_MODE
,
26 enum SigninUserAction
{
27 SIGNIN_USER_BY_TRAY
= 0,
28 SIGNIN_USER_BY_BROWSER_FRAME
,
29 NUM_SIGNIN_USER_ACTIONS
32 enum SwitchActiveUserAction
{
33 SWITCH_ACTIVE_USER_BY_TRAY
= 0,
34 SWITCH_ACTIVE_USER_BY_ACCELERATOR
,
35 NUM_SWITCH_ACTIVE_USER_ACTIONS
38 enum TeleportWindowAction
{
39 TELEPORT_WINDOW_DRAG_AND_DROP
= 0,
40 TELEPORT_WINDOW_CAPTION_MENU
,
41 TELEPORT_WINDOW_RETURN_BY_MINIMIZE
,
42 TELEPORT_WINDOW_RETURN_BY_LAUNCHER
,
43 NUM_TELEPORT_WINDOW_ACTIONS
46 // Record the type of user (multi profile) session.
47 static void RecordSessionMode(SessionMode mode
);
49 // Record signing in a new user and what UI path was taken.
50 static void RecordSigninUser(SigninUserAction action
);
52 // Record switching the active user and what UI path was taken.
53 static void RecordSwitchActiveUser(SwitchActiveUserAction action
);
55 // Record the way and how many times a window got teleported to another desk.
56 static void RecordTeleportAction(TeleportWindowAction action
);
59 DISALLOW_IMPLICIT_CONSTRUCTORS(MultiProfileUMA
);
64 #endif // ASH_MULTI_PROFILE_UMA_H_