Commit Graph

16507 Commits

Author SHA1 Message Date
TreeHugger Robot
82865f85c1 Merge "Pipe featureId from app to noteOp for WallpaperMgr" 2019-11-18 19:01:35 +00:00
Makoto Onuki
b8cf86a2ca Merge "Clean up system service registration. (2nd try)" 2019-11-18 17:22:13 +00:00
Philip P. Moltmann
41ff0f6724 Pipe featureId from app to noteOp for WallpaperMgr
Test: atest CtsAppOpsTestCases(now includes canary test for this flow)
Bug: 136595429
Change-Id: I5f309646286cc4f3e080b87f482199fface67370
2019-11-15 20:09:13 -08:00
Evan Rosky
0740566355 Merge "Include IWindowContainer token along with StackInfo" 2019-11-15 22:56:31 +00:00
Makoto Onuki
05b14f53a5 Clean up system service registration. (2nd try)
Bug: 143788029
Test: boot
Test: build/soong/soong_ui.bash --make-mode dist ANDROID_BUILDSPEC=vendor/google/build/app_build_spec.mk
(This build uses java 8, which caused a build failure at the first try)

Test: atest SystemUITests

Change-Id: I352df4e76c9a2e787c9b4216b26d8d5fc84ff369
2019-11-15 13:39:20 -08:00
Adam Bookatz
b9a57da94c Merge "Introduce user types" 2019-11-15 19:15:37 +00:00
Charles Munger
77c54b3a33 Merge "Deprecate AliasActivity" am: 95b815e26e am: 66f56ac1e8
am: 23220f2726

Change-Id: I5f47c62422441997eacc57856ffa1bc43a778660
2019-11-15 11:11:58 -08:00
Jayachandran Chinnakkannu
5fc195c56e Merge "Remove exposing of ImsManager and RcsMessageManager in system service registery" am: ad648ffc9d am: f3b4fc4dac
am: 3db90e00b0

Change-Id: I4be3eafc38caf7e225bb4bde649c00fe81d85482
2019-11-15 11:09:45 -08:00
Charles Munger
23220f2726 Merge "Deprecate AliasActivity" am: 95b815e26e
am: 66f56ac1e8

Change-Id: I0bcc4914246bac2fe28808bc8a4873550dadbb80
2019-11-15 11:05:42 -08:00
Jayachandran Chinnakkannu
3db90e00b0 Merge "Remove exposing of ImsManager and RcsMessageManager in system service registery" am: ad648ffc9d
am: f3b4fc4dac

Change-Id: I628ab104b1167d8261bcd8fa541287ce790d18d6
2019-11-15 11:01:49 -08:00
Charles Munger
66f56ac1e8 Merge "Deprecate AliasActivity"
am: 95b815e26e

Change-Id: I9013bd8596ba35bbdaa1e2657c0416f1690a37dc
2019-11-15 10:58:06 -08:00
Jayachandran Chinnakkannu
f3b4fc4dac Merge "Remove exposing of ImsManager and RcsMessageManager in system service registery"
am: ad648ffc9d

Change-Id: I9eaf4c5935f69d12ff25fa4d8ac8cc7ec05d591a
2019-11-15 10:50:57 -08:00
Treehugger Robot
95b815e26e Merge "Deprecate AliasActivity" 2019-11-15 18:38:35 +00:00
Jayachandran C
c01f4eda35 Remove exposing of ImsManager and RcsMessageManager in system service registery
Since these are hidden it cannot be accessed by system service registery
Removing it for now and can be added later when these becomes SystemApi

Bug: 140768340
Test: Build & basic sanity
Change-Id: Ibb007f0a761bcbd006ebffbb552d0da82b586d03
2019-11-15 18:10:54 +00:00
Evan Rosky
282ee67dd7 Include IWindowContainer token along with StackInfo
This is needed for stacks to participate in transactions.
Most immediate use-case will be PiP during rotation

Bug: 119687367
Test: Added ActivityTaskManagerServiceTests#testStackTransaction

Change-Id: I50a5c3cea4f23f2be4e55ba38f8a5371fa9dfe79
2019-11-14 12:52:28 -08:00
TreeHugger Robot
9f43c201fe Merge "Do not look for R.class of overlays" 2019-11-14 19:04:48 +00:00
Bookatz
029832a951 Introduce user types
Introduces the notion of 'user types' to UserManager.
Previously, users only had properties, set by UserInfo flags. We now
solidify some of these as formal user types. Each user must be of
precisely one user type. The configuration of each type is defined
in a UserTypeDetails object.

Prior 'types' - namely Guest, Restricted, ManagedProfiles, Demo, and
'normal' - that were set via UserInfo flags are now controlled via
UserType. Previous UserInfo flag methods for categorizing these are
still supported as long as no user of of more than one type.

If a user was (e.g.) previously both Guest and Demo, it is now
invalid and will be prevented from upgrading. This should not be a
problem in AOSP, where these 'types' were assumed mutually exclusive.

UserTypeDetails is sufficiently general to support future non-managed
profiles. To this end, the logic for specifying badges and their
colors/labels is contained by UserTypeDetails, and therefore
UserManager is responsible for delivering the corresponding badge
information.

Bug: 142151520

Test: added new test class UserManagerServiceUserTypeTest
Test: added additional tests in UserManagerServiceUserInfoTest
Test: added additional tests in UserManagerTest
Test: added additional tests in UserManagerServiceCreateProfileTest
Test: created UserTests to run the various pm.User*Test's

Test: atest \
  com.android.server.pm.UserTests \
  UserLifecycleTests \
  ManagedUserContentResolverTest \
  CtsDevicePolicyManagerTestCases \
  CtsMultiUserHostTestCases \
  com.android.server.devicepolicy.DevicePolicyManagerTest \
  com.android.server.am.UserControllerTest \
  CreateManagedProfileTaskTest

Test: atest com.android.server.pm.UserManagerServiceCreateProfileTest
   using adb shell getprop persist.sys.max_profiles # for 5 and -1

Change-Id: Id1183a76055e9a7610965cf40b256d1392afe6f8
2019-11-14 10:00:50 -08:00
Makoto Onuki
57c99d3a2f Merge "Revert "Clean up system service registration."" 2019-11-14 02:28:26 +00:00
Makoto Onuki
202fd24765 Revert "Clean up system service registration."
This reverts commit a9f2224068.

Reason for revert: broke build

Change-Id: I08d1e3b6f7f02627138ff3f50b436772e1eb756f
Fixes: 144460136
2019-11-14 02:25:11 +00:00
Makoto Onuki
3212ad0167 Merge "Clean up system service registration." 2019-11-14 00:14:22 +00:00
Ryan Mitchell
73bfe41bab Do not look for R.class of overlays
Now that RROs are loaded as shared libraries,
LoadedApk#makeApplication is attempting to find the onResourcesLoaded
method of the overlays. This is a performance hit and causes more
memory than necessary to be allocated during application start up.

Bug: 143314947
Test: com.android.performance.tests.HermeticMemoryTest
Change-Id: I3b8cd22dae83e0164d6678c80279f9fffceb34e6
2019-11-13 14:51:14 -08:00
Makoto Onuki
a9f2224068 Clean up system service registration.
Bug: 143788029
Test: boot

Change-Id: I6e19e2b0f08b4977b3df1cf8b6972bf3fda6d4b9
2019-11-13 14:04:00 -08:00
Tej Singh
5918429fa2 Java API for pulled atoms
This creates a java API for registering pullers. Will implement the
statsd side in a follow up CL.

Test: builds, boots
Change-Id: Ib6735984297ce3148839a6370a3c15b2a585baf5
2019-11-13 13:22:27 -08:00
Artur Satayev
79aff5c601 Merge "Add @UnsupportedAppUsage to test apis that are known to be used by apps." am: a98026f7aa
am: 59318bab67

Change-Id: Ic691d764839ecf34daa8b53aa92497e013c9a2a7
2019-11-13 10:40:54 -08:00
Artur Satayev
59318bab67 Merge "Add @UnsupportedAppUsage to test apis that are known to be used by apps."
am: a98026f7aa

