Foldables: Add metric and report usage of the device state over Tron
The device reports the display state and focused app as an action.
The events have
category=ACTION_DISPLAY_FOLD
subtype=0(unfolded) or 1(folded)
package name of focused app.
(include ag/5796847)
The device also reports duration in which state the device is used as
an action.
The events have
category=ACTION_DISPLAY_FOLD
subtype=0x80000000(unfolded) or 0x80000001(folded)
duration is stored in latency field.
(include ag/5781648)
Test: manual - check logcat is output when device is folded/unfolded.
adb logcat -b events | \
fgrep --line-buffered 'sysui_multi_action: [757,1594,'
Bug: 117783763
Change-Id: If7ceafca27c28acf4afa72fe6a9702b9caac669e
5 files changed