83312 Commits

Author SHA1 Message Date
Dianne Hackborn
4428e17c5e Some clean up of app install and user management.
UserManagerService is now closely tied to PackageManagerService,
sharing the same locks.  There is no longer direct access of
Installer by UserManagerService, instead the package manager is
back to solely owning it.

Creating a new user now correctly only installs system apps for
that user.

Fixed some misc bugs, where we were getting nulls when
querying content providers and instrumentation in uninstalled
users, incorrect locking, etc.

Change-Id: Ife69b6e373d0cf7c5cfc03fc588e36b43ad5d8b0
2012-08-24 18:00:37 -07:00
Dianne Hackborn
a31803fca6 Merge "Keep track of whether an app is installed for each user." into jb-mr1-dev 2012-08-24 14:36:22 -07:00
Dianne Hackborn
7767eac323 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
2012-08-24 13:53:13 -07:00
Amith Yamasani
65e08d25fa Merge "Fix permissions on cloned data dirs" into jb-mr1-dev 2012-08-24 13:00:05 -07:00
Amith Yamasani
794d62f607 Fix permissions on cloned data dirs
This makes the downloaded apk visible to the package installer

Change-Id: I0f60cf279a3c6a08c7479f93ef9135d7428f2385
2012-08-24 12:58:27 -07:00
Jeff Sharkey
1552586283 Merge "Clean up firewall interface method names." into jb-mr1-dev 2012-08-24 11:46:27 -07:00
Jeff Sharkey
2c0929850a Clean up firewall interface method names.
Change-Id: I653f0a01af7c90fc96b201abb31ea8354b036e74
2012-08-24 11:44:40 -07:00
Jeff Sharkey
34f8631258 Merge "Migrate legacy VPN arguments to system_server." into jb-mr1-dev 2012-08-24 11:33:00 -07:00
Jeff Sharkey
82f8521d38 Migrate legacy VPN arguments to system_server.
Generate the racoon and mtpd daemon arguments in system_server,
instead of accepting them from Settings.

Bug: 5756357
Change-Id: I42c1a644f6add477fe4222342640d7db15982cb8
2012-08-24 11:29:58 -07:00
Jeff Sharkey
96702ad6d7 Merge "Framework interface for netd firewall." into jb-mr1-dev 2012-08-24 11:07:42 -07:00
Jeff Sharkey
c268f0b19e Framework interface for netd firewall.
Bug: 5756357
Change-Id: If8b9f738fcea2cf16bd01682220718b57346c7cc
2012-08-24 11:00:28 -07:00
Marco Nelissen
4ff8d37934 Merge "Let apps provide a custom data source for extractors" into jb-mr1-dev 2012-08-24 10:59:16 -07:00
Teng-Hui Zhu
e0d5ceefbf Merge "Request Layout after video size changed" into jb-mr1-dev 2012-08-24 10:50:49 -07:00
Marco Nelissen
c209a06cfd Let apps provide a custom data source for extractors
Adds android.media.DataSource, which is modeled after its native namesake,
and a new method on MediaExtractor that lets apps specify their implementation
of a DataSource as the source of data for the extractor.

Change-Id: If1b169bd18d2691ebc4f8996494dfc8ee0894b6c
2012-08-24 10:36:51 -07:00
Chris Wren
e370c46822 Merge "[phones] Only allow double-flick opening of the quicksettings panel." into jb-mr1-dev 2012-08-24 09:24:10 -07:00
Chris Wren
b8ea2f59e2 [phones] Only allow double-flick opening of the quicksettings panel.
Bug: 7043587
Change-Id: I39d208626c477e8c081c9d81c3124eb631152998
2012-08-24 12:20:30 -04:00
Victoria Lease
54f4f91d7c Merge "avert 2500ms wait in InputMethodManager" into jb-mr1-dev 2012-08-24 08:01:41 -07:00
Wink Saville
78e73224ca am 4e9c7e3f: am 5a60f058: am 13ab2c9f: Merge "Telephony: Add ICC_UNKNOWN intent"
* commit '4e9c7e3f60cee01b5bf376d53938b07c97f35a9e':
  Telephony: Add ICC_UNKNOWN intent
