Commit Graph

11741 Commits

Author SHA1 Message Date
Benjamin Miller
1bb5a1e5b3 Merge "Docs: Javadoc comment fixups for secure passcode reset methods." into oc-mr1-dev am: 947528607f
am: 96d506af85

Change-Id: I67da9e4d4a2500d08b0db58f1bff5ad793e3a852
2017-08-16 18:29:38 +00:00
TreeHugger Robot
947528607f Merge "Docs: Javadoc comment fixups for secure passcode reset methods." into oc-mr1-dev 2017-08-16 10:13:09 +00:00
Felipe Leme
50563050c6 Merge "Dismiss Autofill Save UI when a new Activity is launched." into oc-mr1-dev am: 3568046048
am: 409ae8857e

Change-Id: I0d48ebe7fa7c5b033e2f3b72d6444ada8c05200f
2017-08-15 18:36:44 +00:00
David Stevens
1583a4f9c8 Merge "Let external activities run when the primary display is off" 2017-08-15 18:07:15 +00:00
Benjamin Miller
1aed7889c0 Docs: Javadoc comment fixups for secure passcode reset methods.
Exceptions corrected for methods and cross references linked up.
Clarification about resetPassword() and work profiles.
Staged at: go/dac-stage/reference/android/app/admin/DevicePolicyManager.html

Test: make ds-docs with output staged and visually checked in DevicePolicyManager page
Bug: 38026339
Change-Id: I3346144193061fad7988c92e0d4be4b341ef7410
2017-08-15 18:34:06 +02:00
David Stevens
9440dc87a6 Let external activities run when the primary display is off
- Make activity sleep state independent of power manager wakefulness
  state. The state is now entirely dependent on sleep tokens (and the
  voice interactor).
- Make sleep tokens operate on a per-display basis (and convert the
  keyguard to a sleep token).
- Make ActivityStackSupervisor acquire/release sleep tokens for
  non-default displays when the displays are turned on/off.
- Make WindowManagerService.okToDisplay operate on a per-display basis.

Bug: 34280365
Test: android.server.cts.ActivityManagerDisplayTests
Test: #testExternalDisplayActivityTurnPrimaryOff
Test: #testLaunchExternalDisplayActivityWhilePrimaryOff
Test: #testExternalDisplayToggleState
Change-Id: I92086d7006a67b4b4f320c9bb3aa606954f85012
2017-08-14 21:59:06 -07:00
Felipe Leme
05ea98a3f9 Dismiss Autofill Save UI when a new Activity is launched.
Test: manual verification using Settings
Test: cts-tradefed run commandAndExit cts-dev -m CtsAutoFillServiceTestCases -tandroid.autofillservice.cts.SimpleSaveActivityTest#testDismissSave_byLaunchingNewActivity
Test: cts-tradefed run commandAndExit cts-dev -m CtsAutoFillServiceTestCases -tandroid.autofillservice.cts.LoginActivityTest#testSaveGoesAwayWhenLaunchingNewActivity
Test: cts-tradefed run commandAndExit cts-dev -m CtsAutoFillServiceTestCases

Fixes: 64693551

Change-Id: I323031c7285a4b49f9f0ca06618425a0ab7833da
2017-08-14 17:56:30 -07:00
Jeff Sharkey
b358b9f673 Merge "Remove a bunch of deprecated @SystemApi." into oc-mr1-dev am: c2e09129e0
am: b2a9f55488

Change-Id: Ib7e00ad3b02bf62fad1cc32c9e6002b2b7a45369
2017-08-12 03:38:00 +00:00
Jeff Sharkey
c2e09129e0 Merge "Remove a bunch of deprecated @SystemApi." into oc-mr1-dev 2017-08-12 03:21:01 +00:00
Michal Karpinski
2acdbae855 Merge "Merge "Add "Threading" section to BackupAgent's class level javadoc" into oc-mr1-dev am: 5500732584" into oc-mr1-dev-plus-aosp
am: 3e7f323481

Change-Id: I6ab2c9d851ebfe46b7e62753f047ef2976524f6a
2017-08-11 22:53:04 +00:00
Jeff Sharkey
8478911f5e Remove a bunch of deprecated @SystemApi.
Verified that nobody should be using these APIs, and they've been
deprecated long enough that we can remove them.

Bug: 62341924, 62263907, 62264550
Test: make -j32 update-api && make
Change-Id: I9a2333ca13e4984b71374aa7ffed081e5106c67e
2017-08-11 14:45:47 -06:00
Michal Karpinski
6aa05b82d8 Add "Threading" section to BackupAgent's class level javadoc
Test: make -j40 docs
Bug: 34326112
Change-Id: I3038de3f7159b92c72fa714f9ed55159fe3bb66b
2017-08-09 17:25:03 +01:00
Calin Juravle
152cc62627 Merge "Change the location of current profiles for secondary dex files" into oc-mr1-dev am: 284b584499
am: b2963f3351

Change-Id: I6de5ec46a0d93de01acec80a43a8856ca74dc488
2017-08-08 00:32:36 +00:00
Calin Juravle
284b584499 Merge "Change the location of current profiles for secondary dex files" into oc-mr1-dev 2017-08-08 00:17:44 +00:00
Jeff Sharkey
1fb3a312e7 Merge "Fix broken javadocs." into oc-mr1-dev am: b79eb54d36
am: 1ad38fe278

Change-Id: I21266d20be036196dbeddb9c4366d641ab1b68a8
2017-08-06 17:00:09 +00:00
Jeff Sharkey
67f9d5070a Fix broken javadocs.
Bug: 64337634
Test: make -j32 doc-comment-check-docs
Change-Id: I20fdd3dcddef09111d35946c41c596c7689effa6
2017-08-06 07:37:08 -06:00
TreeHugger Robot
acd9589dd7 Merge "Restricting background apps from running jobs" 2017-08-05 04:04:02 +00:00
Calin Juravle
eec18f41e2 Change the location of current profiles for secondary dex files
Move the secondary dex profiles inside the oat folder. This makes it
easier to clean them up and "protects" them against apps which may delete
unknown files from their directories (e.g. search).

Bug: 62336157
Test: Manual: boot the device, use the app, check the profiles are
collected in the new location.

Change-Id: I2fbce7591589d162775e4652b12e4698083adcff
2017-08-04 17:14:22 -07:00
Suprabh Shukla
3ac1daac40 Restricting background apps from running jobs
Introducing a new app op which controls whether apps are allowed to run
jobs in the background. When the app op mode is set to ignored, jobs
will be delayed until the app is in the foreground. The same semantics
as background check for O apps will apply, which means power whitelisted
apps can still run jobs freely and apps will have some settle time after
going to background after which their jobs will be stopped.

Test:
Added AppOpsUpgradeTest for upgrading appops to inherit existing value of
OP_RUN_ANY_IN_BACKGROUND from OP_RUN_IN_BACKGROUND
Added backgroundRestrictionsTest for background jobs. To run the test:
mmm -j32 services/tests/servicestests/
adb install -r \
out/target/product/marlin/data/app/JobTestApp/JobTestApp.apk
adb install -r \
out/target/product/marlin/data/app/FrameworksServicesTests/FrameworksServicesTests.apk
adb  shell am instrument -e class
'com.android.server.job.BackgroundRestrictionsTest' -w
'com.android.frameworks.servicestests/android.support.test.runner.AndroidJUnitRunner'

Bug: 63001625
Change-Id: I6eb01adb6cd2c1d0e7be4f7eca960f57ad9581bf
2017-08-04 16:13:06 -07:00
Christopher Tate
1fb409cbf5 Merge "Use normal API for legacy wallpaper restore" into oc-mr1-dev am: 4204f1658c
am: 454f1466b7

Change-Id: I0e7f9f1297ca3f8a8fd02b7b578905fc38a5b8a9
2017-08-03 23:30:09 +00:00
TreeHugger Robot
4204f1658c Merge "Use normal API for legacy wallpaper restore" into oc-mr1-dev 2017-08-03 23:07:53 +00:00
Christopher Tate
9f22443b4e Use normal API for legacy wallpaper restore
No longer do we play crazy rename-into-place tricks!  Just take
the restored image and treat it as an ordinary new system wallpaper,
and let the system machinery do all its proper work.  While we're at
it, we get rid of the now-spurious shenanigans about backing up the
wallpaper under the 'android' package, an overdue and welcome bit
of thinning.

In addition, we now fully migrate a legacy wallpaper image to have
both a source and a display crop in place.  We were previously
not generating the equivalent source image, which made N+ backups
unable to store the image properly.

Fix 64269208
Fix 62809439
Test: manual (set wallpaper under M, backup, flash to ToT,
      force restore)

Change-Id: If9b26b777f0fda95cf37c3c790a3fa4e82ff0340
2017-08-03 11:10:41 -07:00
Lucas Dupin
23789bc947 Merge "Multi-user and WallpaperColors" into oc-mr1-dev am: 22b418448b
am: 430d7450ed

Change-Id: I65ff692f77886bfed6f64ec71f0bab569a6354c0
2017-08-03 16:46:16 +00:00
Lucas Dupin
22b418448b Merge "Multi-user and WallpaperColors" into oc-mr1-dev 2017-08-03 16:23:41 +00:00
Alan Stokes
6d45286679 Merge "Fix trivial typo in javadoc for ActivityManager#getRunningTasks() Test: Comment change only" 2017-08-03 11:00:35 +00:00
Kurt Nelson
995b268856 Merge "Version guard Application.onCreate strict mode fix" into oc-mr1-dev am: e002f44005
am: ef5a4ca4e0

Change-Id: Icd4e4434901eecf0825421291791fc89b14ffea7
2017-08-03 04:25:59 +00:00
TreeHugger Robot
e002f44005 Merge "Version guard Application.onCreate strict mode fix" into oc-mr1-dev 2017-08-03 04:04:13 +00:00
Dianne Hackborn
b58f02a3c6 Merge "Add documentation for MIN notification interaction with fg services." into oc-mr1-dev am: 530cfc1db3
am: b49a3f1c3a

Change-Id: Idea07952532a5567aff62d70ad3572f6edec6e5b
2017-08-03 01:36:55 +00:00
Lucas Dupin
50ba991655 Multi-user and WallpaperColors
Test: set different wallpapers for different users and switch between them.
Test: re-ran cts tests at cts/tests/app/src/android/app/cts/WallpaperManagerTest.java
Change-Id: Ic06d1dc6db26869a2948590863ca9b8ac81c630e
Fixes: 63513694
2017-08-02 18:34:00 -07:00
TreeHugger Robot
530cfc1db3 Merge "Add documentation for MIN notification interaction with fg services." into oc-mr1-dev 2017-08-03 00:29:25 +00:00
Kurt Nelson
571c3f6e35 Version guard Application.onCreate strict mode fix
In I30b3eafa4a833fc42d0a938da9446007ade80480 we fixed an outstanding bug
around clobbering strict mode in Application.onCreate and allowing disk
writes to go unreported.

This guards that fix to only take effect once an app targets > SDK 26
and applies a ThreadPolicy inside Application.onCreate.

Bug: 63436909
Test: Ran apps with violations
Change-Id: Ib0ac1626e2ef322c4e61bbdf493d1f724b08652d
2017-08-02 15:31:41 +00:00
Todd Kennedy
0681d29966 Merge "Add new API to retrieve app names in a batch" into oc-mr1-dev am: 5e049eb884
am: a1cb029caf

Change-Id: I9454b85835e0deb8264f7371748aad90cf04a42d
2017-08-02 14:43:36 +00:00
Todd Kennedy
5e049eb884 Merge "Add new API to retrieve app names in a batch" into oc-mr1-dev 2017-08-02 14:23:16 +00:00
Alan Stokes
1e4e74ab7c Fix trivial typo in javadoc for ActivityManager#getRunningTasks()
Test: Comment change only

Change-Id: Icbda74290325575d391338584e12f58f9c198dbf
2017-08-02 11:17:37 +01:00
Andrew Solovay
7d266520b9 Merge "docs: Noted that JobIntentService is usually a better choice" into oc-dev am: d71cc3b72e am: 9e1b7759dc am: 6ff61dbc51
am: 49f6afe2f8

Change-Id: I0fd57ed371ae915ee33aa77e198b17eb9e9c8df9
2017-08-01 21:48:14 +00:00
Andrew Solovay
6ff61dbc51 Merge "docs: Noted that JobIntentService is usually a better choice" into oc-dev am: d71cc3b72e
am: 9e1b7759dc

Change-Id: I9b6e9c02f2237c48fdac4fd6f0c4afc4eb8b03cd
2017-08-01 21:31:59 +00:00
Andrew Solovay
9e1b7759dc Merge "docs: Noted that JobIntentService is usually a better choice" into oc-dev
am: d71cc3b72e

Change-Id: I8130d71136078d17196e198db6ff36f7f8489a5c
2017-08-01 21:21:58 +00:00
Calin Juravle
565cab11ff Merge changes from topic 'class-loaders-mr1' into oc-mr1-dev
* changes:
  Use the class loader context when optimizing secondary dex files
  Add DexClassLoader to the list of supported class loaders
