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

DropDown List of JComboBox detached

    XMLWordPrintable

    Details

    • Subcomponent:
    • Resolved In Build:
      b03
    • CPU:
      x86
    • OS:
      windows_7

      Backports

        Description

        FULL PRODUCT VERSION :
        java version "1.7.0"
        Java(TM) SE Runtime Environment (build 1.7.0-b147)
        Java HotSpot(TM) 64-Bit Server VM (build 21.0-b17, mixed mode)

        ADDITIONAL OS VERSION INFORMATION :
        Microsoft Windows [Version 6.1.7601]

        A DESCRIPTION OF THE PROBLEM :
        When an JComboBox is showing its dropdown list in an Applet in a browser, pressing the browser's scrollbar arrow / moving the browser's scrollbar does not update the dropdown list location. It stays still on the screen which makes the dropdown list seems to be "detached" from its JComboBox.


        STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
        Prepare an Applet to display a JComboBox and a HTML file, jnlp...etc for standard applet deployment.
        In the HTML, it should contain some spacing, eg. <br/>, in the <body> part.

        Open an Applet with any browser, resizes height of the browser / input more space in html file so that the browser's vertical scrollbar appears.

        Click on the JComboBox to show its dropdown list, then press the browser's scrollbar arrow or drag the browser's scrollbar to perform scrolling.

        The dropdown list of the JComboBox is detached from its parent instead of scrolling along with the JComboBox.

        EXPECTED VERSUS ACTUAL BEHAVIOR :
        EXPECTED -
        Location of the dropdown list should be updated with its JComboBox.
        ACTUAL -
        Location is not updated.

        REPRODUCIBILITY :
        This bug can be reproduced always.

        ---------- BEGIN SOURCE ----------
        package test.applet;

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

        public class TestApplet extends JApplet {
        public void init() {
        super.init();
        String[] comboBoxModel = new String[] {"This is Choice 1.", "This is Choice 2."};
        JComboBox comboBox = new JComboBox(comboBoxModel);
        getContentPane().add(comboBox);
        setSize(300, 100);
        }
        }
        ---------- END SOURCE ----------

          Attachments

            Issue Links

              Activity

                People

                Assignee:
                anashaty Anton Nashatyrev (Inactive)
                Reporter:
                webbuggrp Webbug Group
                Votes:
                0 Vote for this issue
                Watchers:
                5 Start watching this issue

                  Dates

                  Created:
                  Updated:
                  Resolved:
                  Imported:
                  Indexed: