Commit Graph

17820 Commits

Author SHA1 Message Date
Ryan Mitchell
3c0b8da2c1 Merge changes from topic "invalidate_idmap" into rvc-dev am: 6cb79cdfb7 am: 7cfbff64eb
Change-Id: Ief1e732e3b18738c5c0f62f2fe8c47f66169c85b
2020-04-10 16:17:25 +00:00
Ryan Mitchell
6cb79cdfb7 Merge changes from topic "invalidate_idmap" into rvc-dev
* changes:
  Fix InstallOverlayTests fail to install overlay
  Test that upgrading target apk invalidates idmap
  Invalidate idmap when target updates
2020-04-10 15:50:15 +00:00
Darryl Johnson
cb5b73717f Merge "Temporal fix of the Android Auto orientation chaniging on phone's orientation change." into rvc-dev am: 6c6d81a121 am: 2f8bead66d
Change-Id: I26433dca499ff0731ee713d050606a0da1437ec5
2020-04-10 14:43:49 +00:00
Darryl Johnson
6c6d81a121 Merge "Temporal fix of the Android Auto orientation chaniging on phone's orientation change." into rvc-dev 2020-04-10 14:07:36 +00:00
Hui Yu
1552de74b7 Merge "Document process capability in AppOps.md." into rvc-dev am: d0139b01dd am: 096aafc8d2
Change-Id: I40077ccb1687e484b6a8eda78d680c0d3e060b42
2020-04-09 20:12:04 +00:00
Hui Yu
d0139b01dd Merge "Document process capability in AppOps.md." into rvc-dev 2020-04-09 19:42:09 +00:00
Selim Cinek
671d3aed9a Merge changes I7dc8f5fd,Ia5262ca7 into rvc-dev am: 279238f3c2
Change-Id: I48ea415cdf09b483b1de6009c7f4802969239084
2020-04-09 17:58:00 +00:00
Selim Cinek
279238f3c2 Merge changes I7dc8f5fd,Ia5262ca7 into rvc-dev
* changes:
  Fixed the transformation of min priority notifications
  Always use the largeIcon as avatar replacement
2020-04-09 17:55:27 +00:00
Pavel Grafov
942034fa4a Merge "Copy the remaining policies on migration." into rvc-dev am: c4adf5e87b
Change-Id: I5b21baef6cce593f42033b690bd3ea053d267fbb
2020-04-09 17:39:00 +00:00
Pavel Grafov
57c69d1e30 Copy the remaining policies on migration.
* accountTypesWithManagementDisabled
* disableScreenCapture

For security logging nothing has to be done since the state is
stored in a system property, just changed it so that the logging
will be started after the migration and only events for the
right user are logged.

Also removed the todo about hardening for power cut case, the
risk of additional complexity sees to outweight the benefit.

Bug: 149075700
Test: atest DevicePolicyManagerServiceMigrationTest
Change-Id: I3a58325f2d6f415e51998c5096c5fc123d26602d
2020-04-09 15:47:18 +01:00
Charles Chen
aac2a05518 Merge "Fix WindowContext leak" into rvc-dev am: 5c082c998f
Change-Id: I6683cb8b7dcf4aa57ff7f6d681fa41d88156abc6
2020-04-09 07:52:44 +00:00
Yvonne Jiang
c20ac39f27 Merge "Fix secondary lock screen implementation such that DevicePolicyKeyguardService calls are made on the main (UI) thread." into rvc-dev am: eb31eb5bae
Change-Id: I688c2644161c8c9aa0b375430dc67875efa1a10f
2020-04-09 07:50:45 +00:00
Charles Chen
5c082c998f Merge "Fix WindowContext leak" into rvc-dev 2020-04-09 07:39:29 +00:00
Yvonne Jiang
eb31eb5bae Merge "Fix secondary lock screen implementation such that DevicePolicyKeyguardService calls are made on the main (UI) thread." into rvc-dev 2020-04-09 07:26:48 +00:00
TreeHugger Robot
0e8486557c Merge "Make OPSTR_MANAGE_EXTERNAL_STORAGE test API" into rvc-dev am: ffce5f2b7c
Change-Id: I029689affca7a450379110651fb54f18723f10e8
2020-04-08 23:24:41 +00:00
TreeHugger Robot
ffce5f2b7c Merge "Make OPSTR_MANAGE_EXTERNAL_STORAGE test API" into rvc-dev 2020-04-08 23:21:23 +00:00
Hui Yu
3b1110b170 Document process capability in AppOps.md.
Bug: 153581565
Test: NA
Change-Id: I3c42cf5022c0e7e5b008570fdc656260bb13475f
2020-04-08 16:12:21 -07:00
Makoto Onuki
a9b85d8d08 Merge "Context.getSystemService() shouldn't return null..." into rvc-dev am: 52c24bdedf
Change-Id: Ic448d3fd5fd0a4c58c24bc4baf8b7679571ab2c9
2020-04-08 19:43:36 +00:00
Makoto Onuki
52c24bdedf Merge "Context.getSystemService() shouldn't return null..." into rvc-dev 2020-04-08 19:33:30 +00:00
shafik
2a20790621 Make OPSTR_MANAGE_EXTERNAL_STORAGE test API
We need that to enable CTS for Environment#isExternalStorageManager API

Test: build
Bug: 152478019
Change-Id: I8c24c08991558629c83a25b4bed89c817723d732
2020-04-08 17:49:47 +01:00
Charles Chen
4bff5be1a9 Fix WindowContext leak
The root causes of this issue are:
  1. WindowTokenClient#attachContext makes WindowTokenClient has strong
     reference to WindowContext, which leads to WindowContext cannot be
     GC'd.
  2. WMS#removeWindowToken needs MANAGE_APP_TOKEN permission which
     normal apps don't hold.

This CL does following things:
  1. Use weak reference instead on WindowTokenClient#mContext.
  2. Relax WMS#removeWindowToken to check callingUid if
     MANAGE_WINDOW_TOKEN permission is not held
  3. Deliver config changes to the client side in
     WMS#addWindowTokenWithOption
  4. Some minor fixes

fixes: 150812449
Bug: 150715095
Test: atest WindowContextTest
Test: atest WindowManagerServiceTests
Test: atest WindowTokenTests
Test: atest WindowManagerPermissionTests#testMANAGE_APP_TOKENS
Test: atest
WindowManagerPermissionTests#testADD_WINDOW_TOKEN_WITH_OPTIONS

Change-Id: I9f1d73af2abb78fc9844e6d9eb25e9f0293514e7
2020-04-08 21:30:24 +08:00
Yvonne Jiang
6d34642533 Fix secondary lock screen implementation such that DevicePolicyKeyguardService calls are made on the main (UI) thread.
For implementations of DevicePolicyKeyguardService to provide a SurfacePackage via SurfaceControlViewHost, they must be running on the UI thread.
Additionally, fix dismissal logic to bypass re-checking the secondary lockscreen, and add defensive null checks.

Bug: 136085151
Bug: 151365616
Test: atest AdminSecondaryLockScreenControllerTest
Test: atest KeyguardUpdateMonitorTest
Change-Id: Ibcd7090f50831cddbf952914adf020015750afd8
2020-04-08 05:31:20 -07:00
Evan Rosky
42f14d5442 Merge "Remove some more dead-code from old split impl" into rvc-dev am: e68c8ac02b
Change-Id: I98416e5ae2a7e74ae41b0186e614ba6e44252b02
2020-04-07 22:02:09 +00:00
Makoto Onuki
a49b1e6260 Context.getSystemService() shouldn't return null...
Even when interrupted.

Fix: 153005526
Test: Manual code inspection...
Change-Id: I6747c6b5fb4956b95b43d6fcd3fd636853339b8a
2020-04-07 14:01:30 -07:00
Selim Cinek
cd274d9e5d Always use the largeIcon as avatar replacement
A few apps were targeting >P but not providing avatars yet.
Even though this was an app bug it lead to some weirdness in
our UI. We therefore always do the workaround of using
the largeicon for an avatar instead of generating one if we're
in a OneToOne conversation.

