232468 Commits

Author SHA1 Message Date
Jorim Jaggi
e66edb1056 Do not update Record.visible if not setting visibility
In resumeTopActivityInnerLocked we only update the visibility
if not already visible, to avoid a black flicker. However, in the
interaction when docking a task from recents, makeVisible was
called but the conditions weren't met to make it actually visible,
but Record.visible was still set, leading that we didn't call
WM.setAppVisibility in resumeTopActivityInnerLocked

Bug: 27041808
Change-Id: I400470a5b31881542fedd3edb6a97e524666a8a3
2016-02-08 21:22:47 +00:00
Jorim Jaggi
e161f08e98 Multi-window optimizations #3
- Make sure divider is pushing frames only if necessary
- When starting recents while docking, make sure no unnecessary
animations are played to reduce system load.

Change-Id: I536f009aef7282ed85dde79b853aeae62644f3e3
2016-02-08 21:21:24 +00:00
Jorim Jaggi
c3fb3143a2 Multi-window optimizations #2
- Do not relaunch activities in stacks that are not visible during
resize.

Change-Id: Ia6bd17882c17db045450a466ba5347ce53e9b837
2016-02-08 21:20:37 +00:00
Jorim Jaggi
69abc194f3 Multi-window optimizations #1
- When the window doesn't have a surface, do not add it to
mResizingWindows, so we don't report unnecessary resizes
- computeDragResizing => false when window is not visible, so we
never enter resizing mode even if the window decides to relayout
in the background

Change-Id: I8e6cdef86f1579d128973d4f2f12e87bf9b65524
2016-02-08 21:19:22 +00:00
Jorim Jaggi
0a13bfdefc Fix disappearing translucent status bar background
When relaunching an activity while preserving the window, the content
view was put on top of the status bar background, making it disappear
in case of translucent status bar backgrounds.

Change-Id: I1edff29c10616bf5386e982d7336327135f0f7a0
2016-02-08 21:18:37 +00:00
Geoff Mendal
e074f31c0d Merge "Import translations. DO NOT MERGE" into nyc-dev 2016-02-08 21:14:32 +00:00
Geoff Mendal
ca0c6a2061 Import translations. DO NOT MERGE
Change-Id: I477868c67814a6bd353474266dbff375d3b26b4c
Auto-generated-cl: translation import
2016-02-08 13:10:39 -08:00
Robert Carr
e12aece4ca Ensure surfaces stay alive until activity stop.
Prior to this commit in this case of activity pause, with finishing=true
the activity manager will notify us of app visibility and we will begin
an exit animation. When this exit animation finishes, we will destroy
the application surface (unless its eligible for saving). However there
are two cases where this breaks down:

1. The exit animation finishes before the activity thread handles
the stop transition. Many activities stop rendering on Pause
but many do not and it is totally legal to do so. Sometimes this
results in non fatal dequeue buffer errors and sometimes results in
fatal errors with Pixel Buffers, etc...
2. We may resume the activity shortly after asking the window manager
to pause it. If the window wasn't eligible for animation, we will
immediately destroy it after being told of the visibility change
following PAUSE_FINISHING. It's possible for this to complete
before we process the resume. On the other hand the client
happilly processes the resume and transitions back from PAUSE
and then crashes once it attempts to use it's surface.

In this commit we have the activity manager notify the window manager
when an application has actually finished (or we have timed out
waiting). For windows which have not been explicitly removed by the
client, we defer destruction until we have received both this signal
and the animation has completed.

Bug: 26793431
Change-Id: Ib6ee8fbdd1f03450fbbfd62468a19e97774befab
2016-02-08 20:46:53 +00:00
Felipe Leme
b1a65ee161 Changed list metered-networks so it returns all networks.
Prior to this change it was relying on NMPS.getNetworkPolicies(), which
would not return networks that never had any policy attribute (like
metered) set.

This change fix this problem by also querying the WifiManager for the
list of saved wi-fi networks. In fact, the new logic is very similar to
what's done on SettingLib's NetworkPolicyEditor.

BUG: 26685616
Change-Id: I42f37de3a7367718036f45b15c6b5d37b67e7d01
2016-02-08 12:39:44 -08:00
George Mount
5affef0773 Fix Fade transition interrupt.
Bug 26963113

When a Fade transition is interrupted and reversed, the
View started the animation from the beginning. This change
captures the previous transitionAlpha and starts the animation
from the previous alpha state.

Change-Id: I801fe9ade6af4cf8446838e231bdc71841668a18
(cherry picked from commit 3cf9fa3db0231d035142c27992818d8f7827ac3e)
2016-02-08 20:33:49 +00:00
Steven Ng
76bcfb2e66 Whitelist camera permission for SetupWizard
+ Camera permission is required for QR provisioning in SetupWizard.

Bug: 26932941
Change-Id: I1573cdd3b8ac708f457a9c7efbbf02c3c8ce6d8d
(cherry picked from commit 950b2dee6648a90bd2e9fedecde137f41f7c4513)
2016-02-08 20:26:04 +00:00
Jeff Sharkey
95728a5db6 Merge "Move graphics and JIT caches to DE storage." into nyc-dev 2016-02-08 19:47:20 +00:00
Shawn Willden
8d8c747774 Add attestation API to Android KeyStore.
Bug: 22914603
Change-Id: I7c6162dc7a390aa48a2542494780959b01c23bd4
2016-02-08 19:29:54 +00:00
Geoff Mendal
d1bbdeb86e Merge "Import translations. DO NOT MERGE" into nyc-dev 2016-02-08 19:25:33 +00:00
Jean-Michel Trivi
f82f746903 Support for Bundle in AudioAttributes
Bug 25449464

Change-Id: I99cdfd4589e3161b52620e439ba993ce21d256b4
2016-02-08 19:24:19 +00:00
Jeff Sharkey
e84bdd38ad Move graphics and JIT caches to DE storage.
We confirmed with the graphics and JIT teams that no sensitive
user data is written to these caches, so they're safe to point at DE
storage.

Since we don't have control over what is written by the app, we need
to keep the cache environment variable pointing at CE storage.

Fix ensurePrivateDirExists() to always return a path, instead of
returning null which can cause scary bugs.

Change packages.list to no longer canonicalize data paths, since
these fail when CE storage is still locked.

Bug: 27069522
Change-Id: Ifff64a036fa4aa1e61aa0dd98486bc711fbf8f4a
2016-02-08 12:24:05 -07:00
Geoff Mendal
c2a4bddc05 Import translations. DO NOT MERGE
Change-Id: I14edb5a78192ca001f700de6dcc57c1c55b528fc
Auto-generated-cl: translation import
2016-02-08 11:22:17 -08:00
Adam Powell
44ba79e47d Permit setRetainInstance(true) on nested fragments, framework edition
Save arbitrarily nested fragments across config changes as
nonconfiguration objects. This permits the use of retain-instance
child fragments as arbitrary opaque dependencies within other
fragments.

Change-Id: Ia6640b76cfcf7ec28ba252628957a0c14863e957
(cherry picked from commit 7466be66263d5ebffb786ea402d9ed6e36c254f0)
2016-02-08 19:10:44 +00:00
Brad Ebinger
ec0d33490a Update TelecomManager docs regarding PhoneAccounts
Updates the docs for addNewIncomingCall to mention that if the
PhoneAccountHandle representing a PhoneAccount is not registered or not
enabled, a SecurityException will be thrown (as of b/26864502). Also
notifies the user that PhoneAccounts are stored in DE storage
in registerPhoneAccount.

Bug: 26874536
Bug: 26780305
Change-Id: I2dae932cfa3404d7d5060dad840a75227793603e
2016-02-08 19:07:08 +00:00
Adam Powell
8585ed66b9 FragmentTransaction.commitNow, framework edition
Offer commitNow and commitNowAllowingStateLoss methods on Fragment for
use by encapsulated components using fragments as implementation
details. This can help prevent unexpected ordering side effects at the
app level when a call to a library method wants to commit and
immediately initialize a fragment as an implementation detail.

Note that this change still does not permit reentrant FragmentManager
operations. It is still an error to add/remove/change fragments in the
same FragmentManager while a fragment transaction is being executed.

Have the commonly used ViewPager adapters use commitNow instead of
executePendingTransactions.

Change-Id: Ia37a871234a287423063f0c2c3e4c93d69116cad
(cherry picked from commit f6b30662f87f7339d0d3946dcf71e930c2fead9b)
2016-02-08 19:00:52 +00:00
Adam Powell
2af189a0a7 Preserve compatibility for ViewGroup#showContextMenuForChild
Have the new showContextMenuForChild(View, float, float) call through
to the old showContextMenuForChild(View) before recursing up to its
parent. This ensures that existing apps with custom views that
override the old method still get called as expected if they implement
custom behavior.

