3 |
import java.awt.*; |
import java.awt.*; |
4 |
import java.awt.event.*; |
import java.awt.event.*; |
5 |
|
|
6 |
|
/** |
7 |
|
* This class is where JComponents are added to. |
8 |
|
* Unlike awt where you could just say frame.add(), |
9 |
|
* with swing you need to say frame.getRootPane() |
10 |
|
* (which delivers an instance of this class) |
11 |
|
* and add your components to that. |
12 |
|
* |
13 |
|
* It is implemented by several 'layers' (pane() should be read as plane()) |
14 |
|
* each on top of the others |
15 |
|
* where you can add components to. |
16 |
|
* (getContentPane(), getGlassPane(), getLayeredPane()) |
17 |
|
* |
18 |
|
* @author Ronald Veldema (rveldema@cs.vu.nl) |
19 |
|
*/ |
20 |
|
|
21 |
|
|
22 |
|
|
23 |
public class JRootPane extends JComponent |
public class JRootPane extends JComponent |
24 |
{ |
{ |
25 |
// The class used to obtain the accessible role for this object. |
// The class used to obtain the accessible role for this object. |
41 |
/***********************************************************/ |
/***********************************************************/ |
42 |
|
|
43 |
|
|
44 |
//The glass pane that overlays the menu bar and content pane, so it can intercept mouse movements and such. |
//The glass pane that overlays the menu bar and content pane, so it can intercept mouse movements and such. |
45 |
protected Component glassPane; |
protected Component glassPane; |
46 |
|
|
47 |
//The layered pane that manages the menu bar and content pane. |
//The layered pane that manages the menu bar and content pane. |
54 |
|
|
55 |
/********************************************************/ |
/********************************************************/ |
56 |
|
|
57 |
String getUIClassID() |
public String getUIClassID() |
58 |
{ return "JPanel"; } |
{ return "JPanel"; } |
59 |
|
|
60 |
|
|