summaryrefslogtreecommitdiff
path: root/tests/src
diff options
context:
space:
mode:
Diffstat (limited to 'tests/src')
-rw-r--r--tests/src/com/android/dialer/tests/calllog/FillCallLogTestActivity.java18
1 files changed, 15 insertions, 3 deletions
diff --git a/tests/src/com/android/dialer/tests/calllog/FillCallLogTestActivity.java b/tests/src/com/android/dialer/tests/calllog/FillCallLogTestActivity.java
index aa2d2653b..e499e550d 100644
--- a/tests/src/com/android/dialer/tests/calllog/FillCallLogTestActivity.java
+++ b/tests/src/com/android/dialer/tests/calllog/FillCallLogTestActivity.java
@@ -40,6 +40,8 @@ import android.provider.VoicemailContract.Voicemails;
import android.telecom.PhoneAccount;
import android.telecom.PhoneAccountHandle;
import android.telecom.TelecomManager;
+import android.text.Editable;
+import android.text.TextWatcher;
import android.text.format.DateFormat;
import android.util.Log;
import android.view.MotionEvent;
@@ -151,11 +153,21 @@ public class FillCallLogTestActivity extends Activity {
mAccount0 = (RadioButton) findViewById(R.id.account0);
mAccount1 = (RadioButton) findViewById(R.id.account1);
- mCustomCallTypeTextView.setOnTouchListener(new View.OnTouchListener() {
+ mCustomCallTypeTextView.addTextChangedListener(new TextWatcher() {
@Override
- public boolean onTouch(View v, MotionEvent event) {
+ public void beforeTextChanged(CharSequence s, int start, int count, int after) {
+ // Do nothing.
+ }
+
+ @Override
+ public void onTextChanged(CharSequence s, int start, int before, int count) {
+ // Toggle the custom call type radio button if the text is changed/focused.
mCallTypeCustom.toggle();
- return false;
+ }
+
+ @Override
+ public void afterTextChanged(Editable s) {
+ // Do nothing.
}
});