Unlike some other similar circumstances we aren't implementing this to
be bidirectional as the new behavior doesn't need to be triggered by
invoking the old. If the older method is invoked explicitly we will
still show old-style dialog context menus instead of the newer popup
style since we won't have a good place to visually anchor a popup.

Bug 26919262

Change-Id: Ie09f922d322b5a24789c7867820c4bc43824c385
(cherry picked from commit 759a4c54004af6ac9f42c9c42496a5eb73c461ff)
2016-02-08 18:59:28 +00:00
Philip P. Moltmann
199cb4dfe5 Merge "Clarify synchronization between PrintActivity and RemotePrintDocument" into nyc-dev 2016-02-08 18:41:55 +00:00
Tao Bao
43cd1bcb10 Add system APIs for A/B update.
Add android.os.UpdateEngine and UpdateEngineCallback classes that
communicate with the update engine via binder APIs for A/B update.

Bug: 26695366
Change-Id: I2471858d28df5443bc0b56d9a20281ccebde4484
2016-02-08 10:38:35 -08:00
Jae Seo
abda420b9d TIF: Update the internal input list with new TvInputInfo
Bug: 26864151, Bug: 26863281
Change-Id: I33e357aac74bceda50c794eb6057c363de9250b8
(cherry picked from commit 89a9937927e05a86938aa297a79047ce1a7c7d2d)
2016-02-08 18:19:41 +00:00
Felipe Leme
ed330c7f7d Merge "Replaced 'touch' by 'tap'." into nyc-dev 2016-02-08 18:10:18 +00:00
Geoff Mendal
83f7ae9628 Merge "Import translations. DO NOT MERGE" into nyc-dev 2016-02-08 18:09:21 +00:00
Geoff Mendal
773a356e97 Import translations. DO NOT MERGE
Change-Id: I5c2b346ce87737f9e8077f014d52e0e908a43418
Auto-generated-cl: translation import
2016-02-08 23:24:37 +05:30
Geoff Mendal
0d005fee78 Merge "Import translations. DO NOT MERGE" into nyc-dev 2016-02-08 17:49:22 +00:00
Felipe Leme
8067aed5c7 Replaced 'touch' by 'tap'.
BUG: 26884266
Change-Id: Ic3d7be8a10b768101b161644e46c92cd872621db
2016-02-08 09:42:52 -08:00
Felipe Leme
e86b63bd17 Add pid on main bugreport notifications.
Showing the pid is useful in many cases, like when one bug report is finished
and another one is in progress.

BUG: 26906985
Change-Id: Ib8ae462c85246b99234f8dac63edb608d1eafeb0
2016-02-08 09:40:56 -08:00
Philip P. Moltmann
cc3fa0d295 Clarify synchronization between PrintActivity and RemotePrintDocument
The general theme of these changes is to always delay any action until
the printDocument finishes a command. This is done:
- Before callinng for into a different activity to select a name for the
  PDF
- Before finishing

The second theme is to fix the canceling behavior of
RemotePrintDocument.AsyncCommand.

There are four bugs fixed in this review:

(1)
When the RemotePrintDocument.AsyncCommand is canceled it goes into the
"canceling" state. When it is canceled again it should stay in this
state. Before it went to "canceled" but the command was still running.
(see AsyncCommand#cancel()).

(2)
When finishing the PrintActivity in PrintActivity.doFinish() we cancel
the RemotePrintDocument. If there is a command still in progress (i.e.
isUpdating()) and it finished as canceled we used to call doFinish()
again and then try to double-clean up which lead to exceptions.

The new behavior is that is the PrintActivity is calling doFinish()
while a command is still in progress (i.e. isUpdating()) we delay the
cleanup until the command finishes. The command might finish as
canceled, completed or failed. Hence we have to call doFinish() in the
callbacks for all three cases.

(3)
When canceling there might have still been a nextCommand ready, hence
canceling does not stop execution of the RemotePrintDocument which could
lead to running commands while finshing.

(4)
When getting the location to store the PDF at a command might still be
in progress. This lead to half executed commands and caused issues once
we try to continue after the select-location-activity returns

Bug: 24713704
Bug: 24973884
Change-Id: Ied90fe8dc9bd6ea7f8b3e4ce4f922e477015568d
2016-02-08 17:29:26 +00:00
Geoff Mendal
b727d99a5e Import translations. DO NOT MERGE
Change-Id: Ic6f472559385699038b2d8f5e63d2ed0d5752c4d
Auto-generated-cl: translation import
2016-02-08 22:52:34 +05:30
Geoff Mendal
f872232b45 Merge "Import translations. DO NOT MERGE" into nyc-dev 2016-02-08 16:46:58 +00:00
Geoff Mendal
5f346b6123 Import translations. DO NOT MERGE
Change-Id: I2fd0cda2b14b49646e59253e874cef28e84a5c2f
Auto-generated-cl: translation import
2016-02-08 22:16:31 +05:30
Geoff Mendal
1e2c97f9bc Merge "Import translations. DO NOT MERGE" into nyc-dev 2016-02-08 16:37:32 +00:00
Geoff Mendal
52e62e55a8 Import translations. DO NOT MERGE
Change-Id: I4bf4fefbe2f02647922208fafaa23f70c2fe965a
Auto-generated-cl: translation import
2016-02-08 17:32:25 +01:00
Geoff Mendal
839aa9db82 Import translations. DO NOT MERGE
Change-Id: I70b1edaa1374eb469b691b3dc599f92d94762638
Auto-generated-cl: translation import
2016-02-08 21:58:20 +05:30
Julia Reynolds
ae0f0da91b Merge "Update DND visual interruption choices." into nyc-dev 2016-02-08 16:10:23 +00:00
Paul Crowley
faeb3eb0ba Password security for FBE disk encryption keys
Add the means to protect FBE keys with a combination of an auth token
from Gatekeeper, and a hash of the password. Both of these must be
passed to unlock_user_key. Keys are created unprotected, and
change_user_key changes the way they are protected.

Bug: 22950892
Change-Id: Ie13bc6f82059ce941b0e664a5b60355e52b45f30
2016-02-08 15:58:29 +00:00
Geoff Mendal
d65d343481 Merge "Import translations. DO NOT MERGE" into nyc-dev 2016-02-08 15:54:22 +00:00
Geoff Mendal
4f4b41911d Import translations. DO NOT MERGE
Change-Id: Ibace3035d3275c1fdbb39cd3769844dfaef35d00
Auto-generated-cl: translation import
2016-02-08 10:52:49 -05:00
Julia Reynolds
d560729ce3 Update DND visual interruption choices.
Change-Id: I7050264839c566dcef1dd01d155dda694a8d1ec0
2016-02-08 15:20:02 +00:00
Jason Monk
c3f42c1024 Add support for auto-adding tiles
hotspot, color inversion, data saver, and work profiles should add
themselves when they first become applicable.

Also refactor the availability flow a little bit.

Change-Id: Iaed89059540a98fefd4d26ce69edc0dde987b992
2016-02-08 15:17:11 +00:00
Jason Monk
cafda1f90e Settings drawer work
- Final visuals
 - Show under status bar
 - Fix activity flow surrounding drawer use

Change-Id: I161702219c26cabc6b2d1adbaa6fbfb1d9fd5b07
2016-02-08 15:12:25 +00:00
Nicolas Prévot
e64f3da729 Merge "Fail if setProfileEnabled is called outside a managed profile." into nyc-dev 2016-02-08 14:08:20 +00:00
Nicolas Prevot
e28e5a9d3b Fail if setProfileEnabled is called outside a managed profile.
BUG:26709495
Change-Id: I98adf2dab1e7b27fef926144c460af8823fe96e7
2016-02-08 14:03:39 +00:00
Geoff Mendal
ac534a6c82 Import translations. DO NOT MERGE
Change-Id: I7356ebc23a9842b6594df301f204d79dfcd97bca
Auto-generated-cl: translation import
2016-02-08 09:02:38 -05:00
Martijn Coenen
6f4a2ce5a5 Fix dumpsys meminfo -c output.
Also, this is supposed to be a "machine-parseable" format,
but it's not versioned at all. Added a version field so we
can change the format in the future if desired.

Change-Id: I6aa8ea46e030def04dc10634d01557a044545a9b
2016-02-08 12:04:38 +00:00
Paul Jensen
0ab80e6c26 Fix FrameworksServicesTests.apk to include libc++.so
am: 5f3dec374f

* commit '5f3dec374fac97365ec95ec407a1cffc2c3907c9':
  Fix FrameworksServicesTests.apk to include libc++.so
2016-02-08 11:41:25 +00:00
Paul Jensen
5f3dec374f Fix FrameworksServicesTests.apk to include libc++.so
libc++.so is no longer accessible to the app, so it must be
bundled in the app. This should get ApfTest passing again.

Change-Id: Ide004cb84f7f50feffb8f5acb46b7001dcffd208
2016-02-07 21:58:09 -05:00