title: How the soft keyboard long press backspace works?
body: <p>I'm creating a input method on Android, and I want to implement the long press backspace key to delete character one by one without release (I think the default behavior is press the backspace once got one character deleted).</p>
  
  <p>My current solution is "override" the "onLongPress" function in my sub-class of "KeyboardView", and call a keep running delete to send delete action to the view when the long press with code "KEYCODE_DELETE" was triggered. As my codes below:</p>
  
  <pre><code>    @Override
  protected boolean onLongPress(Key key) {
      if (key.codes[0] == Keyboard.KEYCODE_DELETE) {
          final Handler h = new Handler();
          final int delay = 500;
          h.postDelayed(new Runnable() {
              public void run() {
                  h.postDelayed(this, delay);
                  getOnKeyboardActionListener().onKey(Keyboard.KEYCODE_DELETE, null);
              }
          }, delay);
          return true;
      } else {
          return super.onLongPress(key);
      }
  }
  </code></pre>
  
  <p>So, my question is "how to stop it?" how to track the release of the long press on backspace key? Or is there any way to make the long press deleting happen?</p>