title: KeyListener does not react to keyboard event. Ok for mouse events
body: <p>JPanel reacts very strange to events. It could process the MouseEvent, but won't handle KeyEvent.</p>
  
  <p>JPanel class:</p>
  
  <pre><code>public class DrawPanel extends JPanel {
      class DrawListener extends MouseAdapter implements KeyListener {
          @Override
          public void mouseDragged(MouseEvent e) {
              // works fine
          }
          @Override
          public void mouseReleased(MouseEvent e) {       
              // works fine
          }
          @Override
          public void mouseClicked(MouseEvent e) {
              // works fine
          }
          @Override
          public void keyPressed(KeyEvent e) {
              // Listener is NOT invoked here if anykey is pressed
          }
          @Override
          public void keyReleased(KeyEvent e) {
              // NOT invoked 
          }
          @Override
          public void keyTyped(KeyEvent e) {
              // NOT invoked 
          }
  </code></pre>
  
  <p>Constructor for panel:</p>
  
  <pre><code>// Class constructor
  public DrawPanel() {
          DrawListener l = new DrawListener();
          addMouseListener(l);
          addMouseMotionListener(l);
          addKeyListener(l);
          setFocusable(true);
          requestFocus();
  }
  </code></pre>
  
  <p>How is it possible, if MouseEvent handler works just fine? Where it could be wrong?</p>