It takes some time when Locale is actually switched by the system,
which looks "system halt". Previous implementation doesn't allow
developers to cope with the situation and they just had to let
users wait for a moment.
This change allows the LocalePicker users (developers) to hook
the item change and delay the actual halt. If they don't want it,
calling updateLocale() immediately works fine.
Related
- I29685118467bd2a68b80abcf234f91098839be0b
- Iba7378e51e6d5318e901045ebeda63ea954a0647
Change-Id: I4062a70e11600d87e889b40d30796387c7069e21
This fixes a problem where applications could ask the location
manager to do very heavy-weight things (like... say... update
location every minute), which would get accounted against the
system instead of the application because ultimately it is the
system making the heavy calls (wake locks, etc).
To solve this, we introduce a new class WorkSource representing
the source of some work. Wake locks and Wifi locks allow you
to set the source to use (but only if you are system code and thus
can get the permission to do so), which is what will be reported
to the battery stats until the actual caller.
For the initial implementation, the location manager keeps track
of all clients requesting periodic updates, and tells its providers
about them as a WorkSource param when setting their min update time.
The network location provider uses this to set the source on the
wake and wifi locks it acquires, when doing work because of the
update period.
This should also be used elsewhere, such as in the GPS provider,
but this is a good start.
Change-Id: I2b6ffafad9e90ecf15d7c502e2db675fd52ae3cf
Merge commit 'fb8116f736f2df6d1b2f8044541390a9fd9953cb'
* commit 'fb8116f736f2df6d1b2f8044541390a9fd9953cb':
Fix PointerLocationView when pointer ids are not zero-based.
Merge commit 'c891d2b3529b9cf24ef4781a585cd4784815e711' into gingerbread-plus-aosp
* commit 'c891d2b3529b9cf24ef4781a585cd4784815e711':
Fix PointerLocationView when pointer ids are not zero-based.
Since we support using driver-provided pointer ids (ABS_MT_TRACKING_ID)
there is no guarantee that pointer ids will necessarily start from 0
or be contiguous.
Change-Id: I9609b7a3bb238d7edbcbd68cc839dd6d14baf9df
It took a little bit of refactoring to move the authoritative state
about whether the lights are on or not into the StatusBarManagerService,
so that if the system ui process crashes, the bar comes up in the
right mode.
Change-Id: I95cfaf8f78ca4443ded5262272ea755d44dc5d17
Moves the remoteNativeLibrariesLI call to NativeLibraryHelper to prepare
for being able to symlink the /data/data/<package>/lib dir to the ASEC
container.
Change-Id: Ie3648509c6b6293a8d9bdd815610ab408df5047f
Merge commit '506d724cc356a7ba73995ef2929c65062277c83d' into gingerbread-plus-aosp
* commit '506d724cc356a7ba73995ef2929c65062277c83d':
DO NOT MERGE. I like'd ctate's change so much I'm doin it myself!
Merge commit 'a4ce31f5e080eae6c97e6f37040db0c7f0fc78f2' into gingerbread-plus-aosp
* commit 'a4ce31f5e080eae6c97e6f37040db0c7f0fc78f2':
Small fixes to battery stats.
The number of timers to allocate time shares to is calculated by
disregarding system-UID execution. However, the actual allocation
of time *was* considering system-UID locks as well. This wound up
trying to share time across more timers than had been counted in the
first pass, leading to divide-by-zero exceptions.
This patch changes the logic to account the time slice only to
non-system-UID entities, in keeping with the commentary.
Change-Id: I7384a3c269aea44e52bc983927f9417e11613ad5
Merge commit '9bfb060ac4e30c82ec2c269b78cc758a6cb5daf8' into gingerbread-plus-aosp
* commit '9bfb060ac4e30c82ec2c269b78cc758a6cb5daf8':
Force wallpaper surface to 565.
This is to maintain backward compatibility with badly programmed
GL wallpapers. Wallpapers can call SurfaceHolder.setFormat() to
request a different format.
Change-Id: Ib42b0cf6c7040d1300cad239c3acfd5c4c6cd326
Merge commit '5fdacb8a2818136218afdea4308ad1b10049a201'
* commit '5fdacb8a2818136218afdea4308ad1b10049a201':
People holding partial wake locks now get blamed for CPU usage.
Merge commit 'ee455f5a9572bc0d23c3328f6c22da91dc109a50' into gingerbread-plus-aosp
* commit 'ee455f5a9572bc0d23c3328f6c22da91dc109a50':
People holding partial wake locks now get blamed for CPU usage.
For the duration of the wake lock, 50% of all CPU usage is now
accounted against the app(s) holding partial wake locks, evenly
distributed between them. This is only while the device is on
battery and screen off.
Change-Id: I3e5c978b792b6ef17bf8540705bfe8343dadd464
Summary:
- libcore: new Java based SamplingProfiler
- dalvik: remove old SamplingProfiler native bits
- frameworks/base: New placeholder SamplingProfilerIntegration
- vendor/google: remove old profiler snapshot parsing code
Details:
libcore
A new 100% Java SamplingProfiler. While it has more overhead that
the old native one, the new one can actually collect more than the
current PC and frame pointer, so you can get useful context of
where your app is spending time. It currently provides ASCII hprof
format output for use with tools like PerfAnal
dalvik/src/main/java/dalvik/system/SamplingProfiler.java
Unit test for the new SamplingProfiler
dalvik/src/test/java/dalvik/system/SamplingProfilerTest.java
Add core-tests-dalvik
JavaLibrary.mk
dalvik
Removing native code that supported the old SamplingProfiler
vm/Dvm.mk
vm/native/InternalNative.c
vm/native/dalvik_system_SamplingProfiler.c
frameworks/base
Placeholder SamplingProfilerIntegration. Later plans include
generating EventStackTrace protobufs.
New SamplingProfiler does not have a global instance, so
SamplingProfilerIntegration provides one in INSTANCE. Old binary
snapshot format is temporily replaced with ASCII hprof data.
core/java/com/android/internal/os/SamplingProfilerIntegration.java
Simplified interface for zygote profile snapshotting
core/java/com/android/internal/os/ZygoteInit.java
Current SamplingProfilerIntegration does not track event loop
explicitly, but hprof information does include thread information.
core/java/android/app/ActivityThread.java
vendor/google
Removing code for parsing old SamplingProfiler snapshot format
tools/samplingprofiler/Android.mk
tools/samplingprofiler/NOTICE
tools/samplingprofiler/profiler.iml
tools/samplingprofiler/profiler.ipr
tools/samplingprofiler/pull-snapshots.sh
tools/samplingprofiler/sorttable.js
tools/samplingprofiler/src/com/android/profiler/PrintHtml.java
LocalePicker is in Settings, but we want this in framework
so that we are able to use it from other Setting-like
applications.
Also brings two string-arrays for descripting Chinise locales, which
have been in Settings app.
See also I1364c4810a115958662ca5d6e6e7f29c0c9b2569, for example.
Change-Id: I8a398b9b77601cf88ea8a3840b92dcf7441e6103
Finished the input device capability API.
Added a mechanism for calibrating touch devices to obtain more
accurate information about the touch contact area.
Improved pointer location to show new coordinates and capabilities.
Optimized pointer location display and formatting to avoid allocating large
numbers of temporary objects. The GC churn was causing the application to
stutter very badly when more than a couple of fingers were down).
Added more diagnostics.
Change-Id: Ie25380278ed6f16c5b04cd9df848015850383498