HTML parsing of search suggestions is still a major
CPU hog in the search dialog. This change first
checks if the text contains any HTML markup
(by looking for < and &) before bothering to
treat it as HTML.
Before, SuggestionsAdapter parsed every HTML formatted
string three times, to support state-dependent colors
in <font> tags. Now that there is support in Html
for color resources (added in
https://android-git.corp.google.com/g/7441),
we can get rid of this code.
Also, SuggestionsAdapter had a special purpose view
for drawing background colors when suggestion items
were not selected or pressed. This change replaces that
code with a StateListDrawable of ColorDrawables.
Before this change, HTML parsing used ~17% (uncontrolled benchmark,
just did some random searching) of the system_process CPU.
This change should reduce that by 2/3, i.e. about ~11% total
system_process reduction.
This change adds checking that the searchdialog is initialized
properly to a few key event listeners where it was missing
before.
Also makes sure that the search dialog is not shown if the
global search is requested but the global search provider
cannot be found.
Should fix http://b/issue?id=1982128
"Device rebooting after search results"
where SearchDialog.onKeyDown() threw an NPE
Merge commit '82b283a9bf8e3508e1b5c6d4b6b8cae04597b83c'
* commit '82b283a9bf8e3508e1b5c6d4b6b8cae04597b83c':
Include 'calling_package' extra for uses of in-app voice search so that
Merge commit '6ce4236d70c8543021bb521731ac9f05d22b3002'
* commit '6ce4236d70c8543021bb521731ac9f05d22b3002':
Adding missing addEarcon method. Not having this was a bug as
Merge commit 'c122824f48266c5df1b1b3a0a915619e5963ed7a'
* commit 'c122824f48266c5df1b1b3a0a915619e5963ed7a':
Run background threads associated with filtering at background priority.
Merge commit '66f608758b59517d7db2168806f9764edd28ae1f'
* commit '66f608758b59517d7db2168806f9764edd28ae1f':
Clamp app widget updates from updatePeriodMillis to a minimum of 30 minutes.
Merge commit '5a76ae46854ac449f94e1f75ef13ce035e4c65cd'
* commit '5a76ae46854ac449f94e1f75ef13ce035e4c65cd':
Update Searchables test with new GlobalSearch name
When a package is uninstalled we now remove our notion of its having been backed
up, thereby forcing a backup pass if it is reinstalled at some point in the
future. Removal from the log means rewriting it and doing an atomic rename to
the canonical version. The temporary existence used during the rewrite is *not*
written synchronously; there's no need and it keeps the load on the flash part
much lower.
Because we might crash & reboot in the middle of the rewrite operation, there's
now code during init that sanity-checks the contents of the ever-backed-up log
and ensures that it's in a coherent state.
H_SID and H_NID are now comma separated lists, so update CdmaServiceTracker
accordingly. Note: For now, we still only store away the first of each.
Also remove H_SID and H_NID fetching from RuimRecords.java, since it is unused
(and unlikely to be used) in that class.
Merge commit '37b939a63742c9a0cea4e6982bfb0581def45d6d'
* commit '37b939a63742c9a0cea4e6982bfb0581def45d6d':
Move the silent ringtone to ringtones/notifications, so it can be used for both.
We now schedule a backup pass for any new application we see (at boot or
package-install time) for which we have never performed a backup. The
bookkeeping is a log file with the names of all the packages we've successfully
completed a backup pass on, maintained with synchronous journal-type behavior.
Also, make a bunch of private fields package-scoped to permit cheaper access
from the various worker / binder threads that run under the Backup Manager's
aegis.
Merge commit '83fa3565896ed19846f6498c00de3cc9a29b1a57'
* commit '83fa3565896ed19846f6498c00de3cc9a29b1a57':
Fixing a bug in how stop works - keep stop from always stopping
Merge commit 'b197021e160091897391cd27093c35bd3c22a7fc'
* commit 'b197021e160091897391cd27093c35bd3c22a7fc':
Making sure that the audio buffers for speech are cleared
* changes:
Adding missing addEarcon method. Not having this was a bug as this method is needed to add earcons; otherwise, there is nothing for playEarcon to play.
* changes:
Added fade-in out animation for compatible apps (This CL only add this when the app on the top is in compatibility mode for now. I need some help to do the same when the closing app is in compatibility mode) Refactored DimAnimator
In this first cut, a raw parcel is parsed to check that the overall
format is correct.
At the same time, we record the metadata seen and their position in
the parcel for later retrieval using the get* methods.
This means that the 'has' method to check the existence of a metadata
should work.
Removed size and iterator methods. Instead, I added a new method
to give access to the set of keys. The user can make use of the set
to call size(), empty(), iterator() etc...
Merge commit '4c3a589e8e4efbd6f4c5e63bd94cb6181f189b7d'
* commit '4c3a589e8e4efbd6f4c5e63bd94cb6181f189b7d':
Remove the Google domains from the Gears permission table when the global location setting is set to false
Patch supplied on advice of partner. This causes us to send suspend_sink to
Bluez via socket interface, so we enter suspend on the A2DP link faster.
This is especially important when switching to SCO so that we come closer to
whitepaper recommendations to suspend A2DP before setting up SCO.
We have another patch set to add DBUS A2DP suspend and resume calls to Bluez
that will do a better job of following whitepaper recommendations for
A2DP -> SCO -> A2DP, but this small patch is still an improvement.