Bug 3400770
TextUtils#commaEllipsize creates a MeasuredText "mt" object with the
text to be ellipsized. It calls setPara which initializes mt's mPos
member to be 0. It then calls addStyleRun which moves mPos to the end
of the string. The loop back in commaEllipsize then calls mt addStyleRun
again and this causes IndexOutOfBoundsException, because the paint
object is trying to measure text past the text's length.
It seems this was a typo and that the tempMt variable should be used,
because the code is trying to measure the format string...not the
the string to be ellipsized. This makes the saner parts of CTS test
for this method pass now.
Change-Id: Ib6aa6e4bbd6afff4c95ad4c4d51a384cc1389875
Some devices that use LiPo batteries do not charge them to 100%
as a safety margin and to preserve battery longevity. This change
allows KeyguardUpdateMonitor to determine when the battery state should be
reported as "Charged", provided the device sets BATTERY_STATUS_FULL in
that case.
Change-Id: Iac6cb78e24f9a696017459cc773c38ef7fe7779f
When the user is in a phone or VoIP call, the volume keys should
control the STREAM_VOICE_CALL volume. Before MODE_IN_COMMUNICATION
was introduced to cover VoIP use cases, having an active VoIP call
was determined by checking whether there was any track used the
output stream STREAM_VOICE_CALL, which can give false positives.
This CL checks instead against the audio mode to see if
MODE_IN_COMMUNICATION is selected to determine if a VoIP call
is in progress.
This implies that applications that play on STREAM_VOICE_CALL
shouldn't rely on that fact alone to expect the volume keys
to control the STREAM_VOICE_CALL volume, and should instead,
rely on the official mechanism for that:
android.app.Activity.setVolumeControlStream(int)
Change-Id: Ia487951ea1684477aa3d522c9031fad484d8a40d
(Previous behavior: the tap would pass through to the clock,
which would open the shade. Only sometimes it wouldn't,
because you'd have hit the left-hand-side of the ticker
where there's no clock underneath. So this fixes that too.)
Additionally, tapping the ticker will now immediately
dismiss the ticker.
Bug: 3365129
Change-Id: Ic641184c518b18d799a560c8da6b4c5844c912de
These trackers have two copies of the network type: newSS and newNetworkType. I think thats wrong,
but this was the smaller change on code that will hopefully be refactored soon.
On radio_off we were making a new, empty newSS but not clearing newNetworkType so it
still thought we were on 3G and when we reconnect and get 3G state changes new==old and we don't
send the update. In this fix I reset newNetworkType every time we apply it to networkType.
bug:3389886
Change-Id: I294f34259dc6c6f8f445bf2cb5466c8be747e25c
Or at least make it better. Now if we get a failure locking the surface,
we mark to do a full relayout pass later to try to get a new good surface.
Also fix some bugs in how activity manager was classifying processes for
their OOM adjustment to make better choices in what to kill.
Change-Id: I8e4aa86744211ba7693f9828291d8bbf2698274f
Also removed android:detachWallpaper="false" from lock_screen_exit
since it's not guaranteed to do something sane when windows aren't
owned by applications.
Change-Id: I28b5fc6b68d1aef93f092538d1318ce2b2a835ef
IOException on close() can be useful to indicate that in-progress transactions
were canceled.
I also audited all of our tech classes to make sure every function that needs
to throw IOException does so.
Change-Id: Iaa9c43d79d59ff85772d5c3e4b4d57a6fa8df4cf
Bug 3370191
The documented behavior is to hide the error when the text changes.
However, this should not be the case if the error was reset by a text watcher.
Comparing errorBefore and errorAfter as was done before is not sufficient in the
case where the error is reset to the same value. String pool optimization will re-use
the same Object and it will look like the error has not been modified (hence the
blinking behavior reported in the bug).
For this reason, TextView has a mErrorWasChanged flag. The fix is to export methods
that can use this flag as in done inside TextView when a physical keyboard is used.
These methods are hidden.
Change-Id: Ie3ec59a368f3b1588b81242890b971ac48e8ff7e
* commit 'e3ba5cfe9b4f524d955f77f5fff53440d80f9464':
Fix bug 3399725 - externally reported issue 14317: android:scrollbarSize attribute does not work in ScrollView tag
* commit 'd1f94e36da6276acc00d0a3267a505fd6a61702d':
Fix bug 3399725 - externally reported issue 14317: android:scrollbarSize attribute does not work in ScrollView tag