Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-1261183

event.target in keyDown is different between Win32 and Solaris

    XMLWordPrintable

Details

    • 1.1
    • x86
    • solaris
    • Not verified

    Description


      Run the applet at /usr/sqe/bugs/javacupbugs/snapshots/1261183/tmachine.html
      using JDK1.0.2 appletviewer. See the 1261183 directory for code.

      In the method

      public boolean keyDown(java.awt.Event e, int key)

      found in the source file Turing.java, there is a check to see if e.target == this.
      The results were different between Solaris and Win32, comparing jdk1.0.2 versions. In Solaris, it fails but in the Win version it passes.

      To reproduce: click anywhere on the applet to start and then press a key.

      i added some print statements to std out in the code, which display the key number, e.target, and this respectively...

      *Solaris (Sun or x86, jdk1.0.2 and jdk1.1 from july23):

      in keyDown
      115
      java.awt.TextArea[5,5,31x44,text=,editable,selection=0-0,rows=13,cols=10]
      Turing[0,0,625x225,layout=java.awt.BorderLayout]

      *win (using win95, jdk 1.0.2):

      in keyDown
      115
      Turing[0,0,625x225,layout=java.awt.BorderLayout]
      Turing[0,0,625x225,layout=java.awt.BorderLayout]


      ALSO, as a side note.
      *win (using NT, jdk1.1 from july 23) e.target changes depending on where the mouse click occured,unlike in the above two examples :

      in keyDown
      115
      java.awt.Button .......(this line depends on location of mouse click)
      Turing[0,0,625x225,layout=java.awt.BorderLayout]

      Attachments

        Activity

          People

            tballsunw Tom Ball (Inactive)
            duke J. Duke
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: