35402 Commits

Author SHA1 Message Date
Jorim Jaggi
3b6e05a2a8 Revert "Death to synchronous transactions (2/2)"
This reverts commit dd05f0365aa0df9ba9a7631c8e02ed67f472132d.

There seems to be some logic that gets triggered inside surface flinger
regarding commit time of the transaction, and without it seems that
animations got jankier. No time to investigate...

Bug: 28305789
Change-Id: I7261cf8719d3528f8f5bee19e507b8ba88b8b729
2016-04-21 14:55:31 -07:00
Jorim Jaggi
a20eeda529 Fix a few weird state issues from race-conditions
- When starting another transition while the dock transition
is already set, always override that because that transition
starts prolonged animations which will never be ended.
- Only dock if we get a good UP event.

Bug: 28257206
Change-Id: Icabfcf475f419696d2bcff8fbb53cf3b29dedd69
2016-04-21 14:55:11 -07:00
Jorim Jaggi
023da538a2 Fix lifecycle bug in when calling positionTask
Sometimes the resumed activity from another stack gets positioned
BELOW the top activity of the current stack. We need to carry over
the mResumedActivity to make sure onPause is called on the moved
activity.

Bug: 28235047
Change-Id: I09e6b032cd8d0b00dc5fdd06bec68e53c25aae73
2016-04-21 14:54:51 -07:00
Jorim Jaggi
4ccfc30a80 Animation fixes when task is not resumed
- Make sure to add the activity to mWaitingVisibleActivities
to not destroy the activity before the app transition has
started.
- Defer layouts in startActivityUnchecked so when clearing the
current activities in the current stack, we don't execute the
app transition yet. We need to wait until the new activities
are added as well.

Bug: 28026847
Change-Id: I252cf139e06197ea34329d1466f1f6162f3e7a30
2016-04-21 14:54:17 -07:00
Jorim Jaggi
b8c5876dc0 Keep stack from mReuseTask
When we launch an activity with CLEAR_TOP and NEW_TASK, we clear
all the activities in that task but then we don't reuse the stack,
which can lead to weirdness.

To fix this, we need to keep the target stack in that case.

Bug: 28000613
Change-Id: If85ade73b1036e8a7c0eda418d9f39e8596b8b16
2016-04-21 14:53:52 -07:00
Jorim Jaggi
5c80c41ee0 Final fixes for growing recents transition
- Make sure to reposition windows during animations to avoid that
they lag one frame behind.
- Don't put windows that are gone for layout into resizing mode.
- Don't layout windows that are gone for layout, to avoid resizing
the surface but the client won't draw anymore.

Change-Id: I809feffef00f9a086b44504126e03f509eb7f190
Fixes: 27855229
2016-04-21 14:52:42 -07:00
Chong Zhang
289395b1fe Merge "Fix dead surface/window left on screen" into nyc-dev 2016-04-21 17:58:52 +00:00
Yohei Yukawa
d67a1ca49b Merge "Accept null subtype in InputMethodSubtypeHandle." into nyc-dev 2016-04-21 17:11:55 +00:00
Tony Mak
d3589ee715 Merge "Fix wrong app is launched after solving challenge from tapping notification" into nyc-dev 2016-04-21 15:51:14 +00:00
Tony Mak
646fe9913e Fix wrong app is launched after solving challenge from tapping notification
PendingIntent.FLAG_ONE_SHOT is needed to prevent the PendingIntent being
reused.

Also, flag and activity option of credential intent in BaseStatusBar
is not same as the one in ActivityStarter. Added a new
function startConfirmDeviceCredentialIntent in AM to centralize it.

Change-Id: I2d9e5923ad5d4d012f10057c409c666c8ca299a3
Fix: 28309964
2016-04-21 16:43:08 +01:00
Julia Reynolds
54a6394cf9 Merge "Accept the calendar name in addition to the owner as a calendar filter." into nyc-dev 2016-04-21 15:36:31 +00:00
Julia Reynolds
7c9350a940 Always reevaluate rules when a new service is added.
Otherwise the condition providers may never get an
onSubscribe call and may not turn on at the right time.

Bug: 26981870
Change-Id: Ia622597f10cc26f7c34ece1748013655543f488f
2016-04-21 10:38:32 -04:00
Julia Reynolds
d82e981cf3 Don't call into audiomanager holding a zen lock.
Bug: 27642196
Change-Id: Ib510f2ddf966f36b3670290a4f3f695bf6b7810e
2016-04-21 10:38:32 -04:00
Clara Bayarri
bcedd6b74f Merge "Fix silent errors when launching Keyboard Shortcuts from Settings" into nyc-dev 2016-04-21 14:28:58 +00:00
Paul Jensen
3f45105353 Merge "Cap number of NetworkRequests a UID can make to 100" into nyc-dev 2016-04-21 13:47:13 +00:00
Clara Bayarri
c043ebee4b Fix silent errors when launching Keyboard Shortcuts from Settings
The following error was thrown, given that Activity is generating a
protected broadcast:
Sending non-protected broadcast
android.intent.action.SHOW_KEYBOARD_SHORTCUTS from system

