Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Android: Detect Scroll Event for EditText

I am having problems with a seemingly very simple thing- I want to run code every time the user (or the program) scrolls the EditText up or down, in the same way a TextChanged listener allows you to run code every time the user or program changes the text. Is this possible? Thanks!

like image 813
Henry Thompson Avatar asked Sep 18 '11 15:09

Henry Thompson


1 Answers

Try extending EditText and overriding:

onScrollChanged(int l, int t, int oldl, int oldt)

which is inherited from TextView.

like image 61
Li_W Avatar answered Nov 08 '22 12:11

Li_W