Move services/powermanager into frameworks/native so audioflinger can
use it. Note that this is not the same as a PowerManagerService,
which is part of systemserver and handles turning the screen on and
off, etc. This is just a binder interface to allow taking wakelocks.
Change-Id: I1142e6d9ddbb651cc19ac07d946fa24d8feed8a3
This never worked properly; now it does. We also no longer
do a redundant pair of remove/add operations when a package is
updated.
Bonus memory savings: we were keeping sets of ApplicationInfo
objects as part of the ongoing bookkeeping, but those were no longer
being used for anything other than the package names. That's been
tossed out now and only the name strings are now used; hooray for
memory savings!
Change-Id: I4c6e592a1680e28550bcb4f76789260ded22280d
Broadcast intents that get sent out when users are added/removed/switched.
More work on generating user-specific information in package manager queries.
APIs to update user name and query a user by id.
Removed Package.mSetStopped and mSetEnabled, since they're not user specific.
User removal:
- Cleanup ActivityManager, PackageManager, WallpaperManager, AppWidgetService
and AccountManager.
- Shutdown processes belonging to the user.
Don't show vibrate option in long-press power if there's no vibrator.
Lock the screen when switching users, to force unlocking.
Change-Id: Ib23a721cb75285eef5fd6ba8c7272462764038fa
Fix an issue with buffer lifecycle management which could cause audio
pops on timed outputs. There were two issues at work here.
1) During trim operations for the queued timed audio data, buffers
were being trimmed based on their starting PTS instead of when the
chunk of audio data actually ended. This means that if you have a
very large chunk of audio data (larger than the mixer lead time),
then a buffer at the head of the queue could be eligible to be
trimmed before its data had been completely mixed into the output
stream, even though the output stream was fully buffered and in no
danger of underflow.
2) The implementation of getNextBuffer and releaseBuffer for timed
audio tracks was not keeping anything like a reference to the data
that it handed out to the mixer. The original architecture here
seemed to be expecting a ring buffer design, but timed audio tracks
use a packet based design. Pieces of packets are handed out to the
mixer which then frequently will hold onto that chunk of data
across two mix operations, using the first part of the chunk to
finish a mix buffer and then using the end of the chunk for the
start of the next mix buffer. If the buffer that the mixer is
holding a piece of got trimmed before the start of the next mix
operation, it would return to its heap and could be filled with who
knows what by the time it actually got mixed. On debug builds,
they seem to get zero'ed out as they go back to the heap causing
obvious pops in presentation.
This change addresses both issues. Trim operations are now based on
ending presentation time for a chunk of audio, not the start. Also,
when the head of the queue is in flight to the mixer, it can no longer
be trimmed immediately, merely flagged for trim by the mixer when the
mixer finally does call releaseBuffer.
Signed-off-by: John Grossman <johngro@google.com>
Change-Id: Ia1ba08cb9dea35a698723ab2d9bcbf804f1682fe
The suspend optimizations handling in the driver is being removed.
The framework will hence forth control when these optimizations occur -
we do this at screen off and hold a short wakelock to ensure this.
We also remove the use of the now defunct setsuspendopt command and
handle the high perf locking with the new suspend mode command.
Change-Id: Ia12e38befb2c4f85cad6612bc8f807805bd0dae1
Remove the animation stepping from WindowState and move it into a new
class, WindowStateAnimator. Update all references to moved variables
in related files.
Change-Id: I7540d8f897b370c73975f3ffe450140861cb0cd1
In cases where a Surface does not go from hidden to shown, do not set
the perform layout flag. This keeps us out of repeated passes through
the layout code.
Fixes bug 6222487.
Change-Id: I22601bef5733d2f996a8cbdd50d6b89517bc3122
Previously, if using the "local" debugging transport:
adb shell bmgr wipe com.android.browser
adb shell bmgr wipe com.android.browser
... would bring down the runtime. This no longer happens. The fix
covers two aspects of the situation: 1. the local transport no longer
blows up in this use case, and 2. the backup manager itself now catches
blowups on the part of the transport, and tidies up after them.
Bug 6205185
Change-Id: Ieb9b8827a62523148ad5a0ec15b05a954d198b3d
commit 5e64321e broke the headset detection on stingray.
This is because the name passed with the UEvent upon headset insertion/removal is
different from the dev path (h2w). It actually indicates the type of headset connected.
The fix consists in using the dev path received with the UEvent to find the corresponding
entry in uEventInfo.
Change-Id: I8481cfa17a7af3c8f5d83fc87d0f7c0d2c981098
The member variable WindowAnimator.mPendingLayoutChanges was never
being reset to 0. Consequently once it was set it was causing endless
calls to the layout method.
Fixes bug 6208114, 6220403, 6219546.
Fixed NPE in RecentsPanelView.
Change-Id: Ie529b8f31e535543cb5ae0af9447146306b14eeb
Use it for recent tasks switching.
Not perfect yet by far, but something.
Also fix issue #6186758: Twitter crashes after tapping on a tweet on JRM75D
Change-Id: I49bf6c94aafde875ac652dedaf96d6c08cc9e7d2
In particular, if the low-level zip or crypto layers of the output
pipeline throw, the output becomes invalid at that point, but we
were not properly detecting this; we were missing the exception and
the runtime was going down. Now we catch any such fatal exception
and make sure to shut down the backup operation cleanly, leaving
the output at whatever point in its construction that it had
achieved.
Bug 6131870
Change-Id: If0fe0337857404b776f407a79d11dd88b8e60fd0
Fixes a crash that would occur if an app with a pending backup
pass in the pipeline was updated to remove its agent declaration
from the manifest (or other more esoteric ways that a backup
pass was expected to run for an app without their own agent).
Bug 5776591
Change-Id: I5a8bc8c12de6a2bfa82f5093fe3a15b754109ab1
When READ_EXTERNAL_STORAGE isn't enforced, grant its GID to all
launched processes. When changing enforcement, kill all processes
below foreground adjustment, causing them to be relaunched with
update GIDs.
Bug: 6131916
Change-Id: I6d83efc937919f13a1a7d9caac902e572869406a
Introduction of the class WindowAnimator which takes care of all
animations stepping and Surface operations.
Change-Id: I78f1c269fa57df0616c08adbe156e3059709ae48
* changes:
Merge commit '74803dc'
add config_bluetooth_default_profiles config var and use it to disable bt profiles
Do not allow Surface creation on machines without SurfaceFlinger We will fail later anyways, but this change makes it much easier to track down places where we are inadvertently doing operations that depend on the flinger.
fix setting only usb mode
Detect (at runtime) kernel support for the "hdmi_audio" switch.
Add a config resource to disable key-chord screenshotting
Do not assume that there is always a running activity (Necessary for headless devices)
Add batch volume adjust support to adjustMasterVolume() in AudioManager and AudioService.
If you cleared the last usb mode it would fail (and so would setting
it if you started with none). This fixes it to set and unset the
last property correctly.
Change-Id: Ice5be6e57b6ca6b8c9241b0ac62071a3bc72606a
A new switch was introduced in AndroidAtHome to deal with a race
condition between the WiredAccessoryObserver and the HW composer HAL.
When the new switch ("hdmi_audio") is present, we want to pay
attention to it instead of paying attention to the old switch
("hdmi"). This change checks at startup for the presence or absence
of the new switch and uses it if available, otherwise it falls back on
classic behavior.
see change ID I960cfc2f3e8df5342e7248a26fd313fdad2ca322 for the kernel
side changes.
see bug 6023647 for a discussion of the issue.
Change-Id: I009e443f25662e7beb233e892ca71034b05ebfc2
Signed-off-by: John Grossman <johngro@google.com>