diff options
author | Hyunyoung Song <hyunyoungs@google.com> | 2017-06-29 16:42:04 -0700 |
---|---|---|
committer | Hyunyoung Song <hyunyoungs@google.com> | 2017-06-30 13:59:38 -0700 |
commit | 3f5a11f3a517975e108e8ccb749cddef8670fb54 (patch) | |
tree | 64a502de4446778e281274e1717b9bab795f1214 /src/com/android/launcher3/logging | |
parent | 20c55b0e87f6ddb48a1d489ef025c8b68428b8a0 (diff) | |
download | android_packages_apps_Trebuchet-3f5a11f3a517975e108e8ccb749cddef8670fb54.tar.gz android_packages_apps_Trebuchet-3f5a11f3a517975e108e8ccb749cddef8670fb54.tar.bz2 android_packages_apps_Trebuchet-3f5a11f3a517975e108e8ccb749cddef8670fb54.zip |
Add user event logging for page rearrangement and LEFT/RIGHT swipes
1. Call logOverviewRearrange logging call ONLY when the order actually changed
2. Call logActionOnContainer when containers are swiped.
Bug: 32457561
Bug: 32457561
06-30 11:23:04.082 6585 6585 D UserEvent: action:SWIPE direction=LEFT
06-30 11:23:04.082 6585 6585 D UserEvent: Source child:WORKSPACE id=2
06-30 11:23:04.082 6585 6585 D UserEvent: Elapsed container 50436 ms session 50436 ms action 0 ms
06-30 11:23:04.082 6585 6585 D UserEvent: isInLandscapeMode false
06-30 11:23:04.082 6585 6585 D UserEvent: isInMultiWindowMode false
06-30 11:23:08.266 6585 6585 D UserEvent: action:SWIPE direction=LEFT
06-30 11:23:08.266 6585 6585 D UserEvent: Source child:WORKSPACE id=1
06-30 11:23:08.266 6585 6585 D UserEvent: Elapsed container 54620 ms session 54620 ms action 0 ms
06-30 11:23:08.266 6585 6585 D UserEvent: isInLandscapeMode false
06-30 11:23:08.266 6585 6585 D UserEvent: isInMultiWindowMode false
06-30 11:23:10.742 6585 6585 D UserEvent: action:SWIPE direction=LEFT
06-30 11:23:10.742 6585 6585 D UserEvent: Source child:WORKSPACE id=0
06-30 11:23:10.742 6585 6585 D UserEvent: Elapsed container 57096 ms session 57096 ms action 0 ms
06-30 11:23:10.742 6585 6585 D UserEvent: isInLandscapeMode false
06-30 11:23:10.742 6585 6585 D UserEvent: isInMultiWindowMode false
06-30 11:23:17.286 6585 6585 D UserEvent: action:SWIPE direction=RIGHT
06-30 11:23:17.286 6585 6585 D UserEvent: Source child:WORKSPACE id=-1
06-30 11:23:17.286 6585 6585 D UserEvent: Elapsed container 63639 ms session 63639 ms action 0 ms
06-30 11:23:17.286 6585 6585 D UserEvent: isInLandscapeMode false
06-30 11:23:17.286 6585 6585 D UserEvent: isInMultiWindowMode false
06-30 11:23:19.879 6585 6585 D UserEvent: action:SWIPE direction=RIGHT
06-30 11:23:19.879 6585 6585 D UserEvent: Source child:WORKSPACE id=0
06-30 11:23:19.879 6585 6585 D UserEvent: Elapsed container 66233 ms session 66233 ms action 0 ms
06-30 11:23:19.879 6585 6585 D UserEvent: isInLandscapeMode false
06-30 11:23:19.879 6585 6585 D UserEvent: isInMultiWindowMode false
06-30 11:23:23.811 6585 6585 D UserEvent: action:SWIPE direction=RIGHT
06-30 11:23:23.811 6585 6585 D UserEvent: Source child:WORKSPACE id=1
06-30 11:23:23.811 6585 6585 D UserEvent: Elapsed container 70165 ms session 70165 ms action 0 ms
06-30 11:23:23.811 6585 6585 D UserEvent: isInLandscapeMode false
06-30 11:23:23.811 6585 6585 D UserEvent: isInMultiWindowMode false
Change-Id: I11a48ee44aaa87863e76ccf2b46f499c28e96748
Diffstat (limited to 'src/com/android/launcher3/logging')
-rw-r--r-- | src/com/android/launcher3/logging/LoggerUtils.java | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/com/android/launcher3/logging/LoggerUtils.java b/src/com/android/launcher3/logging/LoggerUtils.java index 329b7d561..72a083b9e 100644 --- a/src/com/android/launcher3/logging/LoggerUtils.java +++ b/src/com/android/launcher3/logging/LoggerUtils.java @@ -66,8 +66,14 @@ public class LoggerUtils { } public static String getActionStr(Action action) { + String str = ""; switch (action.type) { - case Action.Type.TOUCH: return getFieldName(action.touch, Action.Touch.class); + case Action.Type.TOUCH: + str += getFieldName(action.touch, Action.Touch.class); + if (action.touch == Action.Touch.SWIPE) { + str += " direction=" + getFieldName(action.dir, Action.Direction.class); + } + return str; case Action.Type.COMMAND: return getFieldName(action.command, Action.Command.class); default: return UNKNOWN; } |