2012-08-24 07:30:15 -07:00
Dianne Hackborn
d820c38d21 am 513f68bc: am bfe20d1a: am 8bfba7df: Merge "fix wrong substring"
* commit '513f68bc5a5f15d799f8795392d4861a5704fba1':
  fix wrong substring
2012-08-24 07:30:11 -07:00
Jean-Baptiste Queru
58dc9b6bfa am 790d3403: am d86bebb4: am 322b0a16: Merge "Protecting more views from (bad) MotionEvents"
* commit '790d34039df650d983c7c87a2a2e888e18edc2be':
  Protecting more views from (bad) MotionEvents
2012-08-24 07:30:06 -07:00
Irfan Sheriff
058f003507 am 2a4aaf13: Merge "resolved conflicts for merge of 86bb2258 to jb-dev-plus-aosp" into jb-dev-plus-aosp
* commit '2a4aaf133c8bec9bbfcd50c1eb0f25896f579cd1':
  Fix system server restart
2012-08-24 07:29:52 -07:00
Jean-Baptiste Queru
07bde72ff9 resolved conflicts for merge of 9455f8f2 to jb-mr1-dev
Change-Id: I6c6970adb58ac45473c7cc665d99f8e8a6ca8571
2012-08-24 07:21:07 -07:00
Ben Murdoch
4d3a7b0752 Merge "Make SslErrorHandler ctor public/@hide." into jb-mr1-dev 2012-08-24 02:10:38 -07:00
Wu-cheng Li
dad32938cd Merge "Add INTENT_ACTION_STILL_IMAGE_CAMERA_SECURE intent." into jb-mr1-dev 2012-08-24 00:07:32 -07:00
Baligh Uddin
5d1a61ca1e Merge "Import translations. DO NOT MERGE" into jb-mr1-dev 2012-08-23 19:31:15 -07:00
Baligh Uddin
51fabf2319 Merge "Import translations. DO NOT MERGE" into jb-mr1-dev 2012-08-23 19:11:34 -07:00
Baligh Uddin
3081c71a83 Import translations. DO NOT MERGE
Change-Id: Ie2c09a688d76f2886909461362de765820d3e255
Auto-generated-cl: translation import
2012-08-23 17:24:01 -07:00
Baligh Uddin
4e2055b75b Import translations. DO NOT MERGE
Change-Id: I08748f05d8e19beabd73ff7d895e8a15e2952aed
Auto-generated-cl: translation import
2012-08-23 17:09:40 -07:00
Craig Mautner
fc6baa8349 Merge "Fix unprotected variable access by serializing." into jb-mr1-dev 2012-08-23 16:47:50 -07:00
Jeff Sharkey
d5fc86f067 Merge "Begin moving VPN to NetworkStateTracker pattern." into jb-mr1-dev 2012-08-23 16:47:50 -07:00
Jeff Sharkey
899223b97c Begin moving VPN to NetworkStateTracker pattern.
Created base tracker that handles common bookkeeping, and move VPN
to become a tracker.  VPN status is now reflected in NetworkInfo, and
is mapped to LegacyVpnInfo.

Legacy VPN now "babysits" any init services it starts, watching for
when they stop unexpectedly.

Bug: 5756357
Change-Id: Iba7ec79da69469f6bd9a970cc39cf6b885b4c9c4
2012-08-23 16:41:06 -07:00
rich cannings
e7485cbc45 MAXIMUM_VERIFICATION_TIMEOUT incorrect
Missed a 0.

Change-Id: Ia27d97520ef74cde529fb57ac05e6a37122cd3c2
2012-08-23 16:39:12 -07:00
Teng-Hui Zhu
f5d102ed76 Request Layout after video size changed
bug:6800665

Change-Id: I57010ac26246dff9da45f8fdb7ccbe39c454c54f
2012-08-23 16:03:22 -07:00
rich cannings
7646c773fa Merge "Allow verifiers to extend timeout" into jb-mr1-dev 2012-08-23 15:56:04 -07:00
Jean-Baptiste Queru
f1d9f892f1 am 79f6c5f5: am 1e739c96: am a4e34ae8: Merge "Properly handle quick switch between Home button and Gallery app"
* commit '79f6c5f5673c76c359f9f4b38539cfdb0251efee':
  Properly handle quick switch between Home button and Gallery app
2012-08-23 15:54:05 -07:00
Katie McCormick
67de61b060 Merge "resolved conflicts for merge of 9447af12 to jb-mr1-dev" into jb-mr1-dev 2012-08-23 15:50:29 -07:00
rich cannings
d9ef3e5495 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
2012-08-23 15:39:02 -07:00
Victoria Lease
b570c64ad1 avert 2500ms wait in InputMethodManager
When dispatching input events to the main thread, the event is
handled directly rather than queued. If we have a timeout waiting for
the event to happen, it has to be registered before we call the
dispatcher, otherwise we'll wait for the timeout even though the event
has already been handled.

Bug: 6734044
Change-Id: I6826163dbc6133b385cf1076bb077fb4e82870a1
2012-08-23 15:32:42 -07:00
Wink Saville
4e9c7e3f60 am 5a60f058: am 13ab2c9f: Merge "Telephony: Add ICC_UNKNOWN intent"
* commit '5a60f058891fa5417df7d53be28521b604071fea':
  Telephony: Add ICC_UNKNOWN intent
2012-08-23 15:12:31 -07:00
Dianne Hackborn
513f68bc5a am bfe20d1a: am 8bfba7df: Merge "fix wrong substring"
* commit 'bfe20d1aa1b1236e6592914c5682c59d94936432':
  fix wrong substring
2012-08-23 15:12:26 -07:00
Jean-Baptiste Queru
790d34039d am d86bebb4: am 322b0a16: Merge "Protecting more views from (bad) MotionEvents"
* commit 'd86bebb4a9aaf3b98f6d5a189fd7733926d85891':
  Protecting more views from (bad) MotionEvents
2012-08-23 15:12:21 -07:00
Wink Saville
5a60f05889 am 13ab2c9f: Merge "Telephony: Add ICC_UNKNOWN intent"
* commit '13ab2c9fdaec119a40b628ae772fd1462fbb826d':
  Telephony: Add ICC_UNKNOWN intent
2012-08-23 15:09:43 -07:00
Dianne Hackborn
bfe20d1aa1 am 8bfba7df: Merge "fix wrong substring"
* commit '8bfba7df376509cc944b80bd1f1715f1ef94b246':
  fix wrong substring
2012-08-23 15:09:39 -07:00
Jean-Baptiste Queru
d86bebb4a9 am 322b0a16: Merge "Protecting more views from (bad) MotionEvents"
* commit '322b0a160d29ddbac35d59655111c8730cadd3e2':
  Protecting more views from (bad) MotionEvents
2012-08-23 15:09:35 -07:00
Irfan Sheriff
2a4aaf133c Merge "resolved conflicts for merge of 86bb2258 to jb-dev-plus-aosp" into jb-dev-plus-aosp 2012-08-23 14:58:43 -07:00
Katie McCormick
03a429ddcd resolved conflicts for merge of 9447af12 to jb-mr1-dev
Change-Id: I5b5f086dd27a8c567b27fb9a7799b0552a8e0ae4
2012-08-23 14:47:51 -07:00
Jeff Sharkey
2e9aa74127 Merge "Make USER_PRESENT broadcast per-user." into jb-mr1-dev 2012-08-23 14:44:22 -07:00
Jeff Sharkey
6a25cbdd94 Make USER_PRESENT broadcast per-user.
Bug: 7029707
Change-Id: Ic4671b96525dc2fb4d58ce3fca0a4627598a6cae
2012-08-23 14:43:44 -07:00
Irfan Sheriff
2e5b13ef95 resolved conflicts for merge of 86bb2258 to jb-dev-plus-aosp
Change-Id: I5f115310948a03d791c201fb605dfbb576c0576e
2012-08-23 14:37:06 -07:00
Craig Mautner
5642a48fbb Fix unprotected variable access by serializing.
The variables mKeyguardDisabled and mAllowDisableKeyguard were
being modified unprotected by mKeyguardTokenWatcher. Fix is to
serialize accesses to these variables by only referencing them
from the same Handler that mKeyguardTokenWatcher uses. Eliminates
synchronization blocks and mKeyguardDisabled variable.

Fixes bug 7045624.

Change-Id: I6355aa393507408296316bee61e178dc81e2a172
2012-08-23 14:25:34 -07:00