title: dispatchKeyEvent calling method twice
body: <p>I've implemented dispatchKeyEvent in my activity to listen to the Enter key being pressed.
  The problem is that when i click enter,it calls my method twice ? How can i fix this ?
  Thanks,have a nice day !</p>
  
  <pre><code>@Override
  public boolean dispatchKeyEvent(KeyEvent e) {
  if (e.getKeyCode() == KeyEvent.KEYCODE_ENTER) {
  
                enter();
          return true;
      }
      return super.dispatchKeyEvent(e);
  };
  </code></pre>