Commit Graph

12308 Commits

Author SHA1 Message Date
Aran Ink
ac6e1a3616 Merge "Allow insertion of images from IMEs into notification quick replies." 2019-10-15 16:55:42 +00:00
Aran Ink
fd2bfd34bf Allow insertion of images from IMEs into notification quick replies.
Test: Unit tests pass. Creating a Notification with the Notify app allows access to rich media insertion via gboard, and inserted images show up in the Notify app upon sending.

Bug: 137398133
Change-Id: I65218dfaa083f7c24512430e647d8ca79058dff9
2019-10-14 16:40:30 -04:00
Dianne Hackborn
a063a5ff4e Merge "Add new association time totals to procstats proto." 2019-10-14 19:57:50 +00:00
Roshan Pius
20bce169a5 Merge "Window: Mark SHOW_FOR_ALL_USERS flag as @SystemApi" 2019-10-14 18:03:23 +00:00
TreeHugger Robot
d6fd6f27f5 Merge changes from topic "b/142461756"
* changes:
  Ime target window should control when to hide IME (2/2)
  Ime target window should control when to hide IME (1/2)
2019-10-14 17:04:57 +00:00
Ryan Mitchell
3261dacd65 Merge "Add component-override to sysconfig" 2019-10-14 16:14:28 +00:00
Rubin Xu
289100bb97 Merge "Unify lockscreen changing logic in LockPatternUtils" 2019-10-14 13:47:42 +00:00
Rubin Xu
9af061c608 Merge "Introduce LockscreenCredential" 2019-10-14 13:45:14 +00:00
Ivan Chiang
176b8d09e1 Merge "Allow providers block folders in ACTION_OPEN_DOCUMENT_TREE" 2019-10-14 13:15:30 +00:00
Roshan Pius
a3f89c6882 Window: Mark SHOW_FOR_ALL_USERS flag as @SystemApi
Bug: 142090228
Test: Compiles
Change-Id: I850c7759dc909727f73e40fb6331871a9de25f20
2019-10-12 08:32:44 -07:00
Dianne Hackborn
2c0f822add Add new association time totals to procstats proto.
Bug: 142283699
Test: manual
Change-Id: Id3b88c29ea71753b52138f5c34b56d5b63327030
2019-10-11 16:39:09 -07:00
TreeHugger Robot
dacdce4041 Merge "Resolver: Modernize layout" 2019-10-11 20:01:26 +00:00
Matt Pietal
d50712077b Resolver: Modernize layout
Visually align with the work done for sharesheet

Test: visual inspection
Bug: 139485420
Change-Id: Ie2609eefcd12552bba6c4d749ca1669c8232633c
2019-10-11 14:05:58 -04:00
Andrei-Valentin Onea
e8123dc635 Merge "Add extra compat change overriding methods." am: b389ffe2d9 am: 799a6aa021 am: 283ba38e4d
am: fa9179a361

Change-Id: Ic8b5c8e40b0fda124ba5c4790a1edb169a0035a7
2019-10-11 06:51:36 -07:00
Andrei-Valentin Onea
fa9179a361 Merge "Add extra compat change overriding methods." am: b389ffe2d9 am: 799a6aa021
am: 283ba38e4d

Change-Id: I98c2335df98493a6f13c2b2eec68221aaab86785
2019-10-11 06:39:35 -07:00
Andrei-Valentin Onea
283ba38e4d Merge "Add extra compat change overriding methods." am: b389ffe2d9
am: 799a6aa021

Change-Id: I69ad99a90501707d8c2f7f223ecb2bd76ca0e530
2019-10-11 06:29:22 -07:00
Andrei-Valentin Onea
799a6aa021 Merge "Add extra compat change overriding methods."
am: b389ffe2d9

Change-Id: I77f36a1d9be2d486ca126472f26b5a35739a88cb
2019-10-11 06:22:21 -07:00
Andrei-Valentin Onea
b389ffe2d9 Merge "Add extra compat change overriding methods." 2019-10-11 13:04:08 +00:00
Taran Singh
f1e0887eb8 Ime target window should control when to hide IME (1/2)
Input method frameworks uses focused window and some tricks
to best guestimate IME target. Though it doesn't always know the
actual IME target. e.g. when window has both NOT_FOCUSABLE,
ALT_FOCUSABLE_IM; IMF thinks focued window is IME target but it isn't
the case.

The right thing to do is to call both show(IME), hide(IME) on IME
target.

Bug: 142461756
Bug: 111084606
Test: Manually tested using steps below:
  1. Make sure new insets flag is enabled
  2. Launch any activity which has child window with NOT_FOCUSABLE,
     ALT_FOCUSABLE_IM (e.g. Instagram login screen)
  3. Verify IME can be shown and hidden by this window.

Change-Id: I13f3e04f6f9e1574db9cbb56bdb7817152499d03
2019-10-11 10:09:06 +02:00
Dianne Hackborn
b6174ab931 Merge "Fix/improve procstats association data & printing" 2019-10-10 22:46:43 +00:00
Anna Trostanetski
9969d260ca Merge "ADD owners to compat framework code." am: 2bbb78b5c0 am: 9f074ee036 am: fc581db1d6
am: ca6ea8ffdd

Change-Id: Ia7dd0e8767f9f652b01aaaf319c36e06c41db512
2019-10-10 12:17:44 -07:00
Anna Trostanetski
ca6ea8ffdd Merge "ADD owners to compat framework code." am: 2bbb78b5c0 am: 9f074ee036
am: fc581db1d6

Change-Id: I5f4dd5ff7fdfc4c3c54c6dffd0aff4d7bddeafda
2019-10-10 12:11:11 -07:00
Anna Trostanetski
fc581db1d6 Merge "ADD owners to compat framework code." am: 2bbb78b5c0
am: 9f074ee036

Change-Id: I60d021055eb5df79c71f74c546994670c8cb9b5b
2019-10-10 12:04:06 -07:00
Anna Trostanetski
9f074ee036 Merge "ADD owners to compat framework code."
am: 2bbb78b5c0

Change-Id: I5f89a8141ec57c153fb798cf368f02ecbe2dbbdf
2019-10-10 11:57:04 -07:00
Anna Trostanetski
2bbb78b5c0 Merge "ADD owners to compat framework code." 2019-10-10 18:42:25 +00:00
Anna Trostanetski
3503054191 Merge "Reset app reporting on app launch." am: ccaea274c0 am: 3be71b9df6
am: 7cf4b95c22

Change-Id: I44853dba5d86e799a7b40fdf14d70f8f8b96aaaf
2019-10-10 09:55:27 -07:00
Anna Trostanetski
7cf4b95c22 Merge "Reset app reporting on app launch." am: ccaea274c0
am: 3be71b9df6

Change-Id: I6b7126c8bbbfc010f5b0834b8bc3bd4adb8419d8
2019-10-10 09:49:08 -07:00
Anna Trostanetski
3be71b9df6 Merge "Reset app reporting on app launch."
am: ccaea274c0

Change-Id: I2696f954666aecf22ea8ea77bf5d5ddfaac1461a
2019-10-10 09:42:26 -07:00
Andrei Onea
ea997f222c Add extra compat change overriding methods.
This CL adds two new methods to the IPlatformCompat binder interface for
toggling multiple compat changes at once, and for clearing all the
overrides for a given package name.

Bug: 140367850
Test: http://aosp/1113771
Change-Id: I02d08d76e42da308856408dadc2c8c73c7ff20d1
2019-10-10 17:09:02 +01:00
Anna Trostanetski
f030c7e31b Merge "Reset app reporting on app launch." 2019-10-10 14:56:47 +00:00
atrost
dd7c8025cd ADD owners to compat framework code.
Test: none
Change-Id: I4f395bbceef1face1e9bb85817ce4c78563d06e8
2019-10-10 14:32:57 +01:00
atrost
893f84d353 Reset app reporting on app launch.
Store the reported changes by app and clear the app info on app launch.
This means that changes reported to the system server would be logged
once per app launch instead of once per device boot.

Bug: 138374585
Test: flash device, run test app
Change-Id: I24f5dc125488c6af3164b6503f236bc3a24e6292
Merged-In: I24f5dc125488c6af3164b6503f236bc3a24e6292
2019-10-10 14:09:30 +01:00
atrost
8e437d45df Reset app reporting on app launch.
Store the reported changes by app and clear the app info on app launch.
This means that changes reported to the system server would be logged
once per app launch instead of once per device boot.

Bug: 138374585
Test: flash device, run test app
Change-Id: I24f5dc125488c6af3164b6503f236bc3a24e6292
2019-10-10 13:44:27 +01:00
Dianne Hackborn
442e9fa829 Fix/improve procstats association data & printing
- Fix some bugs in how we compute association data.
- Add in overall time for an association, since you can't
  tell that from the time of its individual sources.
- Fix issues in printing data filtered by package/process
  to better select the data.
- Sort the association and source data by active time, so
  the ones with the most impact are first.
- And sort associations by process so that in apps with
  multiple processes (ahem GmsCore), you can tell what is
  going on for each process separately.

Bug: 142283699
Test: manual
Change-Id: I504bd1a0614fce4f4410f3f53993af5cbd576b79
2019-10-09 17:07:13 -07:00
Tri Vo
46f79cfd4e Merge "KernelWakelockReader: reuse buffer when parsing" am: 89e09c3918 am: cce09fd862 am: 18f8293574
am: 4c3fb4e648

Change-Id: I9183f3519923ae2fe55229d60b3740c27730c126
2019-10-09 16:32:17 -07:00
Tri Vo
4c3fb4e648 Merge "KernelWakelockReader: reuse buffer when parsing" am: 89e09c3918 am: cce09fd862
am: 18f8293574

Change-Id: I3cefb52654d9482c3fcfb059a5de3ddb493b88d6
2019-10-09 16:24:46 -07:00
Tri Vo
18f8293574 Merge "KernelWakelockReader: reuse buffer when parsing" am: 89e09c3918
am: cce09fd862

Change-Id: I1fb06848129620e985084b1efe375232dc6b0d2e
2019-10-09 16:17:37 -07:00
Tri Vo
cce09fd862 Merge "KernelWakelockReader: reuse buffer when parsing"
am: 89e09c3918

Change-Id: I91a9577d618c64239dd7755d710a98ce085c05ba
2019-10-09 16:10:44 -07:00
Ryan Mitchell
4fd8e6f693 Add component-override to sysconfig
The <component-override> tag in sys config allows an OEM to configure
the enabled state of package components.

Eg.
<!-- Disable com.foo.bar.MyActivity -->
<component-override package="com.foo.bar">
    <component class=".MyActivity" enabled="false">
</component-override>

The value in the sys config file overrides the value defined within
the package manifest.

Bug: 135048762
Test: adb shell pm resolve-activity
com.android.settings/com.android.settings.RegulatoryInfoDisplayActivity

Change-Id: I71de31601bb175d4be1cc5996142ef93ca279fc1
2019-10-09 22:46:09 +00:00
Tri Vo
b9ad9a68fb KernelWakelockReader: reuse buffer when parsing
Eliminates 32 kb buffer allocation every time readKernelWakelockStats()
is called.

Test: atest FrameworksCoreTests:KernelWakelockReaderTest
Test: "dumpsys batterystats --checkin" contains kernel wake lock
information.
Change-Id: Ifc7254ab3a5272b056cbc75233aa2dfa8219ea84
2019-10-09 12:40:01 -07:00
Rubin Xu
6232a4cd6a Unify lockscreen changing logic in LockPatternUtils
Bug: 65239740
Test: atest com.android.internal.widget.LockPatternUtilsTest
Test: atest MixedManagedProfileOwnerTest#testResetPasswordWithToken

Change-Id: I86fb770fa77c260d93bbe5324391378018b13988
2019-10-09 14:46:06 +01:00
TreeHugger Robot
88bfff3262 Merge "Fix "Set as Default" error in ResolverActivity" 2019-10-08 19:22:34 +00:00
hh83.kim
1dcb9f3d9d Fix "Set as Default" error in ResolverActivity
Sometimes, we have seen cases that 'set as default' feature does not work properly in ResolverActivity.
This issue occurs when an activity, with 'exported=false' attribute, is included in the list returned by PackageManager.queryIntentActivities().
By the logics in ResolverListController.java#getResolversForIntent(), the activity is removed from the list.
This creates a difference between the list that ResolverActivity sends to PackageManager when calling addPreferredActivity() and
the list PackageManager maintains. Due to the difference, PackageManager does not set preferredActivity requested from ResolverActivity,
which results the showing of ResolverActivity the next time with same action(even though user has set preferred activity).
To handle this issue, we recommend that the removal logic should be removed from getResolversForIntent() method
because it is already handled in ResolverListController.java#filterIneligibleActivities() through ActivityManager.checkComponentPermission() api.
As the result of that, the list which will be delivered to PackageManager is not changed.

Bug: b/135738126
Test: 1. Install 'JustDial' application via Play store
      2. Try below command to launch ResolverActivity
         adb shell am start –a android.intent.action.VOICE_COMMAND
      3. Pick an item on ResolverActivity, then press 'Always' button
      4. Repeat the second step again.
         (you will see ResolverActivity comes again)
(cherry picked from commit 5cdfeeaca5516a6d64fa259f9a4ffd2955f8d2ab)
2019-10-08 10:32:01 -07:00
Rubin Xu
a58125d2a4 Introduce LockscreenCredential
* Wrap credential bytes and type into one single object.

* Update all external APIs dealing with lockscreen passoword
  to use the LockscreenCredential class. Remove existing variants
  that handles pin/password/pattern separately.