Bug: 28138503
Change-Id: I50d5212d7776d33ffe6e9df1c5f080205ac4a29d
2016-04-21 11:55:01 +01:00
TreeHugger Robot
b99d6af3ab Merge "Expand NetworkMonitor metrics" into nyc-dev 2016-04-21 05:24:40 +00:00
Hugo Benichi
7261fb27de Merge "Some fixes in ConnectivityService event logging" into nyc-dev 2016-04-21 04:02:55 +00:00
Erik Kline
a488c23dd5 Expand NetworkMonitor metrics
- add netid to CaptivePortalStateChangeEvent
    - add NetworkMonitorEvent for simple duration measurements

Bug: 28204408
Change-Id: I62035e07d64013878a0bce30c67c929c2c7e7a85
2016-04-21 13:02:55 +09:00
Hugo Benichi
75f0346167 Merge "Various fixes in IpReachability event logging" into nyc-dev 2016-04-21 03:54:18 +00:00
Hugo Benichi
5f16f760ad Some fixes in ConnectivityService event logging
Bug: 28204408
Change-Id: I44ed9539bb213a845c2bcc2861c947af7c3c9ef4
2016-04-21 11:03:08 +09:00
Phil Weaver
4b88bddb12 Merge "Fix a11y key event handling from multiple devices." into nyc-dev 2016-04-21 01:38:49 +00:00
Chong Zhang
3cc58ddd3c Fix dead surface/window left on screen
If the surface is explicitly hidden while we're changing resizing mode,
we need to discard the preserved surface immediately, otherwise it could
linger around on screen.

Do not mark mAnimatingExit in setTokenVisibilityLocked. This flag can only
be set after client relayouts to invisible. There we set mAnimatingExit and
mAnimating, so that when animation finishes the surface is marked to be
destroyed. If we marke it too early (and not mark mAnimating at the same
time), the surface may get stuck in exiting state.

bug: 28236574
Change-Id: I5cc916dfa698113e1d783a66547e1878469a9879
2016-04-20 18:01:10 -07:00
TreeHugger Robot
4d07c88919 Merge "Exclude IME dialogs from tap outside task bounds funcationality" into nyc-dev 2016-04-21 00:54:33 +00:00
TreeHugger Robot
2be4c463bc Merge "Throw better exception when startVoiceActivity fails" into nyc-dev 2016-04-21 00:46:32 +00:00
Tim Murray
150553756f Merge "Increase the max binder thread pool size for system_server." into nyc-dev 2016-04-21 00:32:47 +00:00
Hugo Benichi
25bf8f5d56 Various fixes in IpReachability event logging
- fold IpReachabilityMonitor* classes into a single IpReachabilityEvent.
- only log an event for NUD_FAILED Netlink answers.
- distinguish between NUD_FAILED with or without lost of provisioning.
- do not record host ip addresses.
- record interface name instead of interface index when losing
  provisioning.

- also return an error code when probeNeighbor fails, and log this error
  code in IpReachability events.

Bug: 28204408
Change-Id: I5f0def0ab1ace7e467a0c69b3b82d07ef2252307
2016-04-21 09:18:50 +09:00
TreeHugger Robot
1fa356289e Merge "Disallow changing stacks if top activity" into nyc-dev 2016-04-21 00:11:50 +00:00
Rob Carr
abadeba99a Merge "Prevent recents from closing while moving PiP to fullscreen." into nyc-dev 2016-04-21 00:00:09 +00:00
Yohei Yukawa
46ac35d09b Accept null subtype in InputMethodSubtypeHandle.
There are two types of IMEs:
 A. IMEs that have one or more subtypes
 B. IMEs that have no subtype

The initial implementation to update hardware keyboard layout per
subtype change of layout (See Bug 25752812) has supported IMEs in the
category A only, and IMEs in the category B are just ignored in both
system and Settings app.

In order to support IMEs in the category B, InputMethodSubtypeHandle and
related methods need to accept null InputMethodSubtype. Technically
this is a straightforward change, because in InputMethodManagerService
we have already used InputMethodUtils.NOT_A_SUBTYPE_ID for those IMEs in
the category B.  We also need to update Setting App, which will be done
by a different CL [1].

  [1]: I46b9c5b018f08e3eaa4614a0893db0be91652f3c

Bug: 28182650
Change-Id: Ia013784a594ad3beaf30976d047f5ac0fa8185be
2016-04-20 16:59:45 -07:00
TreeHugger Robot
6c0ead993e Merge "Removing disk access from startActivity thread" into nyc-dev 2016-04-20 23:58:03 +00:00
Wale Ogunwale
1f19261527 Exclude IME dialogs from tap outside task bounds funcationality
We don't want tapping on these windows to cause a change in app
focus.

Bug: 28184155
Change-Id: Ibd4ca15b2154c2e83a11f4a2a3edb4356cbfbfed
2016-04-20 16:33:36 -07:00
Jorim Jaggi
4ad9856eb8 Disallow changing stacks if top activity
When we attach an activity to an existing
task, and that task is already on top,
disallow changing stacks altogether even
if launch stack id is set.

Bug: 28026847
Change-Id: Ie70f0585a29dc1b85a5093624fede32110be3c76
2016-04-20 22:39:12 +00:00
Suprabh Shukla
dc4b80dde4 Removing disk access from startActivity thread
Code was checking whether the directory for recent_images existed in
many places unnecessarily causing StrictMode violations. Moved the
code to only attempt to check and create the directory before
actually writing to disk.

Bug: b/28195831
Change-Id: I05f77a10f1dafc8cc0b1836b62352d56549ac1ee
2016-04-20 15:27:42 -07:00
Lifu Tang
a381455472 Merge "Added defensive code to prevent system crash" into nyc-dev 2016-04-20 22:19:19 +00:00
Lifu Tang
e1b51715bd Merge "Fixed bug in upgrading GpsMeasurement" into nyc-dev 2016-04-20 22:19:05 +00:00
Chris Tate
665189f926 Merge "Don't back up wallpapers that we've been told not to" into nyc-dev 2016-04-20 22:10:40 +00:00
Rob Carr
5a6c58e002 Merge "Do not prematurely update position while bounds animating." into nyc-dev 2016-04-20 21:37:12 +00:00
Christopher Tate
d7faf53605 Don't back up wallpapers that we've been told not to
In addition, now that the full uncropped wallpaper image is being
backed up, we now handle that via the full-data backup path instead
of key/value.  Restore still knows about legacy data that gets
delivered via the older key/value mechanism.

This change also has the effect of removing the size limitations
around wallpaper restore acceptance.  Any size source imagery is
valid, as crop & scale are rerun in a device-appropriate way
after the restore.

Bug 25453848
Bug 25727875

Change-Id: Idc64a2eaab97a8ecc9d2b8ca5dc011f29cab324d
2016-04-20 14:34:07 -07:00
Jim Miller
54c4374b4a Merge "Fix bug where fingerprint for wrong userId was attempted to be removed." into nyc-dev 2016-04-20 21:33:15 +00:00
Fyodor Kupolov
366a457b6d Merge "Test coverage for new FBE functionality" into nyc-dev 2016-04-20 21:13:41 +00:00
Ruchi Kandoi
0fea8ad447 Merge "Revert "PowerManager: Adds the Sustained performance API."" into nyc-dev 2016-04-20 20:59:20 +00:00
Chong Zhang
3966fb942c Merge "Fix IME adjust when stack focus changes while IME is visible" into nyc-dev 2016-04-20 20:52:08 +00:00
Ruchi Kandoi
9c36c02f0e Revert "PowerManager: Adds the Sustained performance API."
This reverts commit 0abc001275d6cf0af4990f521ccff7346a7cd2bf.

Bug: 28150358
Change-Id: I99c71b3d6641310a33e898d6fd475d37c79ba9d0
Signed-off-by: Ruchi Kandoi <kandoiruchi@google.com>
2016-04-20 20:49:18 +00:00
Ruchi Kandoi
a645c9753f Merge "window: Adds a Sustained Performance Mode window flag." into nyc-dev 2016-04-20 20:35:21 +00:00
Jim Miller
8f2aca0ee4 Fix bug where fingerprint for wrong userId was attempted to be removed.
- cleaned up private API to ensure userId is distinct from groupId.
- fixed bug where we were sending the wrong userId when attempting to
- fix warning about wrong fingerId when receiving final id of 0.

Fixes bug 28268635

Change-Id: I9507723c1a763152775f2feff76c16762f23cf2d
2016-04-20 13:34:11 -07:00
Phil Weaver
698c96dbd2 Fix a11y key event handling from multiple devices.
For M, we ignored device type entirely, but with ag/760625 we started
paying attention to it, which rejects events when keys from different
devices are pressed simultaneously. Since the volume keys show up as
different devices, the new behavior disrupted the event stream when
both volume keys were pressed.

Now tracking each device separately, which restores the old behavior
but still takes the device id into account. Holding down two keys
when enabling an accessibility service, however, always has and still
can produce an invalid event stream. It doesn't seem worth the
overhead, however, to track each key separately.

Bug: 28091773
Change-Id: I8d30de1f5e05f779b6fe305856d42f209ff8b038
2016-04-20 13:08:35 -07:00
Robert Carr
744e6e3aef Prevent recents from closing while moving PiP to fullscreen.
If we close recents when beginning the animation, we will
trigger a resume of the previous fullscreen app, which will
attempt to aniamte in at the same time we are animating
the PiP to fullscreen. These conflict causing flicker and
churn.

Bug: 27793381
Change-Id: I520181dadab938bbf62b25891f5ba0e4e9783967
2016-04-20 12:56:56 -07:00
Ruben Brunk
6ada702993 Merge "Add settings for altering VR display behavior." into nyc-dev 2016-04-20 19:51:51 +00:00
Lifu Tang
8b7ad976bf Added defensive code to prevent system crash
Bug: 26940611
Change-Id: I8226d1acb42ccc7d2cd910e30b47c7c63c9f490b
2016-04-20 12:21:23 -07:00