14330 Commits

Author SHA1 Message Date
Andrei Stingaceanu
0122f651d1 Suspend apps - disable notifications
Disable notifications and posts for suspended apps by
verifying if the package is suspended in NotificationManagerService
where AppOpsManager.OP_POST_NOTIFICATION is checked.

Note that the notificationEnabled user preference is
preserved when unsuspending.

In a following CL will make the "Block all" notifications
setting while an app is suspended (in Settings -> App Info)
readonly so that the user can not turn notifications on.

Bug: 22776761
Change-Id: Ie8edba508bd23406445f9a014404b6d3b17cb223
2016-01-27 16:47:08 +00:00
Sergey Poromov
7200364e8d Merge "Quota exceeded API in BackupAgent" 2016-01-27 12:15:50 +00:00
Rakesh Iyer
e13d22a62d Merge "Allow smart unlock right after boot." 2016-01-27 06:03:01 +00:00
Jae Seo
fb85c6b60a Merge "TIF: Add Builder to TvInputInfo and deprecate createTvInputInfo methods" 2016-01-27 01:58:37 +00:00
Winson Chung
80a5314ad3 Merge "Fixing notification of the docked stack state for the current user." 2016-01-27 01:50:20 +00:00
Jae Seo
c03671fdf6 TIF: Add Builder to TvInputInfo and deprecate createTvInputInfo methods
Bug: 25726241
Change-Id: I8eae9c0c939e7ec4bdfbdbf40d0d1d70a5e0d45c
2016-01-26 17:40:04 -08:00
Winson
dcf4826c52 Fixing notification of the docked stack state for the current user.
- When there are multiple users, ensure that we check that there are
  tasks in the docked stack for each user (instead of just the presence
  of the docked stack) and re-notify listeners of the state of the
  docked stack when the user is switched.

Change-Id: I911c4a32db187f9cd29d462309bd0cf7febb1993
2016-01-27 01:11:13 +00:00
Vladislav Kaznacheev
a74e729fa9 Merge "Fix SecurityException in Editor.onDrop" 2016-01-27 00:38:38 +00:00
Shishir Agrawal
05a7dfc48d Merge "Unhiding MSIM APIs." 2016-01-27 00:32:26 +00:00
Carlos Valdivia
3cdbc806ff Merge "Permissions: Get rid of GET_ACCOUNTS" 2016-01-27 00:12:06 +00:00
Rakesh Iyer
a7aa4d6f0b Allow smart unlock right after boot.
This change enables relaxing the constraint by which
strong authentication is needed after device reboot.

There are very limited use cases where this might be
safe, one of which is in a car. Cars head units usually
are protected physically by the car and have hardware
anti-theft mechanisms so we can potentially allow for
Android to allow users to use smart unlock to avoid the
lockscreen just after boot.

This change adds in a config flag that sets the default
trust flags, which can be set to allow smart unlock after
boot for car head units.

Bug: 26559008
Change-Id: Id6338a97b617ddaf3d2fae5d51235429a42b81cc
2016-01-26 15:57:29 -08:00
Shishir Agrawal
7ea3e8bf89 Unhiding MSIM APIs.
1. Unhide MSIM APIs in TelephonyManager that already have non-MSIM equivalent
   APIs public.
2. Make MSIM API naming consistent (overloaded, no suffix).
3. Unhide APIs in SubscriptionManager that are necessary for MSIM.

Bug: 26772894
Change-Id: Ibebab7379ea79c8e4812bbd190342827048e30e2
2016-01-26 13:47:27 -08:00
Julia Reynolds
92d456e9a6 Show app level settings when an app doesn't use topics.
Change-Id: I205062868ac3a44aa24a29bcb82a9374026287a7
2016-01-26 15:43:10 -05:00
Marie Janssen
554bc80056 Merge "IBluetooth: remove dump(), support arguments" 2016-01-26 20:14:58 +00:00
Nathan Harold
86d4372c41 Merge "Remove Data RealTime Info Listener Support" 2016-01-26 20:13:26 +00:00
Chris Wren
e9aa39470d Merge "change the default notification rules" 2016-01-26 20:00:58 +00:00
Marie Janssen
9db28ebea5 IBluetooth: remove dump(), support arguments
Because IBluetooth is a Binder service, we don't need dump() to
support dumpsys, just call the IBinder.dump().

Change-Id: Idcd48f758427b824e0b7eaafd091ba3fb2ff8993
(cherry picked from commit adbb3ff062e039b2552c6b5ded92e56346ac3934)
2016-01-26 20:00:11 +00:00
Chris Wren
cdee8cd16a change the default notification rules
should make devices less noisy by default
more metrics so we can tell exactly what we're doing.

