Skip to content

Instantly share code, notes, and snippets.

@deskid
Created July 8, 2016 03:41
Show Gist options
  • Save deskid/fcfc8e43c2563d4a1d1206950025f067 to your computer and use it in GitHub Desktop.
Save deskid/fcfc8e43c2563d4a1d1206950025f067 to your computer and use it in GitHub Desktop.
import android.text.TextWatcher;
/**
* This is a wrapper around {@link TextWatcher} that overrides
* {@link TextWatcher#beforeTextChanged(CharSequence, int, int, int)} and
* {@link TextWatcher#onTextChanged(CharSequence, int, int, int)} with empty bodies.
*/
public abstract class EasyTextWatcher implements TextWatcher {
@Override
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) {
// Do nothing
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment