Fix inconsistent behavior with backspace in the Emoji pallete.

In some ways, the delete key on the Emoji palette was
inconsistent with that in other keyboard layouts.
- It deletes a character in down events, not up events.
- A user cannot cancel the event by moving the finger away from
  the key.

This patch fixes these inconsistencies by revisin
EmojiPalettesView.DeleteKeyOnTouchListener. Notable changes are:
- An explicit state machine is introduced because there are
  different event sequences to be considered.
- Background thread is replaced with CountDownTimer so tha
  key-repeat events can be naturally generated in the UI thread.
- MotionEvent.ACTION_MOVE is now handled to cancel the
  subsequent delete key events when the finger is moved away
  from the key area.

Bug: 12464067
Change-Id: Ibc360a1394afef368a8d9af7b4c0e99e8ce1d83c
1 file changed
tree: 8c30d6237c5b82fcb56d00aa36ac64227f2d1d54
  1. dictionaries/
  2. java/
  3. native/
  4. tests/
  5. tools/
  6. Android.mk
  7. CleanSpec.mk