The empty space on right end sometimes registers as the word at the left end. Fixed this by checking for -1.
Also fixed a bug where the strip moves in the wrong direction on drag, when it shouldn't move at all.
Original author: yamasani
Merged from: //branches/cupcake/...
Automated import of CL 143780