Back to project page Dense-sms-sender-for-android.
The source code is released under:
Apache License
If you think the Android project Dense-sms-sender-for-android listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package mrhs.ce.DenseSms; /*from w w w. j a v a2 s. c o m*/ import java.util.ArrayList; import android.content.Context; import android.text.TextWatcher; import android.util.AttributeSet; import android.widget.EditText; public class MyEditText extends EditText { ArrayList<TextWatcher> list; public MyEditText(Context ctx) { super(ctx); } public MyEditText(Context ctx, AttributeSet attrs) { super(ctx, attrs); } public MyEditText(Context ctx, AttributeSet attrs, int defStyle) { super(ctx, attrs, defStyle); } @Override public void addTextChangedListener(TextWatcher watcher) { // TODO Auto-generated method stub if(list==null){ list=new ArrayList<TextWatcher>(); list.add(null); } list.set(0, watcher); super.addTextChangedListener(watcher); } public void removeTextWatcher(){ removeTextChangedListener(list.get(0)); list.set(0, null); } }