2003-12-26 Guilhem Lavaux <guilhem@kaffe.org>
[official-gcc.git] / libjava / javax / swing / JDesktopPane.java
blob4ad265c9bd945b9ff8fccdb37868b98aba9decb1
1 /* JDesktopPane.java --
2 Copyright (C) 2002 Free Software Foundation, Inc.
4 This file is part of GNU Classpath.
6 GNU Classpath is free software; you can redistribute it and/or modify
7 it under the terms of the GNU General Public License as published by
8 the Free Software Foundation; either version 2, or (at your option)
9 any later version.
11 GNU Classpath is distributed in the hope that it will be useful, but
12 WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 General Public License for more details.
16 You should have received a copy of the GNU General Public License
17 along with GNU Classpath; see the file COPYING. If not, write to the
18 Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
19 02111-1307 USA.
21 Linking this library statically or dynamically with other modules is
22 making a combined work based on this library. Thus, the terms and
23 conditions of the GNU General Public License cover the whole
24 combination.
26 As a special exception, the copyright holders of this library give you
27 permission to link this library with independent modules to produce an
28 executable, regardless of the license terms of these independent
29 modules, and to copy and distribute the resulting executable under
30 terms of your choice, provided that you also meet, for each linked
31 independent module, the terms and conditions of the license of that
32 module. An independent module is a module which is not derived from
33 or based on this library. If you modify this library, you may extend
34 this exception to your version of the library, but you are not
35 obligated to do so. If you do not wish to do so, delete this
36 exception statement from your version. */
38 package javax.swing;
40 // Imports
41 import java.io.*;
42 import javax.accessibility.*;
43 import javax.swing.plaf.*;
45 /**
46 * JDesktopPane
47 * @author Andrew Selkirk
48 * @version 1.0
50 public class JDesktopPane extends JLayeredPane implements Accessible
53 //-------------------------------------------------------------
54 // Classes ----------------------------------------------------
55 //-------------------------------------------------------------
57 /**
58 * AccessibleJDesktopPane
60 protected class AccessibleJDesktopPane extends AccessibleJComponent {
62 //-------------------------------------------------------------
63 // Initialization ---------------------------------------------
64 //-------------------------------------------------------------
66 /**
67 * Constructor AccessibleJDesktopPane
68 * @param component TODO
70 protected AccessibleJDesktopPane(JDesktopPane component) {
71 super(component);
72 // TODO
73 } // AccessibleJDesktopPane()
76 //-------------------------------------------------------------
77 // Methods ----------------------------------------------------
78 //-------------------------------------------------------------
80 /**
81 * getAccessibleRole
82 * @returns AccessibleRole
84 public AccessibleRole getAccessibleRole() {
85 return AccessibleRole.DESKTOP_PANE;
86 } // getAccessibleRole()
89 } // AccessibleJDesktopPane
92 //-------------------------------------------------------------
93 // Constants --------------------------------------------------
94 //-------------------------------------------------------------
96 /**
97 * LIVE_DRAG_MODE
99 public static int LIVE_DRAG_MODE = 0;
102 * OUTLINE_DRAG_MODE
104 public static int OUTLINE_DRAG_MODE = 1;
107 * uiClassID
109 private static final String uiClassID = "DesktopPaneUI";
112 //-------------------------------------------------------------
113 // Variables --------------------------------------------------
114 //-------------------------------------------------------------
117 * selectedFrame
119 private transient JInternalFrame selectedFrame;
122 * desktopManager
124 private transient DesktopManager desktopManager;
128 * dragMode
130 private int dragMode;
133 //-------------------------------------------------------------
134 // Initialization ---------------------------------------------
135 //-------------------------------------------------------------
138 * Constructor JDesktopPane
140 public JDesktopPane() {
141 // TODO
142 } // JDesktopPane()
145 //-------------------------------------------------------------
146 // Methods ----------------------------------------------------
147 //-------------------------------------------------------------
150 * writeObject
151 * @param stream TODO
152 * @exception IOException TODO
154 private void writeObject(ObjectOutputStream stream) throws IOException {
155 // TODO
156 } // writeObject()
159 * getUI
160 * @returns DesktopPaneUI
162 public DesktopPaneUI getUI() {
163 return (DesktopPaneUI) ui;
164 } // getUI()
167 * setUI
168 * @param ui TODO
170 public void setUI(DesktopPaneUI ui) {
171 super.setUI(ui);
172 } // setUI()
175 * setDragMode
176 * @param mode TODO
178 public void setDragMode(int mode) {
179 this.dragMode = mode;
180 // TODO
181 } // setDragMode()
184 * getDragMode
185 * @returns int
187 public int getDragMode() {
188 return dragMode;
189 } // getDragMode()
192 * getDesktopManager
193 * @returns DesktopManager
195 public DesktopManager getDesktopManager() {
196 return desktopManager;
197 } // getDesktopManager()
200 * setDesktopManager
201 * @param manager TODO
203 public void setDesktopManager(DesktopManager manager) {
204 this.desktopManager = manager;
205 // TODO
206 } // setDesktopManager()
209 * updateUI
211 public void updateUI() {
212 setUI((DesktopPaneUI) UIManager.get(this));
213 invalidate();
214 } // updateUI()
217 * getUIClassID
218 * @returns String
220 public String getUIClassID() {
221 return uiClassID;
222 } // getUIClassID()
225 * getAllFrames
226 * @returns JInternalFrame[]
228 public JInternalFrame[] getAllFrames() {
229 return null; // TODO
230 } // getAllFrames()
233 * getSelectedFrame
234 * @returns JInternalFrame
236 public JInternalFrame getSelectedFrame() {
237 return null; // TODO
238 } // getSelectedFrame()
241 * setSelectedFrame
242 * @param frame TODO
244 public void setSelectedFrame(JInternalFrame frame) {
245 // TODO
246 } // setSelectedFrame()
249 * getAllFramesInLayer
250 * @param layer TODO
251 * @returns JInternalFrame[]
253 public JInternalFrame[] getAllFramesInLayer(int layer) {
254 return null; // TODO
255 } // getAllFramesInLayer()
258 * isOpaque
259 * @returns boolean
261 public boolean isOpaque() {
262 return true;
263 } // isOpaque()
266 * paramString
267 * @returns String
269 protected String paramString() {
270 return null; // TODO
271 } // paramString()
274 * getAccessibleContext
275 * @returns AccessibleContext
277 public AccessibleContext getAccessibleContext() {
278 if (accessibleContext == null) {
279 accessibleContext = new AccessibleJDesktopPane(this);
280 } // if
281 return accessibleContext;
282 } // getAccessibleContext()
285 } // JDesktopPane