Bug: 153466270
Test: post hangouts message, observe normal person avatar
Change-Id: Ia5262ca7dfc20d265c2d0532e88932c878f38552
2020-04-07 12:24:23 -07:00
Ryan Mitchell
a90930528d Invalidate idmap when target updates
When the target package update, check if the idmap file must change.
If so, propagate the idmap changes to the targets overlay paths, and
invalidate cached overlay ApkAssets in ResourcesManager.

Bug: 147794117
Bug: 150877400
Test: OverlayRemountedTest
Test: libandroidfw_tests
Change-Id: I6115c30bae3672b188a5ff270720a0eea15b43b5
2020-04-07 12:14:51 -07:00
Evan Rosky
50ea8c15fa Remove some more dead-code from old split impl
Removed moveTasksToFullscreenStack (only a small piece of it
was used by pip, so just localized it).

Remove stack creation/reparenting from resizeTask since modes
don't work like that anymore.

Removed some always-false parameters in AS.setWindowingMode

Bug: 133381284
Test: tests pass
Change-Id: I22e846250196eb93b480a05bed1f66d34b51a092
2020-04-07 10:31:36 -07:00
Linus Tufvesson
6a1c54f181 Merge "Use TYPE_PRIVATE_PRESENTATION for private presentations" into rvc-dev am: b66684981f
Change-Id: Ifaa2e86e7477f1e1ef68e4f2c7ac4559caaea41d
2020-04-07 11:52:25 +00:00
Linus Tufvesson
b66684981f Merge "Use TYPE_PRIVATE_PRESENTATION for private presentations" into rvc-dev 2020-04-07 11:32:16 +00:00
Kholoud Mohamed
0e434418d7 Merge "Remove platform-signed apps from configurable cross profile apps" into rvc-dev am: 5ec3cbac4c
Change-Id: I190c4e382efa6f421f660cf2e316807766dfa9d3
2020-04-07 09:56:52 +00:00
Kholoud Mohamed
5ec3cbac4c Merge "Remove platform-signed apps from configurable cross profile apps" into rvc-dev 2020-04-07 09:55:18 +00:00
Selim Cinek
8776260b29 Merge changes I76df6529,I99594ae9 into rvc-dev am: 35910cacaa
Change-Id: I06c716ffda5d55888b4ad81130699de75ae1f98e
2020-04-07 01:30:28 +00:00
Selim Cinek
35910cacaa Merge changes I76df6529,I99594ae9 into rvc-dev
* changes:
  Fixed the heads up layout of conversations
  Fixed an issue where the conversation title was showing doubled
2020-04-07 01:22:04 +00:00
kholoud mohamed
9bbab6a6df Remove platform-signed apps from configurable cross profile apps
Most apps that declare the INTERACT_ACROSS_PROFILES permission do
not have it granted, but get the app-op instead. We do not
normally want platform-signed apps that are actually given the
permission to appear in the user-configurable section in Settings,
so we remove them from the return value of
canUserAttemptToConfigureInteractAcrossProfiles in this CL.

Note that OEM can choose to allow some platform-signed apps to be
user-configurable by including them in their OEM whitelist file.
This CL respects that and allows these apps to be configured by the user,
despite being granted the permission. If the user rejects the app-op,
PermissionChecker correctly returns false.

Bug: 149742043
Test: atest CrossProfileAppsServiceImplRoboTest
Change-Id: I693338507eec9cdc0ba10a3584e994a58d2d113c
2020-04-06 10:13:09 +00:00
Linus Tufvesson
ac272d5e9f Use TYPE_PRIVATE_PRESENTATION for private presentations
Detect if the Presenation is targeting a private virtual display, and if they
are use the windowType TYPE_PRIVATE_PRESENTATION.

