title: Mouse Click Listener doesn't fire
body: <p>I am following a tutorial <a href="http://www.java2s.com/Tutorial/Java/0260__Swing-Event/Handlingamouseevent.htm" rel="nofollow">here</a> I absolutely did the same thing but when I clicked the mouse buttons nothing happens. I tried to debug but I don't know how to do that.</p>
  
  <pre><code>class MouseClickListener extends MouseAdapter{
  public void MouseClicked(MouseEvent e){
     if(SwingUtilities.isLeftMouseButton(e)){
       System.out.print("Left clicked");
       }
      else if(SwingUtilities.isRightMouseButton(e)){
       System.out.print("Right Clicked");
       System.out.print("sssss");
       }
       else if(SwingUtilities.isMiddleMouseButton(e)){
       System.out.print("Middle clicked");
   }
       System.out.print(e.getClickCount()+"times ");
       int x=e.getX();
       int y=e.getY();
      System.out.println("at ("+x+","+y+" )");
        }
     }
   public class MouseListenerTest1 extends JFrame{
       public static void main(String[] args){
  JFrame.setDefaultLookAndFeelDecorated(true);
  JFrame frm=new JFrame();
  frm.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
  frm.addMouseListener(new MouseClickListener());
  frm.setSize(200, 200);
  frm.setVisible(true);
      }
     }
  </code></pre>