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

Min/Max buttons not created with Frame and JFrame when not resizable

    XMLWordPrintable

    Details

    • Subcomponent:
    • Resolved In Build:
      b01
    • CPU:
      x86
    • OS:
      windows_95, windows_nt

      Backports

        Description

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

        public class CantMinMax extends Frame {

            public static void main(String args[]) {
                CantMinMax cantMinMax = new CantMinMax();
            }

            public CantMinMax () {
                addWindowListener(new WindowAdapter() {public void windowClosing(WindowEvent e) {System.exit(0);}});
                setTitle("Can't Min/Max in JDK 1.1.7");
                setSize(300,150);
                setResizable(false);
                show();
            }
        }
        _______________________________________
        This code demonstrates a problem where min/max buttons do not appear on a Frame which is not resizable. If the code is modified in the following way:

            public CantMinMax () {
                addWindowListener(new WindowAdapter() {public void windowClosing(WindowEvent e) {System.exit(0);}});
                setTitle("Can't Min/Max in JDK 1.1.7");
                setSize(300,150);
                show();
                setResizable(false);
            }

        The frame is not shown onscreen at all. Since Frames and JFrames in 1.1.6 had min/max buttons, the customer expects this code to work.

        elizabeth.mezias@Eng 1998-10-02

          Attachments

            Issue Links

              Activity

                People

                Assignee:
                tmasunw Tao Ma (Inactive)
                Reporter:
                duke J. Duke (Inactive)
                Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                  Dates

                  Created:
                  Updated:
                  Resolved:
                  Imported:
                  Indexed: