9644 Commits

Author SHA1 Message Date
Amith Yamasani
c1cbaaba6c Don't kill apps that are multi-user aware...
... when looking for background user apps that hold RECORD_AUDIO
permission.

On switching users, we kill any apps that might potentially be
recording audio. But we don't want to kill critical apps that need
to stay running because of multi-user aware services.

Bug: 22564430
Change-Id: I6d9a684d4e044cc3018f0f8181a44aa143a3baeb
2015-07-21 11:46:14 -07:00
Wale Ogunwale
e99f20f587 Merge "Don't duplicate recent tasks of the same affinity." into mnc-dev 2015-07-21 14:28:16 +00:00
Wale Ogunwale
7cbfcd8865 Don't duplicate recent tasks of the same affinity.
In change 510e554283d3dc250f836cd3e4abc36d87319333 we stated
limiting the number of document activity entries in recents
by comparing the realActivity of the tasks. This compared was
done for all tasks not just document tasks there by breaking
the use of task affinity to remove tasks with the same affinity
from recent task list. This change limits the compare of
realActivity to just document tasks.

Bug: 22564474
Bug: 18642190
Change-Id: Idc21ec311f194ab2005cb22380ca56303ae0ad94
2015-07-21 07:26:36 -07:00
Jae Seo
b2eed1d6e1 Merge "TIF: Get or create the user state when failed to find existing one" into mnc-dev 2015-07-20 23:59:25 +00:00
Dongwon Kang
6444fe1214 Merge "MediaSessionRecord: do not hold a lock when calling AudioSystem.isStreamActive" into mnc-dev 2015-07-20 23:50:03 +00:00
Jorim Jaggi
4cd7216967 Fix window animation flickering
Bug: 22502673
Change-Id: I939e5840e10f3c0582148a5a01908076f994ae69
2015-07-20 23:31:25 +00:00
Jae Seo
4f1a6d477c TIF: Get or create the user state when failed to find existing one
Bug: 22560640
Change-Id: Idc56dc2b16319d173f005fc236f91f70d1a93fad
2015-07-20 16:20:18 -07:00
Dongwon Kang
500747bf8f MediaSessionRecord: do not hold a lock when calling AudioSystem.isStreamActive
AudioSystem.isStreamActive() includes a blocking IPC, so it shouldn't be called
in MSR.adjustVolume() which is called from MediaSessionService while holding a
lock.

Bug: 22606983
Change-Id: I3ab94e73731176d9bf80dbc2121702025547114c
2015-07-20 15:59:53 -07:00
Simranjit Singh Kohli
02aff29c39 Merge "[Fix MANAGE_USER permission in AccountManagerService] It seems that curently there were situations where the init of Accounts in cache could trigger MANAGE_USER permission needed errors. The callers should make sure they are calling it after clearing identity." into mnc-dev 2015-07-20 22:40:03 +00:00
Jae Seo
26f7720ed0 Merge "MediaSession: Do not lock on AudioManager.getStreamVolume" into mnc-dev 2015-07-20 20:45:11 +00:00
Jeff Sharkey
35ba2cdbf8 Merge "Inherit ABI when moving existing install." into mnc-dev 2015-07-20 20:44:56 +00:00
Jeff Sharkey
40cda8ef7c Inherit ABI when moving existing install.
Previously installed apps are moved between volumes as an complete
package, including any previously unpacked native libraries.  This
means we need to inherit any previously derived ABI when moving.

Bug: 22093837
Change-Id: I7656e338affa44e7f997fe4aa95bb297c0acc165
2015-07-20 13:40:20 -07:00
Dianne Hackborn
78ead58df0 Merge "Fix issue #22531747: Assist info should declare if user has disabled..." into mnc-dev 2015-07-20 19:50:50 +00:00
Dianne Hackborn
17f693520d Fix issue #22531747: Assist info should declare if user has disabled...
...context and/or screenshot

Added new API to find out what contextual data has been globally disabled.

Also updated various documentation to make it clear what kind of contextual
data you will get (and when it will be null).

Also added a new Activity.showAssist() API because...  well, I was already
in there, it was easy to do, it is safe, and maybe people will build cool
things with it.

Change-Id: Ia553d6bcdd098dc0fce4b9237fbfaca9652fc74b
2015-07-20 12:49:10 -07:00
Wale Ogunwale
bde85f741c Merge "Fixed issue with background user window consuming touch events" into mnc-dev 2015-07-20 18:46:00 +00:00
Jean-Michel Trivi
698250fae7 Merge "Media button intent should be send to current user only." into mnc-dev 2015-07-20 17:25:32 +00:00
Christopher Tate
6afdad7e88 Merge "Don't fall back to domain verification state when looking up app linkage state" into mnc-dev 2015-07-20 17:05:32 +00:00
Wale Ogunwale
4eef94f2b8 Fixed issue with background user window consuming touch events
When adding a window for a background user, it is possible for
the window to consume touch events because it is in the
COMMIT_DRAW_PENDING state. We allow the background user window
to transition READY_TO_SHOW state, but hide the window.

Change is based on https://android-review.googlesource.com/#/c/158772
and also reverts commits 6ee618509a392adb183c2e70390cd9e2031ff0d8
and 588932a53e63c0a7ee281dea22559c129b40eb99

Bug: 22531717
Bug: 22207948
Bug: 18510914
https://code.google.com/p/android-developer-preview/issues/detail?id=2667

Change-Id: I68d2e532c2b1def0d7b22c9b60e48110cf3cd686
2015-07-17 22:29:54 -07:00
Jeff Sharkey
c9eb398a1b Merge "Clear identity when killing media provider." into mnc-dev 2015-07-17 23:29:54 +00:00
Jeff Sharkey
b3cf953345 Clear identity when killing media provider.
Otherwise various shell "sm" commands fail because they don't hold
the right permissions.

Bug: 22564405
Change-Id: I88081e8a9b27ee43904d3ea6f745aba3af4e2150
2015-07-17 16:21:43 -07:00
Jeff Sharkey
259453024c Merge "Persist version data on a per-volume basis." into mnc-dev 2015-07-17 23:20:37 +00:00
Jeff Sharkey
f80b52b08a Persist version data on a per-volume basis.
Now that we support multiple adopted external storage devices, we
need to keep track of version data for each volume.  This means we
now correctly handle certificate upgrade edge cases, permission
regranting, and clearing of code caches on a per-volume basis.

Bug: 22298966
Change-Id: Ifb9940c197f6c058a3ecca728257f853ce0fd7f4
2015-07-17 16:19:00 -07:00
Svetoslav Ganov
fbc6f2cb6c Merge "Revert "Do not auto grant GET_ACCOUNTS as it is temporarily normal"" into mnc-dev 2015-07-17 22:39:34 +00:00
Christopher Tate
d85a664202 Don't fall back to domain verification state when looking up app linkage state
This is in support of the always/never/ask UI tweaks in Settings: any
"assume always" fallback at the verification layer should not be
conflated with the user-facing semantic toggle.  This was causing the
UI to report apps as being in the 'always open their links' state
inappropriately.

Bug 22532193

Change-Id: Iaa4bc3a2d5db814e1b0d96bc1c4ecfaafb1e3105
2015-07-17 15:39:08 -07:00
Dianne Hackborn
5c269121d8 Merge "Work on issue #22556778: Starting under voice control not allowed" into mnc-dev 2015-07-17 22:03:46 +00:00
Svet Ganov
5ff4383b46 Merge "Grant default permissions to default apps despite user choices." into mnc-dev 2015-07-17 20:58:13 +00:00
Svet Ganov
4bb5187e63 Grant default permissions to default apps despite user choices.
This implements the policy of granting default permissions to default
apps upon a selection despite past user permission choices. The act of
picking the app as the default one means the user expects it to work in
this capacity as SMS app, Phone app, Browser app.

bug:22062549

Change-Id: I5e427f2b939e85bb8bbfd311cc271b96857a7ce6
2015-07-17 13:43:34 -07:00
Svetoslav Ganov
54a0cf1b95 Revert "Do not auto grant GET_ACCOUNTS as it is temporarily normal"
This reverts commit 33852d8cd21434b4106b8f2c504752ef34abb2da.

Change-Id: I29a212876c93ae0288967ffcff223abafad78827
2015-07-17 20:34:18 +00:00
Svet Ganov
4a1421f3c5 Merge "Do not auto grant GET_ACCOUNTS as it is temporarily normal" into mnc-dev 2015-07-17 20:27:36 +00:00
Svet Ganov
33852d8cd2 Do not auto grant GET_ACCOUNTS as it is temporarily normal
bug:22550851

Change-Id: Iea5dd8fde07074220167a937b32208b1c9488d9d
2015-07-17 13:21:36 -07:00
Wale Ogunwale
af81434023 Merge "Fixed bad merge conflict resolution" into mnc-dev 2015-07-17 18:44:58 +00:00
Dianne Hackborn
f38c4ee903 Work on issue #22556778: Starting under voice control not allowed
The ResolverActivity is voice capable.  In fact, it is capable
of EVERYTHING.

Change-Id: I37c4476d546f61fee3540b747aff77e88b702d48
2015-07-17 11:21:26 -07:00
Jae Seo
d2a8d71ce0 MediaSession: Do not lock on AudioManager.getStreamVolume
Locking on AudioManager.getStreamVolume method causes watchdog killing
system process for it makes a native call to get devices for stream,
which takes time. This change removes such locking.

