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

JInternalFrame can incorrectly exceed its desktop panel's bounds

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: P4 P4
    • None
    • 1.2.2
    • client-libs



      Name: kaC94536 Date: 02/01/2000



      JInternalFrame component exceeds its desktop panel's bounds after moving or resizing in
      some cases.

      The frame window of the following test contains JDesktopPane component and tested
      JInternalFrame component. To see described effect take the following steps:

      1. Try to resize JInternalFrame component to the right (or any other) side as far as
      possible. You can see that right side of the tested component moves outside JDesktopPane
      component. If you resize frame up and left and then release mouse, you have not way to
      get to the left and top sides of the JInternalFrame component.

      2. Try to move JInternalFrame up as far as possible using mouse. After you release mouse,
      you can not get the internal frame back.

      --------------------test.java---------------------------------------------

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

      public class test extends JFrame {
          public test() {
              super("JInternalFrame test");
              JDesktopPane dpane = new JDesktopPane();
              JInternalFrame internalFrame = new JInternalFrame("",true);
              internalFrame.setBounds(20,20,100,150);
              dpane.add(internalFrame);
              getContentPane().add( dpane, BorderLayout.CENTER );
          }

          public static void main(String[] args) {
              JFrame frame = new test();
              frame.setSize(new Dimension(400,300));
              frame.setVisible(true);
          }
      }

      ======================================================================

      ======================================================================

            hgajewsksunw Hania Gajewska (Inactive)
            kanisimosunw Konstantin Anisimov (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: