src/java.desktop/share/classes/javax/swing/JWindow.java

Print this page

        

*** 1,7 **** /* ! * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 only, as * published by the Free Software Foundation. Oracle designates this --- 1,7 ---- /* ! * Copyright (c) 1997, 2015, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 only, as * published by the Free Software Foundation. Oracle designates this
*** 24,37 **** */ package javax.swing; import java.awt.*; import java.awt.event.*; ! import java.beans.PropertyChangeListener; ! import java.util.Locale; ! import java.util.Vector; ! import java.io.Serializable; import javax.accessibility.*; /** * A <code>JWindow</code> is a container that can be displayed anywhere on the --- 24,35 ---- */ package javax.swing; import java.awt.*; import java.awt.event.*; ! import java.beans.JavaBean; ! import java.beans.BeanProperty; import javax.accessibility.*; /** * A <code>JWindow</code> is a container that can be displayed anywhere on the
*** 81,98 **** * has been added to the <code>java.beans</code> package. * Please see {@link java.beans.XMLEncoder}. * * @see JRootPane * - * @beaninfo - * attribute: isContainer true - * attribute: containerDelegate getContentPane - * description: A toplevel window which has no system border or controls. - * * @author David Kloba * @since 1.2 */ @SuppressWarnings("serial") public class JWindow extends Window implements Accessible, RootPaneContainer, TransferHandler.HasGetTransferHandler { --- 79,93 ---- * has been added to the <code>java.beans</code> package. * Please see {@link java.beans.XMLEncoder}. * * @see JRootPane * * @author David Kloba * @since 1.2 */ + @JavaBean(defaultProperty = "accessibleContext", description = "A toplevel window which has no system border or controls.") + @SwingContainer(delegate = "getContentPane") @SuppressWarnings("serial") public class JWindow extends Window implements Accessible, RootPaneContainer, TransferHandler.HasGetTransferHandler {
*** 326,341 **** * * @see TransferHandler * @see #getTransferHandler * @see java.awt.Component#setDropTarget * @since 1.6 - * - * @beaninfo - * bound: true - * hidden: true - * description: Mechanism for transfer of data into the component */ public void setTransferHandler(TransferHandler newHandler) { TransferHandler oldHandler = transferHandler; transferHandler = newHandler; SwingUtilities.installSwingDropTargetAsNecessary(this, transferHandler); firePropertyChange("transferHandler", oldHandler, newHandler); --- 321,333 ---- * * @see TransferHandler * @see #getTransferHandler * @see java.awt.Component#setDropTarget * @since 1.6 */ + @BeanProperty(hidden = true, description + = "Mechanism for transfer of data into the component") public void setTransferHandler(TransferHandler newHandler) { TransferHandler oldHandler = transferHandler; transferHandler = newHandler; SwingUtilities.installSwingDropTargetAsNecessary(this, transferHandler); firePropertyChange("transferHandler", oldHandler, newHandler);
*** 374,387 **** * * @see #addImpl * @see #setLayout * @see #isRootPaneCheckingEnabled * @see javax.swing.RootPaneContainer - * @beaninfo - * hidden: true - * description: Whether the add and setLayout methods are forwarded */ protected void setRootPaneCheckingEnabled(boolean enabled) { rootPaneCheckingEnabled = enabled; } --- 366,378 ---- * * @see #addImpl * @see #setLayout * @see #isRootPaneCheckingEnabled * @see javax.swing.RootPaneContainer */ + @BeanProperty(hidden = true, description + = "Whether the add and setLayout methods are forwarded") protected void setRootPaneCheckingEnabled(boolean enabled) { rootPaneCheckingEnabled = enabled; }
*** 461,470 **** --- 452,463 ---- * @return the <code>rootPane</code> property for this window * * @see #setRootPane * @see RootPaneContainer#getRootPane */ + @BeanProperty(bound = false, hidden = true, description + = "the RootPane object for this window.") public JRootPane getRootPane() { return rootPane; }
*** 472,485 **** * Sets the new <code>rootPane</code> object for this window. * This method is called by the constructor. * * @param root the new <code>rootPane</code> property * @see #getRootPane - * - * @beaninfo - * hidden: true - * description: the RootPane object for this window. */ protected void setRootPane(JRootPane root) { if(rootPane != null) { remove(rootPane); } --- 465,474 ----
*** 517,532 **** * * @exception IllegalComponentStateException (a runtime * exception) if the content pane parameter is <code>null</code> * @see #getContentPane * @see RootPaneContainer#setContentPane - * - * @beaninfo - * hidden: true - * description: The client area of the window where child - * components are normally inserted. */ public void setContentPane(Container contentPane) { getRootPane().setContentPane(contentPane); } /** --- 506,518 ---- * * @exception IllegalComponentStateException (a runtime * exception) if the content pane parameter is <code>null</code> * @see #getContentPane * @see RootPaneContainer#setContentPane */ + @BeanProperty(bound = false, hidden = true, description + = "The client area of the window where child components are normally inserted.") public void setContentPane(Container contentPane) { getRootPane().setContentPane(contentPane); } /**
*** 548,562 **** * * @exception IllegalComponentStateException (a runtime * exception) if the content pane parameter is <code>null</code> * @see #getLayeredPane * @see RootPaneContainer#setLayeredPane - * - * @beaninfo - * hidden: true - * description: The pane which holds the various window layers. */ public void setLayeredPane(JLayeredPane layeredPane) { getRootPane().setLayeredPane(layeredPane); } /** --- 534,546 ---- * * @exception IllegalComponentStateException (a runtime * exception) if the content pane parameter is <code>null</code> * @see #getLayeredPane * @see RootPaneContainer#setLayeredPane */ + @BeanProperty(bound = false, hidden = true, description + = "The pane which holds the various window layers.") public void setLayeredPane(JLayeredPane layeredPane) { getRootPane().setLayeredPane(layeredPane); } /**
*** 575,598 **** * This method is called by the constructor. * @param glassPane the <code>glassPane</code> object for this window * * @see #getGlassPane * @see RootPaneContainer#setGlassPane - * - * @beaninfo - * hidden: true - * description: A transparent pane used for menu rendering. */ public void setGlassPane(Component glassPane) { getRootPane().setGlassPane(glassPane); } /** * {@inheritDoc} * * @since 1.6 */ public Graphics getGraphics() { JComponent.getGraphicsInvoked(this); return super.getGraphics(); } --- 559,581 ---- * This method is called by the constructor. * @param glassPane the <code>glassPane</code> object for this window * * @see #getGlassPane * @see RootPaneContainer#setGlassPane */ + @BeanProperty(bound = false, hidden = true, description + = "A transparent pane used for menu rendering.") public void setGlassPane(Component glassPane) { getRootPane().setGlassPane(glassPane); } /** * {@inheritDoc} * * @since 1.6 */ + @BeanProperty(bound = false) public Graphics getGraphics() { JComponent.getGraphicsInvoked(this); return super.getGraphics(); }