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

Solaris AWT popup menus can hang windowing system

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: P4
    • Resolution: Cannot Reproduce
    • Affects Version/s: 2.0, 1.1.5, 1.1.6, 1.1.7, 1.2.0
    • Fix Version/s: None
    • Component/s: client-libs
    • Subcomponent:
    • CPU:
      sparc
    • OS:
      solaris_2.5, solaris_2.5.1, solaris_2.6

      Description

      Run the following simple test case on Solaris CDE or OpenLook.
      Right click on mouse to get the popup menu many times and pretty soon it will
      lock up the whole windowing system until you login remotely to kill the java
      process running the testcase. Problem happens on JDK1.1.6, JDK1.1.7 and
      JDK1.2 beta 4.1. Please ignore the funky windowClosing method provided by
      the customer.

      --------------------------------------------------------------------------------
      import java.awt.*;
      import java.awt.event.*;


      public class popupbug extends MouseAdapter {

      public static void main(String[] args) {
              pm.add(new MenuItem("One"));
              pm.add(new MenuItem("Two"));
              pm.add(new MenuItem("Three"));
              f1.add(pm);
              f1.addMouseListener(new popupbug());
              f1.addWindowListener(new WindowAdapter() {
                      public void windowClosing(WindowEvent we) {
                              f1.remove(pm);
                      }
              });
              f1.pack();
              f1.show();
      }

      public void mouseClicked(MouseEvent evt) {
              pm.show((Component)evt.getSource(), evt.getX(), evt.getY());
      }

      static PopupMenu pm = new PopupMenu("Duh?");
      static Frame f1 = new Frame("popup bug");

      }

      --------------------------------------------------------------------------------

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              pongsunw Patrick Ong (Inactive)
              Reporter:
              pongsunw Patrick Ong (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Imported:
                Indexed: