9322 Commits

Author SHA1 Message Date
Craig Mautner
4323d6ea51 Merge "Do not hide animating window behind keyguard." into jb-dev 2012-06-13 15:27:51 -07:00
Craig Mautner
f8d05b4ea6 Merge "Update wallpaper visibility at time of hide/show." into jb-dev 2012-06-13 14:09:08 -07:00
Jeff Sharkey
963218905a Merge "Clear identity when snoozing limit." into jb-dev 2012-06-13 12:06:10 -07:00
Craig Mautner
507a2ee12b Update wallpaper visibility at time of hide/show.
Call the Window client method dispatchAppVisibility when hiding or
showing wallpaper rather than wait until the next call to
performLayoutAndPlaceSurfaces.

Fixes bug 6645473.

Change-Id: I363f69f8db0affff92308e11ce52546401959d8f
2012-06-13 08:39:38 -07:00
Jeff Sharkey
6c0b4f393a Clear identity when snoozing limit.
Continues to check MANAGE_NETWORK_POLICY permission.  This allows
SystemUI to invoke snoozeLimit() without CONNECTIVITY_INTERNAL.

Bug: 6653091
Change-Id: I464bf62b79f2647c6b6db151251a0036897d0cc0
2012-06-12 21:06:30 -07:00
Craig Mautner
2ec541fa4b Do not hide animating window behind keyguard.
The transition from clock to keyguard when restarting the device
was janky. The cause was that the clock app was animating away
which kept the adjustWallpaperWindowsLocked() method from setting
the keyguard as the new mWallpaperTarget. At the same time the
WindowAnimator saw that the keyguard was readyToDisplay() which
set mForceHiding true causing the clock to become hidden. Since
the clock was mWallpaperTarget the wallpaper was hidden at the
same time.

This fix does not allow mForceHiding to hide an animating
window.

Fixes bug 6649988.

Change-Id: Ie5cb0dfcc987d5ee1ad2351cf520629b8e301a2b
2012-06-12 19:18:21 -07:00
Craig Mautner
1c9581023c Merge "Set detached wallpaper on the scale up animation." into jb-dev 2012-06-12 19:04:01 -07:00
Jeff Sharkey
f6f7f1d2dc Low disk space string change, surface state.
Surface current low disk state through IPackageManager for use in
Settings app.

Bug: 6576409
Change-Id: I9ae9ce99a2faa3015a237036c03567d1ae11628f
2012-06-12 17:12:08 -07:00
Craig Mautner
a803371535 Set detached wallpaper on the scale up animation.
This keeps the background wallpaper from disappearing when expanding an
app that has a wallpaper background (e.g. clock).

Fixes bug 6649988. The second half of the bug, the first half will be
reissued as a new bug.

Change-Id: I209c9038469e4133586a927c92ef64ae43fb937f
2012-06-12 15:50:45 -07:00
Craig Mautner
4d6a0df379 Merge "Do not cancel animations when switching." into jb-dev 2012-06-12 15:45:37 -07:00
Christopher Tate
4cabbef826 Merge "Make sure to stop noHistory="true" activities properly" into jb-dev 2012-06-12 13:38:56 -07:00
Christopher Tate
5007ddded6 Make sure to stop noHistory="true" activities properly
The code was correctly inducing a 'finish' when such an activity was
being stopped, but then was not continuing with the rest of the stop
bookkeeping at that point.  In some circumstances this could result
in an inconsistent state, with the activity marked as finishing but
neither in the foreground nor stopped.

Bug 6585403

Change-Id: Ib5c5be885bc6534e099e040d87a8589f7b7454ce
2012-06-12 13:08:18 -07:00
Craig Mautner
9fec779587 Do not cancel animations when switching.
Was canceling ongoing animations when starting a new animation which
caused the window of the first animation to restart. This looked
janky. The original cancellation was put in to stop the incorrect
animation being selected when quickly switching between an incoming
app and the homescreen. Reversing the cancellation no longer exposes
the original problem it was put in to fix.

One way to duplicate what this is fixing.
1. Slow down animations to 10x.
2. Run ApiDemos/App/Alert Dialogs/List dialog
3. Tap outside the list dialog and then tap the home button.
Tapping outside the list dialog causes the list dialog to animate
away. Tapping the home button then causes the app to animate away.
Before this fix the list dialog would revert to full size before
the app animates away. With this fix the list dialog continues its
original animation as the app animates away.

Fixes bug 6600726.

Change-Id: I29c940254808a321c3b6c2e4f4b7c78a72b47899
2012-06-12 11:13:41 -07:00
Jeff Brown
265f1ccc51 Improve ANR diagnostics.
When an ANR occurs, log the associated reason.

When an event takes too long to process (currently more than 2 seconds)
log basic information about the event including how long it actually
took.

Dump the contents of the inbound, outbound and wait queues as part
of dumpsys input.

Bug: 6574842
Change-Id: I9ab754c320f609cb86fe266c469a61e7032dfed6
2012-06-11 18:05:31 -07:00
Craig Mautner
0fa77c1e0f Remove over aggressive optimization.
It turns out that sometimes the wallpaper target is migrated to the
bottom of the window stack and then mWallpaperTarget is set to null.
In particular this happens when the launcher all-apps screen is
brought up. When this happens the layer of the wallpaper is
correctly set below the previous wallpaper target.

An optimization in WindowAnimator was keeping the layer update from
propagating to the Surface object. This fix removes that optimization.

Fixes bug 6631717.

Change-Id: I800dd043ce8df83b4e5edbf710503135396bc01e
2012-06-11 16:30:48 -07:00
Craig Mautner
c38869abe5 Revert "Merge errors."
This reverts commit b0419a52008e57475ee254def1da20451da22d4c.
2012-06-11 16:30:48 -07:00
Craig Mautner
a5bbb8987b Merge errors.
Change-Id: I33d0b1aa5dc5018cc879d2e9878e4825adaa4074
2012-06-11 16:30:48 -07:00
Michael Jurka
64dbcd64be Merge "Tweak recents out animation a bit more" into jb-dev 2012-06-11 16:17:35 -07:00
Michael Jurka
c016aaaa42 Tweak recents out animation a bit more
Bug: 6490204

-Fading to black in the recents layer
-Tweaking duration and interpolators
-Removing some unnecessary debug exceptions (Bug: 6642072)

Change-Id: Iba18fade7f874078111fc1d79a81830ee07617d4
2012-06-11 15:23:20 -07:00
Dianne Hackborn
409d563b51 Merge "DO NOT MERGE: Cherry-pick 2ed524966d3c4bd04ea5f54026ed59558d73cd44 to JB." into jb-dev 2012-06-11 13:20:35 -07:00
Craig Mautner
47adf865bd Merge "Fix exposing wallpaper on rotations and other." into jb-dev 2012-06-11 13:10:01 -07:00
Vairavan Srinivasan
ac5f998396 DO NOT MERGE: Cherry-pick 2ed524966d3c4bd04ea5f54026ed59558d73cd44 to JB.
This was contributed from AOSP, a fix to the management of URI write
permissions.  This is a very blatant bug, and with the new Intent ClipData
and other stuff we are making much more use of write permissions in JB,
so it is well worth taking.

Change-Id: I58c86119b4d5c13fefd090944bea139803df1a48
2012-06-11 13:06:41 -07:00
Chia-chi Yeh
d667aebfb3 Merge "VPN: move VpnDialogs away from system uid." into jb-dev 2012-06-11 11:49:46 -07:00
Craig Mautner
b9836b9185 Fix exposing wallpaper on rotations and other.
1. Rotations do not go through standard closing of animations so the
wallpaper was not being hidden when the wallpaper target surface was
destroyed. This fix adds hiding the wallpaper when the wallpaper
target is destroyed.

2. The wallpaper target is nulled when switching from launcher home
screen to launcher all apps. In this case the wallpaper remains
visible but below visible layers. It should be hidden so that when
those layers adjust it is not exposed. (Separate fix for adjusting
wallpaper in this case will come).

Fixes bug 6629464.

Change-Id: I522f97dafc0cdcc0f933a825ec9a29d8f63590b5
2012-06-11 11:40:09 -07:00
Dianne Hackborn
a7e3a1e0e7 Merge "Include important native processes in watchdog stacks." into jb-dev 2012-06-11 10:37:51 -07:00
Svetoslav Ganov
b7726159e3 Merge "Crash in the touch explorer." into jb-dev 2012-06-10 09:59:24 -07:00
Dianne Hackborn
f72467ad98 Include important native processes in watchdog stacks.
Helps us track down deadlocks involving native service processes.

