must press enter key twice to do the work
<p>I have a problem with the enter key in android, I have an edittext where I enter a value and then when I click on enter, I want it to make something. My problem is that I have to press enter twice to get the desired results.</p>

<pre><code>    editText1.setOnKeyListener(new OnKeyListener() {
        public boolean onKey(View v, int keyCode, KeyEvent event) {
            // If the event is a key-down event on the "enter" button
            if ((event.getAction() == KeyEvent.ACTION_DOWN) &amp;&amp;
                (keyCode == KeyEvent.KEYCODE_ENTER)) {

              // Perform action on key press
              mWebView.loadUrl(editText1.getText().toString());
              mWebView.requestFocus(); 
              return true;
            }
            return false;
        }
    });
</code></pre>