Change-Id: I2504df91083074de8fe08c896e017335bc0bc1c7
2016-01-26 14:58:06 -05:00
Vladislav Kaznacheev
c14df8e73d Fix SecurityException in Editor.onDrop
When a content URI is dropped onto EditText, it tries making sense
of the contents, and in the process it accesses the content provider.
If this content provider requires a permission grant, SecurityException
occurs.

This fix does two things:
1. Editor.onDrop now requests DropPermissions and releases is
when it is done. This required the introduction of a new hidden method
DropPermissions.takeTransient, because the existing method required
access to an Activity instance.

2. If the drag originator neglected to allow the permission grant,
DropPermission request would not help, so a try/catch block
is added to Editor.onDrop to avoid breaking the recipient app.

Bug: 26694948
Change-Id: I714429a507e62c83a150d91fbcdee791bced3ad3
2016-01-26 11:53:00 -08:00
Adrian Roos
20d7df3c3f Crash dialog improvements, move crash code to AppErrors
Factors out the crash and ANR handling code into separate
class and allows clearing cache and restarting app from
crash dialog.

Bug: 22692162
Change-Id: I2a08a4255ea02ab3c7441d351bf278128fcf5a5d
2016-01-26 09:16:26 -08:00
Andrei Stingaceanu
4ccec532d7 Hide suspended apps from recents
* Introduce a new boolean realActivitySuspended in TaskRecord to
keep track of the suspended state (this also makes sure the
information is persisted across reboots).
* Introduce a new method onPackagesSuspendedChanged
in RecentTasks which flips the realActivitySuspended for each
TaskRecord for the desired user and packages sent
* Register a new broadcast receiver (for SUSPEND/UNSUSPEND)
in ActivityManager#finishBooting which calls
RecentTasks#markPackagesSuspendedStateForUser
* In ActivityManagerService#getRecentTasks filter out
Taskrecords for suspended apps by checking realActivitySuspended

Bug: 22776761
Change-Id: I52e3593ccb2dae223d1ea11d017a6b1626646639
2016-01-26 16:01:30 +00:00
Clara Bayarri
d1f722d906 Enable enrolling/authenticating a specific work profile.
This change adds support for a separate profile-specific
fingerprint database. This is to be used together with the work
challenge.

Change-Id: I65b3a74a1c887def210d7a6da0b907138f58a5ba
2016-01-26 11:37:48 +00:00
Jeremy Klein
15f3d21599 Implement ui-based provisioning for the new tether api.
This is dependent on ag/850648 and the Settings changes under the
uiprovisioning topic id.

BUG: 26247383
Change-Id: Ib151d56a1ece5ca3a55219abed965286eac5dd60
2016-01-25 20:02:48 -08:00
Jeremy Klein
0301cd9523 Merge "Expose a simple tethering API which includes provision checks." 2016-01-26 03:59:51 +00:00
Wei Liu
8ab7759567 Add a null check before reference networkInfo. am: b8eaf45e1d am: dca8f10031 am: a12d383117
am: 21e0927b47

* commit '21e0927b474a686d5827e059476291370c0b306e':
  Add a null check before reference networkInfo.
2016-01-26 03:16:28 +00:00
Wei Liu
21e0927b47 Add a null check before reference networkInfo. am: b8eaf45e1d am: dca8f10031
am: a12d383117

* commit 'a12d3831178616a171382f1546812c26245af2d0':
  Add a null check before reference networkInfo.
2016-01-26 03:06:09 +00:00
Wei Liu
a12d383117 Add a null check before reference networkInfo. am: b8eaf45e1d
am: dca8f10031

* commit 'dca8f10031f33c7c85577fa1abcc26d560c90388':
  Add a null check before reference networkInfo.
2016-01-26 01:57:31 +00:00
Wei Liu
dca8f10031 Add a null check before reference networkInfo.
am: b8eaf45e1d

* commit 'b8eaf45e1df007fc4f5a11bb58491abaef39cd57':
  Add a null check before reference networkInfo.
2016-01-26 01:52:12 +00:00
Jae Seo
9df90a5ab6 Merge "TIF: Recording API" 2016-01-26 01:39:05 +00:00
Jeremy Klein
36c7aa0325 Expose a simple tethering API which includes provision checks.
This CL exposes startTethering and stopTethering functions which also
encapsulate all provisioning check logic. Right now, only silent checks
are implemented, but UI checks will come in a follow-up CL. GTS tests
and Settings changes are under the same topic ID.

BUG: 26247383
Change-Id: I65f61d899594cb3f9035d8496366af17a57a090f
2016-01-25 16:37:09 -08:00
Jae Seo
a826d0172a TIF: Recording API
Bug: 23786643
Change-Id: Ie26e8944312048bc865b4506aa49fced15360fe4
2016-01-25 16:30:51 -08:00
Wale Ogunwale
cc25a8a24e Send notification we attempted to start an already running pinned acitvity
API will be used by Android TV sys-ui to decide what to do next with the
Pinned activity.

Bug: 26452296
Change-Id: I5411515d079468616422ba9e5093164a924cd6a2
2016-01-25 15:14:26 -08:00
Vladislav Kaznacheev
92b26c5bff Merge "Restore correct mouse pointer after drag and drop" 2016-01-25 22:09:38 +00:00
Dianne Hackborn
bfb94e21d3 Merge "Add and implement JobScheduler content observer APIs." 2016-01-25 20:34:41 +00:00
Sandra Kwan
1ebdb21753 Merge "AccountManager: add finishSessionAsUser api." 2016-01-25 18:40:51 +00:00
Wei Liu
b8eaf45e1d Add a null check before reference networkInfo.
b/26758858

Change-Id: If335ece223114dbfb6b08391f18a09467f377cf1
2016-01-25 10:34:27 -08:00
Wale Ogunwale
2ced3d531c Merge "Don't keep visible windows in pinned stack on screen when app dies" 2016-01-25 18:24:58 +00:00
Wale Ogunwale
3fd20fe8d8 Don't keep visible windows in pinned stack on screen when app dies
We previously introduced logic that keeps an apps visible windows on
screen when the app dies. This was to help with the situation where
freeform apps might be killed by the low memory killer and we want
to preserve the space on screen and relaunch the app when the user
interacts with the window again.
However, this doesn't work for windows in the pinned stack since
they an normally not focusable/interactable.
We no longer do this for windows in the pinned stack.

Bug: 24913379
Bug: 26609941
Change-Id: Ie2e7f7d7c7a8c0ef6c1662517f558c385201c433
2016-01-25 18:20:40 +00:00
Sandra Kwan
0b84b456a7 AccountManager: add finishSessionAsUser api.
Change-Id: I9a08d957a9b25be4c6cf12e4ed35cdc0bfbb8605
2016-01-25 10:09:20 -08:00
Rubin Xu
e6e907ea09 Merge "Show dialog when launching work apps is not possible." 2016-01-25 17:51:22 +00:00
Rubin Xu
795c458c89 Merge "Turn off profile by stopping the user." 2016-01-25 17:33:43 +00:00
Adrian Roos
4afbe99127 Merge "Improved trust error messaging (1/2)" 2016-01-25 17:20:11 +00:00
Rubin Xu
f13c980169 Turn off profile by stopping the user.
Bug: 22541941
Change-Id: I713ab9b87f3dd1b7bd6206af137562d20a44d76d
2016-01-25 16:29:29 +00:00
Adrian Roos
67a55fdb05 Merge "Prevent crash and ANR dialogs in VR mode" 2016-01-25 16:24:24 +00:00
Adrian Roos
c13723f22e Improved trust error messaging (1/2)
Tracks why trust agents are disabled and shows
a generic message on the keyguard. Dedicated strings
in follow-up.

Bug: 22704995
Change-Id: Ibb4fd9c9386c4dc12f0734004502b9a9cc6ded79
2016-01-25 08:04:42 -08:00
Carlos Valdivia
918c55a67c Permissions: Get rid of GET_ACCOUNTS
Bug: 21901286

Change-Id: Id2c42f4d449a32c88078d80dcf952d15e67d536c
2016-01-24 14:57:03 -08:00
Casey Burkhardt
86b867fd45 Adds Settings.System.FONT_SCALE observer to ActivityManagerService
Changes to Settings.System.FONT_SCALE were not being handled by any service,
which required a device reboot for any changes to take effect.  Changes to
this field by the Settings app worked as expected only because it is able to
poke ActivityManager with an updated configuration, whereas unbundled
applications cannot.

This also ensures the setting value is backed up and doesn't conflict with
a configured value from accessibility onboarding during restore.

Bug:23033258
Change-Id: I98d4aed2f9f5893d054e6b10c4dfda406de8eba2
2016-01-24 04:21:36 -08:00
Amith Yamasani
0af6fa7015 Voice Interaction from within an Activity
This allows an app to show a voice search button
and invoke a voice interaction session for use
within the activity. Once the activity exits, the
session is stopped.

Test application has a new activity that
demonstrates it with the test voice interaction
service.

This initial version is functional enough for
an integration test, with some more tests
and improvements to come later.

Bug: 22791070
Change-Id: Ib1e5bc8cae1fde40570c999b9cf4bb29efe4916d
2016-01-23 21:25:50 -08:00
Wale Ogunwale
b9dd234a6c Merge "Removed some left over log spam." 2016-01-24 02:16:18 +00:00
Wale Ogunwale
834c236c40 Removed some left over log spam.
Change-Id: Iaac41b7202b7634185bf522dfab36832c4830bba
2016-01-23 18:14:58 -08:00