History log of /frameworks/base/core/java/android/content/pm/PackageManager.java
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
927d3453d39a9048c41eddf2418a97562757e930 03-May-2016 Ruben Brunk <rubenbrunk@google.com> Update VR API docs.

Bug: 28526281
Change-Id: Iff48d02a2fee542c5ded7fc8cd6cf74957eb738c
/frameworks/base/core/java/android/content/pm/PackageManager.java
b1072718130b998e6d25bc3358eefa62b4fa5a2d 27-Apr-2016 Todd Kennedy <toddke@google.com> Don't override pre-release target sdk

If a package targets a pre-release SDK [eg a letter version] it should not
be allowed to be upgraded by a release SDK [eg a number version]. If one
absolutely must upgrade to a release SDK, use the "--force-sdk" option
during install.

Bug: 28345311
Change-Id: Ic9fb209968e7c5da2c80c5ca4c0f44f5125f610a
/frameworks/base/core/java/android/content/pm/PackageManager.java
ae0e03a9e03de34e37b768b971d7596d7220a053 26-Feb-2016 Svet Ganov <svetoslavganov@google.com> Cleanup of the PackageInstaller API - Frameworks

The PackageInstaller app manages side-loading apps as well
as permission management. It should be updatable, hence
should rely on system APIs to talk to the platform. This
is the first step of defining an API boundary.

Change-Id: I9814eafd0b22ae03b4b847a7007cdbf14c9e5466
/frameworks/base/core/java/android/content/pm/PackageManager.java
5a91b615232374084a45752d7c09c25265e263ed 22-Apr-2016 Svetoslav Ganov <svetoslavganov@google.com> Merge "Disallow disable of the system shared libs." into nyc-dev
ca82e616d3131570bf2ee29778f4796f343720d5 20-Apr-2016 Brian Carlstrom <bdc@google.com> Add reasons to notifyPackageUse calls

This is so we can record more specific times in PackageUsage.
If file with only one timestamp per package is found, the value is
copied to all usage slots.

Bug: 27902702
Change-Id: I8affe43c735e54620a9204433aad367cfddfded7
/frameworks/base/core/java/android/content/pm/PackageManager.java
59c9a93fc268e226495d4ee8cf7c507c2ea2c433 20-Apr-2016 Trevor Johns <trevorjohns@google.com> Merge changes from topic 'merge_docs_nyc-dev' into nyc-dev

* changes:
Remove links to createAndInitializeUser() and createUser()
Resolve merge conflicts of a5060ee to nyc-dev
682c24e22811d4ee17ae1cd61bf255c3f7e722b7 12-Apr-2016 Trevor Johns <trevorjohns@google.com> Resolve merge conflicts of a5060ee to nyc-dev

This undoes the automerger skip which occured in
commit e740c84dc32180214a7fd157105d6c18d30408ee and
replays it as a standard (NOT -s ours) merge.

Change-Id: If5a47be26f73d6a0735c425cd66310a3e2a89086
/frameworks/base/core/java/android/content/pm/PackageManager.java
e54b4397d37e12daa4d068feb61f9532afa6930e 18-Apr-2016 Craig Donner <cdonner@google.com> Merge "Replace CTS with CDD in comment for FEATURE_VR_MODE_HIGH_PERFORMANCE" into nyc-dev
8819c9d2ffff44098843e7380dff16e4ed640110 15-Apr-2016 Craig Donner <cdonner@google.com> Replace CTS with CDD in comment for FEATURE_VR_MODE_HIGH_PERFORMANCE

Bug: 27532416
Change-Id: I303d63d5b70434019acd77e8d82abcbabb1a85c1
/frameworks/base/core/java/android/content/pm/PackageManager.java
a9c2500a6863dabdd786f17a25ce0bf3683109a2 14-Apr-2016 Svetoslav Ganov <svetoslavganov@google.com> Disallow disable of the system shared libs.

bug:28173410

Change-Id: If731f2d90312a083bb940f83431ba3eccf213947
/frameworks/base/core/java/android/content/pm/PackageManager.java
78c9eb8947538f63d2e06684663d400991dfff8f 13-Apr-2016 Suprabh Shukla <suprabh@google.com> Added api to delete cache files for a given user

Added an api to delete application cache files for a specific user. This
allows settings to clear cache files for work profile apps as well.

Bug: b/25338468
Change-Id: I52d4944a7a03b6d63ad44dd6bb868aec62815eab
/frameworks/base/core/java/android/content/pm/PackageManager.java
d6ee0ba57906f83f45ca2a2cd835d7ff6e7a88df 01-Apr-2016 Todd Kennedy <toddke@google.com> Allow retrieving info /system components

Generally we return info for the latest installed package; which could
either be a built-in [i.e. on the /system partition] package or a user
updated package. In certain circumstances, we want to be able to get
the version on the /system partition regardless of whether or not the
user has updated it. We do this by passing MATCH_FACTORY_ONLY to
getPackageInfo().

Bug: 27469181
Change-Id: I8dd1d110e2d72e5c6f024812d0b5d15d8b217347
/frameworks/base/core/java/android/content/pm/PackageManager.java
cf3f0a11a83e7a798e0586a78efdafc82a7f3d08 18-Mar-2016 Jeff Sharkey <jsharkey@android.com> Update direct boot related documentation.

Also hide a few APIs as requested by council. Add a method to
easily determine if a given File would already be encrypted at rest
by the OS.

Bug: 27531029
Change-Id: Icad5f1cd56411ad3ac707db85fd7449acdcc4b94
/frameworks/base/core/java/android/content/pm/PackageManager.java
8a372a0a280127743ce9a7ce4b6198c7a02d2a4f 16-Mar-2016 Jeff Sharkey <jsharkey@android.com> Refactoring FBE APIs based on council feedback.

Mostly consists of removing the word "encryption" from most APIs,
since we can't actually make promises about the data being encrypted.

Bug: 27531029
Change-Id: Iace9d7c4e64716abf86ed11847c40f3947e1d625
/frameworks/base/core/java/android/content/pm/PackageManager.java
f9124ecad9ec20f572df8cdca6f985ef3f97210d 17-Mar-2016 Benjamin Franz <bfranz@google.com> Merge "Flush package restriction changes for a user." into nyc-dev
4dc008cda2980fabb6acbf8a3b7096d1090ee36f 16-Mar-2016 Tony Mak <tonymak@google.com> Fix NotificationListenerService fail to mirror work notification

1. Instead of getting application info in runtime, just retrieve the
one in the context to avoid cross user operation.

2. Functions in PackageManager that retrieve badged icon now return
badged icon if the targer user is managed profile instead of checking
whether target user is a managed profile of the user in mContext.

3. Relax the restriction of getUserInfo, if the caller is asking a user
in the same profile group or having the manage user permission, we let
it go.

Bug: 26469166

Change-Id: Ia1ffc5743f7d94bd489cdb7571eaed51499ebdd9
/frameworks/base/core/java/android/content/pm/PackageManager.java
bbb3ff2b2a29d42771a9ce2fe2d6f576cff62617 09-Jul-2015 Sudheer Shanka <sudheersai@google.com> Flush package restriction changes for a user.

Change-Id: I7c4481f820b6b368487d00de6c783e64cec99f4b
/frameworks/base/core/java/android/content/pm/PackageManager.java
ab750d283aca3dcfa8178589ca64e8be819f848b 10-Mar-2016 Kenny Guy <kennyguy@google.com> Merge "Update docs to make suspend then uninstall clear." into nyc-dev
39ceeb5472d920a6d5f6ddc1effdb9c4fedda4dd 10-Mar-2016 Jesse Hall <jessehall@google.com> Refer to hasSystemFeature(String, int) in Vulkan feature docs

Bug: 27531286
Change-Id: Ifb32ae519fc8118923d6216e1d574cbbf83dfd23
/frameworks/base/core/java/android/content/pm/PackageManager.java
871f3ebb56b5c9219ff3f9cf7bab98038a7b7a5a 09-Mar-2016 Kenny Guy <kennyguy@google.com> Update docs to make suspend then uninstall clear.

Update docs to say suspending then unintalling an
app unsuspends the app. Point out admin can block
uninstall if they want.

Bug: 26935242
Change-Id: I4390fa20c9d8954b36ff80fc449b62891eee598c
/frameworks/base/core/java/android/content/pm/PackageManager.java
dfa93abf2f64237007af8e72c4a4114a5258e858 04-Mar-2016 Todd Kennedy <toddke@google.com> Fix javadoc

Make referenced constants @SystemApi and change argument name to
match its actual meaning.

bug: 25441401
Change-Id: I4277799b95f394edb4305be05f57437717a86691
/frameworks/base/core/java/android/content/pm/PackageManager.java
e8498cd0066113068f2b0294144837546f213bd1 03-Mar-2016 Todd Kennedy <toddke@google.com> Merge "Splits without restart" into nyc-dev
66ae66a7f74ee835807a141a216afbb254664510 19-Feb-2016 Vadim Tryshev <vadimt@google.com> Adding getManagedUserBadgedDrawableForDensity() to PackageManager.

It allows badging an image regardless of of the user (no
user id parameter). The styling for managed users is applied.

This is useful for new cases where the existing functions
wouldn't badge the icon, but we need it.

Bug: 25192539
Change-Id: I2fd2f226f626fb2e6cda1cfe072013350e12b41c
/frameworks/base/core/java/android/content/pm/PackageManager.java
39bfee5e3674faea992c32204abc1c03429b8cda 24-Feb-2016 Todd Kennedy <toddke@google.com> Splits without restart

In specific cases [as determined by the installer], we can install
splits without restarting the application. The split must be purely
additive [i.e. it should not modify class(es)/resource(s) defined
in the base or other splits. Otherwise, the behaviour could be
inconsistent [e.g. if a modified class was already loaded, the
modified version won't be loaded until the process is restarted].
The platform does not perform any verification that the split is
purely additive.

Bug: 26463098
Change-Id: I3526c3b1b847a8e0afabc7a4787fa770422196b7
/frameworks/base/core/java/android/content/pm/PackageManager.java
093622f089a84298b5cfaab839eef6678292de5d 02-Mar-2016 Vadim Tryshev <vadimt@google.com> Revert "Adding getManagedUserBadgedDrawableForDensity() to PackageManager."

This reverts commit 9f68f41a5866e1feb810b16c769705c10e850d5d.

Caused breakage.

Change-Id: I441737f61f6f38ed9f440211b52bbac0f74982e3
/frameworks/base/core/java/android/content/pm/PackageManager.java
9f68f41a5866e1feb810b16c769705c10e850d5d 19-Feb-2016 Vadim Tryshev <vadimt@google.com> Adding getManagedUserBadgedDrawableForDensity() to PackageManager.

It allows badging an image regardless of of the user (no
user id parameter). The styling for managed users is applied.

This is useful for new cases where the existing functions
wouldn't badge the icon, but we need it.

Bug: 25192539
Change-Id: I20ca2d7265cbc3a47c050a72ec1843cc0a481c74
/frameworks/base/core/java/android/content/pm/PackageManager.java
a67932374dbbfbe4c6440d223fc7922b313dd957 24-Feb-2016 Todd Kennedy <toddke@google.com> Revert "Revert "Remove deprecated methods / classes""

This reverts commit 5cbeb5902633646fbc0a1be252081e77aaaee7b4.

Change-Id: Id96010364d65e6131221ebbcc8ce5889a2da256c
/frameworks/base/core/java/android/content/pm/PackageManager.java
e5d76e827600c44657e328599ffc9d0e8a258e58 29-Feb-2016 Ruben Brunk <rubenbrunk@google.com> Revert "DO NOT SUBMIT: Hide VR features for preview."

This reverts commit cfa66a2a45c3cec6c338d0d83806fb33d63cfd44.

Change-Id: Ibf36092205b14c29935d1f28be5f5b5f64b1d16c
/frameworks/base/core/java/android/content/pm/PackageManager.java
cfa66a2a45c3cec6c338d0d83806fb33d63cfd44 27-Feb-2016 Ruben Brunk <rubenbrunk@google.com> DO NOT SUBMIT: Hide VR features for preview.

Bug: 26945446
Change-Id: I37e2f9f6ffc65be60bcbef4bdf87da89561ef313
/frameworks/base/core/java/android/content/pm/PackageManager.java
921dd754ab49df0cd580ff96503f7616c4c85f4a 24-Feb-2016 Alex Klyubin <klyubin@google.com> Disallow downgrading of non-debuggable packages.

An attacker could downgrade a package to an older version with known
security vulnerabilities and then use some of the vulnerabilities to
access the application's data. This would constitute a bypass of
Android Application Sandbox. Thus, downgrading while keeping
application data is no longer permitted.

To help developers debug their apps, packages marked as debuggable can
still be downgraded while keeping their data. This does not put the
installed base at risk because, as a security measure, most
application stores reject packages marked as debuggable.

To downgrade a non-debuggable (i.e., release) package, uninstall the
package (thus wiping its data), then install the older version of the
package.

Bug: 27327503
Change-Id: Iac75ed3c3831b5d925dfd8b660527cfa95813da8
/frameworks/base/core/java/android/content/pm/PackageManager.java
f77a34fa17d64fad80f423aa8a86e781a7441b9e 05-Feb-2016 Jesse Hall <jessehall@google.com> PackageManager: add Vulkan system features

FEATURE_VULKAN_HARDWARE_FEATURES describes the feature set supported
by the device hardware and driver. FEATURE_VULKAN_HARDWARE_VERSION
describes the Vulkan API version supported by the driver, which may be
lower than the API version supported by a particular Android release.

Bug: 26583896
Change-Id: Ia3e6be496abf631cb677eb838d632d3c7b4dd24b
/frameworks/base/core/java/android/content/pm/PackageManager.java
0f3431b616e03fe76cb52cabad209f95e1d7899c 19-Feb-2016 Svetoslav Ganov <svetoslavganov@google.com> Merge "Improve requestPermissions API docs and throw correct exception." into nyc-dev
f66381cd0df0aad41b7e4db9994483e44e0aaada 19-Feb-2016 Svet Ganov <svetoslavganov@google.com> Improve requestPermissions API docs and throw correct exception.

bug:26220898

Change-Id: Iebda3fe13b963b10829de917fb00a9a14186b72c
/frameworks/base/core/java/android/content/pm/PackageManager.java
fc482c30b7a3c2cf7bc14d5c86de758a16f6433d 17-Feb-2016 Makoto Onuki <omakoto@google.com> Merge "[framework] Don't allow apps on external storage to be active admin" into nyc-dev
f34db0a17ee035c165a4e81e9192f73d2455bd1c 17-Feb-2016 Makoto Onuki <omakoto@google.com> [framework] Don't allow apps on external storage to be active admin

Bug 27149287

Change-Id: I6d959d2e66dc0b19f78e6135fbdcf45ca8551958
/frameworks/base/core/java/android/content/pm/PackageManager.java
eb84b1843a3f6805c6109c1d9d023550229a3fc5 26-Jan-2016 Andrei Stingaceanu <stg@google.com> Suspend packages - one call for multiple packages

Refactor setPackageSuspended into setPackagesSuspended. The rationale
is that the consumers of this API are likely to want to remove
multiple packages at once. Rather than calling the API N times, call
it just once.

The good part is that we already have the broadcast intent for
suspended packages take an array so only one broadcast. Less stress
on the system.

Another good part is that (right now) we only have one consumer of
this API and it will be easy to make changes once this CL goes in.

As a shell command, for consistency only allowed one package at
a time.

Bug: 22776761
Change-Id: Ic8b8cf64d0a288ea3a282bb7b72f9d663b3b0049
/frameworks/base/core/java/android/content/pm/PackageManager.java
5ae4e73ef0747c2d08a901f1a76d8fb8ee64a53a 17-Feb-2016 Andrei Stingaceanu <stg@google.com> Merge "Suspend packages - new API for retrieving the suspended status" into nyc-dev
355b232d7998cfc9b29d42a0356390e25191bcbd 12-Feb-2016 Andrei Stingaceanu <stg@google.com> Suspend packages - new API for retrieving the suspended status

Instead of always rebuilding the full ApplicationInfo for a
package when callers are only interested in the suspended status
add a new fast API in Packagemanager (which only checks the
suspended user setting for the requested package and returns
a boolean) and change the appropriate caller code too.

Bug: 26794775
Bug: 22776761
Change-Id: Ide8428ef734479360d5a8a75fd8e0ed8ddf2da7a
/frameworks/base/core/java/android/content/pm/PackageManager.java
115d2c189a46f535778d9dd0923f703ff2f888fe 16-Feb-2016 Jeff Sharkey <jsharkey@android.com> Add feature versions for devices and apps.

We're starting to see more instances of device features that will
increment separately from the SDK API level, such as camera HAL,
GPU capabilities, Bluetooth, and other hardware standards.

This change adds the ability for device features to specify a
version, which is defined to be backwards compatible. That is, apps
requesting an older version of a feature must continue working on
devices with a newer version of that same feature.

When a version is undefined, we assume the default version "0".

Bug: 27162500
Change-Id: If890bf3f3dbb715e8feb80e7059a0d65618482ea
/frameworks/base/core/java/android/content/pm/PackageManager.java
d7b1f41109abee60ec8529369a85d84300b1d678 10-Feb-2016 Svet Ganov <svetoslavganov@google.com> Add an API to query the package name of the services shared lib

The servcies shared lib contains components apps can invoke such
as services to bind to, activities to start, UI choosers, etc.
This lib is built from AOSP code but an OEM may chage its
package name. For example, Google renames the package names for
GMS apps from android.foo.bar to com.google.android.foo.bar.
While we have more than one shared lib that are a part of the
platform (currently shared and services libs) the serivces lib
is the only one clients need to start components in, thus need
to know its package name. This change adds an API to query the
package name of the services shared lib. The API is hidden as
currently the only clients are a part of the system.

Change-Id: Ied48fa4819024522791764b22b3336d4f4b42cc3
/frameworks/base/core/java/android/content/pm/PackageManager.java
354cd3ce2213a1032d9138ea6fa1420f055ab08c 17-Dec-2015 Svet Ganov <svetoslavganov@google.com> Multi packages per APK

This change introduces the ability to have multiple packages per
APK. The feature is currently restricted to privileged apps and
updates to such apps.

In essence the manifest can have multiple child package declarations.
A child package can declare everything an Android package can except
some tags or attributes that are not applicable and instead inherited
from the parent when needed. For example, the target SDK of the parent
applies to all children.

A child package can be updated only through the parent package.
A package with multiple child packages is installed, uninstalled
atomically - no partial installs where some child packages are not
installed.

The remaining work is to ensure broadcasts are also sent for child
packages. This will come in a subsequent change.

Sample app:ag/848432

Design doc: https://docs.google.com/document/d/18nFWtJuZchLxrHf5SBbJW03-Ky9Rh_G0-OVB14b6u78

Change-Id: I6fd021d981bf5786290e0c53502724a14c97358c
/frameworks/base/core/java/android/content/pm/PackageManager.java
e4697136ed8d3e2486738b5798b22f2226b7de75 07-Feb-2016 Jeff Sharkey <jsharkey@android.com> Migrate default app data on non-FBE devices.

When a system app requests "forceDeviceEncrypted" they expect their
default app storage to point at a consistent location regardless of
device FBE support. So when booting upgraded non-FBE devices, we
may need to migrate any data from CE to DE. Note that on non-FBE
devices these are just semantic locations with identical protection.

This migration *only* works for non-FBE devices; changing
forceDeviceEncrypted flags on an FBE device always requires a full
data wipe.

Bug: 26668510
Change-Id: Ic5dfeaaf2db26c385901a638ca8ec35eb3c52859
/frameworks/base/core/java/android/content/pm/PackageManager.java
33e0a5f7edc39d676bb7bd8a3e471d753f223953 01-Feb-2016 Ruben Brunk <rubenbrunk@google.com> Merge "Add feature tag for high-performance VR devices."
7b9f2e1d86e5017dbf5530356ec30d090f703a67 28-Jan-2016 Fyodor Kupolov <fkupolov@google.com> Merge "Added SystemApi for getting serial numbers of users"
940e8577a1569140521fb605336997863529f7ad 26-Jan-2016 Fyodor Kupolov <fkupolov@google.com> Added SystemApi for getting serial numbers of users

Also added UserHandle version of queryBroadcastReceiversAsUser.

Bug: 25844894
Change-Id: I78ecbef186e4ced10425ae2899db72c2d91c5792
/frameworks/base/core/java/android/content/pm/PackageManager.java
b92b05bb4bcaa6f7869128e925d0331eee62e4da 28-Jan-2016 Jeff Sharkey <jsharkey@android.com> Report FBE through a feature string.

Since devices can be converted to enable/disable FBE across a
factory reset, we offer to add the features dynamically depending
on device status.

Bug: 26808417
Change-Id: I905140ba500a5e69756b547f2b1d6167b9a37dc6
/frameworks/base/core/java/android/content/pm/PackageManager.java
31d80ea1815d41b3b8fe2698732dfc310a0fc633 26-Jan-2016 Ruben Brunk <rubenbrunk@google.com> Add feature tag for high-performance VR devices.

Bug: 26667978
Change-Id: I4adeaebdf4cb77eb8ba889bd25f678d873c493cd
/frameworks/base/core/java/android/content/pm/PackageManager.java
f82ab8bea4c914c567a3487297fd4914561978a1 25-Jan-2016 Martijn Coenen <maco@google.com> Merge "Implementation of HCE for NFC-F." am: e168012ff2
am: cf2f9d0966

* commit 'cf2f9d0966af01eb269b9ce6f2d08870647dd22f':
Implementation of HCE for NFC-F.
c52adfe12469a1d1bcd5b7119b83363e094a7b84 22-Jan-2016 Yoshinobu Ito <Yoshinobu.Ito@jp.sony.com> Implementation of HCE for NFC-F.

This impementation includes HCE(Host-based Card Emulation) for NFC-F
which emulates NFC Forum Type 3 Tag on a smartphone.

Signed-off-by: Daisuke Ito <DaisukeE.Ito@jp.sony.com>
Yoshinobu Ito <Yoshinobu.Ito@jp.sony.com>

Change-Id: I1618a7fba801e0705ff3cc078206a1446b3dd56d
/frameworks/base/core/java/android/content/pm/PackageManager.java
e6ff946cd4f40a0d4f3de51b6554e07b8d3cee93 16-Jan-2016 Selim Cinek <cinek@google.com> Switched the work profile badge used in the notifications

Change-Id: I62616f1ae8fcda9953853b9859c69a9f1e6f44ca
/frameworks/base/core/java/android/content/pm/PackageManager.java
3da7357951a1981ecf40391e19ad8e53b45cb046 15-Jan-2016 Etan Cohen <etancohen@google.com> Merge "NAN: baseline NAN manager for discovery." into mm-wireless-dev
am: e540b64aaf

* commit 'e540b64aaf58460f7930a5e4937cee660215c948':
NAN: baseline NAN manager for discovery.
20d329b08df7d1a94e6caee781f09e812a79c913 29-Sep-2015 Etan Cohen <etancohen@google.com> NAN: baseline NAN manager for discovery.

Initial framework for user API (all @hide for now). Supports:
- NAN configuration
- Publish/Subscribe = Discovery
- Message passing
- Notifications

Bug: 26216681
Change-Id: I72e467756a02f7b80c52fae916b9a47c8174af42
/frameworks/base/core/java/android/content/pm/PackageManager.java
c3132513bf73022cb299c9041727233300c46a5c 12-Jan-2016 Jeff Sharkey <jsharkey@android.com> Parsing a static archive should be stateless.

When the caller hasn't specific encryption-related matching flags,
we should match both aware and unaware components.

Bug: 26508249
Change-Id: I2c35f6e00e451ba3f5fa0810223b7a3d80dee233
/frameworks/base/core/java/android/content/pm/PackageManager.java
12705131b95d5d6bcfae79d7991ff3e6f02457e4 06-Jan-2016 Todd Kennedy <toddke@google.com> Hide ephemerality

Change-Id: Ibf60366b3f00b1920e330cd804bcc1c550f8882a

Bug: 26404647
/frameworks/base/core/java/android/content/pm/PackageManager.java
bc215b8426a706c0813575f95d9bd076a060eda2 10-Jan-2016 Jeff Sharkey <jsharkey@google.com> Merge "Fix NPE when UID has no packages."
377ded0fce449f77cd7efae35f97722cdab52693 10-Jan-2016 Jeff Sharkey <jsharkey@android.com> Fix NPE when UID has no packages.

Bug: 25224723
Change-Id: I637214666a1f02bd23474c27a285eea9152cfa9d
/frameworks/base/core/java/android/content/pm/PackageManager.java
5aa86938b8b50a20830bc3d608321fc4c0afb0e8 09-Jan-2016 Jeff Sharkey <jsharkey@android.com> Fix docs build by removing bad links.

Also define InstallFlags and DeleteFlags, and point installPackage()
users towards new PackageInstaller APIs. Remove old movePackage()
API that is no longer used.

Change-Id: I661a65149e4778a7591dbd912b72b4dd81b266da
/frameworks/base/core/java/android/content/pm/PackageManager.java
2b60ca45a1e97bd62e84e5de6ebd353fef956a80 09-Jan-2016 Amith Yamasani <yamasani@google.com> Fix typo in javadoc

Change-Id: I7a61f84f9d19d5ebc64c3a6e01eea42c3fac4fed
/frameworks/base/core/java/android/content/pm/PackageManager.java
cd65448ccd13c4c2d0fe9e9623fec3a898ab9372 09-Jan-2016 Jeff Sharkey <jsharkey@android.com> Even more PackageManager caller triage.

Finish moving all UID/GID callers to single AIDL method that requires
callers to provide flags.

Triage AppWidgets and PrintServices, which currently can only live on
internal storage; we should revisit that later.

Fix two bugs where we'd drop pending install sessions and persisted
Uri grants for apps installed on external storage.

Bug: 26471205
Change-Id: I66fdfc737fda0042050d81ff8839de55c2b4effd
/frameworks/base/core/java/android/content/pm/PackageManager.java
629f98466a4c2d778ddd4ce5a9df107e28f9b98a 09-Jan-2016 Jeff Sharkey <jsharkey@android.com> Fix build.

Change-Id: If128c90225a2237ea015063cec526a64af5bf576
/frameworks/base/core/java/android/content/pm/PackageManager.java
c4fd3c9871e8a2b28ccc6bb51bf4a62b913dba0a 09-Jan-2016 Jeff Sharkey <jsharkey@google.com> Merge "Update javadoc for flags"
6b9bfa1d16f5b3c28b140ae579c031938f207c43 08-Jan-2016 Todd Kennedy <toddke@google.com> Update javadoc for flags

Bug: 25997037
Change-Id: Ia44634b0271ad0195d857ef13afec2a1ef022fae
/frameworks/base/core/java/android/content/pm/PackageManager.java
0ab0bdde2b39c77175d9e0d69d6631e130e4b5ac 09-Jan-2016 Jeff Sharkey <jsharkey@google.com> Merge "More progress on triaging PackageManager callers."
c5967e9862489024c932b0c7fcb84ed0af2a7fd7 08-Jan-2016 Jeff Sharkey <jsharkey@android.com> More progress on triaging PackageManager callers.

Catch a bunch of simple cases where the PackageManager flags are
obvious. Add the ability to use the MATCH_SYSTEM_ONLY flag on
PackageInfo and ApplicationInfo queries.

Re-examine recent tasks after a user is unlocked, since some of the
activities may now be available and runnable.

Bug: 26471205, 26253870
Change-Id: I989d9f8409070e5cae13202b47e2c7de85bf4a5b
/frameworks/base/core/java/android/content/pm/PackageManager.java
bd9402289311c4f3afc3c319075d89cd8ed2fcc4 08-Jan-2016 Jeff Sharkey <jsharkey@android.com> Oh look, GmsCore is using more hidden APIs.

Bug: 26429932
Change-Id: Ie949d4bbdead8864aaed16282a591258ef528ca8
/frameworks/base/core/java/android/content/pm/PackageManager.java
819d2745b4e04eb684ab323742b718c66d19c2c1 30-Sep-2015 Todd Kennedy <toddke@google.com> Update PackageInstaller install handing

* Allow forcing permission check. We want to modify the PackageInstaller to
use the PackageInstallerSession for better security / remove deprecated APIs.
In order to do this and continue to prompt for permissions, we need to prevent
the PakcageInstaller from auto-approving the permissions.

* Add originating UID to SessionParams. This is used for package verifier
checks.

Bug: 22282121
Change-Id: I19079749d20ace66f1332f399d52cb0fb8784cd9
/frameworks/base/core/java/android/content/pm/PackageManager.java
8588bc1ef1f020bbe4a24d46874f675708149a57 07-Jan-2016 Jeff Sharkey <jsharkey@android.com> Add flags to requests for package UID/GIDs.

This gives callers the ability to request details for missing
packages. Also add annotations for userId and appId variables and
start tagging their usage.

Change-Id: I63d5d7f870ac4b7ebae501e0ba4f40e08b14f3f6
/frameworks/base/core/java/android/content/pm/PackageManager.java
a73b8fd1f4faaad00d8a49d6e496aaf249fa7003 07-Jan-2016 Jeff Sharkey <jsharkey@android.com> Add some TestApis to fix build.

Change-Id: Icf0d8d63f3a41d99e46ebe96003863bae637bd9d
/frameworks/base/core/java/android/content/pm/PackageManager.java
e06b4d1d9f718b9fe02980fea794a36831a16db2 06-Jan-2016 Jeff Sharkey <jsharkey@android.com> Consistent naming for PackageManager methods.

When hidden PackageManager methods take a userId argument, they
should be named explicitly with the "AsUser" suffix. This fixes
several lagging examples so that we can pave the way to safely
start passing flags to new methods without scary overloading.

Also fix spacing issues in various logging statements.

Change-Id: I1e42f7f66427410275df713bea04f6e0445fba28
/frameworks/base/core/java/android/content/pm/PackageManager.java
4efb8b4030157dd7445bed37538044949b0641af 06-Jan-2016 Jeff Sharkey <jsharkey@android.com> Add Ethernet feature.

Change-Id: I1f1badff5a8c9237d9489497e36e2578266e34b4
/frameworks/base/core/java/android/content/pm/PackageManager.java
4f6d400b0fa4c94e0f785a7b15ffb30126e6759d 05-Jan-2016 Alex Klyubin <klyubin@google.com> Merge "No need to pass digest of AndroidManifest.xml around."
31ffb442414bd9cf6c0225799d7d0c5409f3769d 21-Dec-2015 Alex Klyubin <klyubin@google.com> No need to pass digest of AndroidManifest.xml around.

When an APK is being installed, the full path to the file is
occasionally passed between processes. To detect changes to the file
during these handovers, the digest of the AndroidManifest.xml entry
could be passed around as well.

This security feature is no longer used and is no longer needed. APKs
should be installed using the modern Package Installer API
(android.content.pm.PackageInstaller).

Bug: 24542768
Change-Id: I2762634c85448e7adcd47ffc9a5294c021e127bd
/frameworks/base/core/java/android/content/pm/PackageManager.java
2f3e35376ada0327b34a71d7c45ac6e6d955d7dc 21-Dec-2015 Jeff Sharkey <jsharkey@android.com> More work towards triaging missing app behavior.

Many places across the platform query package details without
gracefully handling packages or components that go missing for
various reasons. This can cause annoying user data loss, such as
resetting back to built-in apps or dropping of accounts, etc.

This change verifies that system callers have thought about these
edge cases by logging if they use default matching behaviors without
explicitly marking themselves as being "triaged." (The logging is
currently disabled by default.)

Also creates explicit definitions of supported flags for various
incoming PackageManager calls, and defines a clear distinction
between flag types:

-- GET-style flags are used to request additional data that may have
been elided to save wire space.

-- MATCH-style flags are used to include components or packages that
would have otherwise been omitted from a result set by current system
state.

There are a handful of existing GET flags that better fit under the
MATCH definition, so this change clones them to new constants and
marks the old ones as deprecated.

Fixes bug in JobSchedulerService to consider jobs from apps on
external storage. Revert some dialer behavior back to being
untriaged.

Change-Id: I9b6ab0968241e3479bddbd78de0c51e3b9917318
/frameworks/base/core/java/android/content/pm/PackageManager.java
5217cacbd9f382068bb9e176cd5a0b15388a335c 20-Dec-2015 Jeff Sharkey <jsharkey@android.com> Make JobSchedulerService encryption aware.

When a user is started, but a persisted job component doesn't appear
in the normal resolution list, we avoid enqueuing the job. Later
when the user is unlocked, we take another pass over the pending
jobs to see if they became available.

Load keyboard layouts from XML metadata regardless of crypto status,
since we don't need to spin up any remote code.

Add MATCH_SYSTEM_ONLY to make system logic easier to write when
looking for trusted components.

Sprinkle more annotations on ArrayUtils methods.

Bug: 26279465
Change-Id: Iec28e0bb46862b07d740b12a79f6360de68dab0f
/frameworks/base/core/java/android/content/pm/PackageManager.java
2a9e3f8e6813716ab88ca54fd04ae047dc9aaaeb 18-Dec-2015 Jeff Sharkey <jsharkey@android.com> Better named encryption flags, start triaging.

Create distinct flags for encryption aware, unaware, and both, and
name them like the other MATCH_ flags.

Start adding logic to help triage all system internal callers to
verify that they've done their homework and thought about how to
handle apps while locked. Call sites in the system should either
ask for explicit matching behavior, or explicitly use the DEFAULT
match flag to indicate that they've been triaged to use the
default state-based matching.

Bug: 26250295
Change-Id: I86214e5c4f71a6dc72f06930800388713aecd107
/frameworks/base/core/java/android/content/pm/PackageManager.java
55bed957788e853d3ee3f674dd6eea79ad3a193b 18-Dec-2015 Ruben Brunk <rubenbrunk@google.com> Merge "Add a framework service tracking VR mode state."
373f0b4313d3a2444aebf6b89a71c4ba64566110 16-Dec-2015 Todd Kennedy <toddke@google.com> revert quick install

bug: 25118622
Change-Id: I61c3a1ea9015599dc45bd9e656f99f6bf8c4ec02
/frameworks/base/core/java/android/content/pm/PackageManager.java
dd18a0b69537954d1cc34929a1386deb54f12b14 05-Dec-2015 Ruben Brunk <rubenbrunk@google.com> Add a framework service tracking VR mode state.

- Implement a "VR mode" that may be enabled by a focused Activity.
- Add a system service that tracks the current VR mode state and notifies
other core framework services of mode changes.
- Extend NotificationListenerService to allow the bind/unbind lifecycle
of specified listeners to be triggered by system events.

Bug: 22855417
Bug: 25479708

Change-Id: I1ac8692bbb5521bb6c7cfb9d2b56b98b720f8568
/frameworks/base/core/java/android/content/pm/PackageManager.java
1e2839188fb49575b86646d3aadb355c81ef9cc5 26-Nov-2015 Andrei Stingaceanu <stg@google.com> Wire call to suspend a package

Adds APIs in DevicePolicyManager and PackageManager for allowing
a device admin to suspend a package. PackageManagerService sets
or unsets a new PackageUserState 'suspended' setting. Terminal
command to suspend/unsuspend has been added via
PackageManagerShellCommand (as root).

Next steps:
* use the new 'suspended' setting for denying access to start app
(probably in ActivityStackSupervisor)
* broadcast a PACKAGE_(UN)SUSPENDED intent for launchers to pick up
* remove app from recents (go further and kill it if it is running)
* erase existing notifications for this app

Bug: 22776576
Change-Id: I718b3498f6a53cc0c6fdfb6d15031e53ddca4353
/frameworks/base/core/java/android/content/pm/PackageManager.java
fbe12c4e0ff33f385704edd34aabe6eaa75fedbe 07-Dec-2015 Wale Ogunwale <ogunwale@google.com> Added PackageManager#FEATURE_PICTURE_IN_PICTURE

Indicating that a device supports picture-in-picture
multi-window mode.

Also allow activities to be in Pip mode if force resizeable
is enabled.

Bug: 25580820
Bug: 26187878
Change-Id: If80edfee39ece5a51d21040e4d3a8a9135aa1783
/frameworks/base/core/java/android/content/pm/PackageManager.java
2acf063da08dfff69f184c9a6a90a7a5fe60d818 25-Nov-2015 Svet Ganov <svetoslavganov@google.com> Ephemeral cookie API

Add APIs for an ephemeral app to set a cookie which is a small
peice of data cached longer than the app itself. This is useful
for avoiding the user to login every time they use the ephemeral
app. The cookie is stored after an ephemeral app is uninstalled.
Normal apps or ephemeral apps upgraded to full apps can also use
these APIs with the difference that once they are uninstalled
the cookie is deleted.

The cookie size defaults to 16KB and is configurable by a global
settings which can be adjusted via gservices. Also eviction policy
is time based with a default of one month and is configurable by
a global setting which can be adjusted via gservices. If the cert
of the app cahnges (when ephemeral is installed, uninstalled and
installed again) the cooke is wiped to prevent data leaks.

This cahange also adds an API for apps to know whether they run in
an ephemeral mode since it this mode some APIs will not be available.
Another API exposed by this change is private for the system and
exposes all ephemeral apps - installed and uninstalled. Only the
system can call this API. When an ephemeral app is uninstalled the
system stores its name, icon, and permissions. When the app is
reinstalled or a full version is installed the permissions are
propagated.

Change-Id: Id4a73a7750bfbabda0bfcb9bf9018d2062e94367
/frameworks/base/core/java/android/content/pm/PackageManager.java
c72b3101ee368d2a9943e4436ede679acfa38f92 07-Dec-2015 Todd Kennedy <toddke@google.com> Merge "Add ephemeral installs"
b3523c45dd764ba9926ee70a04cfee78b10e7ab4 04-Dec-2015 Tony Mak <tonymak@google.com> Merge "Introduce ONLY_IF_NO_MATCH_FOUND in CrossProfileIntentFilter"
2699f065558ba78066887210b0c7346105959860 20-Nov-2015 Todd Kennedy <toddke@google.com> Add ephemeral installs

* Add a new --ephemeral argument to 'adb install'
* Add plumbing to internally track ephemeralness
* Create new app directory for ephemeral installs

Bug: 25119046
Change-Id: I1d379f5ccd42e9444c9051eef2d025a37bd824fe
/frameworks/base/core/java/android/content/pm/PackageManager.java
9c165d76010d9f79f5cd71978742a335b6b8d1b4 02-Dec-2015 Svet Ganov <svetoslavganov@google.com> Add optional permission review for legacy apps - framework

For some markets we have to allow the user to review permissions
for legacy apps at runtime despite them not supporting the new
permission model. This is achieved by showing a review UI before
launching any app component. If an update is installed the user
should see a permission review UI for the newly requested
permissions.

To allow distinguishing which permissions need a review we set
a special flag in the permission flags that a review is required.
This flag is set if a runtime permission is granted to a legacy
app and the system does not launch any app components until this
flag is cleared. Since install permissions are shared across all
users the dangerous permissions for legacy apps in review mode
are represented as always granted runtime permissions since the
reivew requirement is on a per user basis.

Whether the build supports permission review for legacy apps is
determined by a build constant allowing us to compile away the
unnecessary code for markets that do not require a permissions
review.

If an app launches an activity in another app that has some
permissions needing review, we launch the permissions review
UI and pass it a pending intent to launch the activity after
the review is completed.

If an app sends a broadcast to another app that has some permissions
needing review, we do not deliver the broadcast and if the sending
app is in the foreground plus the broadcast is explicit (has a
component) we launch the review UI giving it a pending intent to
send the broadcast after the review is completed.

If an app starts a service in another app that has some permissions
needing review, we do not start the service and if the calling app
is in the foreground we launch the review UI and pass it a pending
intent to start the service after the review is completed.

If an app binds to a service in another app that has some permissions
needing review, we schedule the binding but do not spin the target
service's process and we launch the review UI and pass it a callback
to invoke after the review is completed which spins the service
process and completes the binding.

If an app requests a content provider in another app that has some
permissions needing review we do not return the provider and if
the calling app is in the foreground we show the review UI.

Change-Id: I550f5ff6cadc46a98a1d1a7b8415eca551203acf
/frameworks/base/core/java/android/content/pm/PackageManager.java
807e01cb47c2d5442f76e27b70a7206f77ed76d8 01-Dec-2015 Tony Mak <tonymak@google.com> Introduce ONLY_IF_NO_MATCH_FOUND in CrossProfileIntentFilter

With this flag, activities in other profiles can respond to the intent
only if no intent-filter with non-negative priority in current profile can
respond to it.
It is designed like this because activities with negative priority
intentfilter are always used as a fallback in case no one can respond
to the intent. In this case, we expect there is a "real" activity in
other profiles can handle the intentfilter

Here is the example activity that handle the call related intents when
there is no dialer.

NonPhoneActivity.java in Contacts app is an example.
https://github.com/android/platform_packages_apps_contacts/blob/master/AndroidManifest.xml#L461

Bug: 25760508

Change-Id: Ife2a7c19e91ddf5d2e81ad09bd4cf712cdcdb986
/frameworks/base/core/java/android/content/pm/PackageManager.java
811dc3b42b4d3c967a2304bf1e01840147b1a528 23-Nov-2015 Filip Gruszczynski <gruszczy@google.com> Allow preloading of freefore multi window drawables.

Bug: 25081468
Change-Id: Ic6ec6050882e5362e1ab8734962d163fff04b53d
/frameworks/base/core/java/android/content/pm/PackageManager.java
ba51235ef5c598d845b77fcf14491329493da34f 13-Nov-2015 Jeff Sharkey <jsharkey@android.com> More file-based encryption work.

Add new "am unlock-user" command so we can trigger changes from the
command line.

Move FBE check to static method so it can safely be called early
during boot before the mount service is ready. Move FBE emulation
to persisted system property, and start reading/writing that value.

Change default permission grants to ignore current encryption-aware
flags, since many of the target apps aren't crypto aware.

Always prepare package data directories, which is how we create the
new "user_de" paths during boot.

Bug: 22358539
Change-Id: I6f58ea2d34b3a466d3775d614f8a13de92272621
/frameworks/base/core/java/android/content/pm/PackageManager.java
e17ac1569793c333bb4dce86607a342e7c982ae7 07-Nov-2015 Jeff Sharkey <jsharkey@android.com> More APIs for encryption-aware apps.

Apps can mark manifest components as being encryption-aware, which
means they can safely be run before the credential encrypted storage
is available.

Start adding filtering logic so that we only return these components
when a user is running "with amnesia." That is to say, only device
encrypted storage is available, so the user is running but with only
partial knowledge of its data.

To avoid calling into ActivityManager with the PackageManager lock
held, we quickly determine user state and splice the state into the
flags for later per-component evaluation.

Bug: 22358539
Change-Id: Idc56ec29f1ef04da8963e004314d7f5e47400997
/frameworks/base/core/java/android/content/pm/PackageManager.java
7587edccd04a5e76ca712fc34fbab0fb562ac86e 31-Oct-2015 Glenn Kasten <gkasten@google.com> CDD for pro audio feature does not specify acoustics

Change-Id: If24a2ee485a35ad18969abacf55798b64ff939af
/frameworks/base/core/java/android/content/pm/PackageManager.java
56f0720fd7f67bc8e71c98459ef7a255a6f35f4b 28-Oct-2015 Vladislav Kaznacheev <kaznacheev@google.com> Merge " Add PackageManager.FEATURE_FREEFORM_WINDOW_MANAGEMENT"
d303b25ad3dc7249800b28c4a5bda2d787f0c4c5 28-Oct-2015 Vladislav Kaznacheev <kaznacheev@google.com> Add PackageManager.FEATURE_FREEFORM_WINDOW_MANAGEMENT

Bug: 25329519

Change-Id: Ib09cb2332ee1810b2f774a8453fe519fa920cd5d
/frameworks/base/core/java/android/content/pm/PackageManager.java
27c24fb8b85c36298de053699b1967a808c6d308 18-Sep-2015 Todd Kennedy <toddke@google.com> Enable "quick install"

Quick install skips a lot of the normal install steps in order to
dramatically reduce the installation time [eg Twitter normally takes
20s to install. But, installs in under 2.5s with quick install]

The specific optimizations [with caveats]:
1. Use the JIT. Although the oat file is technically created, it
only contains the exploded contents of the APK and does not contain
pre-compiled native binary code. While this improves install time,
it impacts app execution. [saves 17s]
2. Bypass Play verification. Play normally verifies all installs
to ensure we're not installing malware. But, it can take multiple
seconds for Play to collect and send package information to our
backend servers. [saves 2.7s]
3. Reduce JAR file verification. Due to the structure of the JAR
certs, we cannot completely bypass JAR processing. However we skip
the step of verifying every manifest entry. [saves 1.3s]

NOTE: #2 and #3 will only occur on eng/user-debug builds.

Bug: 22848361
Change-Id: I48e77595ad5c13a9534fdb06da67ba8dae2797fb
/frameworks/base/core/java/android/content/pm/PackageManager.java
3da3ca609ec48e1ff23bcfda0b208632fab88d80 01-Oct-2015 Todd Kennedy <toddke@google.com> Merge "Update PackageInstaller install handing"
a1d12cfdb072acb14fa95d5e771e23396e6bd8e1 30-Sep-2015 Todd Kennedy <toddke@google.com> Update PackageInstaller install handing

* Allow forcing permission check. We want to modify the PackageInstaller to
use the PackageInstallerSession for better security / remove deprecated APIs.
In order to do this and continue to prompt for permissions, we need to prevent
the PakcageInstaller from auto-approving the permissions.

* Add originating UID to SessionParams. This is used for package verifier
checks.

Bug: 22282121
Change-Id: I19079749d20ace66f1332f399d52cb0fb8784cd9
/frameworks/base/core/java/android/content/pm/PackageManager.java
9a80e53b27cd1ca00364a30a0ad153c83000b9d2 23-Sep-2015 Nicolas Prevot <nprevot@google.com> Add more methods that take a userId to PackageManager.

Add methods installPackageAsUser and installExistingPackageAsUser
and deletePackageAsUser and getPackageInfoAsUser.

BUG:23516394
Change-Id: I15e30d2ec45ab18c7f8c0ac02cfc617c50fedb44
/frameworks/base/core/java/android/content/pm/PackageManager.java
3355eca23e89045be068b39f5236cd43406a2a2d 23-Sep-2015 Nicolas Prévot <nprevot@google.com> Revert "Add more methods that take a userId to PackageManager."

This reverts commit 3b0fc3cf24e1fecdbc11808483c2109415ebfdd2.

It breaks the build. I had missed other places that extend PackageManager.

Change-Id: Iff012ed4ec8d2d32821586eca85fce55ae67f5b5
/frameworks/base/core/java/android/content/pm/PackageManager.java
3b0fc3cf24e1fecdbc11808483c2109415ebfdd2 21-Sep-2015 Nicolas Prevot <nprevot@google.com> Add more methods that take a userId to PackageManager.

Add methods installPackageAsUser and installExistingPackageAsUser
and deletePackageAsUser and getPackageInfoAsUser.

Change-Id: I9a3ff96f968b4f8d21a57cc7760679628d35c1a9
BUG:23516394
/frameworks/base/core/java/android/content/pm/PackageManager.java
56f0ff3c48c88b969d9bf5e62eb1ee590e03e461 14-Aug-2015 Christopher Tate <ctate@google.com> Make "Ask every time" actually work that way

..in link-opening behavior. If a candidate is marked as "ask
every time," then the user is guaranteed to get a disambiguation
prompt including that candidate even when some other candidate
app is in the "always prefer this over a browser" state.

Bug 23147746

Change-Id: I904d8697a992b3f16f32b1c1b49c2bf9424c7137
/frameworks/base/core/java/android/content/pm/PackageManager.java
f1b7f20bb839c96e8254ccb65398135f10fd45d9 29-Jul-2015 Svet Ganov <svetoslavganov@google.com> Remove dependencies on the package installer's package name

bug:22700053

Change-Id: I8540eb8577fbec84e1a67e31e1c31ba654c828a4
/frameworks/base/core/java/android/content/pm/PackageManager.java
d9b9d41082dae0a4bbed1bdb8a62f9f7e87ec14c 23-Jul-2015 Jim Miller <jaggies@google.com> Add FEATURE_FINGERPRINT to PackageManager's feature list

Fixes bug 22674557

Change-Id: I3d78e6bedc3ac18a25a06ac50e3a7eee4161fe70
/frameworks/base/core/java/android/content/pm/PackageManager.java
171fe6ac0aa5b0d2dd64ac1cdda25cdcb5f183f3 10-Jul-2015 Svet Ganov <svetoslavganov@google.com> Merge "Add an API for apps to query if a permisison is denied by policy." into mnc-dev
ad3b2975574f916c14382628d50c710a78064746 08-Jul-2015 Svet Ganov <svetoslavganov@google.com> Add an API for apps to query if a permisison is denied by policy.

bug:22177216

Change-Id: I32227f55097fae997f33743fd1eee06cb18f47f1
/frameworks/base/core/java/android/content/pm/PackageManager.java
4a5f4a2bc7a379a5b4174f78fefeefe745e6cd37 08-Jul-2015 Svetoslav <svetoslavganov@google.com> Fix reset permissions on clear data and package uninstall.

If the user clears data for an app we reset the permission but
only the changes made by the user. We do not modify syste or
policy flags and also ensure the permission that were granted
by default are granted after the data wipe. This is the same
as starting with a clean slate.

If the package whose data is cleared is a part of a shared user
we resent to initial state only the permissions that the cleared
package contributed. Hence, if another package also declared the
permission as used we do not clear the permission state as it is
still in use.

When a package is deleted for a user but still present for another
user we reset its permissions to their inital state follwoing
above described strategy.

Lastly when a preinstalled package wtih an upgrade is diabled
(triggers upgrade uninstall) and this package is a part of a
shared user, we do not drop permission state (grants and flags)
for permissions used by the shadowed system package. This ensures
that we do not drop runtime permission state (such state is
default grants and user changes).i

bug:22248525

Change-Id: I3a3007476d2cb9f4ff824e1e137a6e1a4d04408b
/frameworks/base/core/java/android/content/pm/PackageManager.java
38cae6c8bcb86236b21d69f852473351c0c1d82a 06-Jul-2015 Jeff Sharkey <jsharkey@android.com> Merge "Reconcile private volumes when mounted." into mnc-dev
6dce4964b4d1a13d276d95730b8fb09d6a5a8d04 04-Jul-2015 Jeff Sharkey <jsharkey@android.com> Reconcile private volumes when mounted.

Many things can happen while a private volume is ejected, so we need
to reconcile newly mounted volumes against known state.

First, user IDs can be recycled, so we store the serial number in the
extended attributes of the /data/user/[id] directory inode. Since a
serial number is always unique, we can quickly determine if a user
directory "10" really belongs to the current user "10". When we
detect a mismatched serial number, we destroy all data belonging to
that user. Gracefully handles upgrade case and assumes current serial
number is valid when none is defined.

Second, we destroy apps that we find no record of, either due to
uninstallation while the volume was unmounted, or reinstallation on
another volume.

When mounting a volume, ensure that data directories exist for all
current users. Similarly, create data directories on all mounted
volumes when creating a user. When forgetting a volume, gracefully
uninstall any apps that had been installed on that volume.

Bug: 20674082, 20275572
Change-Id: I4e3448837f7c03daf00d71681ebdc96e3d8b9cc9
/frameworks/base/core/java/android/content/pm/PackageManager.java
77ab6a888afaeb9010c7c3884adcd4819dbcee66 03-Jul-2015 Svet Ganov <svetoslavganov@google.com> Show basic feature warning for default granted permissions

bug:22174223

Change-Id: Ie8209e1f678ac459893151b5125e86eb5025aad8
/frameworks/base/core/java/android/content/pm/PackageManager.java
abe6580199f8f61cd3070f377be61191e51cac00 18-Jun-2015 Christopher Tate <ctate@google.com> Document possible null returns in PackageManager

In particular queryIntentServices() but also a few others.

Bug 19127758

Change-Id: I590605ce4870b2ab300385678df8917cfade60f9
/frameworks/base/core/java/android/content/pm/PackageManager.java
75a0ee081fa31b75649e164a8bf79a23a3ebd060 11-Jun-2015 Svetoslav <svetoslavganov@google.com> Merge "Add system API to watch for permission changes" into mnc-dev
f7c06eb03ab4479b9d0656a23a4733d17e995183 11-Jun-2015 Svetoslav <svetoslavganov@google.com> Add system API to watch for permission changes

Change-Id: I1ce450a59fb326c14848f46732d877dea33f33c7
/frameworks/base/core/java/android/content/pm/PackageManager.java
95120bbb6fb8d36d52e32d6d8d5435fc92318ca7 11-Jun-2015 Jonathan Basseri <misterikkit@google.com> Merge "Fix typo possibly -> possible." into mnc-dev
ab2340996a515ea0c437ad5bb1ea1fa88ab9edff 10-Jun-2015 Jeff Sharkey <jsharkey@android.com> Flags to select storage volume for app installs.

Remote callers can now provide the "--install-location" value from
the APK to help select a location, or they can explicitly force a
volume by UUID.

Bug: 21676789
Change-Id: Iefc92d770a851fc33e37edbf259fdb8df2b14ae5
/frameworks/base/core/java/android/content/pm/PackageManager.java
a73e4599506a1d3498ef5e9c240d79d7125fd2e9 08-Jun-2015 Kenny Guy <kennyguy@google.com> Merge "Correct the docs for getUserBadgedIcon" into mnc-dev
20770ddbd4d6f2af0093f36462a8f44a678b084b 30-May-2015 Svetoslav <svetoslavganov@google.com> Add API to hint whether to show on-board UI before a permission request.

bug:21511988

Change-Id: I9d1d7adf34b68074e65510f53b6e642cf784cf6b
/frameworks/base/core/java/android/content/pm/PackageManager.java
df77d717c33584f8fa04cb3780af68d38269cdf5 29-May-2015 Kenny Guy <kennyguy@google.com> Correct the docs for getUserBadgedIcon

Previously it wasn't clear that it was checking
if the target user was a managed profile in the
calling user = target user case.

Bug: 21455229
Change-Id: Iedce853092d2e5de6d84b06ca0ef4849bb26df26
/frameworks/base/core/java/android/content/pm/PackageManager.java
d9653703987f0ba194df6383d766173f65bf758e 14-May-2015 Svetoslav <svetoslavganov@google.com> Do not allow opting out from the new permission model.

bug:20525775

Change-Id: I84cd4587db5adb96f6f29148adb242905f53f2dc
/frameworks/base/core/java/android/content/pm/PackageManager.java
7ea3a33d72cea41a836c965f7b6c86eda32b4980 13-May-2015 Jonathan Basseri <misterikkit@google.com> Fix typo possibly -> possible.

Change-Id: I3729109620355a2dd8343210354aace5008dcc68
/frameworks/base/core/java/android/content/pm/PackageManager.java
a5c24e3bfe60770ac3180aac15df6c14dbf3bd4a 13-May-2015 Fabrice Di Meglio <fdimeglio@google.com> Merge "Add IntentFilter auto verification - part 9" into mnc-dev
ef741da4d434b1eb95cc63dd1e5ded551795e44a 13-May-2015 Fabrice Di Meglio <fdimeglio@google.com> Add IntentFilter auto verification - part 9

- make verifyIntentFilter(int, int, List<String>) a SystemApi

See bug #19628271

Change-Id: I8b1f29da385867beb8b19829c124db1821450c41
/frameworks/base/core/java/android/content/pm/PackageManager.java
b3f22b48bbd4e4816212e596e3cb612457d48fe5 12-May-2015 Svet Ganov <svetoslavganov@google.com> Runtime permissions for system components not revokable - framework

Change-Id: I5b1d7bb1618ffa8d1231618ece47d0905c82f7bf
/frameworks/base/core/java/android/content/pm/PackageManager.java
8c7f700a59ad26e75c9791335d78f14322cad49a 07-May-2015 Svet Ganov <svetoslavganov@google.com> Add permission meta-state flags to support grant/revoke permission policy.

We now maintain a mata-state with each permission in the form of flags
specyfying the policy for this permission. This enables support of the
following use cases:

1. The user denies a permission with prejudice in which case an app cannot
request the permission at runtime. If an app requests such a permssion
it gets a denial unless the user grants the permission from settings.

2. A legacy app with disabled app-ops being upgraded to support runtime
permissions. The disabled app ops are converted to permission revocations.
The app ops manager is a part of the activity manger which sits on top
of the package manager, hence the latter cannot have a dependency on the
former. To avoid this the package installer which is the global
permission managment authority marks the permission as revoked on
upgrade and the package manager revokes it on upgrade.

3. A device policy fixing a permission in a granted or revoked state. This
additional information is folded in the meta-state flags and neither
apps can request such permissions if revoked not the user can change
the permission state in the UI.

Change-Id: I443e8a7bb94bfcb4ff6003d158e1408c26149811
/frameworks/base/core/java/android/content/pm/PackageManager.java
cdcb57791f8392ae37bf80deb33b3d0282260405 07-May-2015 Glenn Kasten <gkasten@google.com> Add feature for pro audio

The specification for CDD is in progress

Bug: 20877157
Change-Id: Iaf37b2ccb21562170a080b53668a41b85c410241
/frameworks/base/core/java/android/content/pm/PackageManager.java
50a05454795c93ac483f5cb6819e74cb17be1b5b 29-Apr-2015 Jeff Sharkey <jsharkey@android.com> Returning to wizard, split move events.

Finish wiring up notifications to jump back into in-progress wizard
flow, using moveId as identifier.

Split move events back into separate creation and progress events,
and pass details as bundle to pass extra stuff like UUID. Null
package still means moving primary storage.

Add explicit "volume forgotten" event for PackageManager to clean
up internal state with.

Plumb through internal path reported by vold, and bring back FUSE
bypass rewriting optimization.

Bug: 19993667
Change-Id: I0f43edbba36c58c5cd33550022c54c4eb9f01a48
/frameworks/base/core/java/android/content/pm/PackageManager.java
b36586a7c9b7718f33961406537e27bbd9b16211 27-Apr-2015 Jeff Sharkey <jsharkey@android.com> Split some VolumeInfo state into VolumeRecord.

VolumeRecord is a historical record of a volume that we've seen in
the past. It's now surfaced outside the framework for SystemUI to
drive the notifications that bug users to reinsert missing private
volumes.

Show progress notifications for both storage and package movement
operations. Notify when an empty disk is inserted (no usable volumes)
which launches into the normal format flow.

Add API to forget volumes.

Bug: 20275424, 20275424
Change-Id: I75602c17fdcd4d1f1f62324e1a08c4a33093eefa
/frameworks/base/core/java/android/content/pm/PackageManager.java
9f7e39fc9d278642a29df48daf44dceff11acd17 11-Apr-2015 Fabrice Di Meglio <fdimeglio@google.com> Use Default Browser App for IntentResolution when needed

- add MATCH_ALL as a new flag for telling that all results need to
be returned (even if there is some sort of filtering done).
- take into account the default Browser App for Intent resolution
- also, dont do any domain verification priming for non system app

See bug #20144393

Change-Id: Iddd1f2029e3bbf3b99ebc5f416dc7f17e5bad10c
/frameworks/base/core/java/android/content/pm/PackageManager.java
620b32b316fd4f1bab4eef55ec8802d14a55e7dd 24-Apr-2015 Jeff Sharkey <jsharkey@android.com> Package and storage movement callbacks.

Since package and primary storage movement can take quite awhile,
we want to have SystemUI surface progress and allow the Settings
app to be torn down while the movement proceeds in the background.

Movement requests now return a unique ID that identifies an ongoing
operation, and interested parties can observe ongoing progress and
final status. Internally, progress and status are overloaded so
the values 0-100 are progress, and any values outside that range
are terminal status.

Add explicit constants for special-cased volume UUIDs, and change
the APIs to accept VolumeInfo to reduce confusion. Internally the
UUID value "null" means internal storage, and "primary_physical"
means the current primary physical volume. These values are used
for both package and primary storage movement destinations.

Persist the current primary storage location in MountService
metadata, since it can be moved over time.

Surface disk scanned events with separate volume count so we can
determine when it's partitioned successfully. Also send broadcast
to support TvSettings launching into adoption flow.

Bug: 19993667
Change-Id: Ic8a4034033c3cb3262023dba4a642efc6795af10
/frameworks/base/core/java/android/content/pm/PackageManager.java
7f95a00ec0ed9d48579e758249e7ffb06371b2b8 22-Apr-2015 Todd Kennedy <toddke@google.com> Add hardware feature describing a car

We need to define a hardware feature for when Android is running
embedded on a vehicle's headunit. This is not applicable when
running Android on a phone and projecting onto a headunit.

Bug: 20016089
Change-Id: I70e94564f7493afe70a49bf582a627c5ea9f0a60
/frameworks/base/core/java/android/content/pm/PackageManager.java
529f91fc8e7e884ef19bef8eb3e4e3a1d69336f4 19-Apr-2015 Jeff Sharkey <jsharkey@android.com> Always send volume UUID with installd commands.

Since packages can be moved to other volumes, all relevant commands
to installd now require an explicit volume UUID parameter.

Bug: 20275577
Change-Id: Ie84f5bc43c7aada5800b8d71692c7928b42b965e
/frameworks/base/core/java/android/content/pm/PackageManager.java
e2d45be4dae116307f8edd85eaa61134221cb8f9 16-Apr-2015 Jeff Sharkey <jsharkey@android.com> Candidate volumes for packages, fix symlink.

Add API to determine the possible candidate volumes that a package
can be moved to. For example, it currently knows that we need to
move ASEC-based apps through internal storage before migrating them
to a private volume.

Comparator for consistent VolumeInfo ordering when displayed in UI.

Fix native library symlink to be volume UUID aware.

Bug: 19993667
Change-Id: I68d5fac5f0f776ac1c7dd15e7a984bfe2704f3f7
/frameworks/base/core/java/android/content/pm/PackageManager.java
6036cd51265d31c08eefe0470a9f37e7f757aae8 11-Apr-2015 Jeff Sharkey <jsharkey@android.com> Merge "Support moving apps to expanded storage."
30ca50a3ddf35e6426e7b561b95e0864885de6d5 11-Apr-2015 Fabrice Di Meglio <fdimeglio@google.com> Merge "Add Default Browser App support and relax Hosts validation for AppLinks"
6227172310663e1267b1fabd68be890a1cb7e145 11-Apr-2015 Fabrice Di Meglio <fdimeglio@google.com> Add Default Browser App support and relax Hosts validation for AppLinks

- add private PackageManager APIs for setting/getting the default
Browser App package name
- serialize / deserialize the default Browser App package name per User

Also relax the Hosts name validation for the AppLinls feature. Now we
just care if the IntentFilter is having an HTTP or HTTPS scheme.

Change-Id: I4436f66ac6beff57e14f7f3a2a00b0b582c03be9
/frameworks/base/core/java/android/content/pm/PackageManager.java
eae371bf6f34a838b1209e491414bd306f68f7a3 09-Apr-2015 Ashutosh Joshi <ashutoshj@google.com> Adding a feature string for high capability sensors.

Adding a feature string for higher capability sensor platforms.
The string is supposed to signal the availability of lower power and
higher accuracy sensor processing on a supporting device.

Change-Id: I8093065278589fc9cc41fcc7f9b898c7eae20dff
/frameworks/base/core/java/android/content/pm/PackageManager.java
b9f3674c11ed9c89b80a69f728cbc5f540b2ecde 09-Apr-2015 Jeff Sharkey <jsharkey@android.com> Support moving apps to expanded storage.

Start deriving the data path for apps based on the volume UUID where
the app lives. This path is used for all higher-level APIs, giving
us a clean place to switch app storage.

When parsing a package, keep track of the volume UUID where it lives
and update PackageSetting once installed. For now continue treating
moves as installs, but we'll eventually clean this up to avoid the
additional dexopt pass. Wire up move to use the new installd command
to move private data between devices.

Cache LoadedApk only for the current user, since otherwise the data
dir points at the wrong path.

Bug: 19993667
Change-Id: I53336e3b147d5fd3130e6800869af172b628da37
/frameworks/base/core/java/android/content/pm/PackageManager.java
0788595e0c9bc5e8c1907c63db595010006ef5b4 07-Apr-2015 Fabrice Di Meglio <fdimeglio@google.com> Add IntentFilter auto verification - part 3

- add private API PackageManager.getAllIntentFilters(String)
for getting all IntentFilters from a given package
- update IntentFilterVerificationInfo to use an ArrayList<String>
for domains instead of a String[]
- if you make an App a default domain handler then make the
others as non default
- create an IntentVerificationInfo even if the App IntentFilters
do not need to be verified. This would be done only if the App
has some domain URLs defined and would allow to make it the
default handler for a domain
- a few code optimizations here and there

Change-Id: I4535372a0bb1a2c8e662e1485be8ca700003e9b3
/frameworks/base/core/java/android/content/pm/PackageManager.java
b2b9ab8354da1485178cd8d8e9d89ac915b3f269 06-Apr-2015 Jeff Sharkey <jsharkey@android.com> Installing packages to expanded storage.

PackageManager now offers to load/unload packages when expanded
volumes are mounted/unmounted. Expanded storage volumes are still
treated as FLAG_EXTERNAL_STORAGE from a public API point-of-view,
but this change starts treating the INSTALL_EXTERNAL flag as
exclusively meaning ASEC containers.

Start tracking the UUID of the volume where a package is installed,
giving us a quick way to find relevant packages. When resolving an
install location, look across all expanded volumes and pick the one
with the largest free space. When upgrading an existing package,
continue preferring the existing volume. PackageInstaller now knows
how to stage on these volumes.

Add new movePackage() variant that accepts a target volume UUID
as destination, it will eventually move data too. Expose this
move command through "pm" command for testing.

Automount expanded volumes when they appear.

Bug: 19993667
Change-Id: I9ca2aa328b9977d34e8b3e153db4bea8b8d6f8e3
/frameworks/base/core/java/android/content/pm/PackageManager.java
1c1b47125da018b44240739db75f8898e064a948 20-Nov-2014 Fabrice Di Meglio <fdimeglio@google.com> Add IntentFilter auto verification

The purpose of this feature is to prompt the Disambiguation dialog
to Users as less as possible.

- add the new "autoVerify" property to the IntentFilter class
- add new APIs to PackageManager:
verifyIntentFilter(int, int, List<String>),
getIntentVerificationStatus(String, int),
updateIntentVerificationStatus(String, int, int),
getIntentFilterVerifications(String)
for supporting IntentFilter verification
- add support for multi-user
- update PackageManager for IntentFilter verification:
basically when we are installing a new package, ask for verification
of all domains from the IntentFilters that have the "autoVerify" to true.
This means that the PackageManager will send a well defined protected
broadcast (with a new INTENT_FILTER_NEEDS_VERIFICATION action) to
an IntentFilter verifier to do the real job of verification.
We are passing in the broadcast Intent all the necessary data for
doing the verification. The PackageManager will receive as response
the result code of the domain verifications and, if needed, the list
of domains that have failed the verification.
- add a new INTENT_FILTER_VERIFICATION_AGENT permission that needs to
be set by an intent filter verifier to be considered as a trustable
party by the PackageManager.
- add also a new BIND_INTENT_FILTER_VERIFIER permission for securing
the binding between the PackageManager and a service doing the
intent filter verifications.
- add ResolveInfo filterNeedsVerification which is a boolean
to knows if the IntentFilter is of a type that needs a verification
(action VIEW, category BROWABLE, HTTP/HTTPS data URI)
- add new "domain-preferred-apps" / "d" dump command for listing the
prefered Apps for all domains
- add new "intent-filter-verifiers" / "ivf" command for listing the
IntentFilterVerifier used
- introduce the IntentVerificationService which is a basic service
for verifying IntentFilters. This service will send HTTPS requests
to the domain declared in the IntentFilter(s) for doing the
verification. This service has a low priority level so that it
can be replaced by a more sophisticated one if needed. This service
is updating the PackageManager intent verification states thru
the updateIntentVerificationStatus(...) API.
- update MockPackageManager

Change-Id: I0bfed193d0bf1f7c7ac79f6c1b160b7ab93b5fb5
/frameworks/base/core/java/android/content/pm/PackageManager.java
5781cd5b218dc3e5a19d8f69e6fb9f310bed4df6 27-Mar-2015 Mike Lockwood <lockwood@google.com> Make the MIDI Manager optional, enabled by "android.software.midi" feature

Change-Id: I76d442ea28beea4b9e2876bfef501d8f61403702
/frameworks/base/core/java/android/content/pm/PackageManager.java
95c1adea0c5fe10ceba217a327163757f4589d3d 19-Mar-2015 Svet Ganov <svetoslavganov@google.com> Add install option to grant all runtime permissions.

Change-Id: I72ba67a72025646a3d53611621b0353d3a86677c
/frameworks/base/core/java/android/content/pm/PackageManager.java
c6d1c345f41cf817bf2c07c97b97107d94296064 26-Feb-2015 Svetoslav <svetoslavganov@google.com> Runtime permissions: per user permission tracking.

Before all permissions were granted at install time at once, so the user
was persented with an all or nothing choice. In the new runtime permissions
model all dangarous permissions (nomal are always granted and signature
one are granted if signatures match) are not granted at install time and
the app can request them as necessary at runtime.

Before, all granted permission to an app were identical for all users as
granting is performed at install time. However, the new runtime model
allows the same app running under two different users to have different
runtime permission grants. This change refactors the permissions book
keeping in the package manager to enable per user permission tracking.

The change also adds the app facing APIs for requesting runtime permissions.

Change-Id: Icbf2fc2ced15c42ca206c335996206bd1a4a4be5
/frameworks/base/core/java/android/content/pm/PackageManager.java
38e6425bb490fbc65c1d0d74cdca205b4db4197d 18-Mar-2015 John Spurlock <jspurlock@google.com> Update package manager documentation.

Out lists are required to be non null.

Change-Id: I87b586a90f9f221bbea6f6f18135bfcdd65680c2
/frameworks/base/core/java/android/content/pm/PackageManager.java
1c2bf03d1082fc6b7eb42cbd163c60c07cf2bccc 02-Mar-2015 Tor Norbye <tnorbye@google.com> Annotate return values with @CheckReturn

Change-Id: Icd8fb6adb591ccd7f35f2336ae716b198abf69c5
/frameworks/base/core/java/android/content/pm/PackageManager.java
7b9c912f536925ac6ec43935d6e97506851b33d6 31-May-2013 Tor Norbye <tnorbye@google.com> Add @ResourceInt annotations on APIs

Change-Id: I119cc059c2f8bd98fd585fc84ac2b1b7d5892a08
/frameworks/base/core/java/android/content/pm/PackageManager.java
08a125562c9af620e83e9f96c7810eae871d6067 03-Dec-2014 Eino-Ville Talvala <etalvala@google.com> Revert "Camera: Add new capability flags as system features as well"

This reverts commit 6aee1d2ba52cf7f44c9355f279844b8a937903da.
But leaves in some of the improved documentation.

Bug: 18281970
Bug: 18573576
Change-Id: I320f2229456ac039bc8f3cd8bc8b4ea6cf0e80eb
/frameworks/base/core/java/android/content/pm/PackageManager.java
6aee1d2ba52cf7f44c9355f279844b8a937903da 20-Nov-2014 Eino-Ville Talvala <etalvala@google.com> Camera: Add new capability flags as system features as well

Also add all the L and L MR1 new system features to the uses-feature documentation.

Bug: 18281970
Change-Id: I116ca3fd04cd90eb53cc696b6fa62488687e7740
/frameworks/base/core/java/android/content/pm/PackageManager.java
9f60c08a446e38f9e2d5271546ef69ca5941eba9 29-Oct-2014 Jeff Hao <jeffhao@google.com> Change boot screen title to "Android is starting" when not upgrading.

Bug: 17565501
Change-Id: Id5741e6e7a40750feee1cd7306e79f7baeec67de
/frameworks/base/core/java/android/content/pm/PackageManager.java
ec2d48b96d1f95fb266914df294a27c210f8c3f5 01-Oct-2014 Benjamin Franz <bfranz@google.com> Introduce new API to get an unbadged icon and unbadge permissions.

Bug: 17125560
Change-Id: I61b884186c96cc54dcaf1d3c7ee8f47610fd1d21
/frameworks/base/core/java/android/content/pm/PackageManager.java
1ec6888685e1dd172502ade6ce455ad938400e0e 12-Sep-2014 Ihab Awad <ihab@google.com> Add system feature for ConnectionService API support (1/3)

Bug: 17445268
Change-Id: Ibf52cb394f00d075afd07b883a91f00da84b3c85
/frameworks/base/core/java/android/content/pm/PackageManager.java
1d653272a2847c0cda10482f70e991e7afdaee4b 12-Sep-2014 Amith Yamasani <yamasani@google.com> Rename and repurpose feature MANAGED_PROFILES to MANAGED_USERS

Bug: 17392243
Change-Id: I5ff0e70eeeeba264c96eaa2a17a6bd3669576c96
/frameworks/base/core/java/android/content/pm/PackageManager.java
e107c3eb79be40f1071c4370fd9a3f9e4fd6d6de 09-Sep-2014 Adam Connors <adamconnors@google.com> Remove package level intent forwarding.

Clean up unused methods.

Bug: 17389110
Change-Id: I8a80fe3e14219f06572de05c390cdda0efcbf5db
/frameworks/base/core/java/android/content/pm/PackageManager.java
c90f95c79ddd930c3fba13352f15ce7666eca402 10-Sep-2014 Adam Connors <adamconnors@google.com> Merge "Add feature flags for verified boot and securely remove users." into lmp-dev
76776943204fa5367d13948dba5b1e3de8916cd9 09-Sep-2014 Alexandra Gherghina <alexgherghina@google.com> Merge "Removing the NO_CROSS_PROFILE flag for intent forwarding" into lmp-dev
c788487ae5b28bb6f84410fcdb101f0bdfcd467e 09-Sep-2014 Alexandra Gherghina <alexgherghina@google.com> Removing the NO_CROSS_PROFILE flag for intent forwarding

Bug: 17435289
Change-Id: Iffbecd3cf9338a8633bfcc5bc47247bfc50e7546
/frameworks/base/core/java/android/content/pm/PackageManager.java
8e3b4d41e3a70eef19e3928f6aca9b7e8712aa08 09-Sep-2014 Michael Wright <michaelwr@google.com> Merge "Add FEATURE_GAMEPAD." into lmp-dev
6faa6759cde497acbdf33cadbed74cd1c5e94471 06-Sep-2014 Michael Wright <michaelwr@google.com> Add FEATURE_GAMEPAD.

This allows micro-consoles or other devices to signify that there's a
game controller in the box, even if the user hasn't connected it.

Change-Id: Ie5e2cf69f777ebe84abb83f34c9ed63d9555deff
/frameworks/base/core/java/android/content/pm/PackageManager.java
19ccb5fd759dc9284da32320ed1219bee3e031be 08-Sep-2014 Adam Connors <adamconnors@google.com> Add feature flags for verified boot and securely remove users.

Bug: 17405636
Change-Id: I5e81cf02f8b3d5b98957019c76844875b491181c
/frameworks/base/core/java/android/content/pm/PackageManager.java
68c936f77d836285c255e98b73bdadb78025ade9 07-Sep-2014 Unsuk Jung <unsuk@google.com> Merge "Add a hardware feature definition corresponding to audio output support." into lmp-dev
c7d62f02b8acfd0a6b31f8544ec2c07e780fe4bb 05-Sep-2014 Svetoslav <svetoslavganov@google.com> Addressing API council comments for UserManager.

bug:17390424

Change-Id: I498d2541289915cb7db16e5c3249ccc7a7dc5ee6
/frameworks/base/core/java/android/content/pm/PackageManager.java
50909f673268aaa477149d5db56379398f9a89db 03-Sep-2014 Unsuk Jung <unsuk@google.com> Add a hardware feature definition corresponding to audio output support.

Should also update/add xml files in platform/frameworks/native

Bug: 15318046

Change-Id: I5038ef38cd82977f257ec1499964d0bc291cbf59
/frameworks/base/core/java/android/content/pm/PackageManager.java
efb1f36f09cdada7c3b2677e6628492d8f256729 30-Aug-2014 dcashman <dcashman@google.com> Merge "Address KeySet API Review" into lmp-dev
cfd861ec15fe96143c61948d396e747b221a7f9d 27-Aug-2014 Jae Seo <jaeseo@google.com> Add android.software.live_tv feature

This feature will be listed by Android TV devices that allow displaying
contents from TV inputs implemented with the
android.media.tv.TvInputService API. (Note that not all leanback devices
support this feature.)

Bug: 17284986
Change-Id: Ic1f23f6f5955866e9f1db9229693d370576066a3
/frameworks/base/core/java/android/content/pm/PackageManager.java
1ab7689ce8a4164a86cf472fa028d7b0f18f696f 20-Aug-2014 Vinod Krishnan <vinodkrishnan@google.com> Fwk: Adding an ECG hardware feature

Change-Id: I77e36b010a8ff0cce89a419b64a24f16d7e68caf
/frameworks/base/core/java/android/content/pm/PackageManager.java
91306bccf16715f0867a10f3537122179527f7c3 16-Aug-2014 Adam Lesinski <adamlesinski@google.com> Merge "Add FeatureGroup to PackageInfo" into lmp-dev
d3edfde51bd069a63e820282421d1a534fcf00ce 09-Aug-2014 Adam Lesinski <adamlesinski@google.com> Add FeatureGroup to PackageInfo

FeatureGroups replace top-level FeatureInfo objects.
FeatureGroups inherit top-level FeatureInfos but override
them if the feature names are the same.

Bug:16822121

Change-Id: I80b2cb778a0fbcb4521efce986fba641e0914290
/frameworks/base/core/java/android/content/pm/PackageManager.java
a0907436c01fd8c545a6b5c7b28bc3bc9db59270 15-Aug-2014 Jeff Sharkey <jsharkey@android.com> PackageInstaller API refactoring.

Switch to using IntentSender for results to give installers easier
lifecycle management. Move param and info objects to inner classes.

Bug: 17008440
Change-Id: I944cfc580325ccc07acf22e0c681a5542d6abc43
/frameworks/base/core/java/android/content/pm/PackageManager.java
c6f22499f3046684d7175e10ca42cce1492cd36f 14-Aug-2014 dcashman <dcashman@google.com> Address KeySet API Review

Hide KeySet API. Change getKeySetByAlias to not require aliases from the calling
package. Make KeySet parcelable. Add hashCode method.

Bug: 16895228
Bug: 17009318
Change-Id: I75951947dfc7a3cca9f8873bda72576d11abaaf0
/frameworks/base/core/java/android/content/pm/PackageManager.java
6c0b9da65e36543bb50833d1b54ca532d0bd3aab 08-Aug-2014 Jeff Sharkey <jsharkey@android.com> Handle null IPackageDeleteObserver.

Bug: 16862614
Change-Id: I0c197a994b89d49123027f24fe46827c2b994ab6
/frameworks/base/core/java/android/content/pm/PackageManager.java
f06009542390472872da986486d385001e91a2a7 08-Aug-2014 Jeff Sharkey <jsharkey@android.com> Logic to confirm uninstalls.

Prompt user for confirmation when caller doesn't have DELETE_PACKAGES
permission. Also extend uninstall events to return failure codes.

Bug: 16515814
Change-Id: I15b52190ff02dbeaaf038b92364264f64c57ba89
/frameworks/base/core/java/android/content/pm/PackageManager.java
7328a1b39b3dae1c0cd390c0a3695c6a46b8e9d8 07-Aug-2014 Jeff Sharkey <jsharkey@android.com> Logic to confirm permissions on install sessions.

When an app without INSTALL permission attempts to commit a session,
we involve user to confirm permissions. We currently point at the
base APK, which defines all permissions for an app, handling the case
where a session may only be adding splits.

Add failure codes to represent rejection. Fix bug by ignoring stages
during initial boot scan.

Bug: 16515814
Change-Id: I702bb72445216817bcc62b79c83980c1c2bb0120
/frameworks/base/core/java/android/content/pm/PackageManager.java
e41ce995a0c2c6b167ed64b51e34865c5d58ea4d 29-Jul-2014 Alexandra Gherghina <alexgherghina@google.com> Add hidden API for removing cross-profile package filters

Bug: 16646591
Change-Id: Iaf6837fe4390ac1018c49df366ea434776ed7244
/frameworks/base/core/java/android/content/pm/PackageManager.java
41c1ded7f042a4cf303479550b38fa66d7a18906 05-Aug-2014 Amith Yamasani <yamasani@google.com> Allow phone UID to export singleton providers

Also add a user variant of replacePreferredActivity for use
by SmsApplication.

Map user restrictions for SMS/MMS to AppOps perms.

Bug: 16681533
Change-Id: I3dfed5fc754e33bb51c6f571851653a7c2770e46
/frameworks/base/core/java/android/content/pm/PackageManager.java
3f7777fa4f1d392e18bad39edcd4539880c52ff9 24-Jul-2014 Nicolas Prevot <nprevot@google.com> Storing the app who sets a CrossProfileIntentFilter.

When we add a CrossProfileIntentFilter, we store the package and userId of the calling app
inside the CrossProfileIntentFilter.
When an app calls clearCrossProfileIntentFilters, we only remove the filters that the calling app
has set itself.

BUG: 16537557

Change-Id: I6e7bc859383ea66553d9f4230365df8ba27525f3
/frameworks/base/core/java/android/content/pm/PackageManager.java
16c8e3f49497b6046972ae650772f65768366be8 25-Jul-2014 Jeff Sharkey <jsharkey@android.com> PackageInstaller changes based on feedback.

Mostly cosmetic changes from API council feedback.

Bug: 16543552
Change-Id: Ic926829b3f77c31f50a899c59b779353daf00d59
/frameworks/base/core/java/android/content/pm/PackageManager.java
e5bcff624fb58b6f95be8ddff7f5b6b3bf5d19c7 20-Jul-2014 Amith Yamasani <yamasani@google.com> Rename setApplicationBlocked to setApplicationHidden

This corrects the expected behavior of the app state. Hidden apps
can be installed by the store to be brought out of hidden state.

Bug: 16191518
Change-Id: Id128ce971ceee99ba1dea14ba07ce03bd8d77335
/frameworks/base/core/java/android/content/pm/PackageManager.java
7f51706265cab675ba139d2cfba5c01ce7dba077 18-Jul-2014 Jesse Hall <jessehall@google.com> Add FEATURE_OPENGLES_EXTENSION_PACK_ES31A

Bug: 15593761
Change-Id: Id1865cbf27c98a611cc6414fe47ee979c1d7cee2
/frameworks/base/core/java/android/content/pm/PackageManager.java
611fecec08eb9efeb4393b986d590369df5c812f 11-Jul-2014 Eino-Ville Talvala <etalvala@google.com> Add PackageManager features for differentiating camera2 devices

Also rename DNG capability to RAW.

Bug: 15415688
Change-Id: I1ea9f65b03c4fa06a5004f9d1d485935742001c8
/frameworks/base/core/java/android/content/pm/PackageManager.java
f7cecf8f4bd7e34c8c49ca8816ffe3966195b6da 16-Jul-2014 Andrew Solovay <asolovay@google.com> am c8fcb3bc: am 57553775: am 63477e67: Merge "cherrypick from klp-docs docs: Corrected doc for getLaunchIntentForPackage(). Change-Id: I2eab0956eaedac71289e19a3618a3553908f8c38" into klp-modular-docs

* commit 'c8fcb3bcdb71fe16624bea146a67b13c150adb82':
cherrypick from klp-docs docs: Corrected doc for getLaunchIntentForPackage(). Change-Id: I2eab0956eaedac71289e19a3618a3553908f8c38
c8fcb3bcdb71fe16624bea146a67b13c150adb82 16-Jul-2014 Andrew Solovay <asolovay@google.com> am 57553775: am 63477e67: Merge "cherrypick from klp-docs docs: Corrected doc for getLaunchIntentForPackage(). Change-Id: I2eab0956eaedac71289e19a3618a3553908f8c38" into klp-modular-docs

* commit '575537759222e0277c3979e33342407aa7ca1a78':
cherrypick from klp-docs docs: Corrected doc for getLaunchIntentForPackage(). Change-Id: I2eab0956eaedac71289e19a3618a3553908f8c38
5ae13354773911f2c1567332a846020ff93390e3 06-Jun-2014 Andrew Solovay <asolovay@google.com> cherrypick from klp-docs docs: Corrected doc for getLaunchIntentForPackage(). Change-Id: I2eab0956eaedac71289e19a3618a3553908f8c38

Doc had inaccurately said that getLaunchIntentForPackage() throws an
exception if the package name is not recognized; in fact, it returns
null. Also cleaned up some style issues for that Javadoc item.

Doc is staged to:

http://asolovay.mtv:9655/reference/android/content/pm/PackageManager.html#getLaunchIntentForPackage(java.lang.String)

Bug: 15022655
Original SHA1: I2eab0956eaedac71289e19a3618a3553908f8c38

Change-Id: Ief8dfaac248ba03779c6f13237aff9b26d362fd9
/frameworks/base/core/java/android/content/pm/PackageManager.java
69ea974f1712c83a9ad194187237edf1169f9064 15-Jul-2014 Jeff Sharkey <jsharkey@android.com> Merge "Public API for PackageInstaller!" into lmp-dev
6c833e07a05c48ca60ee4d72421bf8b1e78dc710 15-Jul-2014 Jeff Sharkey <jsharkey@android.com> Public API for PackageInstaller!

Flesh out documentation and finalize first cut of API. Also surface
installLocation and splitNames through PackageInfo.

Bug: 14975160, 15348430
Change-Id: Ic27696d20ed06e508aa3526218e9cb20835af6a0
/frameworks/base/core/java/android/content/pm/PackageManager.java
8b674abf4d83db29ae1e7488dbdb520edf970e67 15-Jul-2014 Aravind Akella <aakella@google.com> Merge "Add PackageManager feature strings for relative humidity and temperature sensors." into lmp-dev
9d2f441f9bb2c8dcac1150e2cba1d15a86a4efb1 09-Jun-2014 dcashman <dcashman@google.com> Initial KeySet API.

Previously submitted but reverted due to doc-compilation bug.

Bug: 6967056
Change-Id: I9bd7ef299a4c92c4b327f5b5d7e951f0753b4c8a
/frameworks/base/core/java/android/content/pm/PackageManager.java
8b8e74bd74e5a4bc4316d4bf0fc84cb46106e3ab 09-Jul-2014 Aravind Akella <aakella@google.com> Add PackageManager feature strings for relative humidity and temperature sensors.

Change-Id: I56351f37f1c51517a3384b6040df0ed2be0c95b0
/frameworks/base/core/java/android/content/pm/PackageManager.java
9726eeb2b01a0e5a3d52139f3bc48d4690af1ea9 12-Jul-2014 dcashman <dcashman@google.com> Merge "Revert "Initial KeySet API.""
5de7377feca5242fe7127e2d4dc7792d4886d365 12-Jul-2014 dcashman <dcashman@google.com> Revert "Initial KeySet API."

This reverts commit 9a643fe02bc960e266484547dda5572b094a4c72.
/frameworks/base/core/java/android/content/pm/PackageManager.java
405912bce074e9e59a246e2357a108e50dffabf8 09-Jun-2014 dcashman <dcashman@google.com> Initial KeySet API.

Bug: 6967056
Change-Id: I47a01bd5dc25591cc70f58f38920ad0a021094ae
/frameworks/base/core/java/android/content/pm/PackageManager.java
d2794789c8ddcdb5876bb7c609438aac6edd2bfe 12-Jul-2014 dcashman <dcashman@google.com> Merge "Initial KeySet API."
bb580670350b76fa2fcc5ee873f99b7970759cbf 10-Jul-2014 Jeff Sharkey <jsharkey@android.com> Progress toward installer public API: callbacks.

Instead of surfacing all the existing cryptic error codes, we're
going to classify them into broad categories when surfacing through
public API. This change introduces InstallResultCallback and
UninstallResultCallback, and wires them up to existing AIDL
interfaces.

Also start defining general SessionObserver for apps interested
in general progress details, such as Launcher apps. Details about
active sessions are returned through new InstallSessionInfo objects.

Bug: 14975160
Change-Id: I068e2b0c30135f6340f59ae0fff93c321047f8f9
/frameworks/base/core/java/android/content/pm/PackageManager.java
a0c4a06ba336df1c1775d3918f20ba14b4607052 10-Jul-2014 Yuncheol Heo <ycheo@google.com> Add the system feature for HDMI-CEC.

Change-Id: I2a985cedf49d50649c89f2ac5fbb80a81300156d
/frameworks/base/core/java/android/content/pm/PackageManager.java
1b88da54a684cf12f36b74bbc7c9548f35180fbe 10-Jul-2014 Kenny Guy <kennyguy@google.com> Enforce block uninstall in PackageManager

Bug: 14127299
Change-Id: I144233b97e5774f6a5d1d2b49f3f0f8a360557ac
/frameworks/base/core/java/android/content/pm/PackageManager.java
4bb015d90ae2aa3ce30778f3f584e0b7124f7505 05-Jul-2014 Joe LaPenna <jlapenna@google.com> CW on Master: Disable CaptivePortalTracker, EthernetService

BUG: 15143878

Change-Id: I6c534a28c1fcd475982ae70e7f3af69f3a219e24
/frameworks/base/core/java/android/content/pm/PackageManager.java
c13053bf1c05b980421611487ce67677c08db299 29-May-2014 Kenny Guy <kennyguy@google.com> Add package state to block uninstall.

Add package state to allow profile or device
owners to block uninstall of packages.
Add API to DevicePolicyManager to set/get the
state.

Bug: 14127299
Change-Id: I03528819850b42df7bafa7747bb9e4558d20c4e6
/frameworks/base/core/java/android/content/pm/PackageManager.java
7f7b0c759e2970178ef68805b21f06a26e24eb76 23-Jun-2014 Nicolas Prevot <nprevot@google.com> Returning badged icons for components of corporate apps.

So, corporate apps in disambiguation dialogs are badged.
And updating the way we show the icon of the personal space to this new design.

BUG: 14377051

Change-Id: Idc707773a64a8feb2d9d4df88c425d5100542636
/frameworks/base/core/java/android/content/pm/PackageManager.java
0363c3eb089afd4474bfd6ae6ee8a500d6e97614 23-Jun-2014 Alexandra Gherghina <alexgherghina@google.com> Expose per-user APIs for content services.

Bug: 15466880
Change-Id: Ib5a030e78559307627fe0d2e80ce6f1a7825109d
/frameworks/base/core/java/android/content/pm/PackageManager.java
fa4533f3a07ebed479d2a0e7af7d6e03d4417d41 24-Jun-2014 Alexandra Gherghina <alexgherghina@google.com> Skip forwarding launcher intents

If we forward intents when looking up launcher icons, we end up
having an icon for a disambig activity instead of the apps for that user.

Bug: 15769854
Change-Id: Ia57525466dba57b6669b2b5cedf98f202d08f586
/frameworks/base/core/java/android/content/pm/PackageManager.java
88cc346d0602e0b173b5076cd0051120682da601 14-May-2014 Nicolas Prevot <nprevot@google.com> Show the icon of the personal space.

In an intent disambiguation dialog from a managed profile,
when the intent can be forwarded to the personal space:
show the icon of the parent next to "Personal apps".
And put it at the bottom of the dialog.

Change-Id: I523222aac5dde9653e784eb26cf23cdaf018b86c
/frameworks/base/core/java/android/content/pm/PackageManager.java
aeb0ed74670e0502a04b689fe1b4fe0f537f4a91 23-Jun-2014 Alexandra Gherghina <alexgherghina@google.com> Merge "Adds cross-profile intent filters for the Settings app"
6e2ae2590ded39f04f76d5ddca0f06fe01586e26 12-Jun-2014 Alexandra Gherghina <alexgherghina@google.com> Adds cross-profile intent filters for the Settings app

Bug: 15466742
Change-Id: Id9af588f2f3d51a562ef2a06fe7404c96123cc2e
/frameworks/base/core/java/android/content/pm/PackageManager.java
e7cd37e6138c5e769cc6cb398e632bca24d2d1ab 19-Jun-2014 Nicolas Prevot <nprevot@google.com> Merge "Introducing crossProfileIntentFilters that skip the current profile."
63798c596dc757135950313eb4bb44ca58696c68 27-May-2014 Nicolas Prevot <nprevot@google.com> Introducing crossProfileIntentFilters that skip the current profile.

For these crossProfileIntentFilters, the activities in the current profile cannot
respond to the intent.
Only activities in the target profile can respond to the intent.

BUG: 14936725

Change-Id: I5e2704c2b56ff50a8339dd49284956391d7fad7e
/frameworks/base/core/java/android/content/pm/PackageManager.java
275e085d5a42ced54bb79e40ff76c77539e7d82d 18-Jun-2014 Jeff Sharkey <jsharkey@android.com> Stronger PackageParser contract, more split work.

Require that method callers always provide relevant paths, instead of
relying on constructor. Move DisplayMetrics to be an overall parser
parameter, and move PARSE_TRUSTED_OVERLAY to flags.

Parse split APKs and apply deterministic ordering based on split
names. Assert consistent package name and version code across all
split APKs in a package, and enforce unique split names and required
base APK.

Collect certificates for split APKs, enforcing they're all signed
consistently. Better flow control and resource cleanup when
collecting certs. Refactor validation code so it's easier to reason
about. Cleaner maintenance of read buffer when draining stream
contents.

Change-Id: I8bc8c62095fbb933227b9e76ad8771f4b1246fe8
/frameworks/base/core/java/android/content/pm/PackageManager.java
0270cfb71df55c1d213340bf9b678a48cc7b8e6e 20-Jun-2014 Jeff Sharkey <jsharkey@android.com> Merge "Explicitly collect manifest digests."
032f2b246bd01653c592f2b148d6a0debfe164b2 20-Jun-2014 Jeff Sharkey <jsharkey@android.com> Explicitly collect manifest digests.

Previously it was a side effect of collectCertificates().

Bug: 15740334
Change-Id: I2e044fdcc1c86ce730b9570bfbecf873366325e1
/frameworks/base/core/java/android/content/pm/PackageManager.java
c4858a2ba972e86436d629c4d3f18eb49116de14 16-Jun-2014 Jeff Sharkey <jsharkey@android.com> Switch PackageParser to reference single path.

It previously kept mPath separate from mScanPath for some very odd
edge cases around moving apps-on-SD. This changes it to always use
a single path, refactors moving to keep separate paths.

Refactors method names in PackageParser to be clearer about their
APK-versus-package relationship.

Beginnings of a split package parser. Instead of requiring that
callers check error codes when null, switch to always throwing on
parse errors, to require that callers deal with the error. Longer
term the entire parser should switch to this style, but its too
pervasive for a simple refactoring.

Change-Id: If071d8e55e46e56cc201fadfb51cb471713ae973
/frameworks/base/core/java/android/content/pm/PackageManager.java
d5a5b5a547462f3e7c6315a501909bce2418ba86 06-Jun-2014 Jeff Brown <jeffbrown@google.com> Rename PrivateApi annotation to SystemApi.

Change-Id: I97b473884f81ad375d0733e4766afe091dfdd854
/frameworks/base/core/java/android/content/pm/PackageManager.java
7283f963d30c2cc9694e1a1a178641ac40dd3a07 05-Jun-2014 Adam Connors <adamconnors@google.com> Merge "API Review: rename FEATURE_MANAGEDPROFILES"
551c0789bcc6e2fe428d848f5845e6b939f81c47 05-Jun-2014 Adam Connors <adamconnors@google.com> API Review: rename FEATURE_MANAGEDPROFILES

To be FEATURE_MANAGED_PROFILES

Bug: 15025371
Change-Id: I2f818b4d8488fe7943fe5ff6051d6b1f84ca9e8c
/frameworks/base/core/java/android/content/pm/PackageManager.java
a2d1454133405f5a031d5838a68159106f719720 05-Jun-2014 Elliott Hughes <enh@google.com> am ef3aeeca: am 38a5a257: am 759a8978: Merge "Minor javadoc improvements for PackageManager."

* commit 'ef3aeecacd4c47f6baeb96d06d69aad1ca4bcb1a':
Minor javadoc improvements for PackageManager.
ef3aeecacd4c47f6baeb96d06d69aad1ca4bcb1a 05-Jun-2014 Elliott Hughes <enh@google.com> am 38a5a257: am 759a8978: Merge "Minor javadoc improvements for PackageManager."

* commit '38a5a257a9aaf85606eb7117d943a877dc7d3c93':
Minor javadoc improvements for PackageManager.
dde24269c1eecb3ade2f625f4777492d4ef71526 04-Jun-2014 Amaury Medeiros <amaurymedeiros@gmail.com> Minor javadoc improvements for PackageManager.

- Removed duplicated use of the word "the".
- Changed @return and @param explanation of getApplicationEnabledSetting,
which should get the enabled state of an application and not just one component.

Change-Id: Ide07ec84ceb5b9b5caa28efa9ba838a40ee7b514
Signed-off-by: Amaury Medeiros <amaurymedeiros@gmail.com>
/frameworks/base/core/java/android/content/pm/PackageManager.java
8194899071e0a84c95ef10614bd1b9485b48f589 16-May-2014 Nicolas Prevot <nprevot@google.com> Rename code related to cross-profile intents.

For example, replace ForwardingIntentFilter by CrossProfileIntentFilter

Bug: 15023443

Change-Id: Iee8cdf578817ef9956bcdece803a49b0d07b67f7
/frameworks/base/core/java/android/content/pm/PackageManager.java
f564c7fe86d2aa9a7622667771d9e4bbf5518ffa 20-May-2014 Ben Murdoch <benm@google.com> resolved conflicts for merge of ecf09321 to master

Change-Id: I7a440204dfc79f3b82bd95d3d1276158bf3d44a2
ecf09321c5604558b159057e430b7faf7e6a7352 20-May-2014 Ben Murdoch <benm@google.com> am e0d6a6b0: Merge "Add PackagManager flag for WebView system feature." into klp-modular-dev

* commit 'e0d6a6b05b0861a5aa6dd8189de61a4da8d39dae':
Add PackagManager flag for WebView system feature.
422c7a5834b4e0f1bbf56d00fb824c9bbbd3ead4 16-May-2014 Ben Murdoch <benm@google.com> Add PackagManager flag for WebView system feature.

Add a flag for PackageManager.hasSystemFeature to determine
if a functional webview is available on the device.

Bug: 13438487

Change-Id: I770f7e924b3e5fa6be0397904acf18c9306096e4
/frameworks/base/core/java/android/content/pm/PackageManager.java
8b0cfb7dbde6f19a5dd5879fef3d16576f2eeba4 15-May-2014 Jeff Sharkey <jsharkey@android.com> Binder interfaces mean we can't use @PrivateApi.

Change-Id: Ie6d516b9ef8b7874160634b3b7b70d19481d1605
/frameworks/base/core/java/android/content/pm/PackageManager.java
3a44f3f1b446315ef894e01d2ab9b5388c2bd8c4 29-Apr-2014 Jeff Sharkey <jsharkey@android.com> Initial support for split APKs, PackageInstaller.

Defines a new PackageInstaller class that will be used for installing
and upgrading packages. An application desiring to install an
application creates a session, stages one or more package files in
that session, and then kicks off the install.

Previously, PackageManager would always make its own copy of a package
before inspecting it, to ensure the data could be trusted. This new
session concept allows the installer to write package data directly to
its final resting place on disk, reducing disk I/O and footprint
requirements. Writes are directed through an intermediate pipe
to ensure we can prevent mutations once an install has been initiated.
Also uses fallocate() internally to support optimal ext4 block
allocation using extents to reduce fragmentation.

Sessions are also the way we support installing multiple "split" APKs
in a single atomic operation. For a set of packages to form a valid
application, they must have exactly the same package name, version
code, and certificates. A session can also be used to add a small
handful of splits to an application by inheriting existing packages
when not performing a full install.

Add PackageParser support for extracting split names and certificates.

Bug: 14975160
Change-Id: I23d1bf4fbeb9f99a8c83be0c458900a0f0d1bccc
/frameworks/base/core/java/android/content/pm/PackageManager.java
89b77cded638cab56a002c28da4d09f144f7c6cb 01-May-2014 Jeff Sharkey <jsharkey@android.com> Mark hidden PM APIs that bundled apps depend on.

Change-Id: I18f2561ee65888fee08c61babc956bb8c3285366
/frameworks/base/core/java/android/content/pm/PackageManager.java
0ff8f796d968a45d26038e3a08ba9785f985a1ec 12-May-2014 Tim Kilbourn <tkilbourn@google.com> am d6fc5115: Merge "DO NOT MERGE Hide leanback packagemanager apis." into klp-modular-dev

* commit 'd6fc5115a656f9d06dd1d455f8bedd5f5eca943b':
DO NOT MERGE Hide leanback packagemanager apis.
d6fc5115a656f9d06dd1d455f8bedd5f5eca943b 12-May-2014 Tim Kilbourn <tkilbourn@google.com> Merge "DO NOT MERGE Hide leanback packagemanager apis." into klp-modular-dev
8bfb3513ee8f0bd6ccd98f347a4cbdf99de703a1 09-May-2014 Eino-Ville Talvala <etalvala@google.com> am 1caeb10a: DO NOT MERGE: Add android.hardware.camera.external feature.

* commit '1caeb10a7a288d937195d925c52f441f454cbc9a':
DO NOT MERGE: Add android.hardware.camera.external feature.
1caeb10a7a288d937195d925c52f441f454cbc9a 08-May-2014 Eino-Ville Talvala <etalvala@google.com> DO NOT MERGE: Add android.hardware.camera.external feature.

This feature will be listed by Android devices that allow for an
external camera to be connected to it. Such camera devices may
not always be available or connected.

Also clarify that android.hardware.camera.any also encompasses
devices that list android.hardware.camera.external.

Change-Id: I57497758877e4286c1f0116961731d483b56808f
/frameworks/base/core/java/android/content/pm/PackageManager.java
2e58d6de062fc48ad2a032d90d4956cf8041a894 08-May-2014 Eino-Ville Talvala <etalvala@google.com> Merge "Add android.hardware.camera.external feature."
9131da28e17856fa583d42ea23da211f7689487f 08-May-2014 Eino-Ville Talvala <etalvala@google.com> Add android.hardware.camera.external feature.

This feature will be listed by Android devices that allow for an
external camera to be connected to it. Such camera devices may
not always be available or connected.

Also clarify that android.hardware.camera.any also encompasses
devices that list android.hardware.camera.external.

Change-Id: I57497758877e4286c1f0116961731d483b56808f
/frameworks/base/core/java/android/content/pm/PackageManager.java
7d3387bc13427b61708d5a39fc4f626ee869ecdc 08-May-2014 Vinod Krishnan <vinodkrishnan@google.com> am 03498d34: am b9d71fa1: Merge "Adding a HeartRate Feature" into klp-modular-dev

* commit '03498d349ae3aa5e429e999b97036d194981373f':
Adding a HeartRate Feature
03498d349ae3aa5e429e999b97036d194981373f 07-May-2014 Vinod Krishnan <vinodkrishnan@google.com> am b9d71fa1: Merge "Adding a HeartRate Feature" into klp-modular-dev

* commit 'b9d71fa1081dc318a811b60660009d0769c02971':
Adding a HeartRate Feature
eeeacab5d52dea25adcc5d3e40b5afe7dfa105de 06-May-2014 Tim Kilbourn <tkilbourn@google.com> DO NOT MERGE Hide leanback packagemanager apis.

Bug: 14116162
Change-Id: I410d720013ba4e2bc1b0f8a6973daba5ca9008c6
/frameworks/base/core/java/android/content/pm/PackageManager.java
c79586ede6dcd6a167bc8360f058cb5cc655b33d 06-May-2014 Nicolas Prevot <nprevot@google.com> Cleaning code related to the forwarding intent filters.

Checking for INTERACT_ACROSS_USERS_FULL
Adding equivalent methods in the PackageManager

Change-Id: Iaa1328fa666613a78e67ca669ea045144275e895
/frameworks/base/core/java/android/content/pm/PackageManager.java
8afb23cbf6506008d7724197d881979d8c29f17b 30-Apr-2014 Vinod Krishnan <vinodkrishnan@google.com> Adding a HeartRate Feature

Bug: 14140142

Change-Id: I080bf12995355eac7621ef46e1a4a64d1f865500
/frameworks/base/core/java/android/content/pm/PackageManager.java
91097de49b0f683b00e26a75dbc0ac6082344137 05-Apr-2014 Dianne Hackborn <hackbod@google.com> Initial implementation of new voice interaction API.

This gives a basic working implementation of a persist
running service that can start a voice interaction when
it wants, with the target activity(s) able to go through
the protocol to interact with it. It may even work when
the screen is off by putting the activity manager in the
correct state to act like the screen is on.

Includes a sample app that is a voice interation service
and also has an activity it can launch.

Now that I have this initial implementation, I think I
want to rework some aspects of the API.

Change-Id: I7646d0af8fb4ac768c63a18fe3de43f8091f60e9
/frameworks/base/core/java/android/content/pm/PackageManager.java
68b9d97593d2ec79892813ab06f1b89c41de64b0 11-Apr-2014 Jose Lima <joselima@google.com> am 9e99cab7: am 970417c7: Added getLeanbackLaunchIntentForPackage()

* commit '9e99cab7d9a0ec2315140c21bb1958eb7ff76a09':
Added getLeanbackLaunchIntentForPackage()
9e99cab7d9a0ec2315140c21bb1958eb7ff76a09 11-Apr-2014 Jose Lima <joselima@google.com> am 970417c7: Added getLeanbackLaunchIntentForPackage()

* commit '970417c7d3e33ccbd6918e28d9bc5da24651f5b3':
Added getLeanbackLaunchIntentForPackage()
970417c7d3e33ccbd6918e28d9bc5da24651f5b3 10-Apr-2014 Jose Lima <joselima@google.com> Added getLeanbackLaunchIntentForPackage()

Change-Id: I23be3bfa59be812a915adc37e08fdf59be8ad90f
/frameworks/base/core/java/android/content/pm/PackageManager.java
d11f223c535ed9ce628fe5aaf0fd5692dd0cf9e4 10-Apr-2014 Narayan Kamath <narayan@google.com> resolved conflicts for merge of 286a247e to master

Change-Id: I63df9d482da3ce2ac851959223b9180020ffad0c
286a247e4c8fcecb59636f668678d24e33142744 10-Apr-2014 Narayan Kamath <narayan@google.com> am 0fd40cb1: am 80413c9f: Merge "Re-implement native library search and copies."

* commit '0fd40cb100bccbd5d9ad6109ca39c818a857f889':
Re-implement native library search and copies.
1378aba7aeeb7f6dd6cc2503968ba7b0e58d9333 28-Feb-2014 Ramin Zaghi <ramin.zaghi@arm.com> Re-implement native library search and copies.

We now use a two step approach :

- First we look through the list of shared libraries in an
APK, and choose an ABI based on the (priority) list of ABIs
a given device supports.
- Then we look through the list of shared libraries and copy
all shared libraries that match the ABI we've selected.

This fixes a long-standing bug where we would sometimes copy
a mixture of different ABIs to the device, and also allows us
to clearly pick an ABI to run an app with.

The code in NativeLibraryHelper has been refactored so that all
file name validation & matching logic is done in a single place
(NativeLibrariesIterator). This allows us to avoid a lot of
redundant logic and straightens out a few corner cases (for eg.
where the abi determination & copying logic do not agree on
what files to skip).

bug: https://code.google.com/p/android/issues/detail?id=65053
bug: 13647418

Change-Id: I34d08353f24115b0f6b800a7eda3ac427fa25fef
Co-Authored-By: Zhenghua Wang <zhenghua.wang0923@gmail.com>
Co-Authored-By: Ramin Zaghi <ramin.zaghi@arm.com>
Co-Authored-By: Narayan Kamath <narayan@google.com>
/frameworks/base/core/java/android/content/pm/PackageManager.java
23cc04e598cfb1c7f10e3fab05b188a8738edb35 01-Apr-2014 Adam Connors <adamconnors@google.com> Add android.software.managedprofiles feature flag.

Change-Id: I108d2952996d3a74596337ee2294fb33f1e28ee4
/frameworks/base/core/java/android/content/pm/PackageManager.java
f1977b4500e82b72ea6aa5c46d97406a20017caf 25-Mar-2014 Christopher Tate <ctate@google.com> Expand install observer semantics

...and now fail conservatively when two apps both attempt to define
the same permission. Apps signed with the same certificate are
permitted to redefine permissions.

We also finally have a (hidden) interface class for observing package
installation so that we can now rev the interface without breaking
existing callers.

Bug 13551375

Change-Id: Ifa4e59154dcccbb286ee46a35a6f25e4ad0f0f01
/frameworks/base/core/java/android/content/pm/PackageManager.java
7629a18a3f190368e6268d3f2827824905683268 26-Mar-2014 Glenn Kasten <gkasten@google.com> Revert "Expand install observer semantics"

This reverts commit ab8a501f255b272af887acb0e66eb71cdf24c755.

Change-Id: I4ab4ae1a96efa2adf9d5a513793d8b84eef38b4e
/frameworks/base/core/java/android/content/pm/PackageManager.java
ab8a501f255b272af887acb0e66eb71cdf24c755 25-Mar-2014 Christopher Tate <ctate@google.com> Expand install observer semantics

...and now fail conservatively when two apps both attempt to define
the same permission.

We also finally have a (hidden) interface class for observing package
installation so that we can now rev the interface without breaking
existing callers.

Bug 13551375

Change-Id: I3a286d024a30e812ee4b098f345401df3c00e178
/frameworks/base/core/java/android/content/pm/PackageManager.java
9b18001ab53c8c78aee0647983adf3ad8a1ee97c 14-Mar-2014 Tim Kilbourn <tkilbourn@google.com> am ec033943: am 9873e099: am 55740325: Merge "Add leanback device features." into klp-modular-dev

* commit 'ec0339437869ebb42a67a2811dc6de31239d5d62':
Add leanback device features.
92703e62c1dc88a410a32b05c2d44f391c193140 14-Mar-2014 Jose Lima <joselima@google.com> resolved conflicts for merge of 4882ddfa to master

Change-Id: I179899697c148ac34a67b195e2dbd3df2f9138de
f94b6a93a4afa910f4ee4869f001183f7b4c1de7 08-Mar-2014 Tim Kilbourn <tkilbourn@google.com> Add leanback device features.

android.software.leanback - the device supports leanback UIs.
android.software.leanback_only - the device ONLY supports leanback UIs.

leanback_only is a hidden feature for now.

Change-Id: I497bd96464125ad81212c804e150f210f3e95af2
/frameworks/base/core/java/android/content/pm/PackageManager.java
f78e312db2aa7653ddc021e7dc58ce48f95ba047 06-Mar-2014 Jose Lima <joselima@google.com> Add banner attribute to app manifest

Change-Id: I28b0dc6dee9623ec7534bb0e741b88f439b48c9f
/frameworks/base/core/java/android/content/pm/PackageManager.java
0be0a5039b60ae4c1c8c0b6a1a2c0e7400d372d5 21-Feb-2014 Justin Koh <justinkoh@google.com> am 7206ac56: am a79ac472: am 744d3473: Merge "Add hardware feature describing a watch." into klp-modular-dev

* commit '7206ac561291298f08809614be95963966a72ca8':
Add hardware feature describing a watch.
b5731f091c711a617e24ceb04cd7a1cc4ef1f717 14-Feb-2014 Justin Koh <justinkoh@google.com> Add hardware feature describing a watch.

Add hardware feature describing a watch so that hardware can specify that
it is a device that is worn on the body (perhaps the wrist).

Change-Id: I9d4cb7e86067f6ad41b39bcc545222b3b0fbf890
/frameworks/base/core/java/android/content/pm/PackageManager.java
5441745effb885589c03050b59885e8a3ad96ad6 19-Feb-2014 Adam Lesinski <adamlesinski@google.com> am 019b1f26: am 2ea983a5: am 3d9bcb90: Create FEATURE_ constants for print and backup

* commit '019b1f2668ac17f5e52b6ce32a524d26134a062a':
Create FEATURE_ constants for print and backup
3d9bcb90ee6c0ffff93642539ae64fb672c7f14a 18-Feb-2014 Adam Lesinski <adamlesinski@google.com> Create FEATURE_ constants for print and backup

Bug:13079822

Change-Id: I6f4b759951d45989e8aad4011fae431ee2ecae0c
/frameworks/base/core/java/android/content/pm/PackageManager.java
45484ee6bb45604d90454f56bd09a44d81691148 14-Oct-2013 Aravind Akella <aakella@google.com> am 67af9ce3: am c73810de: am 45ca531e: Merge "Adding stepcounter & stepdetector feature strings." into klp-dev

* commit '67af9ce31e7642ffc5737b9c29812c4bfdf789e0':
Adding stepcounter & stepdetector feature strings.
068b0c05fe089f58d96f71a82d57b87c5ebc1894 13-Oct-2013 Aravind Akella <aakella@google.com> Adding stepcounter & stepdetector feature strings.

Change-Id: Ic8cc95612f776db7cb1d1c13a228d5cd8ed64f56
/frameworks/base/core/java/android/content/pm/PackageManager.java
5b6372171c5ee06dc0ce00644008297e7a14bb38 08-Oct-2013 Jeff Sharkey <jsharkey@android.com> am 9d1383c6: am 5e02e0a9: am bcc77b50: Merge "Add <intent-filter> support to <provider>." into klp-dev

* commit '9d1383c61ca0932cb36b104a89c32db15de6a10e':
Add <intent-filter> support to <provider>.
bcc77b502b56d4b91610adfa10c657003c9c820d 07-Oct-2013 Jeff Sharkey <jsharkey@android.com> Merge "Add <intent-filter> support to <provider>." into klp-dev
85f5f8132015d8a5043ea4413702420d0d157c9f 07-Oct-2013 Jeff Sharkey <jsharkey@android.com> Add <intent-filter> support to <provider>.

For the new documents work, we're only interested in the subset of
ContentProviders that actually implement DocumentsContract. Instead
of returning all providers, add <intent-filter> support to make it
easier to limit the set of returned ProviderInfo.

Define a well-known action for DocumentsProviders, and start using it
when querying for roots. Continue supporting the old <meta-data>
approach until all apps have been updated.

Bug: 8599233
Change-Id: I05f049bba21311f5421738002f99ee214447c909
/frameworks/base/core/java/android/content/pm/PackageManager.java
1ac74b74fffd2897046b895eff3e9c6636955a33 04-Oct-2013 Alex Ray <aray@google.com> am 849ef427: am 2bbf0bfc: am 0ab7c883: Merge "Add Consumer IR feature" into klp-dev

* commit '849ef427b804c3d308e2d74eebd64e19144ef976':
Add Consumer IR feature
0c9d61f0989e5a85674fbbc24cf06dd3de1fc326 03-Oct-2013 Alex Ray <aray@google.com> Add Consumer IR feature

Bug: 10676690
Change-Id: Id2c118225dc6ef259f5ed97da4071e9b6de3a83a
/frameworks/base/core/java/android/content/pm/PackageManager.java
000ecdd3f5e38c8135cfc3caffea2327c668fbc1 17-Sep-2013 Amith Yamasani <yamasani@google.com> am 6484c42e: am 33caca5c: Merge "Add a feature to specify if device admins are supported on the device" into klp-dev

* commit '6484c42eb44bfe8fc8d2972bfc564b96f0f7f16c':
Add a feature to specify if device admins are supported on the device
44a01b742c2ad2ebc6185425be887b4bc987c4d0 16-Sep-2013 Amith Yamasani <yamasani@google.com> Add a feature to specify if device admins are supported on the device

Bug: 9520957

DevicePolicyManagerService will play dumb if the feature is not installed.

Continue to keep track of failed password attempts for keyguard's use.

Change-Id: I28d258dc09a8b4976b188da6f453d8daabcc4bdd
/frameworks/base/core/java/android/content/pm/PackageManager.java
9b6c9a15922ccb1518b8147f7bd05cae754c8c3c 14-Sep-2013 Christopher Tate <ctate@google.com> am fcda3283: am 7560c256: Merge "Add hidden API for querying available \'home\' activities" into klp-dev

* commit 'fcda3283d27f8dfaa812fb735af43eea2e077c64':
Add hidden API for querying available 'home' activities
a2a0850de8e7324db37e0595d5374bb9c9903461 06-Sep-2013 Christopher Tate <ctate@google.com> Add hidden API for querying available 'home' activities

To support improved home-app selection UX in Settings.

Bug 9958444

Change-Id: I106090784618bf7bea6fce28f4f9b9fb8480d310
/frameworks/base/core/java/android/content/pm/PackageManager.java
d9273d6f289d9b55da3fd0db2f659fdfb48106a8 31-May-2013 Tor Norbye <tnorbye@google.com> Add typedefs and nullness annotations.

This changeset adds in typedef annotations (custom annotations
marked with @IntDef) for various int parameters and return values
in the API. It also adds nullness annotations for cases where the
documentation explicitly mentioned null policy, or where it was
blindingly obvious from the context. Also fixed some typos in the
documentation.

Change-Id: Ica27c01368895818e26237544edd8483007155bb
/frameworks/base/core/java/android/content/pm/PackageManager.java
df4d1d624d44008e919755c7a212d9e2feb4f00b 28-Aug-2013 Martijn Coenen <maco@google.com> Add requireDeviceUnlock attribute for NFC HCE.

Also added AID description, and renamed PackageManager
feature. The old name has to stay at least for a bit,
because we are already deploying apps in our builds that
use the constant.

Bug: 10461409
Bug: 10461753
Change-Id: I7a5bb023bb567dd8b0a17e8e54e9559d7fcf64f5
/frameworks/base/core/java/android/content/pm/PackageManager.java
f4bf158328fd1bcb171baab043460efd5c58152c 22-Jul-2013 Martijn Coenen <maco@google.com> Add host-based card emu feature to PackageManager.

Change-Id: Id55025e5ab8443be1e6ac23ac5d9ab93565a53f0
/frameworks/base/core/java/android/content/pm/PackageManager.java
655d0e2029e6ae77a47e922dce4c4989818b8dd1 12-Jun-2013 Amith Yamasani <yamasani@google.com> Single-user restrictions

Introduces a new "blocked" state for each package. This is used to temporarily
disable an app via Settings->Restrictions.

PIN creation and challenge activities for use by Settings and other apps. PIN
is stored by the User Manager and it manages the interval for retry attempts
across reboots.

Change-Id: I4915329d1f72399bbcaf93a9ca9c0d2e69d098dd
/frameworks/base/core/java/android/content/pm/PackageManager.java
a722772b284c8a9889e59fcb28aa0aa87c0e8b46 19-Apr-2013 Matthew Xie <mattx@google.com> Add hardware feature android.hardware.bluetooth.le

The feature is used to differ platforms that support bluetooth low
engery radio
bug 8369273

Change-Id: Ibe23da73f7ecfa854bdb8b8bfc1a32b8e3aeee56
/frameworks/base/core/java/android/content/pm/PackageManager.java
32eb5b182458c05f744f9ab2963a13ef620ce069 11-Apr-2013 Nick Kralevich <nnk@google.com> Optional <uses-permission> not yet supported.

Change-Id: Ieaa97a29db75161f35905ff340b2c525bbf50612
/frameworks/base/core/java/android/content/pm/PackageManager.java
80ab68ce233598ab13a9875fe17d4ec51aa5517b 28-Mar-2013 kmccormick <kmccormick@google.com> am 5c3ddcd1: am 425c3d5f: am 99049335: am 3ed65cb3: am 689e827a: Merge "Doc update: superceeded > superseded" into jb-mr1.1-docs

* commit '5c3ddcd14b79c4737ea06f68d8efd39543d60382':
Doc update: superceeded > superseded
ac66b85a0454793502a12926bddf70b16a0dfd7d 28-Mar-2013 kmccormick <kmccormick@google.com> Doc update: superceeded > superseded

"Bug: 5935672"

Change-Id: Ie2324d00d454cf3f3f3ed422dea2017b8a7a4c54
/frameworks/base/core/java/android/content/pm/PackageManager.java
24b8947f62d9bdb91aae408894faa5fe59564e46 28-Mar-2013 kmccormick <kmccormick@google.com> resolved conflicts for merge of 603f987f to jb-mr2-dev

Change-Id: I4a130dad9d4669799f5d477f67e0f9a6a04381ca
30498b41827b67a320360e1cc308064bab9d23f1 28-Mar-2013 kmccormick <kmccormick@google.com> Doc change: Fix typo DONT_DELTE

"Bug: 8273156"

Change-Id: I6ba2e780d1a8c2b7d1771e93125a10b228227020
/frameworks/base/core/java/android/content/pm/PackageManager.java
828c16f140eadb9265f2bf53469902dc7cdb2284 27-Mar-2013 Nick Kralevich <nnk@google.com> Reenable optional permissions parsing and expose APIs

Modify the package parsing code to understand optional permissions
(android:required="false"). This is essentially a rollback of
e824120016248bcfe3962883fe9f3b0481dd1c3d with some minor changes.

Expose the requestPermission API to third party apps. This allows
an app to request an Intent which, when passed to
startActivityForResult, will prompt the user to approve permissions
for an app.

In the event we decide to not launch with this feature, this change
can be rolled back.

Change-Id: Ie3626deae9b16e510323f94a2c80377f7c84b26f
/frameworks/base/core/java/android/content/pm/PackageManager.java
035f80d7c75b282f33ab10a33a3019f614ffd67d 27-Mar-2013 Nick Kralevich <nnk@google.com> Add buildPermissionRequestIntent to PackageManager

Add the buildPermissionRequestIntent API to PackageManager. This allows
an app to request an Intent which, when passed to
startActivityForResult, will prompt the user to approve permissions
for an app.

Currently, the API is @hide. It will be unhidden in a future change.

Change-Id: I4ec677002afa799a6eb5c2657c28452c91012436
/frameworks/base/core/java/android/content/pm/PackageManager.java
119bbc378d3c836f1196e14b847e564205a29728 23-Mar-2013 Dianne Hackborn <hackbod@google.com> Implement #8323587, #8323342, #8323590: new features.

8323587: Add feature for supporting app widgets
8323342: Add feature for replacing the home screen
8323590: Add feature for supporting input methods

The app widget service looks for the app widget feature
and refuses to work if it doesn't exist. I didn't do
this for the input method service because some devices
will probably want to still make use of that mechanism
without supporting third party input methods.

Change-Id: Ie3b089105e104f4d767cdb03cdbe4fdb1c17382e
/frameworks/base/core/java/android/content/pm/PackageManager.java
c895be7bc68b6f5b37fbb9881f464dd5ea0eb017 12-Mar-2013 Dianne Hackborn <hackbod@google.com> Implement limited shared libraries in apks.

You can now declare shared libraries in apks that are
on the system image. This is like the existing mechanism
of using raw jar files as shared libraries, but since they
are contained in an apk the library can actually be updated
from the Play Store. And this even (mostly) works.

There are some deliberate limitations on this feature. A
new shared library *must* be declared by an apk on the system
image. Installing an update to a system image apk does not
allow you to add new shared libraries; they must be defined
by everything on the base system image. This allows us to
get rid of a lot of ugly edge cases (shared libraries that were
there disappearing after an update is uninstalled for example)
and give some brakes on apps that happen to be pre-installed
on devices from being able to throw in new shared libraries
after the fact.

In working on this, I ran into a recently introduced bug where
uninstalling updated to system apps would fail. This was done
to allow for the new restricted users that don't have all
system apps, but conflicts with the existing semantics for
uninstalling system apps. To fix this I added a new uninstall
flag that lets you switch on the new mode if desired.

Also to implement the desired logic for limitations on declaring
new shared libraries in app updates, I needed to slightly tweak
the initial boot to keep the Package object for hidden system
packages associated with their PackageSetting, so we can look at
it to determine which shared libraries are allowed. I think
this is probably more right than it was before -- we already
need to parse the package anyway, so we have it, and when you
install an update to a system app we are in this same state
until you reboot anyway.

And having this fixed also allowed me to fix another bug where
we wouldn't grant a new permission to an updated app if its
system image version is updated to request the permission but
its version is still older than whatever is currently installed
as an update. So that's good.

Also add new sample code showing the implementation of an apk
shared library and a client app using it.

Change-Id: I8ccca8f3c3bffd036c5968e22bd7f8a73e69be22
/frameworks/base/core/java/android/content/pm/PackageManager.java
e4cf73437a18c1444055f88a1fcc0d146ec23ac5 17-Dec-2012 Amith Yamasani <yamasani@google.com> Starting point for User Restrictions API

Restrictions saved as key/value pairs, mostly booleans right now
but might be expanded to other types later.

Save and restore restrictions in the user manager service.
Enforce some of the restrictions at the framework level. Some
are enforced (also) at the app level, such as in Settings.

Change-Id: Id11ffe129cb6a177e094edf79635727388c26f40
/frameworks/base/core/java/android/content/pm/PackageManager.java
fd7adedebf88427162a3ce27fcc9cfd3893c869d 23-Jan-2013 Dianne Hackborn <hackbod@google.com> Add new disabled state for "optional" built-in apps.

The disabled state allows you to make an app disabled
except for whatever parts of the system still want to
provide access to them and automatically enable them
if the user want to use it.

Currently the input method manager service is the only
part of the system that supports this, so you can put
an IME in this state and it will generally look disabled
but still be available in the IME list and once selected
switched to the enabled state.

Change-Id: I77f01c70610d82ce9070d4aabbadec8ae2cff2a3
/frameworks/base/core/java/android/content/pm/PackageManager.java
e799175b6ba3aadd972f4b861758d675d1f93987 17-Jan-2013 Dianne Hackborn <hackbod@google.com> AppOps: fix nested op tracking, new API to get apps using
permissions.

Change-Id: I20c7bd58febc01d6911a90440867eaacd133c464
/frameworks/base/core/java/android/content/pm/PackageManager.java
a06de0f29b58df9246779cc4bfd8f06f7205ddb6 12-Dec-2012 Dianne Hackborn <hackbod@google.com> New "app ops" service.

Initial implementation, tracking use of the vibrator, GPS,
and location reports.

Also includes an update to battery stats to also keep track of
vibrator usage (since I had to be in the vibrator code anyway
to instrument it).

The service itself is only half-done. Currently no API to
retrieve the data (which once there will allow us to show you
which apps are currently causing the GPS to run and who has
recently accessed your location), it doesn't persist its data
like it should, and no way to tell it to reject app requests
for various operations.

But hey, it's a start!

Change-Id: I05b8d76cc4a4f7f37bc758c1701f51f9e0550e15
/frameworks/base/core/java/android/content/pm/PackageManager.java
98edc951712823dbf5db2b7e9c203a0e98fc616b 25-Sep-2012 Amith Yamasani <yamasani@google.com> Load resources for the correct user

For apps that are only installed on secondary users, the SystemUI is
unable to see them by default. Added some methods to explicitly pass the
userId of the user the resources are requested for by the StatusBarIcon

Bug: 7214384

Also fix binding to remote views

Bug: 7192802

Change-Id: I5d6c5f624aa37fb231f3467f9764c8d99077a91d
/frameworks/base/core/java/android/content/pm/PackageManager.java
a91c9f9f7a3c5d09333bdf27ef06012bb4e7d710 23-Sep-2012 Eino-Ville Talvala <etalvala@google.com> Merge "Unhide and document feature android.hardware.camera.any." into jb-mr1-dev
c9108b1856c7b6d98ddc04fbe330df21f2da890d 22-Sep-2012 Eino-Ville Talvala <etalvala@google.com> Merge "Add hardware feature android.hardware.camera.any." into jb-mr1-dev
58d37b55bd228032355360ea3303e46a804e0516 18-Sep-2012 Svetoslav Ganov <svetoslavganov@google.com> Multi-user support for the accessibility layer.

1. This change converts the accessibility manager service to
maintain a state per user. When the user changes the services
for the user that is going away are disconnected, the local
accessibility managers in the processes for this user are
disabled, the state is swapped with the new user's one, and
the new user state is refreshed.

This change updates all calls into the system to use their
user specific versions when applicable. For example, regisetring
content observers, package monitors, calls into other system
services, etc.

There are some components that are shared across users such
as UI created by the system process and the SystemUI package.
Such components are managed as a global state shared across
all users and are updated accordingly on a user switch. Since
the SystemUI is running in a normal app process this change
adds hidden APIs on the local window manager to allow the
SystemUI to notify the accessibility layer that it will run
accross users.

Calls to AccessibiltyManager's isEnabled(), isTouchExplorationEnabled()
and sendAccessibilityEvent return false or a are a nop for a
background user sice he should not send accessibility events,
and should not perform touch exploration.

Update the internal accessibility tests due to changes in the
AccessibilityManager.

This change also fixes several issues that were encountered
such as calling out the accessibility manager service with a
lock held.

Removed some incorrect debugging code from the TouchExplorer
that was leading to a system crash.

bug:6967373

Change-Id: I2cf32ffdee1d827a8197ae4ce717dc0ff798b259
/frameworks/base/core/java/android/content/pm/PackageManager.java
72b4db15b6f30a5bc1c906aece93873b223f7dc2 19-Sep-2012 Eino-Ville Talvala <etalvala@google.com> Unhide and document feature android.hardware.camera.any.

Bug: 6847310
Change-Id: I67a973dccfdc735aac457fce625003a386ff2fbe
/frameworks/base/core/java/android/content/pm/PackageManager.java
752af83e5b28a4225510406a0ec868585caf1ccc 18-Sep-2012 Eino-Ville Talvala <etalvala@google.com> Add hardware feature android.hardware.camera.any.

This feature means that a device has at least one camera, facing in
some direction, so it matches devices that:
- Have just a back-facing camera
- Have just a front-facing camera
- Have both

In the future, it could also be used for devices that have a camera
that's neither front- or back-facing, such as a webcam or other
flexibly-pointed device.

Hidden for now.

Bug: 6847310
Change-Id: I51ea3b4db2020b0f056d77e10629a6b5f2daebe1
/frameworks/base/core/java/android/content/pm/PackageManager.java
8832c18d8b63367929c2d394c9c508f56003d400 18-Sep-2012 Dianne Hackborn <hackbod@google.com> Fix API review bugs.

7173152 API REVIEW: android.content.pm.PackageUserState
7172969 API REVIEW: android.app.PendingIntent
7172730 API REVIEW: android.content.Context
7172726 API REVIEW: android.manifest.permission

Change-Id: Iad470256d3b5ca5596487f6a699ec1871457c3b5
/frameworks/base/core/java/android/content/pm/PackageManager.java
13d428e8306d1bb1a3017045bc5d2f76edec32df 13-Sep-2012 rich cannings <richc@google.com> Send more information to verifiers

Send package name, version code and the uid of the application requesting the
install to package verifiers.

Bug: 7164155
Change-Id: I2464dc5d4551f60b4f38f7982495a8920c83e1cd
/frameworks/base/core/java/android/content/pm/PackageManager.java
151ec4c9f8ca34625733730a4551a23eb97cda23 08-Sep-2012 Amith Yamasani <yamasani@google.com> More multi-user methods in PM

pm can list installed packages by user now.

Bug: 6926465

Change-Id: I822311bfd6e7e2d6fb315fc484739fbf953c9bb6
/frameworks/base/core/java/android/content/pm/PackageManager.java
a2875f481bc40fb5c7e5ae2d475dfb6d557294c0 31-Aug-2012 rich cannings <richc@google.com> Merge "Notify verifiers that verification is complete" into jb-mr1-dev
f203aeef993b0f4ce65c9630d06bbd50a504e89f 30-Aug-2012 Amith Yamasani <yamasani@google.com> Enforce permissions for calls with specified userId

Fix a couple of places where incorrect userIds were being passed in.

Change-Id: I398c676e0488ff7e584be96e96c8b32652134238
/frameworks/base/core/java/android/content/pm/PackageManager.java
d1b5cfc94ae940f42be352e7ed98c21c973471b2 29-Aug-2012 rich cannings <richc@google.com> Notify verifiers that verification is complete

Send the Intent.ACTION_PACKAGE_VERIFIED to all verifiers when
verification is complete (either one verifier verified the package or a
timeout occurred). Details of what occurred is in a new extra,
PackageManager.EXTRA_VERIFICATION_RESULT.

Bug: 7048930
Change-Id: I4f9855a29b0eb6d77f469891402c69e2e8922945
/frameworks/base/core/java/android/content/pm/PackageManager.java
7e67151b912622f8a279ab1523a9bcf26ebaff3d 27-Aug-2012 rich cannings <richc@google.com> Add permission checks for Verification API calls

Ensure that only applications with
android.Manifest.permission.PACKAGE_VERIFICATION_AGENT can call application
verification APIs, like PackageManager.verifyPendingInstall and
PackageManager.extendVerificationTimeout

Bug: 7049083
Change-Id: I5fc28b37e864d67cd319a1ed9d03a90dd15ad052
/frameworks/base/core/java/android/content/pm/PackageManager.java
7767eac3232ba2fb9828766813cdb481d6a97584 24-Aug-2012 Dianne Hackborn <hackbod@google.com> Keep track of whether an app is installed for each user.

This add a new per-user state for an app, indicating whether
it is installed for that user.

All system apps are always installed for all users (we still
use disable to "uninstall" them).

Now when you call into the package manager to install an app,
it will only install the app for that user unless you supply
a flag saying to install for all users. Only being installed
for the user is just the normal install state, but all other
users have marked in their state for that app that it is not
installed.

When you call the package manager APIs for information about
apps, uninstalled apps are treated as really being not visible
(somewhat more-so than disabled apps), unless you use the
GET_UNINSTALLED_PACKAGES flag.

If another user calls to install an app that is already installed,
just not for them, then the normal install process takes place
but in addition that user's installed state is toggled on.

The package manager will not send PACKAGE_ADDED, PACKAGE_REMOVED,
PACKAGE_REPLACED etc broadcasts to users who don't have a package
installed or not being involved in a change in the install state.
There are a few things that are not quite right with this -- for
example if you go through a full install (with a new apk) of an
app for one user who doesn't have it already installed, you will
still get the PACKAGED_REPLACED messages even though this is
technically the first install for your user. I'm not sure how
much of an issue this is.

When you call the existing API to uninstall an app, this toggles
the installed state of the app for that user to be off. Only if
that is the last user user that has the app uinstalled will it
actually be removed from the device. Again there is a new flag
you can pass in to force the app to be uninstalled for all users.

Also fixed issues with cleaning external storage of apps, which
was not dealing with multiple users. We now keep track of cleaning
each user for each package.

Change-Id: I00e66452b149defc08c5e0183fa673f532465ed5
/frameworks/base/core/java/android/content/pm/PackageManager.java
d9ef3e5495db1c46bcfcc1a2d4386af8db6deb0c 22-Aug-2012 rich cannings <richc@google.com> Allow verifiers to extend timeout

Create a new verifier API to extend the timeout for a giving package,
including the resulting action (allow or deny) upon the timeout occuring.

Bug: 6901038
Change-Id: I351f7944327f863aff1d7dd1227be74652fa1511
/frameworks/base/core/java/android/content/pm/PackageManager.java
0c3804950236fe170ebf6cc7a5f1e3e305b8f315 21-Aug-2012 Dianne Hackborn <hackbod@google.com> Improve multi-user app management.

Introduce API to get per-user storage information, keep track
of services associated with users, and various small cleanup.

Change-Id: I5d4e784e7ff3cccfed627d66a090d2f464202634
/frameworks/base/core/java/android/content/pm/PackageManager.java
706e8ba26bf0de19ad5f736516dae40c4c88c2d7 20-Aug-2012 rich cannings <richc@google.com> Pass URLs to package verifiers

This change passes the originating URL and accompanied referrer to
package verifiers, when available.

Bug: 6544677
Change-Id: I9ebc71bc13f549bd88267e444816151a99bda000
/frameworks/base/core/java/android/content/pm/PackageManager.java
a3f133afe885f9e005dfc0584cb7b3b90f75f665 10-Aug-2012 Amith Yamasani <yamasani@google.com> Save preferred activity info with user id.

So each user can have their own set of intent resolution preferences.

ResolverActivity now launches the activity on the correct user, and
persists the preference for the correct user.

Bug: 6961905
Change-Id: I6d3a8a9af89bc649277d4fc8d0f367ee123f8392
/frameworks/base/core/java/android/content/pm/PackageManager.java
258848d2ae04f447ff1c18023fa76b139fcc0862 11-Aug-2012 Amith Yamasani <yamasani@google.com> User Manager service to manage users and query user details

Moved a bunch of methods from PackageManager to UserManager.

Fix launching of activities from recents to correct user.

Guest creation APIs

Change-Id: I0733405e6eb2829675665e225c759d6baa2b708f
/frameworks/base/core/java/android/content/pm/PackageManager.java
e1d7c711df3e3a2d2f195457882aa4ddb5626167 08-Aug-2012 Rich Cannings <richc@google.com> Revert "Pass URLs to package verifiers"

This reverts commit 24713907fe4632d263aea82f7a35c8fb08918a09

Change-Id: Ie04ba73475b813635c4a74915c45e83250801b6b
/frameworks/base/core/java/android/content/pm/PackageManager.java
24713907fe4632d263aea82f7a35c8fb08918a09 26-Jul-2012 rich cannings <richc@google.com> Pass URLs to package verifiers

This change passes the originating URL and accompanied referrer to
package verifiers, when available.

Bug: 6544677
Change-Id: If9ff6663ad7f3426b7aea2aceb1413b689788138
/frameworks/base/core/java/android/content/pm/PackageManager.java
ddd88726a247e4100cb62b3dc9d0887ca2ae2ec4 26-Jul-2012 Jeff Smith <whydoubt@yahoo.com> am 71930dd7: am a45746ef: Fix several cases of broken droiddoc syntax external issue 35214

* commit '71930dd77e4dc6f6be5c648019d2ab0da5f0584c':
Fix several cases of broken droiddoc syntax external issue 35214
a45746efadd11bb7dfab026fb3c81a25fae74ca4 19-Jul-2012 Jeff Smith <whydoubt@yahoo.com> Fix several cases of broken droiddoc syntax
external issue 35214

patch contributed by Jeff Smith <whydoubt@yahoo.com>

Change-Id: I70dcee88a140699bf3e1ab369bed6dcd2fdd3d83
/frameworks/base/core/java/android/content/pm/PackageManager.java
b8151ecd6ef4faa5c16d0a4c3abb45ec84d1f97a 19-Apr-2012 Amith Yamasani <yamasani@google.com> Add an icon to the user information.

Store the icon in the user folder under /data/system,
similar to how the wallpaper is stored.

Change-Id: Id8ccb55b9e2ba7b4c557505a7f69f04eca1518cf
/frameworks/base/core/java/android/content/pm/PackageManager.java
d0c5f515c05d05c9d24971695337daf9d6ce409c 08-Jun-2012 Dianne Hackborn <hackbod@google.com> Fix issue #6295373: "Package com.google.android.apps.authenticator2 has...

...mismatched uid: X on disk, Y in settings" errors on Froyo and Gingerbread

Deal more gracefully with the uid changing in three ways:

1. If the uid on disk has become root, then have installd change it to
the application's uid. This is to correct a potential case where
installd was interrupted while linking or unlinking the libs dir,
during which it temporarily changes the owner of the dir to root
so that a malicious app can not get in its way. So if the uid on
disk has become root, we assume we can safely just change it back
to the correct uid.

2. When scaning packages at boot, use the same "delete and rebuild data
directory" code for third party applications as we have for system
applications. This allows us to at least end up in a state where the
app will run, even if its data is lost.

3. But we really don't want to get in to case 2, so if an application
update is being installed and we find that the uid we now have for
the app is different than the one on disk, fail the update. This will
protect against for example a developer changing the sharedUserId of
their app and getting into this bad state.

Bug: 6295373
Change-Id: Ic802fdd818ac62449ff3c61d1fff1aa4d4942f39
/frameworks/base/core/java/android/content/pm/PackageManager.java
0cf2c8a53350a800055e76c1c9bf0a6d44480768 18-May-2012 Dianne Hackborn <hackbod@google.com> Fix issue #6515427: Add android.hardware.television and fix...

...logic for notouch in Configuration

Added new TELEVISION feature.

We now force the configuration to "television" if the TELEVISION
feature is set, and "notouch" if the TOUCHSCREEN feature is not set.

Also cleaned up documentation, deprecated some configurations that
are not used.

Change-Id: If1c7a284b580a8a66bda2a75f0c7fa841b3dc9b7
/frameworks/base/core/java/android/content/pm/PackageManager.java
f53857716a0db805c51c0cae93550d90e32e4749 11-May-2012 Jeff Sharkey <jsharkey@android.com> Enforce READ_EXTERNAL through Settings.Secure.

Always defers to user-defined setting, when present.

Bug: 6389556
Change-Id: I079d2a41b772facfdac74eefc4c8072fc9284f97
/frameworks/base/core/java/android/content/pm/PackageManager.java
ceb1b0bfaea56251796b08c07b963de7403d84eb 24-Apr-2012 Anonymous Coward <nobody@android.com> Add encryption parameters to package installation

Change-Id: Ic9f8ab9f8110f08bb3c00725cfce5b8ee7b766f3
/frameworks/base/core/java/android/content/pm/PackageManager.java
d776f617f5ad8052245e173602a7b80703f5fb39 24-Apr-2012 Jeff Sharkey <jsharkey@android.com> Disable READ_EXTERNAL enforcement until API level cut.

Bug: 6389556
Change-Id: I78238b9de24c1b8ebb4fdc35d8aafd2e85a4adfe
/frameworks/base/core/java/android/content/pm/PackageManager.java
5d32e772b3a19c1ac84e665f2885755427d590c8 13-Apr-2012 Jeff Sharkey <jsharkey@android.com> Enforce READ_EXTERNAL on non-user builds.

Enable default enforcement of READ_EXTERNAL_STORAGE on non-user
builds. Users can still explicitly enable enforcement in Settings.

Bug: 6131916
Change-Id: I7dc66b624ad252ed2a2ad3647f3ea85dda7f8e82
/frameworks/base/core/java/android/content/pm/PackageManager.java
1c27576aff247ff1d7789e0a571958726f161593 12-Apr-2012 Jeff Sharkey <jsharkey@android.com> Include enforcement state in dumpsys.

Bug: 6323087
Change-Id: I6d779798538c114ea9816d3bdbbff5552c285df6
/frameworks/base/core/java/android/content/pm/PackageManager.java
135936072b24b090fb63940aea41b408d855a4f3 23-Mar-2012 Amith Yamasani <yamasani@google.com> User management and switching

Broadcast intents that get sent out when users are added/removed/switched.

More work on generating user-specific information in package manager queries.
APIs to update user name and query a user by id.
Removed Package.mSetStopped and mSetEnabled, since they're not user specific.

User removal:
- Cleanup ActivityManager, PackageManager, WallpaperManager, AppWidgetService
and AccountManager.
- Shutdown processes belonging to the user.

Don't show vibrate option in long-press power if there's no vibrator.

Lock the screen when switching users, to force unlocking.

Change-Id: Ib23a721cb75285eef5fd6ba8c7272462764038fa
/frameworks/base/core/java/android/content/pm/PackageManager.java
edc84ee8392afa0102f098168329db5bb43a6d4b 20-Mar-2012 Jeff Sharkey <jsharkey@android.com> Selective enforcement of READ_EXTERNAL_STORAGE.

Store enforcement state of specific permissions, allowing them to be
selectively enforced. Currently supports READ_EXTERNAL_STORAGE, which
by default isn't enforced, but enforcement can be enabled at runtime.

Bug: 6131916
Change-Id: I4bcc215a2eb5e6507d6257b577311cbd13c77acf
/frameworks/base/core/java/android/content/pm/PackageManager.java
f76a50ce8fdc6aea22cabc77b2977a1a15a79630 09-Mar-2012 Ken Wakasa <kwakasa@google.com> Fix obvious typos under frameworks/base/core

Change-Id: Ia5fc3db1bb51824e7523885553be926bcc42d736
/frameworks/base/core/java/android/content/pm/PackageManager.java
e639da7baa23121e35aa06d6e182558e0e755696 22-Feb-2012 Dianne Hackborn <hackbod@google.com> New development permissions.

These are permissions that an application can request, but won't
normally be granted. To have the permission granted, the user
must explicitly do so through a new "adb shell pm grant" command.

I put these permissions in the "development tools" permission
group. Looking at the stuff there, I think all of the permissions
we already had in that group should be turned to development
permissions; I don't think any of them are protecting public APIs,
and they are really not things normal applications should use.

The support this, the protectionLevel of a permission has been
modified to consist of a base protection type with additional
flags. The signatureOrSystem permission has thus been converted
to a signature base type with a new "system" flag; you can use
"system" and/or "dangerous" flags with signature permissions as
desired.

The permissions UI has been updated to understand these new types
of permissions and know when to display them. Along with doing
that, it also now shows you which permissions are new when updating
an existing application.

This also starts laying the ground-work for "optional" permissions
(which development permissions are a certain specialized form of).
Completing that work requires some more features in the package
manager to understand generic optional permissions (having a
facility to not apply them when installing), along with the
appropriate UI for the app and user to manage those permissions.

Change-Id: I6571785c6bb5f6b291862b7a9be584885f88f3a5
/frameworks/base/core/java/android/content/pm/PackageManager.java
742a67127366c376fdf188ff99ba30b27d3bf90c 04-May-2011 Amith Yamasani <yamasani@google.com> Multi-user - 1st major checkin

Switching activity stacks
Cache ContentProvider per user
Long-press power to switch users (on phone)

Added ServiceMap for separating services by user
Launch PendingIntents on the correct user's uid
Fix task switching from Recents list
AppWidgetService is mostly working.

Commands added to pm and am to allow creating and switching profiles.

Change-Id: I15810e8cfbe50a04bd3323a7ef5a8ff4230870ed
/frameworks/base/core/java/android/content/pm/PackageManager.java
685f490eff35e33e435e455e9b784c9d70083e49 03-Nov-2011 Kenny Root <kroot@google.com> Update GET_UNINSTALLED_PACKAGES flag documentation

Change-Id: I483b84f07836e6ad96c75e7dd3a86633cb29db22
/frameworks/base/core/java/android/content/pm/PackageManager.java
6ccd41265db1a6bfb3c54d64aba2df67d373af4f 13-Oct-2011 Kenny Root <kroot@google.com> Add support for signature in getPackageArchiveInfo

GET_SIGNATURES was indicated as supported, but it never actually did
anything.

This is needed for the package verifier development sample.

Change-Id: I09ca6790cd8bf9435aa208c0711359b4d76fb278
/frameworks/base/core/java/android/content/pm/PackageManager.java
d0e8fb431ac9c1fcc2f5b0eba884d29fc57a4cf1 28-Sep-2011 Mathew Inwood <mathewi@google.com> Merge "Document thrown IllegalArgumentException."
1b9f8d92a934188eb200647025bffaf90469ee55 26-Sep-2011 Mathew Inwood <mathewi@google.com> Document thrown IllegalArgumentException.

Change-Id: I502f91e3c1130c14ad8f67934bf52a7206de302f
/frameworks/base/core/java/android/content/pm/PackageManager.java
05ca4c90644921df9193d92b2abdc81ef77e4a62 15-Sep-2011 Kenny Root <kroot@google.com> Allow non-required package verifiers

* Verifiers can be specified in the AndroidManifest.xml

* Those verifiers can respond to the new Intent action

* PackageManager API for those verifiers: verifyPendingInstall

Change-Id: I4892bce2e6984871e6e93c60a1ca0dae145f5df5
/frameworks/base/core/java/android/content/pm/PackageManager.java
3a9b5fbb97e65019abec97f172b4cbf2100d1225 20-Sep-2011 Kenny Root <kroot@google.com> Unhide new PackageManager APIs for API 14

Change-Id: I83110285ccee39a4cd872a1c2af8357f541833d4
/frameworks/base/core/java/android/content/pm/PackageManager.java
0aaa0d931716e9f57a1d84d795fab2df75092756 13-Sep-2011 Kenny Root <kroot@google.com> Add verifier device identity

This adds a special device identifier that is usable only for device
validation. The user will be presented with this number encoded in
easily-transcribable Base32 in the Developer options of Settings.

Change-Id: I4843f55ee90d689a51d0269b22454ca04c1be7ec
/frameworks/base/core/java/android/content/pm/PackageManager.java
45b8b464992bbfa9bd2a587f05c1e1723aedcecd 07-Sep-2011 Irfan Sheriff <isheriff@google.com> Add feature definition for Wi-Fi Direct

Bug: 5267396
Change-Id: I4f61b0afd1466420ab951f6d74ec444036772b21
/frameworks/base/core/java/android/content/pm/PackageManager.java
5ab2157bf1f105b02d3e2913cd3a33f9765b74ca 27-Jul-2011 Kenny Root <kroot@google.com> Infrastructure to support package verifier

Allow a package verifier to approve or disapprove of a package being
installed.

Change-Id: Ibfea0f2b1aaa4ab1589a4e59f96144702b9bf94b
/frameworks/base/core/java/android/content/pm/PackageManager.java
0ac3031c159a0904e73eb4439cdc724d8df4a6e6 17-Jun-2011 Dianne Hackborn <hackbod@google.com> Implement remaining infrastructure for user disabling apps.

Change-Id: If8135eb0e27ec36f8f159eb7b6397add7acd0299
/frameworks/base/core/java/android/content/pm/PackageManager.java
711516d140390aeec9e3eefb8fdb2681c3454980 14-Jun-2011 Dianne Hackborn <hackbod@google.com> resolved conflicts for merge of 77fc8b80 to master

Change-Id: I014f9a886d6f05607d2a5d101ad2052a6841ee8d
e289bff0ec2b1af4ba773e0c8d49d5fd46eb9921 14-Jun-2011 Dianne Hackborn <hackbod@google.com> Add new landscape and portrait orientation features.

Updates aapt to know about these. Also updates aapt badging to:

- No longer crash due to the change to how we match unspecified
configuration resources.
- Report the new "smallest screen" supported screen configs.
- Infer old screen size buckets based on new smallest width attrs.
- Report all of the different labels and icons in an app.

Change-Id: I7376042b817391bd070f549cebbc7f03be4635c8
/frameworks/base/core/java/android/content/pm/PackageManager.java
e6b03d0979e0bd6dfeda7b45850182c3092bb3e7 10-Jun-2011 Dianne Hackborn <hackbod@google.com> resolved conflicts for merge of 9dfd7d0a to master

Change-Id: I9fbee3209b7fe5c7b5b42b62309eb60dc49bf9e2
e22fe9331ad8a9f81470751fdeca7633f654cffa 09-Jun-2011 Dianne Hackborn <hackbod@google.com> Fix issue #4582417: Need to add new PackageManager...

...FEATURE_ constant for FAKE_MULTITOUCH in MR2

Change-Id: Ib6950d9dbdd58618aec593de7e0cf1c01b7d6ef9
/frameworks/base/core/java/android/content/pm/PackageManager.java
0b285499db739ba50f2f839d633e763c70e67f96 15-Apr-2011 Amith Yamasani <yamasani@google.com> Plumbing in PackageManager and installd for multi-user support.

- Create /data/user directory and symlink /data/user/0 -> /data/data for
backward compatibility
- Create data directories for all packages for new user

- Remove data directories when removing a user

- Create data directories for all users when a package is created

- Clear / Remove data for multiple users

- Fixed a bug in verifying the location of a system app

- pm commands for createUser and removeUser (will be disabled later)

- symlink duplicate lib directories to the original lib directory

Change-Id: Id9fdfcf0e62406a8896aa811314dfc08d5f6ed95
/frameworks/base/core/java/android/content/pm/PackageManager.java
4b2e934928a2eb65927bd39197198c28c49efb94 31-Mar-2011 Amith Yamasani <yamasani@google.com> Package manager changes to store and update user information.

Some API stubs for managing users and storing their details.
List of users is stored in an xml file.
Each user's properties are stored in a separate xml file.

Some unit tests for modifying the XML files.

Change-Id: If2ce2420723111bd426f6762def3c2afc19a0ae5
/frameworks/base/core/java/android/content/pm/PackageManager.java
18cd686fc828c9c75596de1494ecaa5467fcc195 23-Mar-2011 Scott Main <smain@google.com> am ef6b305b: docs: fix markup error

* commit 'ef6b305b93009b60ad7c6ddbd200d1b5c554963f':
docs: fix markup error
ef6b305b93009b60ad7c6ddbd200d1b5c554963f 23-Mar-2011 Scott Main <smain@google.com> docs: fix markup error

Change-Id: I59e379a7a36c4184862095442c53a6b9496d856e
/frameworks/base/core/java/android/content/pm/PackageManager.java
3dee21eb0f253a7e78572872b8dfc7b5d990a063 02-Mar-2011 Kenny Root <kroot@google.com> Merge "Switch to returnCode for IPackageDeleteObserver"
c39bb4aaa7be1b9b0cc9fb0b1f03d54f7609ffeb 28-Feb-2011 Kenny Root <kroot@google.com> Switch to returnCode for IPackageDeleteObserver

Before the IPackageDeleteObserver only knew whether the deletion
succeeded or failed, but not the reason why.

Bug: 2520191
Change-Id: I1f0d7c04f06c539660b6e17e7e133defb0f61b5b
/frameworks/base/core/java/android/content/pm/PackageManager.java
f4ca247158ffb83139d675ac0e1d25239c310be2 27-Feb-2011 Mike Lockwood <lockwood@android.com> Add platform features for USB host and USB accessory support.

Also removed config_hasUsbHostSupport framework resource, which is now obsolete.

Change-Id: I6f18cc1c4f68085de8b8363e1b5edff79aff404f
Signed-off-by: Mike Lockwood <lockwood@android.com>
/frameworks/base/core/java/android/content/pm/PackageManager.java
a537687c3863912b1199c13c1aa010d74c243fcc 23-Jan-2011 Dan Morrill <morrildl@google.com> Adding faketouch feature.

Change-Id: Idff0b059c2f82fa4237d6238710e87dc55ae76a8
/frameworks/base/core/java/android/content/pm/PackageManager.java
a1cbb94dbc9a82d4eb3a47242fe161af21803858 17-Jan-2011 Kenny Root <kroot@google.com> Revert "Add the {get,set}PackageObbPaths calls to API"

This reverts commit 5d40fe9c6846ba765072e50ed1254293cb9195e4.

Change-Id: Ie41010c92fb860b19a12bcf63f6fe95ffa68da81
/frameworks/base/core/java/android/content/pm/PackageManager.java
5d40fe9c6846ba765072e50ed1254293cb9195e4 14-Jan-2011 Kenny Root <kroot@google.com> Add the {get,set}PackageObbPaths calls to API

Add getPackageObbPaths() and setPackageObbPaths() to the public API.

Bug: 3214719
Change-Id: I8627b5f674a795d5780eb5c08911419110670a41
/frameworks/base/core/java/android/content/pm/PackageManager.java
194157638ae59418b9d9cb4d73f7e285f59bc579 15-Dec-2010 Dianne Hackborn <hackbod@google.com> Fix launching of activities that I broke.

Change-Id: I39f4189bad6bdecdc7f9362410f36453fd816121
/frameworks/base/core/java/android/content/pm/PackageManager.java
30d7189067524000c738c188c4ff91f84f474d25 11-Dec-2010 Dianne Hackborn <hackbod@google.com> Fix issue #3274841: Orientation change problem with a paused activity

Plus a bunch of debug output improvements.

And some new Intent helpers for dealing with restarting an app.

Change-Id: I50ec56bca6a86c562156b13fe8a6fdf68038a12e
/frameworks/base/core/java/android/content/pm/PackageManager.java
880119bf43d738ca632b5d3861eb52d655c1c0fc 19-Nov-2010 Dianne Hackborn <hackbod@google.com> Implement issue #2367442: Please add API for manipulating installer
package names

Change-Id: I0563e896a47ae1a6e77aebc2d624fb1bde52ffbc
/frameworks/base/core/java/android/content/pm/PackageManager.java
78d688369a2240009d3bbe4126996a973b2e2fe2 07-Oct-2010 Dianne Hackborn <hackbod@google.com> Implement tracking of package install times.

Provides information about the time at which the package was
first installed and the time it was last updated.

Change-Id: Icb43f77b5b669a1ce685e8913046b8be386b6175
/frameworks/base/core/java/android/content/pm/PackageManager.java
4d023d214d12c8588b6a3441c2b4bd7c09900937 01-Oct-2010 Dianne Hackborn <hackbod@google.com> Some documentation fixes.

Change-Id: Iaae452fc1430af788ce440a043ca7fb53e667a61
/frameworks/base/core/java/android/content/pm/PackageManager.java
898e1e8860dea8490ba9208fca7965adf9cb8298 27-Sep-2010 Dan Morrill <morrildl@google.com> Adding a feature to indicate that the device possesses low-latency audio.
The specific criteria for low-latency audio are defined in the CDD, but since
that hasn't yet been settled for Gingerbread, this change doesn't go into
details. We can do a docs change later once GB CDD is final.

Change-Id: Ic5ad9d04e8ecd78c81b6f09439affec6bf8cb9b2
/frameworks/base/core/java/android/content/pm/PackageManager.java
5744bb4aa5dea525d1ae236cd16379134024eae1 02-Sep-2010 Dan Morrill <morrildl@google.com> Adding new feature definitions for new sensors (barometer and gyroscope.)

Change-Id: Ic3a35c7b277921eaa5b05e3285b6aed5ed75bea6
/frameworks/base/core/java/android/content/pm/PackageManager.java
09f3360f51b216fb9c40f78e7a4eee41cd9cc187 13-Sep-2010 Chris Palmer <palmer@google.com> DO NOT MERGE Correct the PackageManager.checkSignatures documentation.

Make the documentation match the current behavior since change ID
Ibdeff170bd386d723f774136b18e0ad59d9cdabb.

Will add @deprecated tags back in in a separate CL. This is just to get
things in the same state as master, following the build breakage mishap.

Change-Id: I47c53700892473061093002c32ad8f095b5813d1

Do not merge to master; an equivalent CL has already been committed there.
/frameworks/base/core/java/android/content/pm/PackageManager.java
6993d3d136fed8600a3e337d710907b50d8d6e49 03-Sep-2010 Dan Morrill <morrildl@google.com> Adding a feature denoting support for 5 or more fully
independent multitouch pointers.

Change-Id: I9997ed9c481dbd507e9eff70d8beb9e1140cca3f
/frameworks/base/core/java/android/content/pm/PackageManager.java
3424c02e6b931a8bbd651ae75217bebd008b2605 27-Aug-2010 Hung-ying Tyan <tyanh@google.com> Add software features for SIP and VOIP

and block SipService creation and SIP API if the feature is not available.

Change-Id: Icf780af1ac20dda4d8180cea3e5b20e21a8350bc
/frameworks/base/core/java/android/content/pm/PackageManager.java
76437d379357a418b8236b041d1b3e03939264e6 01-Sep-2010 Dan Morrill <morrildl@google.com> Adding a feature definition corresponding to support for Near-Field
Communications (NFC).

Change-Id: I32b1b949524bfd978f53e23e02d38dfba4a2ea9c
/frameworks/base/core/java/android/content/pm/PackageManager.java
361199b5e742c6635d4d7a03de6cf37b31cf442c 31-Aug-2010 Dianne Hackborn <hackbod@google.com> Add PackageManager API to get information about a provider component.

Kind-of useful when all you have is a ComponentName.

Change-Id: I9a99f12daabb29e97e882e09c43ca0df70c00651
/frameworks/base/core/java/android/content/pm/PackageManager.java
deb112674e9940a46c87fa4e3bae5d8d1ee84ef3 02-Aug-2010 Kenny Root <kroot@google.com> Only allow one movePackage operation in-flight

When a movePackage operation is requested, don't allow multiple requests
to pile up for one package. Once a move is completed, an observer will
receive the message and be allowed to call movePackage again.

Change-Id: Ie3842b6d96446febc0037bf9b8f1ca250735edc2
/frameworks/base/core/java/android/content/pm/PackageManager.java
93565c4b3265c16aee4a82d7556f811776c17db8 19-Jun-2010 Kenny Root <kroot@google.com> OBB API for PackageManager

Simple API for tracking .obb files associated with packages. Stores the
path in the PackageSettings. No verification of file content is done
now since the PackageManagerService can't read the SD card where these
files will likely live.

Change-Id: Ibeaf26ba0526b6d60f401137e58f46ee9faff39e
/frameworks/base/core/java/android/content/pm/PackageManager.java
de1057c4a6aa41c3b88bcc4fd49d70f973f1d9eb 14-Jun-2010 Chih-Chung Chang <chihchung@google.com> Unhide new API for supporting multiple cameras.

Change-Id: I916a536c80330444a15986ba380205a6deed2390
/frameworks/base/core/java/android/content/pm/PackageManager.java
81cd2e90ccdda498234384c8207afe2213714e60 22-Apr-2010 Adam Powell <adamp@google.com> Logo attribute for manifest and PackageManager methods to fetch it

Change-Id: I2c5ac44a4e2af982a616b2012901d7395013b19f
/frameworks/base/core/java/android/content/pm/PackageManager.java
b0fe033ff8695418645ede29ce683949f68033c2 05-Apr-2010 Dan Morrill <morrildl@google.com> Adding a feature definition for touchscreens that was overlooked in the last
round.

Change-Id: I8f30676a7b468a9868503b05f366709d5534a44e
/frameworks/base/core/java/android/content/pm/PackageManager.java
d7c096845dee7616095eda0fe9e7aa08f0ba9c20 30-Mar-2010 Dianne Hackborn <hackbod@google.com> Package manager optimizations.

Addresses:
Issue #2550648: PackageManagerService setComponentEnabledSetting unconditionally
writes Settings xml
Issue #2549084: Make PackageManager.addPermission have async version

Also make the writing of settings when changing the preferred activities to use
the same async mechanism, and fiddle with thread priorities in the background
thread to go up to foreground priority when holding the lock to write settings
and a few other places. (At some point we should really clean this up to never
acquire the main lock while in the background.)

Change-Id: Ib2b7632543f6fb3f92a225518579f3b2d15e1413
/frameworks/base/core/java/android/content/pm/PackageManager.java
2e805b19cdb309ea6eeb6d2e8b0915681f831f5a 22-Mar-2010 Brad Fitzpatrick <bradfitz@android.com> Grammar fixes.

Change-Id: I77672d2260c26aee146bb6a853137c14e3db1f28
/frameworks/base/core/java/android/content/pm/PackageManager.java
14b6abda1309631d49d4bebbb0317a7e1dfc0a50 17-Mar-2010 Suchi Amalapurapu <asuchitra@google.com> Add new install flag to install on internal flash only
Change default install location policy for new flag.
New error code for media unavailable.

Change-Id: I5a5d0828b067692b2b94a15a2bcc7534f796c1a2
/frameworks/base/core/java/android/content/pm/PackageManager.java
8a9ab24a5c9b595ac0268fcade4b5bbfe7c45c2d 12-Mar-2010 Suchi Amalapurapu <asuchitra@google.com> Do storage checks before initiating a move.
Add new remote method to check for insufficient error conditions.
Some fixes in MountService when updating media status on PackageManagerService
Fix size calculation condition in installd.

Add new error code if media is unavailable.
New tests for testing error codes.
Some additional debugging statements in MountService.

Change-Id: Ibfe90d5ed6c71d57f9c1c67806f38b5ae9ecdfbf
/frameworks/base/core/java/android/content/pm/PackageManager.java
2ee89ea2887252053c31541c54126a8b084c9bca 11-Mar-2010 Dianne Hackborn <hackbod@google.com> Applications should -not- be able to set preferred activities.

I can't believe I let this slip through. And in the SDK no less. :(

The APIs for setting preferred activities will now throw a security
exception when used. This may break some apps, we'll see how it
goes. If it is too bad we can just make these log and not throw
anything, but I would much prefer they throw an exception.

Change-Id: I3aed434750eef8b202aa9d5bd774a0121be521c6
/frameworks/base/core/java/android/content/pm/PackageManager.java
50ab63f5831fed5cfa888fb67f0a27eb4c0a86c4 06-Mar-2010 Dan Morrill <morrildl@google.com> Adding definitions & APIs for features that are newly-optional in FroYo.
This also refactors the files containing the features so that they are more
modular. Note that this also changes data/etc/Android.mk so that
required_hardware.xml is NOT copied automatically for all devices
anymore. Accordingly, that file is removed.
/frameworks/base/core/java/android/content/pm/PackageManager.java
1f9e1b4c37c135b75cf064cbb5675aa576e2942a 26-Feb-2010 Suchi Amalapurapu <asuchitra@google.com> Remove public variables in PackageManager
Dont invoke getInstallLocation for forward locked apps.
If INSTALL_ON_SDCARD is selected as default, forward locked
apps are not being installed because of conflicting flags.
/frameworks/base/core/java/android/content/pm/PackageManager.java
8946dd3355fc1dcbad872c0546e356474d4cc5de 19-Feb-2010 Suchi Amalapurapu <asuchitra@google.com> Move package from internal to external and vice versa.
/frameworks/base/core/java/android/content/pm/PackageManager.java
bd3f527ea0fcca2be0f773e5d6832a80a884699f 19-Feb-2010 Mike LeBeau <mlebeau@android.com> Elaborate a little on the documentation for PackageManager's resolveActivity.

Not sure if this wording is perfectly appropriate, so comments welcome.
/frameworks/base/core/java/android/content/pm/PackageManager.java
5b993ce7bc29e43a3215a50ce6ce5d6550d4e5e2 12-Feb-2010 Suchi Amalapurapu <asuchitra@google.com> Include install location preference when installing packages.
Changes include
Add new remote call in default container service to determine
install location.
Rename INSTALL_ON_SDCARD
Remove recommentAppInstall method
Add some additional flags used in remote stubs.
Move check for protected apps prior to copy.
Unit tests

DefaultContainerService first parses the file uri(if content uri is specified
it returns a default install internal only value) and returns
a recommended location. Based on which the temporary id is determined
either a file name or a container id and the file is copied there.
This is then later renamed during install.
Todo's light weight parsing of package when determining location since we
just need the install location attribute only when finding out
recomended location. This will also enable to move the check for
updated system apps(cannot be on sdcard) prior to copying.
/frameworks/base/core/java/android/content/pm/PackageManager.java
470969346d7958f859d97d1a136b4ecc11e2a464 12-Feb-2010 Dianne Hackborn <hackbod@google.com> Add APIs for mapping between new and current package names.

This will allow Market and others to find out what the "real" name
of a package is, when it is currently running under the old name of
a previously installed version.
/frameworks/base/core/java/android/content/pm/PackageManager.java
117818e4f171b1fd9daa05349c48f61388f04567 09-Feb-2010 Suchi Amalapurapu <asuchitra@google.com> Add new manifest option for install location
Change recommendAppInstallLocation api
add code to parse new attribute.
Define flags in PackageInfo
Add new settings attributes for enabling setting and value for install location
Some tests
The policy for install location: if explicitly set in manifest as internal only we try to install the app only on internal storage. if set to preferExternal, we try to install it on sdcard if possible. If not we fall back to internal.
If the user enables setting SET_INSTALL_LOCATION(which will always
be set to false in final release builds) and sets a prefered location, we try
to honour it.
/frameworks/base/core/java/android/content/pm/PackageManager.java
e83cefcef07f9ac025642c1ffec76b4c7ab39cf2 05-Feb-2010 Dianne Hackborn <hackbod@google.com> New external storage APIs.

This implements the spec for external storage organization, and
properly reflects how the media scanner organizes the files it finds.

Also includes package manager support for removing app private
files from external storage when the application is uninstalled.

For the new APIs and paths, the main place to look is Environment
and Context.
/frameworks/base/core/java/android/content/pm/PackageManager.java
b56ae20b22fd7283df32072a431ab6d4965f3c1b 05-Feb-2010 Suchi Amalapurapu <asuchitra@google.com> Rename media resource broadcasts
Add checks for fwdlocked and updated system apps
add more tests
remove duplicate adds
/frameworks/base/core/java/android/content/pm/PackageManager.java
cdc428bdb73db7e0d3403b6515c65573b182e218 01-Feb-2010 Oscar Montemayor <oam@google.com> Apps on SD project.
Javadoc fixes for new method in PackageManager class.
/frameworks/base/core/java/android/content/pm/PackageManager.java
539d3c475f44b1499499a8b70375a192545cf113 30-Jan-2010 Oscar Montemayor <oam@google.com> Apps on SD card project.
Refactored recommendAppInstallLocation(..) method in PackageManager by making it an instance method.
Since PackageManager has only abstarct instance methods, moved implementation to ApplicationContext.ApplicationPackageManager class, in line with the rest of the method
implementations. Tah way, chage is consistent with best coding practices.
Also MockPackageManager received the additional method.
/frameworks/base/core/java/android/content/pm/PackageManager.java
1228d0a1dddb8c03474ee3823499936a8b1d850c 28-Jan-2010 Oscar Montemayor <oam@google.com> Apps on SD card project.
This class implements heuristics to determine best app install location, without looking at the package flags (pre-parsing stage).
/frameworks/base/core/java/android/content/pm/PackageManager.java
af8e9f4805643f90a9dc0ecfa119e0a860c12f8a 12-Jan-2010 Suchi Amalapurapu <asuchitra@google.com> app install on sdcard. provide skeleton implementation
to install an app on sdcard, just resources.
Add new install path for /asec in installd.
ignore . when checking for apk path since the sdcard packages id'ed
by package name.
Add new -s option to adb shell pm
Refactor fwd locked from scanMode to ApplicationInfo.
Add new flag for sd install
Add new parse flags for fwd locking and installing on sdcard
New mock api's in PackageManagerService to invoke MountService api's. These
will be refactored again and so have been wrapped internally.
Some error codes in PackageManager
Changes in PackageManagerService to use mPath and mScanPath during installation
and switch to using PackageParser.Package.applicationInfo attributes for
source and public resource directories.
Some known issues that will be addressed later
using system_uid for now. needs some tinkering with uid and packagesetting creation to use the actual app uid
error handling from vold not very robust. ignoring lot of things for now
sending a delayed destroy to delete packages. will revisit later
revisit temp file creation later. just copy for now
/frameworks/base/core/java/android/content/pm/PackageManager.java
3274b9b7da6f3ee0ee0285deb955907adec52bad 15-Dec-2009 Xavier Ducrohet <xav@android.com> Add Annotation for optional features.

This is used by the SDK to display available features in the
editors.

Change-Id: I10073d503d1b3dcb92a5dc526cd054285b85fa3a
/frameworks/base/core/java/android/content/pm/PackageManager.java
a7ca0e5e320bbb643f8bc9feb4717dbc5e78e0b9 01-Dec-2009 Dianne Hackborn <hackbod@google.com> Fix issue #2296457: PackageManager.addPackageToPreferred needs to a no-op

Change-Id: I0d8f75938226e1bb49cf7b1154445631b0bb0bc9
/frameworks/base/core/java/android/content/pm/PackageManager.java
08ee42ce864dc2b3ca2ca92af7220a3681d06835 20-Nov-2009 Dianne Hackborn <hackbod@google.com> More on issue #2271640: Fix wallpaper etc docs

Publish the features developers may be interested in.

Change-Id: I7d40ad9a9f4b9770e2f8dd1b0a729b0d322c062e
/frameworks/base/core/java/android/content/pm/PackageManager.java
039c68e75606e837cf021815a0210836724574ad 27-Sep-2009 Dianne Hackborn <hackbod@google.com> The touch screen is probably a feature.

Also extend the feature APIs a bit.

Change-Id: I99e932d7f4e61edb0e20f75c55e9831e4b59a14d
/frameworks/base/core/java/android/content/pm/PackageManager.java
49237345d83e62fdb9eb8d50b13ad086636a04fa 28-Aug-2009 Dianne Hackborn <hackbod@google.com> Add platform infrastructure for features.

This introduces a new mechanism to define features associated with
a platform, query the current device for the available features,
and enforce that apps requiring features that aren't available can't
be installed.

Also now allows uses-library to specify that a library is optional,
so the lack of such a library will not prevent the app from being
installed (but if it does exist it will be correctly linked into
the app).

Change-Id: I5b369b46cfa0b3d37c9e08fd14ef1098a978e67b
/frameworks/base/core/java/android/content/pm/PackageManager.java
25660ec2c8175559d86d50bc2bfdef29589d0813 13-Aug-2009 Joe Onorato <joeo@android.com> Unbreak the sdk build.

I didn't break it, so if this doesn't fix it, somebody else should give
it a shot.
/frameworks/base/core/java/android/content/pm/PackageManager.java
766cbfe44be3c5013a6a22bd6cd8ad1055a37256 13-Aug-2009 Dianne Hackborn <hackbod@google.com> Add new API to compare certs of two UIDs.
/frameworks/base/core/java/android/content/pm/PackageManager.java
c00c04d7d8758a5ade185d465624e47dcf1bd7c0 22-Jul-2009 Dianne Hackborn <hackbod@google.com> am 11b822d2: Simplify density compatibility to a boolean.

Merge commit '11b822d2a91ea17c34c0cb1c11e80a9a30d72864'

* commit '11b822d2a91ea17c34c0cb1c11e80a9a30d72864':
Simplify density compatibility to a boolean.
11b822d2a91ea17c34c0cb1c11e80a9a30d72864 22-Jul-2009 Dianne Hackborn <hackbod@google.com> Simplify density compatibility to a boolean.

Instead of a list, we now just have a single boolean indicating whether an
application is density aware, and this set set to true by default as of
Donut.
/frameworks/base/core/java/android/content/pm/PackageManager.java
c73e9ad55a28f6bec3260e919573e0597fdd23ab 19-Jun-2009 Suchi Amalapurapu <asuchitra@google.com> am bc806f65: Remove deprecated api. Aptly rename freeStorageWithIntent to freeStorage.

Merge commit 'bc806f65edc33f6eda0f475ac84e5e037a013a90'

* commit 'bc806f65edc33f6eda0f475ac84e5e037a013a90':
Remove deprecated api. Aptly rename freeStorageWithIntent to freeStorage.
bc806f65edc33f6eda0f475ac84e5e037a013a90 18-Jun-2009 Suchi Amalapurapu <asuchitra@google.com> Remove deprecated api. Aptly rename freeStorageWithIntent to freeStorage.
/frameworks/base/core/java/android/content/pm/PackageManager.java
8dbbe3b52f815c49be986814743a521f802b4785 19-Jun-2009 Android (Google) Code Review <android-gerrit@google.com> am 63e7155c: Merge change 4696 into donut

Merge commit '63e7155c7d1d0c3f0027400aa09e9a45f648a80d'

* commit '63e7155c7d1d0c3f0027400aa09e9a45f648a80d':
Fix targetSdkVersion, make resize mode a flag, delayed dexopt, easy ApplicationInfo.
5c1e00b14d2ef10ec76abf3e951fa8003a67f558 19-Jun-2009 Dianne Hackborn <hackbod@google.com> Fix targetSdkVersion, make resize mode a flag, delayed dexopt, easy ApplicationInfo.

- Fix a bug where targetSdkVersion could not be set if minSdkVersion. Stupid, stupid.
Also make sure to fail if minSdkVersion is for a code name. Really stupid.

- Change the API for resize compatibility mode to be a bit in the flags field, instead
of a separate boolean.

- Implement delayed dexopting, to avoid the looong full dexopt during boot. This is
only enabled for "eng" builds. When in this mode, the activity manager will make
sure that a dexopt has been done before loading an .apk into a process, and will
try to avoid displaying ANRs if they are due to the dexopt causing some operation
to take longer than it normally would (though I make no guarantees about this
totally working).

- Add API to Context to get the ApplicationInfo for its package, for easy access to
things like targetSdkVersion.
/frameworks/base/core/java/android/content/pm/PackageManager.java
abb01dba70fa52b3576fa9f6a175f3840b959fde 18-Jun-2009 Dianne Hackborn <hackbod@google.com> am c14b9ccd: Extend Intent/Uri conversion for use by Browser

Merge commit 'c14b9ccdf13163cae5ce5d21bcf377010b37594b'

* commit 'c14b9ccdf13163cae5ce5d21bcf377010b37594b':
Extend Intent/Uri conversion for use by Browser
c14b9ccdf13163cae5ce5d21bcf377010b37594b 18-Jun-2009 Dianne Hackborn <hackbod@google.com> Extend Intent/Uri conversion for use by Browser

This introduces a new Uri form of Intent with an "intent:" scheme, and a
corresponding update to the parser to handle these, so that the browser
can use this generic facility for starting activities based on the links
that are clicked and allow for web pages to link to arbitrary intents.

There is also a new "package" field on Intent which allows you to limit
the components it finds to a given package. This replaces the new method
that was added to PackageManger for doing this when resolving activities,
and implements it for all Intent queries against the package manager.
/frameworks/base/core/java/android/content/pm/PackageManager.java
e1fae30e20b1515eeb036a7c103e1e70de130bdd 18-Jun-2009 Suchi Amalapurapu <asuchitra@google.com> Merge commit '0781df94' into manualmerge

Conflicts:
Android.mk
api/current.xml
1ccac75e1f1b97eccb916a8de04fc1012b30f6e5 12-Jun-2009 Suchi Amalapurapu <asuchitra@google.com> Remove circular dependency in PackageManager. api freeStorage uses PendingIntent from android.app
Create a new public IntentSender class that can be used by PackageManager instead.
This new class uses IIntentSender internally and can only be created by PendingIntent for now.
Provide a new getIntentSender api in PendingIntent to create an instance of this class.
Move IIntentSender and IIntentReceiver from android.app to android.content
Change imports of IIntentSender and IIntentReceiver to reflect the new package name
The PackageManager api has been named as freeStorageWithIntent and will be renamed as freeStorage
once the older api(which has been deprecated) will be removed shortly.
/frameworks/base/core/java/android/content/pm/PackageManager.java
342d59d3197caa1cd1de7a600c6e0ba4a59883f4 04-Jun-2009 Mitsuru Oshima <oshima@google.com> am 9189cabb: * Moved supports-density tag under manifest * Refactored Compatibility code * Added CompatibilityInfo class * Removed getApplicationScale from Context * Added Resources#getCompatibilityInfo so that RootView can get the compatibility info w/o going through Context * Expandable support * Added expandable tag under manifest * Old application w/o expandable is given the default screen size ([320, 480] x density). * The non-expandable window is centered.

Merge commit '9189cabb0b6c6c28232fe6f412b7ba7a37352a6a'

* commit '9189cabb0b6c6c28232fe6f412b7ba7a37352a6a':
* Moved supports-density tag under manifest
9189cabb0b6c6c28232fe6f412b7ba7a37352a6a 03-Jun-2009 Mitsuru Oshima <oshima@google.com> * Moved supports-density tag under manifest
* Refactored Compatibility code
* Added CompatibilityInfo class
* Removed getApplicationScale from Context
* Added Resources#getCompatibilityInfo so that RootView can get the compatibility info w/o going through Context
* Expandable support
* Added expandable tag under manifest
* Old application w/o expandable is given the default screen size ([320, 480] x density).
* The non-expandable window is centered.
/frameworks/base/core/java/android/content/pm/PackageManager.java
ae8c5b868fa518306b50e08da9e5258ad075fa61 03-Jun-2009 Satish Sampath <satish@android.com> am 8dbe612d: Adding internal method replacePreferredActivity.

Merge commit '8dbe612dc60526d635e57257b58627b33a099678'

* commit '8dbe612dc60526d635e57257b58627b33a099678':
Adding internal method replacePreferredActivity.
8dbe612dc60526d635e57257b58627b33a099678 03-Jun-2009 Satish Sampath <satish@android.com> Adding internal method replacePreferredActivity.

This was required because we need a way to set the preferred activity for a
particular intent filter based on user selection (in our case the
ACTION_WEB_SEARCH intent filter for selecting the preferred search engine from
the list of available search engines providers). The current
addPreferredActivity call was not sufficient since it leaves the existing
preferred activities in the list and does not remove them, which this call
does.
/frameworks/base/core/java/android/content/pm/PackageManager.java
385bb79ebb436e5672915eac2fc1a4fcdedf88b6 23-May-2009 Dianne Hackborn <hackbod@google.com> am b181118b: Define TARGET_CPU_ABI for finding native code in .apks

Merge commit 'b181118b6e58c0014da4e9d52bf38548adc73a8a'

* commit 'b181118b6e58c0014da4e9d52bf38548adc73a8a':
Define TARGET_CPU_ABI for finding native code in .apks
b181118b6e58c0014da4e9d52bf38548adc73a8a 22-May-2009 Dianne Hackborn <hackbod@google.com> Define TARGET_CPU_ABI for finding native code in .apks
/frameworks/base/core/java/android/content/pm/PackageManager.java
dd6face5a66ed6c9ac24b2754ec046b82881182c 15-May-2009 Mihai Preda <preda@google.com> am eae850ce: Allow intent resolution to be constrained by package name.

Merge commit 'eae850cefe7e149f396c9e8ca1f34ec02b20a3f0'

* commit 'eae850cefe7e149f396c9e8ca1f34ec02b20a3f0':
Allow intent resolution to be constrained by package name.
eae850cefe7e149f396c9e8ca1f34ec02b20a3f0 13-May-2009 Mihai Preda <preda@google.com> Allow intent resolution to be constrained by package name.
/frameworks/base/core/java/android/content/pm/PackageManager.java
d2b4929ba00939c1aa5037927f27427637cc2f68 13-May-2009 Dianne Hackborn <hackbod@google.com> am ade3eca: Implement issue #1783881 (manifest option for adb-install-on

Merge commit 'ade3ecad94d1f4431576f53bae26c35efbf7a2c9'

* commit 'ade3ecad94d1f4431576f53bae26c35efbf7a2c9':
Implement issue #1783881 (manifest option for adb-install-only apps)
ade3ecad94d1f4431576f53bae26c35efbf7a2c9 12-May-2009 Dianne Hackborn <hackbod@google.com> Implement issue #1783881 (manifest option for adb-install-only apps)

You can now use android:testOnly="true" to not allow your .apk to be installed
as a normal app. The only way to do so is with the pm command and giving the
-t option, which sets a new INSTALL_ALLOW_TEST flag when installing.

I also used this to clean up the install API... actually, mostly to hide
it, since it is not accessible to apps so shouldn't be in the SDK. We
will be doing some more work on it, so this will prevent adding yet
another backwards-compatibility-for-no-reason version.
/frameworks/base/core/java/android/content/pm/PackageManager.java
c64322c35212e919906ffd66118c7d5d3ad36636 28-Apr-2009 Jacek Surazski <jaceks@google.com> PackageManager keeps track of who installed what.

Stores the package name of the installer app in packages.xml
/frameworks/base/core/java/android/content/pm/PackageManager.java
65e13171e12cb9e9fc2f608d0c8a92cd3c098648 28-Apr-2009 Jacek Surazski <jaceks@google.com> PackageManager keeps track of who installed what.

Stores the package name of the installer app in packages.xml
/frameworks/base/core/java/android/content/pm/PackageManager.java
1655be46d2b7d45f071a6a1411ac8bd41c749c21 08-May-2009 Dianne Hackborn <hackbod@google.com> Fix issue #1837610 and #1753079

Issue 1837610 Adding a Widget before Running the Associated App Causes a Force Close

We were not retrieving the shared libraries of an application when deliving a
broadcast to an explicit component.

Issue 1753079 loading class path of instrumented app into instrumentation may load wrong path when instrumented app shares process with other apps:

We were using the ApplicationInfo that was used to originally create the process, not the one that the
instrumentation is against.
/frameworks/base/core/java/android/content/pm/PackageManager.java
851a54143c15a1c33361efae2db3f7f45059b472 08-May-2009 Dianne Hackborn <hackbod@google.com> Implement targetSdkVersion and maxSdkVersion, plus version code names.

This adds new attributes for specifying a targetSdkVersion and maxSdkVersion.
There is a new ApplicationInfo flag that is set if the application has set
its targetSdkVersion to the current platform or later. Also you can now
use a string for minSdkVersion and targetSdkVerion, to indicate you are
building against a development tree instead of an official platform.
/frameworks/base/core/java/android/content/pm/PackageManager.java
8d112675879a2b83197d3b4ae4fb623abd1a1ec3 27-Apr-2009 Mitsuru Oshima <> AI 147845: Compatibility mode support. Part 1
Adding supports-density tag to manifest file/ApplicationInfo.
BUG=1752478

Automated import of CL 147845
/frameworks/base/core/java/android/content/pm/PackageManager.java
105925376f8d0f6b318c9938c7b83ef7fef094da 19-Mar-2009 The Android Open Source Project <initial-contribution@android.com> auto import from //branches/cupcake_rel/...@140373
/frameworks/base/core/java/android/content/pm/PackageManager.java
9066cfe9886ac131c34d59ed0e2d287b0e3c0087 04-Mar-2009 The Android Open Source Project <initial-contribution@android.com> auto import from //depot/cupcake/@135843
/frameworks/base/core/java/android/content/pm/PackageManager.java
d83a98f4ce9cfa908f5c54bbd70f03eec07e7553 04-Mar-2009 The Android Open Source Project <initial-contribution@android.com> auto import from //depot/cupcake/@135843
/frameworks/base/core/java/android/content/pm/PackageManager.java
076357b8567458d4b6dfdcf839ef751634cd2bfb 03-Mar-2009 The Android Open Source Project <initial-contribution@android.com> auto import from //depot/cupcake/@132589
/frameworks/base/core/java/android/content/pm/PackageManager.java
3dec7d563a2f3e1eb967ce2054a00b6620e3558c 03-Mar-2009 The Android Open Source Project <initial-contribution@android.com> auto import from //depot/cupcake/@137055
/frameworks/base/core/java/android/content/pm/PackageManager.java
d24b8183b93e781080b2c16c487e60d51c12da31 11-Feb-2009 The Android Open Source Project <initial-contribution@android.com> auto import from //branches/cupcake/...@130745
/frameworks/base/core/java/android/content/pm/PackageManager.java
f1e484acb594a726fb57ad0ae4cfe902c7f35858 22-Jan-2009 The Android Open Source Project <initial-contribution@android.com> auto import from //branches/cupcake/...@127436
/frameworks/base/core/java/android/content/pm/PackageManager.java
f013e1afd1e68af5e3b868c26a653bbfb39538f8 18-Dec-2008 The Android Open Source Project <initial-contribution@android.com> Code drop from //branches/cupcake/...@124589
/frameworks/base/core/java/android/content/pm/PackageManager.java
54b6cfa9a9e5b861a9930af873580d6dc20f773c 21-Oct-2008 The Android Open Source Project <initial-contribution@android.com> Initial Contribution
/frameworks/base/core/java/android/content/pm/PackageManager.java