Change-Id: Ia39fbc2200aa7262e4a05b0710b7a382bb01b276
2019-11-13 10:33:06 -08:00
TreeHugger Robot
bc7671b9fb Merge "Add @UnsupportedAppUsage to test apis that are known to be used by apps." 2019-11-13 15:46:27 +00:00
Artur Satayev
5a525851a8 Add @UnsupportedAppUsage to test apis that are known to be used by apps.
go/testapi-enforcement

Bug: 133832325
Test: m
Change-Id: Ifc8db120640a1554dcbf1722e61e09c7ddc65dd6
Merged-In: Ifc8db120640a1554dcbf1722e61e09c7ddc65dd6
2019-11-13 15:05:56 +00:00
Artur Satayev
f0b7d0ba51 Add @UnsupportedAppUsage to test apis that are known to be used by apps.
go/testapi-enforcement

Bug: 133832325
Test: m
Change-Id: Ifc8db120640a1554dcbf1722e61e09c7ddc65dd6
Merged-In: Ifc8db120640a1554dcbf1722e61e09c7ddc65dd6
2019-11-13 12:58:29 +00:00
Alex Johnston
5ab1017716 Merge "Call getPasswordComplexity on the parent profile" 2019-11-13 12:07:23 +00:00
TreeHugger Robot
a22721f5ed Merge "Add Bubble as an option in NotificationInfo longpress menu" 2019-11-12 20:12:32 +00:00
satayev
c265820ec3 Merge "Add --no-test-api-acces to am instrument." am: 188abff5b2
am: 5c8ed7f6e7

Change-Id: I6b9f9634df7925a85bd837ba0868cd96b5087757
2019-11-12 10:53:34 -08:00
satayev
5c8ed7f6e7 Merge "Add --no-test-api-acces to am instrument."
am: 188abff5b2

Change-Id: I4b345fd330ba92caa96781f64f703a057adad2b0
2019-11-12 10:49:01 -08:00
Yuncheol Heo
fe0e4a2478 Merge "Make onActivityViewDestroyed called when AV is released." 2019-11-12 18:39:16 +00:00
Alex Johnston
07cb9f04c7 Call getPasswordComplexity on the parent profile
Previously, this API did not support explicitly querying the parent profile.
This CL will now allow the WP DPC to call this method since all other password
related methods can already be called.

Screenshot of TestDPC: https://hsv.googleplex.com/4804408720228352 (WP DPC)
                       https://hsv.googleplex.com/5189846769336320

Bug: 138709470
Test: manual testing using Personal and WP TestDPC
      atest com.android.cts.devicepolicy.ManagedProfileTest
      atest com.android.cts.devicepolicy.PasswordComplexityTest
      atest com.android.server.devicepolicy.DevicePolicyManagerTest

Change-Id: I0fb3a96c4469046c8712b5de582c501ea7eb3d8b
2019-11-12 16:58:33 +00:00
Artur Satayev
d9bc075335 Merge "Add --no-test-api-acces to am instrument." 2019-11-12 16:00:07 +00:00
Artur Satayev
ab4d5afcf7 Add --no-test-api-acces to am instrument.
By default instrumented processed have access to @TestApis; however for certain CTS tests we want to disable access to test APIs, where this flag would be used.

Test: manual
Bug: 133832325
Change-Id: Id56ce3079bcea2632d4002edcf120d9d5c9e0a26
2019-11-12 12:52:34 +00:00
Artur Satayev
e2ebc1be4b Add --no-test-api-acces to am instrument.
By default instrumented processed have access to @TestApis; however for certain CTS tests we want to disable access to test APIs, where this flag would be used.

Test: manual
Bug: 133832325
Change-Id: Id56ce3079bcea2632d4002edcf120d9d5c9e0a26
Merged-In: Id56ce3079bcea2632d4002edcf120d9d5c9e0a26
2019-11-12 12:52:19 +00:00
TreeHugger Robot
59cee214bf Merge "Merge Task and TaskRecord into one class (65/n)" 2019-11-12 04:11:33 +00:00
Louis Chang
cdec080895 Merge Task and TaskRecord into one class (65/n)
Merge Task and TaskRecord into a single Task class. Also Consolidate
updateTaskMovement() call points to TaskStack.onChildPositionChanged().

Bug: 80414790
Test: Existing tests pass
Change-Id: Iec0101b211bf34fab42131aae6cddfe1262e2add
2019-11-12 10:29:39 +08:00
Mady Mellor
53162c13a3 Add Bubble as an option in NotificationInfo longpress menu
- If the content is able to bubble, the bubble option will show in
  the menu
- If that notif is able to bubble (either via bubble metadata or via
  notification contents), then show the menu
- Adds tests for the bubble menu option, also tests selection for alert
  and silence buttons; removes unused test code

Test: atest NotificationInfoTest NotificationGutsManagerTest
Test: manual - post a bubble with bubbles test app, longpress on notif
               and demote it via menu => bubble is gone
             - long press on notif and promote it via menu => bubble is
               created
Bug: 138116133
Bug: 143173197
Change-Id: I2f2767ec12c49e5d3a8d2a7b86db5457d062275c
2019-11-11 16:29:37 -08:00
Charles Munger
f8f78aeb25 Deprecate AliasActivity
Bug: 144042891
Change-Id: Ie7f32516265dbe64799ec79263d1731817cfbbfb
2019-11-11 16:12:46 -08:00
Artur Satayev
756d3b447a Merge "Add @UnsupportedAppUsage annotations for greylist." am: 423c3a32d6
am: 7a565c45b1

Change-Id: I48075ef4296e0b55c0055f7364c5129bbd60e9ed
2019-11-11 09:33:13 -08:00
Artur Satayev
7a565c45b1 Merge "Add @UnsupportedAppUsage annotations for greylist."
am: 423c3a32d6

Change-Id: I5387b4742fdaf67ad3189356f2361f73969b53a8
2019-11-11 09:13:24 -08:00
Hyangseok Chae
1d9b805409 Fix a missing synchronization to Notification
Concurrent access on allPendingIntents could cause
crash by ArrayIndexOutOfBoundsException.
Below two accesses can occur in two different threads.
But allPendingIntents(ArraySet) is not thread-safe.
1. Access to write.
   allPendingIntents = new ArraySet<>();
   parcel.writeArraySet(allPendingIntents)
2. Access to add.
   allPendingIntents.add(intent);

So, we added missing synchronization to Notification

Test:
It is hard to reproduce by manual.
Make/Update notification with pendingintent.

Change-Id: Ib866f6b92528f7a944ac93997a9cff07892d4192
Bugs: 144081764
2019-11-11 14:09:42 +00:00
Jorim Jaggi
5fdaa0c9af Merge "Remove FEATURE_SWIPE_TO_DISMISS functionality" 2019-11-11 13:10:30 +00:00
Yuncheol Heo
9076eacaaf Make onActivityViewDestroyed called when AV is released.
Test: WmTests:TaskStackChangedListenerTest#testSingleTaskDisplayEmpty
Change-Id: I1271edb08b65b3ca29f92b237d0a65defb7bb38a
2019-11-10 11:34:08 -08:00
Meng Wang
d4976c4f46 Merge "System API: Context#registerReceiverForAllUsers" 2019-11-08 18:03:02 +00:00
Artur Satayev
3be4d59369 Merge "Add @UnsupportedAppUsage annotations for max-p." am: 8893f158c6
am: da4d6567c2

Change-Id: Iff80c388dec2c6f8184b739be6fb38b8ec8a1a49
2019-11-08 09:49:03 -08:00
Artur Satayev
da4d6567c2 Merge "Add @UnsupportedAppUsage annotations for max-p."
am: 8893f158c6

Change-Id: I2f249063c274b54a58a24cda23f1d5a60fa14540
2019-11-08 09:38:12 -08:00
Artur Satayev
fc46be7dbd Add @UnsupportedAppUsage annotations for greylist.
go/cleanup-greylist-txt

These have already been greylisted, however due to bugs/omissions in the tooling have been kept in go/greylist-txt instead of being annotated in the code.

Bug: 137350495
Test: m

Change-Id: Id6c1f5e403a0e66edb1102ee45f3bf19f244fb09
Merged-In: Id6c1f5e403a0e66edb1102ee45f3bf19f244fb09
2019-11-08 16:17:13 +00:00