From 55b030a8bbb0323a4823fc34f3167a248a0ff899 Mon Sep 17 00:00:00 2001 From: Yorke Lee Date: Mon, 28 Jan 2013 12:10:30 -0800 Subject: Smart Dialling v2 with phone number support Behavior: Use a prefix tree to cache contacts instead of an array list Perform matches against phone numbers as well DialpadFragment now ignores results from stale tasks where queries no longer match Add ability to not use default phone number for phone number disambiguation dialog Contacts are now ranked by the order which they were sorted by in the ContactsProvider (affinity) Change remapAccentedChars to always return lowercase characters to avoid overhead of uppercase character conversion Resource/Layout changes: Tweak margins so that the section containing smart dial suggestions looks cleaner Use color resource instead of hardcoding color values Add phone number to SmartDial items ContentObserver: Add a contentobserver to be notified on changes in contacts Refactored cache to allow for forced cache refreshes Use a single instance of SmartDialCache Tests: Added SmartDialTrie tests Comments: Comment cleanup Change-Id: Ica2854e2845d4d75048aa1fd982f139496d21bf3 --- res/layout/dialpad_fragment.xml | 5 ++--- res/layout/dialpad_smartdial_item.xml | 33 +++++++++++++++++++++++---------- res/values/colors.xml | 1 + 3 files changed, 26 insertions(+), 13 deletions(-) (limited to 'res') diff --git a/res/layout/dialpad_fragment.xml b/res/layout/dialpad_fragment.xml index e672551bb..27ba2da46 100644 --- a/res/layout/dialpad_fragment.xml +++ b/res/layout/dialpad_fragment.xml @@ -56,17 +56,16 @@ android:src="@drawable/ic_dial_action_delete" /> - - diff --git a/res/layout/dialpad_smartdial_item.xml b/res/layout/dialpad_smartdial_item.xml index eed257035..54f2a084e 100644 --- a/res/layout/dialpad_smartdial_item.xml +++ b/res/layout/dialpad_smartdial_item.xml @@ -13,16 +13,29 @@ See the License for the specific language governing permissions and limitations under the License. --> - - + + + + diff --git a/res/values/colors.xml b/res/values/colors.xml index ebdc2f60e..288f58b64 100644 --- a/res/values/colors.xml +++ b/res/values/colors.xml @@ -19,6 +19,7 @@ #888888 #39caff + #39caff #ffffff -- cgit v1.2.3