Bug: 6615693
Change-Id: I580047550772e29586195a8cf440141574e3f40c
2012-06-08 18:36:48 -07:00
Svetoslav Ganov
e45c0b230b Crash in the touch explorer.
1. The touch explorer was notified for accessibility events from
   a binder thread which was poking the internal state of the
   latter which by design is not tread safe. Since the touch
   explorer is expected to be running only on the main thread
   the accessibility manager service delivers the accessibility
   events to the explorer on that thread.

bug:6635496

Change-Id: Ifdc5329e4be8e485d7f77f0fb472184494fa0d15
2012-06-08 17:49:52 -07:00
Svetoslav Ganov
ee33ad24cd Settings crash after enabling TalkBack accessibility.
1. AccessibilityInput filter was not checking whether the touch
   explorer instance is not null before passing it an accessibility
   event. If the accessibility event is dispatched before the input
   filter is installed but after it is created we runt into this
   case.

2. Added a missing null check in accessibility node info.

bug:6635089

Change-Id: Ia389dc1f427427eb73794f6331ccb870e0b44c55
2012-06-08 16:09:36 -07:00
Craig Mautner
78fc35bde4 Merge "Hide wallpaper when wallpaper target gets hidden." into jb-dev 2012-06-08 13:14:54 -07:00
Chia-chi Yeh
dadc857d9d VPN: move VpnDialogs away from system uid.
Bug: 6632536
Change-Id: Iece647c077caf5298ccfe7d7aba5f0911a4ed0d1
2012-06-08 13:05:58 -07:00
Craig Mautner
ff92f04e76 Hide wallpaper when wallpaper target gets hidden.
Another location that potentially hides the wallpaper target while
leaving the wallpaper itself still visible. Causes the wallpaper to
show up when upper surfaces are transparent all the way down.

Fixes bug b6621986.

Change-Id: If75053160f041eb78868eda36b7820fb2110d069
2012-06-08 12:56:14 -07:00
Craig Mautner
7f786b8fa2 Merge "Do not animate keyboard and button brightness." into jb-dev 2012-06-08 12:48:19 -07:00
Craig Mautner
fab75dc830 Merge "Turn off dimming immediately for removed windows." into jb-dev 2012-06-08 11:36:36 -07:00
Dianne Hackborn
0876ab0ac1 Merge "Fix issue #6295373: "Package com.google.android.apps.authenticator2 has..." into jb-dev 2012-06-08 11:01:42 -07:00
Craig Mautner
236a35b77a Turn off dimming immediately for removed windows.
Dimming was only turning off immediately for app-animated windows.
For removed windows dimming wouldn't turn off until the window was
completely gone.

Fixes bug 6628057.

Change-Id: I3ba6501b10a31b6f8c91012e17ad8734a84050c4
2012-06-08 09:54:59 -07:00
Craig Mautner
291576ec6f Do not animate keyboard and button brightness.
Keyboard and button brightness are always set to assign values
immediately but were being passed through the animation process
anyways. This interfered with the state of the screen brightness
animation. Intercept keyboard and button brightness directives and
implement them immediately.

Also use actual screen brightness and value to determine when we
are dimming or brightening. Previously we were using the sensor
values to determine whether the action called for was to brighten or
dim. This looks at the actual screen brightness level to make that
determination. If the two values get out of sync it is better to rely
on the screen value than the sensor value.

Fixes bug 6626681.

Change-Id: I82158f5188ffb739e01f818ba88e79f03a405c58
2012-06-08 09:22:36 -07:00
Kenny Root
f27f2f8f71 Merge "Delete old forward-locked apps on upgrade" into jb-dev 2012-06-08 09:16:40 -07:00
Svetoslav Ganov
75fb3e7ac2 Merge "Cannot click on the last touch explored auto-completion item." into jb-dev 2012-06-07 19:52:19 -07:00
Dianne Hackborn
d0c5f515c0 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
2012-06-07 16:57:57 -07:00
Svetoslav Ganov
385d9f24b5 Cannot click on the last touch explored auto-completion item.
1. When typing into an auto completion edit field a list of completions pops up and if
   the user touch explores the list and tries to double tap to select the touched
   completion the latter is not selected.

   The auto completion is a popup that does not take input focus and is overlaid on
   top of the window that has input focus. The touch explorer was clicking on the
   location of the accessibility focus if the last touch explored location is within
   the bounds of the active window. In this case this was the window with the edit
   text into which the user is typing. The check performed by the touch explorer
   was missing the case when the last touch explored location was within the bounds
   of the active window but it actually was deloverd to another overlaid window.
   Now we are poking on the accessibility focus location if the last explored
   location is within the active window and was delivered to it.

bug:6629535

Change-Id: Ie66d5bb81ab021f2bb0414339b7de26d96826191
2012-06-07 16:35:11 -07:00
Kenny Root
87353093ef Merge "Measure ASECs for forward-locked apps" into jb-dev 2012-06-07 15:40:54 -07:00
Kenny Root
906272b977 Merge "Only call fixSdPermissions when appropriate" into jb-dev 2012-06-07 14:21:14 -07:00
Kenny Root
2afded11aa Measure ASECs for forward-locked apps
Forward-locked apps are mostly in ASEC containers now, so the
containers need to be measured as well.

Bug: 6606390
Change-Id: I69e9fe47aabe1e130568779a45fe8000b3ce9d4c
2012-06-07 13:23:10 -07:00
Kenny Root
c7a8999a52 Only call fixSdPermissions when appropriate
When media packages were loaded, they would lose their forward-locked
status since the flags covering it was not available when the
doPostInstall step was called.

Bug: 6611980
Change-Id: I807fcec6b61cedf7654808b704fba7de9c7c1922
2012-06-07 12:50:15 -07:00
Svetoslav Ganov
86783474fd Cannot interact with dialogs when IME is up and on not touch explored popups.
1. If the last touch explored location is within the active window we
   used to click on exact location if it is within the accessibility
   focus otherwise in the accessibility focus center. If the last touch
   explored location is not within the active window we used to just
   click there. This breaks in the case were one has touch explored
   at a given place in the current window and now a dialog opens *not*
   covering the touch explored location. If one uses swipes to move
   accessibility focus i.e. to traverse the dialog without touching
   it one cannot activate anything because the touch explorer is using
   the last touch explored location that is outside of the active
   window e.g the dialog.

   The solution is to clear the last touch explored location when a
   window opens or accessibility focus moves. If the last touch
   explored location is null we are clicking in the accessibility
   focus location.

bug:6620911

2. There is a bug in the window manager that does not notify a
   window that its location has changed (bug:6623031). This breaks
   accessibility interaction with dialogs that have input because
   when the IME is up the dialog is moved but not notified. Now
   the accessibility layer gets incorrect location for the
   accessibility focus and the window bounds.

   The soluion is when the accessibility manager service calls
   into the remove thress to obtain some accessibility node infos
   it passes the window left and top which it gets from the
   window manager. These values are used to update the attach info
   window left and top so all accessibility node infos emitted
   from that window had correct bounds in screen coordinates.

bug:6620796

Change-Id: I18914f2095c55cfc826acf5277bd94b776bda0c8
2012-06-07 12:02:16 -07:00
Kenny Root
84e35eadfb Delete old forward-locked apps on upgrade
The old style forward-locked apps were in a directory called
/data/app-private but the new style forward-locked apps are in ASEC
containers. This made the upgrade path confused and it wouldn't
correctly generate the InstallArgs to delete the old file.

Bug: 6619438
Change-Id: If4323fa8701d9fc653998f5db58670b4124b9e87
2012-06-06 16:06:21 -07:00
Craig Mautner
a9144ffd64 Merge "Disable automatic screen dimming." into jb-dev 2012-06-06 15:24:36 -07:00
Craig Mautner
a4e96d5a6e Disable automatic screen dimming.
Done by setting the dimming period to Integer.MAX_VALUE. While it
doesn't technically disable dimming it will take 248 days to get to
any target value.

Fixes bug 6616423.

Change-Id: I5b753286b9d93664fbff79021be38adf4d8a007d
2012-06-06 14:49:44 -07:00
Craig Mautner
3793368f72 Set screen brightness to match sensor at power on.
Use the first sensor value received after screen on to set the screen
brightness. Do this setting immediately rather than animate to the
target brightness.

Fixes bug 6612418.

Change-Id: I6c24c55e0bd35ef58a6494d3b5e449954241fd00
2012-06-06 14:13:39 -07:00