Previously, if an app threw an uncaught exception in an input,
vsync or native activity callback, it would log the exception then
continue limping merrily along. In the case of input, it
could result in an ANR occurring because we had not drained
all of the pending input events and marked them as finished
(we only marked the most recent one finished).
Bug: 6304124
Change-Id: I87d76f7fd605e1a8af1237c66d8d62973080277e
Two types of USB audio devices are defined:
- USB audio device: the audio device in USB device mode while
the Android device is in USB host mode.
- USB audio accessory: the audio device in USB host mode while
the Android device is in USB device mode.
Renamed intents for analog and digital docks to avoid confusion:
- ACTION_USB_ANLG_HEADSET_PLUG to ACTION_ANALOG_AUDIO_DOCK_PLUG
- ACTION_USB_DGTL_HEADSET_PLUG to ACTION_DIGITAL_AUDIO_DOCK_PLUG
Factorized code in AudioService broadcast receiver.
Change-Id: I1b6d0257a9d68ecb9495c78c98bac8c67fec7891
An odd alignment of the stars can end up with all of mAppToken.allDrawn
animating and mAppToken.startingDisplayed all false, and animation not
null. In such a case we can continue returning false but still pass
the test in WindowAnimator.updateWindowsAndRotation setting
wasAnimating to true. The combination continually sets the
FINISH_LAYOUT_REDO_WALLPAPER bit in mPendingLayoutChanges.
Fixes bug 6304838.
Change-Id: Ie7a7b39ea218213f51dc3df3eefe4ff03f1d885d
The purpose of the input device descriptor is to make it possible
to associate persistent settings for each input device, such as the
keyboard layout.
The descriptor is a hash of the information we have about the
device, such as its vendor id, product id, unique id, name,
or location.
Bug: 6110399
Change-Id: Idb80f946819b3f0dbf4e661bb0a753dbc2b60981
Wakelock usage for the purpose of sending an alarm broadcast is now
attributed to the application which posted the alarm, not to the OS.
Bug 5911317
Change-Id: I8cb79c3bd5db467388716ab68285f4ab0bfe468b
Stop animate() from using the mWindows maintained by
WindowManagerService. Animating WindowStateAnimators are now drawn from
a HashSet maintained by WindowAnimator and containing just those
WindowStateAnimators that have Surfaces.
When starting a move animation do not place parameters directly into
the WindowStateAnimator, instead pass them through the Handler.
Also removed synchronization points from mWindows/mAppTokens
add/remove.
Users outside system_server now explicitly communicate their
lifecycle, which keeps a strong-reference chain to any fully loaded
NetworkStatsCollection histories.
Bug: 6236498
Change-Id: I8e22739b6e89a626b676967a736d7117fd000778
In this change, only the USB audio accessory support is implemented.
Change-Id: Id9b411319b07a96dc56649ca74cc5f3f89a55a7c
Signed-off-by: Mike Lockwood <lockwood@google.com>
Simplified input injection API down to just one call.
Removed all input state reading API. It was only used by the
window manager policy and required a permission that applications
could not obtain. READ_INPUT_STATE is now unused and deprecated.
Change-Id: I41278141586ddee9468cae0fb59ff0dced6cbc00
Dimming was constantly being turned off if it wasn't time to turn it
on. This caused endless reentry into the Window Manager and consumed
lots of CPU.
Fixes bug 6293953.
Change-Id: Id87e60c7c70e96e66ce0b6297442f5ac0d2ff477
Add networkId field to NetworkIdentity to identify Wi-Fi networks by
SSID. Add support for policies without usage cycles.
Only apply mobile policies when SIM state is ready, which is cleaner
than just checking for airplane mode. Also avoids creating no-op
default policies when subscriberId is null.
Bug: 3001465, 3291052
Change-Id: I1f8aaa49a5db306df022c402ea7f3f5d4bc0cfc7
Extracted the input system from the window manager service into
a new input manager service. This will make it easier to
offer new input-related features to applications.
Cleaned up the input manager service JNI layer somewhat to get rid
of all of the unnecessary checks for whether the input manager
had been initialized. Simplified the callback layer as well.
Change-Id: I3175d01307aed1420780d3c093d2694b41edf66e
Move all lockscreen related settings to LockSettingsService.
LockPatternUtils uses this through IPC instead of Secure settings.
Migrate old settings to new database managed by LockSettingsService.
Passwords and patterns are stored in a new per-user location, except
for the primary user, for backward compatibility.
KeyguardViewMediator and LockPatternKeyguardView listen for changes
to user and updates the lockscreen.
Settings provider will look for Lock settings in the LockSettings
service now for the entries that used to be stored in Settings.
Change-Id: I956cd5b95e2d9d45a6401af7e270e6a5aa2dcc98
A previous check in changed the collection we were pulling exiting
AppWindowTokens from. Instead of pulling them from mExitingAppTokens
they came from mAppTokens and hence were not animated away.
Fixes bug 6296433.
Change-Id: I23347085658fce5412abb8ea119ce7e6152cab8b
Promote navigation helpers from the support library to the core
platform.
The support library's meta-data element has been replaced with a
first-class parentActivityName attribute. This attribute is valid
on both activity and activity-alias elements. An activity-alias
will inherit the target activity's parentActivityName if one is
not explicitly specified.
Automatic Up navigation for Activities
Add the public method onNavigateUp() to Activity. The default
implementation will use the metadata supplied in the manifest about an
activity's hierarchical parent (parentActivityName) to do the right
thing.
If any activities in the parent chain require special Intent
arguments, the Activity subclass should override onNavigateUp() to
properly implement Up navigation for the app, supplying such arguments
as needed.
If automatic Up navigation within the same task can't find an activity
matching the supplied intent in the current task stack, it will act as
an in-app "home" and return to the root activity (presumably the app's
front page) in that task. (From this state, pressing "back" with
default behavior will return to the launcher.)
Change-Id: If163e27e59587f7af36975a09c986cb117ec3bc6
To boost accurary and enhance capability of cell location api,
two new APIs, TelephonyManager.getAllCellInfo() and
TelephonyManager.listen(LISTEN_CELL_INFO), are added. Two new
Class, CellInfo and CellIdentity, are created.
This API change returns all information of one cell locaiton
at the same time. It also provides additional LTE and timestamp information.
Change-Id: I4d0f813107e625ec4ac88c8d980ffd171aa5fc30
The status bar and navigation bar are two completely separate
elements, with their own semantics. The system bar now classifies
itself as a navigation bar, since that is really how it behaves.
This required rewriting the HDMI resizing code, so that it is
all done by PhoneWindowManager since that is what is responsible
for the size of the navigation bar (and thus now system bar). This
actually gets rid of a fair amount of code, and means we can also
do the same thing for a pure navigation bar.
Likewise the system bar now has the navigation bar ability to be
hidden when requested by system UI flags. To get the behavior
we want on Xoom, we only allow the nav bar to be hidden when it
will help provide a better aspect ratio for showing widescreen
videos.
Finally the nav/system bar now animates when hidden and shown.
Change-Id: Ie927154b68376a0b61802f99171ff56b8da92e7a
- Isolate DimAnimator animation from the layout side.
- Isolate mWallpaperForceHidingChanged and mOrientationChangeComplete
from the animation side.
- Eliminate a redundant setting of mOrientationChangeComplete to true.
It was already true at that point.
- Synchronize changes to mWindows and mAppTokens on mAnimator. This is
a nop until we go to multiple threads.
- Synchronize AppWindowToken.freezingScreen on mAnimator.
- Modification to repeat layout debugging including temporary enabling
of spew on layout repeats.
Change-Id: Ic8d82b1c197144aaf6957caa5f71e175288220f2
Replace four booleans (mDrawPending, mCommitDrawPending, mReadyToShow
and mHasDrawn) with a single int that can take on the four states.
Move mLastHidden from WindowState to WindowStateAnimator.
Change-Id: Ieff319dfa19123bf5a6cdc98e9ab28fd432b8153