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

Plug-in and Netscape both freeze after a modal dialog is launched from JavaScrip

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • P3
    • 1.4.1_05
    • 1.4.0
    • deploy
    • 05
    • x86
    • windows_2000
    • Verified

    Backports

      Description



        Name: gm110360 Date: 04/25/2002


        FULL PRODUCT VERSION :
        java version "1.3.1_03"
        Java(TM) 2 Runtime Environment, Standard Edition (build 1.3.1_03-b03)
        Java HotSpot(TM) Client VM (build 1.3.1_03-b03, mixed mode)


        FULL OPERATING SYSTEM VERSION :
        Microsoft Windows 2000 [Wersja 5.00.2195]

        ADDITIONAL OPERATING SYSTEMS :
        Windows 98
        Windows 98 SE


        EXTRA RELEVANT SYSTEM CONFIGURATION :
        Netscape 6, version 6.2
        Mozilla, build 2002041711

        A DESCRIPTION OF THE PROBLEM :
        Basically speaking, bug identical to 4506751 (which regards
        Java Plugin for Internet Explorer and was fixed) cause
        lock-up problem in Java Plugin for Netscape.
        The problem is that the browser and plug-in become locked-up
        after a modal dialog is shown when invoked via JavaScript.
        I have been able to reproduce this problem with Java Plug-in
        1.3.0, 1.3.1, and 1.4.0. As the most simple scenario,
        imagine an HTML document with an Applet and a form with a
        button that has a JavaScript method that is called when the
        button is pressed.
        The onPressed event calls a JavaScript method that gets the
        Applet and then makes a call into a method that brings up a
        modal dialog. This modal dialog can be a Swing Dialog such
        as JOptionPane or a custom dialog. It does not matter.
        I think bug is in one of npjava*.dll.

        STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
        Identical to ones listed in report for bug 4506751.

        EXPECTED VERSUS ACTUAL BEHAVIOR :
        Expected: Dialog shown should get input from user.
        Actual: Dialog shows and browser freezes.

        ERROR MESSAGES/STACK TRACES THAT OCCUR :
        None - JVM hangs.

        This bug can be reproduced always.

        ---------- BEGIN SOURCE ----------
        HTML page:
        <html>
        <head>
        <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-2">
        <title>
        HTML Test Page
        </title>
        </head>
        <body>
        AppletTest will appear below in a Java enabled browser.<br>
        <applet
          codebase = "."
          code = "AppletTest.class"
          name = "TestApplet"
          width = "400"
          height = "300"
          hspace = "0"
          vspace = "0"
          align = "middle"
          scriptable = true
          mayscript = true
        >
        </applet>
        <INPUT VALUE="J" TYPE="button"
        onClick="document.applets[0].showJOption();alert('after')">
        </body>
        </html>

        Java applet:
        import java.awt.*;
        import java.io.*;
        import javax.swing.*;

        public class AppletTest extends JApplet {

          public AppletTest() {
          }

          public void init() {
            super.init();
          }

          public void showJOption() {
            System.out.println("showJ enter");

            Frame f = (Frame)SwingUtilities.getRoot(this);
         
        JOptionPane.showMessageDialog(f,"Message","Title",JOptionPane.INFORMATION_MESSAGE);

            System.out.println("showJ exit");
          }
        }

        ---------- END SOURCE ----------

        CUSTOMER WORKAROUND :
        None found.
        (Review ID: 145817)
        ======================================================================

        Attachments

          Issue Links

            Activity

              People

                zgu Zhengyu Gu
                gmanwanisunw Girish Manwani (Inactive)
                Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                  Created:
                  Updated:
                  Resolved:
                  Imported:
                  Indexed: