summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYorke Lee <yorkelee@google.com>2015-10-14 19:20:04 +0000
committerAndroid (Google) Code Review <android-gerrit@google.com>2015-10-14 19:20:04 +0000
commit8fbbc59c1b3c9fc60c4e2b78d6f6f2cc9f885709 (patch)
tree76c513ea646c37e5ed4dc4318c3849311aea79e5
parentc8a187e5fc4c6d9de1fba451801805414f84fa6d (diff)
parentd9a9316985a77fb8a9562f8086e36d3722f19d5c (diff)
Merge "Correctly set query string for new SmartDialSearchFragment instance" into ub-contactsdialer-a-dev
-rw-r--r--src/com/android/dialer/DialtactsActivity.java5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/com/android/dialer/DialtactsActivity.java b/src/com/android/dialer/DialtactsActivity.java
index bfb908f04..0893b1c56 100644
--- a/src/com/android/dialer/DialtactsActivity.java
+++ b/src/com/android/dialer/DialtactsActivity.java
@@ -230,6 +230,7 @@ public class DialtactsActivity extends TransactionSafeActivity implements View.O
private View mVoiceSearchButton;
private String mSearchQuery;
+ private String mDialpadQuery;
private DialerDatabaseHelper mDialerDatabaseHelper;
private DragDropController mDragDropController;
@@ -604,6 +605,9 @@ public class DialtactsActivity extends TransactionSafeActivity implements View.O
} else if (fragment instanceof SmartDialSearchFragment) {
mSmartDialSearchFragment = (SmartDialSearchFragment) fragment;
mSmartDialSearchFragment.setOnPhoneNumberPickerActionListener(this);
+ if (!TextUtils.isEmpty(mDialpadQuery)) {
+ mSmartDialSearchFragment.setAddToContactNumber(mDialpadQuery);
+ }
} else if (fragment instanceof SearchFragment) {
mRegularSearchFragment = (RegularSearchFragment) fragment;
mRegularSearchFragment.setOnPhoneNumberPickerActionListener(this);
@@ -1142,6 +1146,7 @@ public class DialtactsActivity extends TransactionSafeActivity implements View.O
@Override
public void onDialpadQueryChanged(String query) {
+ mDialpadQuery = query;
if (mSmartDialSearchFragment != null) {
mSmartDialSearchFragment.setAddToContactNumber(query);
}