Bug: 152652348
Bug: 141745510
Test: atest CtsWindowManagerDeviceTestCases:PresentationTest
Test: atest CtsDisplayTestCases:android.display.cts.VirtualDisplayTest
Change-Id: I58834636e092f992e403342e36b475dc60e8f20a
2020-04-06 09:43:41 +00:00
Selim Cinek
dcfa46c5ca Fixed an issue where the conversation title was showing doubled
For conversations, it's not necessary anymore to extract
the conversation title into the heads up layout.

Fixes: 152655946
Test: add conversation group, observe no double text
Change-Id: I99594ae9e503cf8589603899e0053793be96958a
2020-04-03 17:00:49 -07:00
Yara Hassan
5781186727 Merge "Enabled Content Capture in Service" into rvc-dev am: e081caae5f
Change-Id: I9caf74b18f4138eed5b1669de700d27b9d6d509d
2020-04-03 16:55:48 +00:00
Yara Hassan
e081caae5f Merge "Enabled Content Capture in Service" into rvc-dev 2020-04-03 16:53:42 +00:00
Amith Yamasani
c8cc71a091 Merge "Mark secondary lockscreen API as SystemApi." into rvc-dev am: 040563da5f
Change-Id: Idd633967cc9eb5f16d7dbf29de9f2ea6efb09e1e
2020-04-03 14:28:23 +00:00
Amith Yamasani
040563da5f Merge "Mark secondary lockscreen API as SystemApi." into rvc-dev 2020-04-03 14:13:43 +00:00
Bernardo Rufino
f2c0580ea2 Merge "Rename test in TEST_MAPPING" into rvc-dev am: 884e9515d6
Change-Id: Ia0c52ca3580daec1ed4392fbf1b2f11f9ba9ef0c
2020-04-03 10:21:09 +00:00
Bernardo Rufino
884e9515d6 Merge "Rename test in TEST_MAPPING" into rvc-dev 2020-04-03 10:02:09 +00:00
Bernardo Rufino
434c17c0e6 Rename test in TEST_MAPPING
ToastTest became ToastWindowTest in ag/10919524, updating TEST_MAPPING
to reflect that.

Test: croot frameworks/base/core/java/android/app && atest --dry-run --test-mapping
Test: croot frameworks/base/core/java/android/widget && atest --dry-run --test-mapping
Test: croot frameworks/base/services/core/java/com/android/server && atest --dry-run --test-mapping
Bug: 152973950
Change-Id: I5b9e9b83d17c4a93a1e830c26d7f44001ccf175d
2020-04-03 08:48:00 +01:00
Jing Ji
2173365c0e Merge "Fix some Java doc errors" into rvc-dev am: 0cfca4a3c4
Change-Id: I948baf8f73c4ccec44574dc167ae34219e432be1
2020-04-03 07:46:54 +00:00
Jing Ji
e2757e64b7 Fix some Java doc errors
Bug: 148413462
Test: Manual
Change-Id: Idfabf5ac6548fd821bc69afb3588c1d124d0011b
2020-04-02 14:27:04 -07:00
Makoto Onuki
36bfe3e01c Merge "Add WTF when a system server wrapper can't be found" into rvc-dev am: bea34c409f
Change-Id: I046320bca3c7faa63fb296ceb36f3c0e5559e765
2020-04-02 20:51:09 +00:00
Makoto Onuki
bea34c409f Merge "Add WTF when a system server wrapper can't be found" into rvc-dev 2020-04-02 20:39:32 +00:00
Adam Bookatz
08da76161c Merge "Avoid getUserBadgeNoBackgroundResId if no badge" into rvc-dev am: 2f559add63
Change-Id: I703ba5f4dd669f4461aca1597763e4ba05336400
2020-04-02 19:00:17 +00:00
Adam Bookatz
2f559add63 Merge "Avoid getUserBadgeNoBackgroundResId if no badge" into rvc-dev 2020-04-02 18:42:07 +00:00
Yara Hassan
6b6c4b1889 Enabled Content Capture in Service
Bug: 150451947
Fix: 150451947
Test: Locally
Change-Id: Icbcbe4c46c4c5eb39b176b80c01dcce96f9dfbbd
2020-04-02 12:25:35 +01:00