Bug: 22404242
Change-Id: I23de3efe33642341205d65f58bc5b74542f1f506
2015-07-17 10:41:55 -07:00
Todd Kennedy
5fe22e4fcb Merge "clear calling identity to dexopt" into mnc-dev 2015-07-17 14:40:00 +00:00
Wale Ogunwale
24b243d53d Fixed bad merge conflict resolution
https://android-review.googlesource.com/#/c/137534/ was accepted
and merged on 03/04/15. However, a bad merge conflict resolution
caused half of the change to be reverted. This adds back the missing
change.

Change-Id: I4f7c2503e60321b692e12316961958b149baf4ea
2015-07-17 07:20:57 -07:00
Simranjit Singh Kohli
ba0b10af5f [Fix MANAGE_USER permission in AccountManagerService]
It seems that curently there were situations where the init of
Accounts in cache could trigger MANAGE_USER permission needed errors.
The callers should make sure they are calling it after clearing
identity.

Bug: 22492964
Change-Id: I44e890ff03a3bf144c907f2692dc1c6be8816f11
2015-07-16 20:46:00 -07:00
Adrian Roos
5536bb48b2 Merge "Fix stuck scrim on keyguard-less devices" into mnc-dev 2015-07-17 00:43:18 +00:00
Todd Kennedy
2a89545739 clear calling identity to dexopt
Bug: 22067670
Change-Id: I3596f26a079660f6898401ed679463193b00c799
2015-07-16 16:39:46 -07:00
Svet Ganov
d4b566bf56 Merge "Add APIs for verifier to grant at install and revoke permissions" into mnc-dev 2015-07-16 22:22:01 +00:00
Dianne Hackborn
aaee5b5334 Merge "Work on issue #22516282: ChooserTarget URI grants not forwarded" into mnc-dev 2015-07-16 21:44:21 +00:00
Makoto Onuki
b09b84cafd Merge "DefaultPermission: GET_ACCOUNTS is now in CONTACTS" into mnc-dev 2015-07-16 21:01:39 +00:00
Makoto Onuki
bc92479a29 DefaultPermission: GET_ACCOUNTS is now in CONTACTS
Bug 22532312

Change-Id: If7ad0faa3a196bb28da1ddc13788c0430df1d1ee
2015-07-16 11:38:00 -07:00
Todd Kennedy
a4911ed971 Merge "Verfiy global apps with device owner" into mnc-dev 2015-07-16 17:59:35 +00:00
Dianne Hackborn
a7cfbe0e54 Work on issue #22516282: ChooserTarget URI grants not forwarded
Add new option to startActivityAsCaller() which allows you to
specify that we should not do security checks on the target
activity being launched.

Change-Id: Ie6b28807b96fef35ccdff93b0a01066cfd8fa307
2015-07-16 10:52:52 -07:00
Wale Ogunwale
1181323230 Merge "Animate app exit for cases where the app is already hidden before transition" into mnc-dev 2015-07-16 17:01:15 +00:00
Wale Ogunwale
b60c0f616c Animate app exit for cases where the app is already hidden before transition
It is possible for an app token to be marked as hidden and exiting
because the previous activity destory is completed before we are
good-to-go with app transition since we are still waiting for the
opening app to be done drawing. In this case we don't apply the
exiting animation since the token is not changing visibility state
during the app transition (it is already hidden and we are telling
it to hide...).
We now allow the animation to load if the token is already hidden
and marked as exiting.

Bug: 22381703
Change-Id: I5c27b6c3c1f810f05b2d716122055c6f12d0a167
2015-07-16 09:45:35 -07:00
Todd Kennedy
633f199831 Verfiy global apps with device owner
Applications installed for a specific user must be verfied as that user. However,
apps that are installed globally [i.e. UserHandle.ALL] should not be verified by
every user on the device. Instead, they should be verified by the device owner.

Bug: 21901423
Change-Id: I5fd3f690d08e7e911a3c86f09bbfcd4eb635b418
2015-07-16 09:44:31 -07:00
Nicolas Prevot
dbdf7c4538 Don't send app links to the parent if status = never (part 2)
To qualify for cross-profile app linking, an intent should resolve
with a better status than "NEVER". Moved this check from canForwardTo
into the source method, getCrossProfileDomainPreferredLpr, to stop
bad resolutions leaking out.

BUG:22287521
Change-Id: I195979d78a783864d841a81f358780912bbf168e
2015-07-16 10:13:00 +01:00
Vineeta Srivastava
47e0409062 Merge "Remove redundant cancel events from FingerprintService" into mnc-dev 2015-07-16 07:06:54 +00:00
Svet Ganov
7121e18595 Add APIs for verifier to grant at install and revoke permissions
bug:22231699

Change-Id: Ie0c758bf73699f50bf99ff5aa0bf98dcc9004e37
2015-07-15 22:22:59 -07:00