2017-08-01 18:38:05 +00:00
Andrew Solovay
494f1a4dfa docs: Noted that JobIntentService is usually a better choice
Since IntentService is subject to the O background restrictions,
most devs are better off switching to the new JobIntentService.
(I assume IntentService is not actually deprecated; if it is, tell
me and I'll change this to a @deprecated tag!)

See first comment for doc stage location.

Test: make ds-docs
Bug: 64159987
Change-Id: I83a53d1e6336c2134bf4c61bedd2ae42cd80493a
2017-07-31 19:41:01 -07:00
Adam Lesinski
45053367ba Merge "Remove extraneous invalidate call that unregisters AssetManagers" into oc-dr1-dev am: defdb1fd70 am: 80454c2c88
am: 4733bcaa76

Change-Id: I95bbfb04d83b270de47c7a7143b68b6b94eeabf4
2017-07-31 22:36:23 +00:00
Adam Lesinski
80454c2c88 Merge "Remove extraneous invalidate call that unregisters AssetManagers" into oc-dr1-dev
am: defdb1fd70

Change-Id: I6878ca92b2bd8b2e9569147dde007ae657adc87c
2017-07-31 22:17:27 +00:00
Adam Lesinski
defdb1fd70 Merge "Remove extraneous invalidate call that unregisters AssetManagers" into oc-dr1-dev 2017-07-31 22:08:30 +00:00
Dianne Hackborn
6e5bd3f9f8 Add documentation for MIN notification interaction with fg services.
Don't do this, you won't get what you want.

Test: built

Change-Id: I57ae93ced2b9ad563197c00ad8d94f7b492dff0c
2017-07-31 14:25:39 -07:00
Bryce Lee
d2ed053f6e Merge "Do not call onConfigurationChanged for appBound position changes." into oc-dr1-dev am: 33d4702a12 am: 05865fb40a
am: 94795bcaf8

Change-Id: Ifb914ce593e914e83db9cea9c9c574c627216d6f
2017-07-31 19:00:08 +00:00
Bryce Lee
94795bcaf8 Merge "Do not call onConfigurationChanged for appBound position changes." into oc-dr1-dev am: 33d4702a12
am: 05865fb40a

Change-Id: Ia5817040ce14ee6dbd995bd83444f34e78bef375
2017-07-31 18:53:39 +00:00
Bryce Lee
05865fb40a Merge "Do not call onConfigurationChanged for appBound position changes." into oc-dr1-dev
am: 33d4702a12

Change-Id: I990a3554730cc07440c7d4bc0236e0aeb00e2980
2017-07-31 18:46:20 +00:00
Bryce Lee
69aac0a7b6 Merge "Do not call onConfigurationChanged for appBound position changes." into oc-dr1-dev
am: 33d4702a12

Change-Id: Id6748aab9ee83844303324ea397d4ac699fb5839
2017-07-31 18:45:19 +00:00
Todd Kennedy
9da8b8a7fc Add new API to retrieve app names in a batch
Change-Id: I57e5c132bc58a32d70007a7a105775b526ff7bb9
Fixes: 62805090
Test: cts-tradefed run commandAndExit cts-dev -m CtsContentTestCases -t android.content.pm.cts.PackageManagerTest#testGetNamesForUids_null
Test: cts-tradefed run commandAndExit cts-dev -m CtsContentTestCases -t android.content.pm.cts.PackageManagerTest#testGetNamesForUids_empty
Test: cts-tradefed run commandAndExit cts-dev -m CtsContentTestCases -t android.content.pm.cts.PackageManagerTest#testGetNamesForUids_valid
2017-07-31 11:29:37 -07:00
Bryce Lee
658d984f04 Do not call onConfigurationChanged for appBound position changes.
Since appBounds encodes both dimensions and positions, movement will
cause a diff change. This happens in situations where the dimensions
stay constant, such as dragging a PiP window around.

To avoid flooding the client side with configuration changes, this CL
checks whether the new configuration is equivalent to the existing
configuration with the exception of the position of the appBounds
before sending to the registered callbacks.

Change-Id: I8fbc94458fd9ed3b39494c3587f25e704ec02a7d
Fixes: 63927944
Test: bit FrameworksServicesTests:com.android.server.wm.AppBoundsTests
Test: go/wm-smoke
2017-07-31 08:46:00 -07:00
Adam Lesinski
662153740d Remove extraneous invalidate call that unregisters AssetManagers
We are already taking care of updating AssetManagers affected by
path changes to a running app's ApplicationInfo. There is no need
to invalidate ALL AssetManagers, thereby unregistering them
from ResourcesManager and preventing configuration changes from
reaching them.

Bug: 64004601
Test: manual
Change-Id: I39311ec9b1dfd34eb7025836f75c92e0516bc36b
2017-07-28 16:33:11 -07:00