* Coerce password quality passed to LockSettingsService into one
  of UNSPECIFIED, PATTERN, NUMERIC or ALPHABETIC (explained below).

* Update all clients & tests to interface with LockscreenCredential.

Note: LockscreenCredential distinguishes between PIN and password
in its public interfaces, this is to pave the way for the next
patch of formally introducing a CREDENTIAL_TYPE_PIN type and
getting rid of the requestedQuality being passed along (whose
sole purpose nowadays is to distinguish between PIN and password)
For now LockscreenCredential still uses the quality value internally
to make that distinction. This does result in a change to what
quality values LockSettingsService receives as part of credential
change: after this CL LSS will only see the quality being
one of UNSPECIFIED, PATTERN, NUMERIC or ALPHABETIC, while it used to
receive other qualities (NUMERIC_COMPLEX, ALPHANUMERIC etc) if device
admin sets a password policy. This shouldn't make any behaviour changes
though, because the new range of values is still sufficient to
distinguish between PIN/Pattern/Password, which is what the consumers
of the stored quality care about.

Bug: 65239740
Test: atest com.android.server.locksettings
Test: atest com.android.server.devicepolicy.DevicePolicyManagerTest
Test: atest com.android.internal.widget.LockPatternUtilsTest
Test: atest com.android.internal.widget.LockscreenCredentialTest
Test: make RunSettingsRoboTests ROBOTEST_FILTER=com.android.settings.password
Test: atest MixedManagedProfileOwnerTest#testResetPasswordWithToken
Test: atest MixedDeviceOwnerTest#testResetPasswordWithToken
Test: manually set an PIN/Pattern/Password; then change to
      PIN/Pattern/Password; finally remove password
Test: manually create a work profile; try unify and ununify work
      challenge.
Test: manually test lockscreen FRP flow (change password via Settings /
DPC)
Change-Id: I04cc04057c96292a7b1b672bff2a09d594ea9b3c
2019-10-08 17:29:47 +01:00
Kevin Chyn
f8ff281ae0 Merge changes from topic "biometric-ui-credentials"
* changes:
  Animate panel to transparent if profile is managed
  17/n: Show credential UI if setDeviceCredentialAllowed(true) and no biometrics
  16/n: Add PIN/Password
  15/n: Allow Auth UI to start in credential UI
  14/n: Animate to device credential UI when lockout occurs
  13/n: persist device credential across configuration changes
  12/n: Add LockPatternView for setDeviceCredentialAllowed(true)
  11/n: Animate panel to full-screen when "Use Password" is pressed
  Removing old confirm device credential logic
2019-10-05 02:37:26 +00:00
Kevin Chyn
86f1b8e335 15/n: Allow Auth UI to start in credential UI
If the user is locked out of biometrics, and
BiometricPrompt#setDeviceCredentialAllowed(true), the user should be
shown the credential UI.

This change gives BiometricService the ability to request SystemUI
to show AuthCredentialView without first showing AuthBiometricView.

Bug: 140127687

Test: atest BiometricServiceTest
Test: atest com.android.systemui.biometrics

Change-Id: Ic26986ba044b7992641676c3d3b99fc1395a45b7
2019-10-04 13:13:12 -07:00
Evan Laird
367b6142a6 Move the people filtering to DeviceConfig flag
This way it can be turned on/off without a recompile, and checking the
flag doesn't require a context

Test: adb shell device_config put systemui notifications_use_people_filtering false && adb shell kill $(pid com.android.systemui)
Bug: 140232781
Change-Id: I8ba5e7809dc58e9493397db8447456601a398540
2019-10-04 15:10:10 -04:00
Tobias Thierer
c4ff79cf8a Merge "Construct default MimeMap lazily rather than eagerly." am: 7dbc7ed543 am: 59d2c429bb am: bfd4e55a48
am: b12401b24d

Change-Id: I85934d988f022491b232525f92997c50e7a4ec39
2019-10-04 10:37:44 -07:00
Tobias Thierer
b12401b24d Merge "Construct default MimeMap lazily rather than eagerly." am: 7dbc7ed543 am: 59d2c429bb
am: bfd4e55a48

Change-Id: I8110cd6d464b5d0b79498cb68cf1267402b139d8
2019-10-04 10:15:24 -07:00
Tobias Thierer
bfd4e55a48 Merge "Construct default MimeMap lazily rather than eagerly." am: 7dbc7ed543
am: 59d2c429bb

Change-Id: I023b1d784814499319c62db7e7647ce14e7c0fba
2019-10-04 10:00:29 -07:00