title: Why does moving textview focus work in button function but not in onKeyListener?
body: <p>I have this form where you are adding multiple names to a list. I have two edit texts, Firstname and LastName. When the add button is clicked, the focus moves from the last name back to the first name. Works pretty well: </p>
  
  <pre><code>public void onAddBtnClick(View v) {
       addNameToList();
       TextView txtFirstName = (TextView) findViewById(R.id.txtFirstName);
       Selection.setSelection((Editable) txtFirstName.getText(), txtFirstName.getSelectionStart());
       txtFirstName.requestFocus();
       }
  </code></pre>
  
  <p>No problems here. However, I want it to do the same thing when the user hits the "Next" button within their keyboard, i.e. the enter button. Here, it does all the functions in addNameToList() and goes through the next few lines within the code. But it doesn't remove the focus from the second textview: </p>
  
  <pre><code>EditText etLastName = (EditText) findViewById(R.id.txtLastName);
  
      etLastName.setOnKeyListener(new View.OnKeyListener() {
          @Override
          public boolean onKey(View v, int keyCode, KeyEvent event) {
              if ((event.getAction() == KeyEvent.ACTION_DOWN) &amp;&amp;
                      (keyCode == KeyEvent.KEYCODE_ENTER)) {
                  Button btn = (Button) findViewById(R.id.btnAdd);
                  btn.performClick();
              }
              return true;
          }
      });
  </code></pre>
  
  <p>As you see, I tried just doing the performClick to see if that would work, but it still keeps the focus. I also tried putting the focus code there. Is there anyway I can make it do the same action on the enter? </p>