Since applications can have Account providers, they need to be delayed
until after PackageManagerService says everything is mounted.
Otherwise the accounts associated with that provider will be removed
immediately when startup happens.
Bug: 6820670
Change-Id: Iba81765260421649f706624d0605a40ebc1347b1
The Settings.Secure value locationPackagePrefixBlacklist and
locationPackagePrefixWhitelist contains comma seperated package-name
prefixes.
Location & geo-fence updates are silently dropped if the receiving
package name has a prefix on the blacklist. Status updates are
not affected. All other API's work as before.
A content observer is used so run-time updates to the blacklist
apply immediately. There is both a blacklist and a whitelist.
The blacklist applies first, and then exemptions are allowed
from the whitelist. In other words, if your package name prefix
matches both the black AND white list, then it is allowed.
Change-Id: I4ea2ad56fa6bd75d32151bc250ac25c26a5777c4
Previous to this change the forceHiding variable was a boolean. This
change recognizes the different configurations of the keyguard by
defining separate states for forceHiding and testing for window
visibility differently in each state.
Fixes bug 6786114.
Change-Id: I3460c45ea6da772a4ff76bb016de7aa4b051a673
The flag indicating that the Starting window is displayed was not
being cleared when the Starting window was removed. That caused the
goodToGo indication to falsely indicate that all windows were drawn
when in fact the destination activity had not yet been drawn. This
caused the animation to begin when it was still black behind the old
animation.
This fixes bug 6764727.
Change-Id: Iacef73b0335b9bde2cdc8d0b072034222cd728e8
Only force hide windows when the keyguard is animating in.
Fixes bug 6721572.
Change-Id: Iad7b8b811bcf0840726cbf6c6f279dabd08a3aba
Conflicts:
services/java/com/android/server/wm/WindowAnimator.java
The package manager calls to clear data / clear cache were not also
having default container service clear the data on external storage. Now
they do.
Change-Id: Ib5e5eb6adf2cac5a4cc094cc1a02ac8cfb6a2edf
- There was a long-standing bug when using FLAG_ACTIVITY_REORDER_TO_FRONT
where we could find and use an activity that is currently finishing.
- There was a recently introduced bug where activities being destroyed
would not be removed from the history stack at the time they are done
being destroyed, allowing the above bug to be exposed.
- Removing a task would not kill any processes associated with the app
that had a different name from the app itself.
Change-Id: I4401ab6d348a69e1ac4fb8f719d2c69d5a78e567
...turns itself immediately back on.
The ON_AFTER_RELEASE flag is documented to not turn the screen on if
it is currently off.
Unfortunately, it didn't seem to actually do this -- it would just
cause a userActivity() call, which turns on the screen if it is
currently off.
Fix this by adding yet another boolean to that function to tell it
to not poke user activity if the screen is off. (Yes the number of
booleans on it is now insane, and should be cleaned up after we
get through JB.)
Bug: 6730064
Change-Id: I850dfbc777c7668d08b7d63f42a293e22b878256
Reduce the amount of unnecessary information emitted from
the DevicePolicyManagerService.
Bug: 6732364
Change-Id: I639f6beab8471bdbe41ce6cd3a5a378acaf678b2
When adding an system app via OTA, trying to remove it from mPackages
directly doesn't work. The ContentProviders and other things aren't
removed and point to the hidden system app's applicationInfo instead of
the updated app.
Bug: 6685263
Change-Id: I487cf518e0e3c60fae736e9b974617023a7dee8d
FLAG_ACTIVITY_CLOSE_SYSTEM_DIALOGS was a mistake.
Instead, and the infrastructure for the status bar to take care
of closing and hiding things itself when you press these buttons,
just like it does for the main Intent of the notification.
Bug: 6717667
Change-Id: I1b22186e0cedc05f46a1a3ec78053a72afaf61b1
Make sure that all cases where we remove an activity from the history
stack, we call resumeTopActivityLocked() to cause the home activity
to be launched if the stack is now empty.
Also fixed a problem where some timeouts would not be removed when destroying
an activity, and a race condition in boot that would cause the
PhoneWindowManager to initially start out with the home key not working.
Bug: 6381224
Change-Id: If046bb01aed624b0d9ee3bbaaba68ed6b98fd1d0
When launching only core apps, the wallpaper service
is not started. Without this change the WM waits
up to 30 seconds for the wallpaper window to be created even
though it will never happen. This introduces a significant
delay before the boot animation is dismissed so the user can
enter a decryption password.
Bug: 6263070
Change-Id: Ia975127a0bf09cf99818f7cc4fd6c0264b740ec6
The Starting window was being made visible early because the app
token had the dummy animation set. When the real animation started
the Starting window picked it up and became transparent causing
the underlying window to become visible again => jank.
Fixes bug 6691421.
Change-Id: I95fe88d2887760e6da3adedeb6be300eb6755283
In the course of the window manager refactoring into a separate
layout state, we introduced a bad interaction between the two
sides of the world. This resulting in multiple hops needed between
the two sides after an application has said it is finished drawing
its window, until the window/app transition is actually started.
Especially since these hops require going through the anim side
which is vsynced (so will delay its operation until the next frame),
this could introduce a notable delay until the window is first shown.
Fix this by re-arranging the code to make one straight path from
when a window reports it is shown to us starting the app transition
that is waiting for it. This change also includes various improvements
to debugging code that was done while working on it.
Change-Id: I7883674052da1a58df89cd1d9b8d754843cdd3db
Three problems fixed:
1. When one Activity took over for another Activity not all of the
starting window state was being copied over. Now copying over more
parameters.
2. When the visibility of an Activity was being changed the dummy
animation was overwriting the existing animation. If that animation
was the starting window animating then it started over when the
dummy animation was assigned. Now the dummy animation no longer
replaces an existing starting window animation.
3. The test for whether to animate away the starting window only
looked to see if the Activity had already drawn a window but did
not include the starting window. This caused the starting window
to immediately be hidden when the Activity was removed if no
windows were drawn, thereby exposing the fading window behind.
Now the starting window is included in the hasAppShownWindows test
and is animated away if it is exposed.
Fixes bug 6691421.
Change-Id: I4d32a1546c201652574a44d9e7f2752f1f1eb5a6
This normally shouldn't noramlly happen, but it can in the case of
bug 6647334 (crash in LoadedApk.makeApplication) where the package
manager information becomes inconsistent, and it could also happen
if an app was uninstalled or started updating at just the right
time during a launch.
Bug: 6647334
Change-Id: Iba22efe1d646cdac46099b2135466309577dfa54
...lock screen does not response to onNewIntent()
We now keep activities stopped even while the lock screen is
displayed. (We used to keep them stopped while the screen was
off, and then resume the top activity when the screen was turned
on even though they are covered by the lock screen.)
When a new intent is being delivered to an application, if it
is not resumed it is held in a pending list until the next
time the activity is resumed. Unfortunately that means for
the case where the activity is being held stopped due to the
screen off or lock screen, it will not receive any new intents,
even though it is at the top of the stack.
Fix this by adding an additional condition that allows the new
intent to be delivered immediately if the activity manager is
sleeping and the target activity is at the top of the stack.
Also some debug output improvements, since pending new intents
were not being included in the debug output, making it impossible
to see we were in that situation.
Change-Id: I5df82ac21657f1c82e05fd8bf21474e883f44e6f
...or settings from lock screen
When a window is drawn, the code to determine whether it should now
be shown was calling WindowState.isReadyForDisplay(). Part of the
condition of this function is that it is not ready if a policy is
forcing the window to be hidden -- which is the case when the lock
screen is shown. As a result, we wouldn't show the window at that
point, so wouldn't tell the activity manager that the token's windows
are visibible, and wouldn't tell the lock screen to go away.
This adds a new variation WindowState.isReadyForDisplayIgnoringKeyguard(),
which is the same as the original method but ignores the policy visibility
for app windows. This allows windows to be go through the complete
path of handling when the window is finally drawn and telling the
activity manager about it, even if behind the lock screen. By making it
a separate function, we don't impact any other code that is calling the
old function and may be relying on its behavior.
Also cleaned up a little of the dumpsys output. Most important, the
new ANR section is now moved to the top, since we want
"adb shell dumpsys window" to still give a nice summary of what we
normally care about -- the window stack and important global state.
Change-Id: Ica3ea85ce46f3f5f5cd2cc30fbd9de13d3885a57
This fix adjusts the sensitivity of the gesture recognizer by
eliminating gesture rotation in the recognition process.
Bug:6697119
Change-Id: Ic767f513c05210b27e583338c4f0adcaa1c4c625
Was counting on moving the app to the top to clear the flag
indicating that the app was being sent to the bottom. Since this
did not always happen the sendingToBottom flag was occasionally
left set. In this case the focus was skipped for that app and
consequently input was never propagated to it.
This fix clears the sendingToBottom flag each time the app
animations are completed.
Fixes bug 6691421.
Change-Id: I6f851dc5bedca95182db8490d87c876a71ad5fde
NetworkPolicy currently uses a single background thread to process
various broadcasts. When processing other broadcasts, this thread
can block our handling of SCREEN_ON/OFF, which are sent as ordered
broadcasts.
This change moves SCREEN_ON/OFF handling to the main thread, and
dispatches a one-way message to the background thread, allowing the
ordered broadcast to always proceed.
Bug: 6677047
Change-Id: I52de2c7b75beb8059bb87e123689ba4a9c4ae349
This fix forces the path through the updateLightsLocked method to turn
the screen on immediately if mWaitingForFirstLightSensor is true. Also
do not clear mWaitingForFirstLightSensor if mPreparingForScreenOn
is true. Wait until it turns false.
Fixes bug 6612418.
Change-Id: I03407e748cce4906a73de1f15df1654649b133c4
...for a smoother OOB experience
Way provided.
Put your defaults in system/etc/preferred-apps/*.xml.
Figure out what to put there with "adb shell dumpsys package preferred-xml".
Bug: 6680894
Change-Id: Ia06bb0061876274a5f80bf06d1ba5ad155edc323