bug-classpath
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug swing/24458] New: JFrames don't receive KeyEvents


From: abalkiss at redhat dot com
Subject: [Bug swing/24458] New: JFrames don't receive KeyEvents
Date: 20 Oct 2005 18:10:11 -0000

The testcase below shows that an empty JFrame with a KeyListener attached
doesn't receive key events and pass them on to that listener.

***TESTCASE***
import javax.swing.*;
import java.awt.event.*;

public class NoKeyEvents{

  public static void main(String[] args) {

    JFrame jd = new JFrame();
    jd.addKeyListener( new KeyAdapter(){
        public void keyPressed(KeyEvent e)
        {
          System.out.println ("hi");
        }
      });
    jd.setSize(100, 100);
    jd.show();
  }
}


-- 
           Summary: JFrames don't receive KeyEvents
           Product: classpath
           Version: unspecified
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: swing
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: abalkiss at redhat dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=24458





reply via email to

[Prev in Thread] Current Thread [Next in Thread]