Commit Graph

21600 Commits

Author SHA1 Message Date
Jeff DeCew
4e9a31b73c Merge "Use SRC_ATOP instead of SRC_IN for blending the NotificationExpandButton" into sc-dev am: d14c60be51 am: 1dfc1b579b
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15237912

Change-Id: I669a3703f71320fde265c1a4bbc6314d74693830
2021-07-12 20:18:26 +00:00
Jeff DeCew
d14c60be51 Merge "Use SRC_ATOP instead of SRC_IN for blending the NotificationExpandButton" into sc-dev 2021-07-12 19:48:58 +00:00
TreeHugger Robot
26bcb4a503 Merge "Optimize AttributionSource tokens - base" into sc-dev am: 2b90cc827b am: 5e1a6bc443
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15247205

Change-Id: Ida44135b60e19d97c24f79ba2ff4d019d830b908
2021-07-10 02:36:28 +00:00
Svet Ganov
1babd5bf51 Optimize AttributionSource tokens - base
For cases where the attribution soruce doesn't need to be
registered as trusted we are now using a shares static
token since the only purpose of the token in these cases
is for watching the source process dying as opposed to that
and security for registered cases.

bug: 192415943

Test: CtsPermissionTestCases
      CtsPermission2TestCases
      CtsPermission3TestCases
      CtsPermission4TestCases
      CtsPermission5TestCases

Change-Id: I93fde9ca1cacada7929761533dcae11b2736ce1e
2021-07-10 00:24:30 +00:00
Jeff DeCew
8d6f3cc158 Use SRC_ATOP instead of SRC_IN for blending the NotificationExpandButton
Bug: 191969252
Bug: 193157438
Test: check for number of layers in the scene
Change-Id: I65bd80c71b55582347da1559cf707e9d023b7f13
2021-07-09 15:40:31 -04:00
Amith Yamasani
79e00a0659 Merge "Fix FGS notification mismatch" into sc-dev am: 9eed97ac10 am: fa49c40843
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15226946

Change-Id: Ie56b95c04aa2e050da8e5d133683996fd11933fa
2021-07-09 02:15:59 +00:00
Amith Yamasani
9eed97ac10 Merge "Fix FGS notification mismatch" into sc-dev 2021-07-09 01:45:59 +00:00
Chris Li
9faa470aec Merge "Revert "Revert "Not show size compat UI when task is not visible""" into sc-dev am: 50c03ea7ed am: 886a6697a8
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15237129

Change-Id: I724309d4ee1d3bce6830951ff7d5cfe1692af51d
2021-07-08 22:15:06 +00:00
Chris Li
a23a2bb5db Revert "Revert "Not show size compat UI when task is not visible""
This reverts commit 76370b6fe6.

Reason for revert: Fix the merge break in ShellTaskOrganizerTests.java

Fix: 193069342
Test: atest WMShellUnitTests:ShellTaskOrganizerTests
Change-Id: I02c4bddc407eaac0ebb7cd5abb0b394f242d4d6e
2021-07-08 12:09:40 -07:00
Evan Rosky
38fd37d465 Merge "Hook up split-launch to legacy transition system" into sc-v2-dev am: 5b003d97e8 am: 884bd51e3a
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15138014

Change-Id: Iac1f788b593b94b552049575d8e5811c8e75a40c
2021-07-08 18:29:07 +00:00
Evan Rosky
884bd51e3a Merge "Hook up split-launch to legacy transition system" into sc-v2-dev am: 5b003d97e8
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15138014

Change-Id: Iba00e82284ae6e4f6dd4a6ba46c4af4147591be4
2021-07-08 18:11:43 +00:00
Chris Li
e7ed99bfc2 Merge "Remove TaskInfo#topActivityToken usage in size compat for security" into sc-dev 2021-07-08 18:05:40 +00:00
Lee Shombert
f41fe17e76 Merge "PropertyInvalidatedCache unit test" 2021-07-08 16:55:30 +00:00
Evan Rosky
5ca3820ae6 Hook up split-launch to legacy transition system
Part 1 of hooking up stage-split to legacy stuff. This
actually routes the legacy remoteAnimation through shell
in order to gather the dividerbar and interract with the
WindowProcessController

Bug: 192279476
Test: atest WindowOrganizerTests.
      use SPLIT_SELECT to launch 2 apps in split and observe.
Change-Id: I4f8802e6eb33f068fae0e4b3c12942bea76e332b
2021-07-08 09:02:59 -07:00
Ayush Sharma
ff35ae3ea8 Merge "Deprecate no-op flag KEYGUARD_DISABLE_REMOTE_INPUT" 2021-07-08 12:57:04 +00:00
Bernardo Rufino
30ee7900de Merge "Require proper permission for togglePanel()/handleSystemKey()" into sc-dev am: 6b1896db4f am: bef6e7a3c6 am: f9d3c4aa09
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15216476

Change-Id: I2504d56daf5d61019466b93c77749e063f373c59
2021-07-08 10:40:47 +00:00
Bernardo Rufino
f9d3c4aa09 Merge "Require proper permission for togglePanel()/handleSystemKey()" into sc-dev am: 6b1896db4f am: bef6e7a3c6
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15216476

Change-Id: I1e946ebc3fc1909a01dfa110444f27f97415d558
2021-07-08 10:36:03 +00:00
Bernardo Rufino
bef6e7a3c6 Merge "Require proper permission for togglePanel()/handleSystemKey()" into sc-dev am: 6b1896db4f
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15216476

Change-Id: Ibba7df55a23bffb6ff0a28322f242278c9a0d8cf
2021-07-08 10:30:42 +00:00
Leon Jeng
f44dc909e1 Revert "Not show size compat UI when task is not visible" am: 76370b6fe6 am: 15cbad37a8
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15232572

Change-Id: Ifbc94e6e1a32a59933db3dfd4978a1e8e5f8ffdb
2021-07-08 10:12:19 +00:00
Leon Jeng
3378200e36 Revert "Not show size compat UI when task is not visible" am: 76370b6fe6 am: 4e86d92f71
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15232572

Change-Id: Ifc3812e3ce2a0f10c235ab679dcdd21391c90711
2021-07-08 10:11:31 +00:00
Leon Jeng
979db138fe Revert "Not show size compat UI when task is not visible" am: 76370b6fe6
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15232572

Change-Id: Ib61cabd6c4d77d4fa5cd3f64b2272fcd684db153
2021-07-08 10:01:44 +00:00
Leon Jeng
15cbad37a8 Revert "Not show size compat UI when task is not visible" am: 76370b6fe6
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15232572

Change-Id: I1ca637c6e88906c74fe0ac0ab8f883e9fdbdce5a
2021-07-08 10:00:52 +00:00
Leon Jeng
76370b6fe6 Revert "Not show size compat UI when task is not visible"
This reverts commit adb92508c0.

Reason for revert: DroidMonitor-triggered revert due to breakage https://android-build.googleplex.com/builds/quarterdeck?branch=git_master&target=coral-userdebug&lkgb=7530814&lkbb=7530923&fkbb=7530923, bug b/193105445

Bug: 193105445
Change-Id: I697229da6986d6466d7f13872e9ae7a727b80838
2021-07-08 09:48:10 +00:00
Chris Li
4a6fe52bce Merge "Not show size compat UI when task is not visible" into sc-dev am: 927c644bfa am: 2d8b03190d
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15225378

Change-Id: I7ca2c507dc934c52b638261c1707238e80f6e6dd
2021-07-08 07:14:43 +00:00
Chris Li
4693896d4a Merge "Not show size compat UI when task is not visible" into sc-dev am: 927c644bfa am: 1402f79d1b
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15225378

Change-Id: Id2d1a91f49855fc92be3f3eba3b782f3ea3fe4ee
2021-07-08 07:14:11 +00:00
Chris Li
2d8b03190d Merge "Not show size compat UI when task is not visible" into sc-dev am: 927c644bfa
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15225378

Change-Id: Ic80035d84e4e2f2a5471bd4f85cc90ff61cda49f
2021-07-08 07:01:54 +00:00
Chris Li
85a76668fc Merge "Not show size compat UI when task is not visible" into sc-dev am: 927c644bfa
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15225378

Change-Id: I7d380e2e6bb351db4bb5a8a68c236c3444ef2bf1
2021-07-08 07:00:25 +00:00
Chris Li
927c644bfa Merge "Not show size compat UI when task is not visible" into sc-dev 2021-07-08 05:53:15 +00:00
Chris Li
fc422208b1 Merge "Remove TaskInfo#topActivityToken usage in size compat for security" into sc-v2-dev am: 9d86a7b10f am: 7ee5c0b861
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15140327

Change-Id: I2ebd8ee5a949740f7faa6aae66f12e43d9b9cae5
2021-07-08 04:25:13 +00:00
Chris Li
1245aefa49 Remove TaskInfo#topActivityToken usage in size compat for security
Security report shows that this can cause leak token of different app.

Replace the functionality with a callback to the TaskOrganizerController
to restart activity when size compat restart button is clicked.

Bug: 186776724
Test: manually verify the restart button still works
Change-Id: I097b9f02e8435e6765695b9d5a531a4e165bac66
Merged-In: I097b9f02e8435e6765695b9d5a531a4e165bac66
2021-07-07 21:09:24 -07:00
Chris Li
7ee5c0b861 Merge "Remove TaskInfo#topActivityToken usage in size compat for security" into sc-v2-dev am: 9d86a7b10f
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15140327

Change-Id: I055350435baff2260423ab43c0667009034033f7
2021-07-08 04:06:42 +00:00
Christopher Tate
ac4c63c682 Fix FGS notification mismatch
Mistakenly matching against id alone, rather than the (id,tag) tuple,
led to some notifications mistakenly being flagged as FGS-related.

Bug: 191518901
Test: atest CtsAppTestCases:android.app.cts.ServiceTest
Test: atest CtsAppTestCases:android.app.cts.NotificationManagerTest
Test: manual
Change-Id: I11c3993c13ded7859a5a860dcc99728f3db9809f
2021-07-07 19:15:08 -07:00
Chris Li
adb92508c0 Not show size compat UI when task is not visible
Before, when a size compat task was hidden, the size compat UI might
still be showing. Now, remove the UI when the task is no longer visible.

Bug: 193069342
Test: manually verify the size compat button is not showing in recents
Change-Id: Ia17a97f5e7a9af497d8da16b31bb5169dd502d53
2021-07-07 17:46:08 -07:00
Chris Li
ae54032e9a Remove TaskInfo#topActivityToken usage in size compat for security
Security report shows that this can cause leak token of different app.

Replace the functionality with a callback to the TaskOrganizerController
to restart activity when size compat restart button is clicked.

Bug: 186776724
Test: manually verify the restart button still works
Change-Id: I097b9f02e8435e6765695b9d5a531a4e165bac66
2021-07-07 12:50:53 -07:00
Lee Shombert
d28f1e4dec PropertyInvalidatedCache unit test
Bug: 192588767

This change corrects a latent defect related by the new bypass()
method in PropertyInvalidatedCache.  The defect is not current issue
because there are no clients using the bypass() method yet.

PropertyInvalidatedCache is modified to work without sytsem
properties, because test code generaly does not have permission to
read or write properties.  The modification has minimal impact when
there is not testing in progress.  New tests for basic cache
functionality are added.

Bypass statistics are included in 'dumpsys cacheinfo'.  We can
identify caches with a low hit ratio due to wildcard users, and
revisit the logic for those particular caches.

Lint warnings were corrected in the class javadoc comment and by
changing all occurrences of String.format() to
TextUtils.formatSimple().

Test: atest
 * FrameworksCoreTests:PropertyInvalidatedCacheTests

Change-Id: Ie3fbd2f4cb8a38b205a555af389814d7d64dd6bd
2021-07-07 15:23:21 +00:00
Bernardo Rufino
224dd7ca0d Require proper permission for togglePanel()/handleSystemKey()
In S, we're preventing apps from closing notification shade unless they
fall into certain exemptions. The methods togglePanel() and
handleSystemKey() weren't properly protected, so fixing that.

These methods were @hide, only available in the AIDL and their only
usages were inside the system

Introducing @TestApis to be able to verify this in CTS.

Bug: 192946152
Test: atest -d CtsAppTestCases:android.app.cts.StatusBarManagerTest
Test: atest -d CtsLegacyNotification30TestCases:android.app.notification.legacy30.cts.StatusBarManagerApi30Test
Test: 1. adb shell input keyevent KEYCODE_SYSTEM_NAVIGATION_DOWN
      2. Verify status bar expands
      3. adb shell input keyevent KEYCODE_SYSTEM_NAVIGATION_UP
      4. Verify status bar collapses

Change-Id: I925e3570c8d275a1159e4b6912e4628c9528cb61
2021-07-07 11:12:50 +01:00
“Ayush
c9e6ad64dc Deprecate no-op flag KEYGUARD_DISABLE_REMOTE_INPUT
Change-Id: I62f74d14374792ffe9ac470478c27e1f36152bd6
Bug: 191141181
Test: make -j docs
2021-07-07 07:48:30 +00:00
Riddle Hsu
e38a9044d4 Merge "Fix NPE caused by config change on a destroyed activity" into sc-v2-dev am: ee37f56c37 am: c02fca0481
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15183789

Change-Id: I63f8dc5124f8f25ff54e4e7d147e21eb03586b82
2021-07-06 12:33:22 +00:00
Riddle Hsu
c02fca0481 Merge "Fix NPE caused by config change on a destroyed activity" into sc-v2-dev am: ee37f56c37
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15183789

Change-Id: I8dcf3e24e13cb89ed9f48049ee3fa6b9ae172200
2021-07-06 12:15:37 +00:00
Riddle Hsu
ee37f56c37 Merge "Fix NPE caused by config change on a destroyed activity" into sc-v2-dev 2021-07-06 11:59:57 +00:00
Riddle Hsu
9a2454c595 Fix NPE caused by config change on a destroyed activity
The config callback from view root may not know the state
of activity. That may trigger a stale callback, so
 - Restore the null check when getting mSizeConfigurations.
 - Clear the callback if the activity will be removed.

Bug: 192603207
Test: ActivityLifecycleTopResumedStateTests
Change-Id: I17ea8fc2ba994f630d5ad7baa3de298d90a32827
2021-07-06 12:36:39 +08:00
Alex Johnston
f474a43a8d Merge "Update API contract PASSWORD_COMPLEXITY_LOW" into sc-dev am: 61a9cafe83 am: 540cfa9bbf
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15156192

Change-Id: I14eb93f7c0ce76230d791b66ea13d7345db33fc4
2021-07-05 09:27:08 +00:00
Alex Johnston
c426433a3f Merge "Update API contract PASSWORD_COMPLEXITY_LOW" into sc-dev am: 61a9cafe83 am: 67593fe8c2
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15156192

Change-Id: I6aacc470fa693c54e8ef5ca27296b0c23361a523
2021-07-05 09:26:39 +00:00
Alex Johnston
540cfa9bbf Merge "Update API contract PASSWORD_COMPLEXITY_LOW" into sc-dev am: 61a9cafe83
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15156192

Change-Id: I200f120fdacc35b63423c4217de2bb6d09f9d442
2021-07-05 09:09:55 +00:00
Alex Johnston
8a0289694d Merge "Update API contract PASSWORD_COMPLEXITY_LOW" into sc-dev am: 61a9cafe83
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15156192

Change-Id: Ie3f742431813e169c4f66765416cd08f6826058b
2021-07-05 09:08:23 +00:00
Alex Johnston
61a9cafe83 Merge "Update API contract PASSWORD_COMPLEXITY_LOW" into sc-dev 2021-07-05 08:56:48 +00:00
TreeHugger Robot
9f1e578942 Merge "Add OPSTR_RECORD_AUDIO_HOTWORD to TestApi" into sc-dev am: 881dc456c8 am: fd201ca290
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15166612

Change-Id: I12539c925c146b233d34264da930622dff04fe46
2021-07-03 10:58:11 +00:00
TreeHugger Robot
087d6de261 Merge "Add OPSTR_RECORD_AUDIO_HOTWORD to TestApi" into sc-dev am: 881dc456c8 am: 70ad1b76fa
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15166612

Change-Id: I882cac9615758a714e195268f5b34ba2bd8c9856
2021-07-03 10:57:20 +00:00
TreeHugger Robot
57ef687087 Merge "Add OPSTR_RECORD_AUDIO_HOTWORD to TestApi" into sc-dev am: 881dc456c8
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15166612

Change-Id: I5607b1df1e275ac5d3bf0f2a0bf75e67521b1cd6
2021-07-03 10:45:17 +00:00
TreeHugger Robot
fd201ca290 Merge "Add OPSTR_RECORD_AUDIO_HOTWORD to TestApi" into sc-dev am: 881dc456c8
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15166612

Change-Id: I998e849a8e4f005c80bc1f50fbf836471be044c7
2021-07-03 10:44:28 +00:00