The beforeText in a text changed event was coming from
the underlying CharSequence, not what was on the screen.
As a result, it was not sent for password fields. Now
we just provide whatever is on the screen, which is
obfuscated to the same degree it is for a user looking
at the screen.
Bug: 75324441
Test: Verified with password field in TalkBack sample app.
Also atest CtsAccessibilityServiceTestCases
Change-Id: Ib7a10313d2f9d0e44d2052e81e47f19967a67bc4
Match upstream Linux kernel support for UAC2 jack detection.
The patch that was included upstream names USB input and
output jack controls by ending them in
"Input Jack" or "Output Jack" respectively.
see 5a222e84945 ('ALSA: usb-audio: UAC2 jack detection') in
git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound.git
Update UsbAlsaJackDetector appropriately.
Test: Verified on a UAC2 device with the above kernel patch,
tinymix -D 1 produced:
...
2 BOOL 1 Headset - Input Jack Off
...
9 BOOL 1 Headset - Output Jack On
With a headset connected, and when the jack was unplugged, Youtube
paused.
Bug: 70632415
Change-Id: I2e5dd48c7a9d174aabbb3a3315496fb30f7a545a
The only allowed format - usage pairs are currently:
* PRIVATE with USAGE_GPU_SAMPLED_IMAGE
* PRIVATE with USAGE_VIDEO_ENCODE
* PRIVATE with USAGE_GPU_SAMPLED_IMAGE | USAGE_VIDEO_ENCODE
* Non-PRIVATE with USAGE_CPU_READ_RARELY
* Non-PRIVATE with USAGE_CPU_READ_OFTEN
This commit enable other cases, ie. PRIVATE with
GRALLOC_USAGE_HW_COMPOSER.
Bug: 77148005
Test: Manually tested it.
Change-Id: I414c25bc62d52a3573461df6cec4d88512509ec4
Add usage stats tracking of screen time. There are two new
events, one for when the device is an interactive state, the
other for when it is non-interactive. Also add a whole new
usage stats API for retrieving aggregated data that is associated
with general events, not particular packages. In this case
it allows you to find the time the device spent interactive
and non-interactive and the count of the transitions in to
each of those states.
Bug: 74404949
Test: atest CtsUsageStatsTestCases:UsageStatsTest\#testInteractiveEvents
Change-Id: Ibe6d55e2aecb0c8519b1358644378ec5c7a4250d
This reverts commit 390b242367.
The reverted change closed the output PrintWriter too early
and led to truncated dumps.
Bug: 74423421
Change-Id: I62902f2aa20be460b6dec42e811b21bf953fcfe3
Test: manual
(cherry picked from commit 1af397c9f7)
Display timeout does not lock the keyguard, which means that
activities won't immediatelly disappear.
We need to factor AOD into to equation to make sure that
the user won't see phantom activities under the status bar
window when the display times out.
Fixes: 73120928
Test: open Settings, wait for display timeout
Test: Wait for display timeout, press power, see launcher
Test: Launch maps, start navigation (FLAG_SHOW_WHEN_LOCKED)
Test: Go to AOD, press power button: activity is occluding keyguard
Test: Press home: bouncer shows up
Test: Unlock: maps goes into pip mode
Test: Go to AOD and back to lock screen: keyguard visible
Test: Expand maps, go to AOD, back to lock screen: maps is occluding keyguard
Change-Id: I9b7512313af2f851d8788ec53de7880bce3bed2c
Record USB data link state in addition to plug & charging state, since
modern USB controller can keep USB data link connected with minimum
current. Device is not acutally charging at those times.
Test: manual
Fixes: 76209292
Change-Id: I0710d547399a631d594488a524682ccc32a25ce6