author | alexsch |
Mon, 17 Feb 2014 13:41:50 +0400 | |
changeset 23297 | 2946ef51ee24 |
parent 23268 | 2cdb715ff32d |
child 24147 | 204ae465851d |
permissions | -rw-r--r-- |
1978
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
1 |
/* |
23268 | 2 |
* Copyright (c) 2008, 2014, Oracle and/or its affiliates. All rights reserved. |
1978
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
3 |
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
4 |
* |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
5 |
* This code is free software; you can redistribute it and/or modify it |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
6 |
* under the terms of the GNU General Public License version 2 only, as |
5506 | 7 |
* published by the Free Software Foundation. Oracle designates this |
1978
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
8 |
* particular file as subject to the "Classpath" exception as provided |
5506 | 9 |
* by Oracle in the LICENSE file that accompanied this code. |
1978
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
10 |
* |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
11 |
* This code is distributed in the hope that it will be useful, but WITHOUT |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
12 |
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
13 |
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
14 |
* version 2 for more details (a copy is included in the LICENSE file that |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
15 |
* accompanied this code). |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
16 |
* |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
17 |
* You should have received a copy of the GNU General Public License version |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
18 |
* 2 along with this work; if not, write to the Free Software Foundation, |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
19 |
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
20 |
* |
5506 | 21 |
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA |
22 |
* or visit www.oracle.com if you need additional information or have any |
|
23 |
* questions. |
|
1978
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
24 |
*/ |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
25 |
|
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
26 |
package sun.awt; |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
27 |
|
10097
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
28 |
import sun.misc.Unsafe; |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
29 |
|
1978
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
30 |
import java.awt.*; |
12047
320a714614e9
7113349: Initial changeset for Macosx port to jdk
michaelm
parents:
10097
diff
changeset
|
31 |
import java.awt.KeyboardFocusManager; |
13604 | 32 |
import java.awt.DefaultKeyboardFocusManager; |
6825 | 33 |
import java.awt.event.InputEvent; |
21246 | 34 |
import java.awt.event.InvocationEvent; |
13604 | 35 |
import java.awt.event.KeyEvent; |
2451 | 36 |
import java.awt.geom.Point2D; |
23297 | 37 |
import java.awt.image.BufferStrategy; |
3084
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
38 |
import java.awt.peer.ComponentPeer; |
16092 | 39 |
|
40 |
import java.lang.reflect.InvocationTargetException; |
|
8816
29f983feda95
6907662: System clipboard should ensure access restrictions
denis
parents:
7668
diff
changeset
|
41 |
import java.security.AccessControlContext; |
29f983feda95
6907662: System clipboard should ensure access restrictions
denis
parents:
7668
diff
changeset
|
42 |
|
12653
07d5ca30e79e
7124337: [macosx] FileDialog fails to select multiple files
dcherepanov
parents:
12047
diff
changeset
|
43 |
import java.io.File; |
20147
78e51d8fcb92
7129133: [macosx] Accelerators are displayed as Meta instead of the Command symbol
leonidr
parents:
20097
diff
changeset
|
44 |
import java.util.ResourceBundle; |
13604 | 45 |
import java.util.Vector; |
12653
07d5ca30e79e
7124337: [macosx] FileDialog fails to select multiple files
dcherepanov
parents:
12047
diff
changeset
|
46 |
|
2464
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
47 |
/** |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
48 |
* The AWTAccessor utility class. |
1978
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
49 |
* The main purpose of this class is to enable accessing |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
50 |
* private and package-private fields of classes from |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
51 |
* different classes/packages. See sun.misc.SharedSecretes |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
52 |
* for another example. |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
53 |
*/ |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
54 |
public final class AWTAccessor { |
2451 | 55 |
|
1978
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
56 |
private static final Unsafe unsafe = Unsafe.getUnsafe(); |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
57 |
|
2451 | 58 |
/* |
59 |
* We don't need any objects of this class. |
|
1978
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
60 |
* It's rather a collection of static methods |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
61 |
* and interfaces. |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
62 |
*/ |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
63 |
private AWTAccessor() { |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
64 |
} |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
65 |
|
2451 | 66 |
/* |
67 |
* An interface of accessor for the java.awt.Component class. |
|
1978
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
68 |
*/ |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
69 |
public interface ComponentAccessor { |
2451 | 70 |
/* |
71 |
* Sets whether the native background erase for a component |
|
72 |
* has been disabled via SunToolkit.disableBackgroundErase(). |
|
73 |
*/ |
|
74 |
void setBackgroundEraseDisabled(Component comp, boolean disabled); |
|
75 |
/* |
|
76 |
* Indicates whether the native background erase for a |
|
77 |
* component has been disabled via |
|
78 |
* SunToolkit.disableBackgroundErase(). |
|
79 |
*/ |
|
80 |
boolean getBackgroundEraseDisabled(Component comp); |
|
81 |
/* |
|
82 |
* |
|
83 |
* Gets the bounds of this component in the form of a |
|
84 |
* <code>Rectangle</code> object. The bounds specify this |
|
85 |
* component's width, height, and location relative to |
|
86 |
* its parent. |
|
87 |
*/ |
|
88 |
Rectangle getBounds(Component comp); |
|
89 |
/* |
|
1978
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
90 |
* Sets the shape of a lw component to cut out from hw components. |
2451 | 91 |
* |
92 |
* See 6797587, 6776743, 6768307, and 6768332 for details |
|
1978
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
93 |
*/ |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
94 |
void setMixingCutoutShape(Component comp, Shape shape); |
2459
08f3416ff334
6804747: Ensure consistent graphicsConfig member across components hierarchy
anthony
parents:
2453
diff
changeset
|
95 |
|
08f3416ff334
6804747: Ensure consistent graphicsConfig member across components hierarchy
anthony
parents:
2453
diff
changeset
|
96 |
/** |
08f3416ff334
6804747: Ensure consistent graphicsConfig member across components hierarchy
anthony
parents:
2453
diff
changeset
|
97 |
* Sets GraphicsConfiguration value for the component. |
08f3416ff334
6804747: Ensure consistent graphicsConfig member across components hierarchy
anthony
parents:
2453
diff
changeset
|
98 |
*/ |
08f3416ff334
6804747: Ensure consistent graphicsConfig member across components hierarchy
anthony
parents:
2453
diff
changeset
|
99 |
void setGraphicsConfiguration(Component comp, GraphicsConfiguration gc); |
2464
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
100 |
/* |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
101 |
* Requests focus to the component. |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
102 |
*/ |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
103 |
boolean requestFocus(Component comp, CausedFocusEvent.Cause cause); |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
104 |
/* |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
105 |
* Determines if the component can gain focus. |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
106 |
*/ |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
107 |
boolean canBeFocusOwner(Component comp); |
2472
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
108 |
|
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
109 |
/** |
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
110 |
* Returns whether the component is visible without invoking |
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
111 |
* any client code. |
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
112 |
*/ |
4371
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
113 |
boolean isVisible(Component comp); |
3084
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
114 |
|
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
115 |
/** |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
116 |
* Sets the RequestFocusController. |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
117 |
*/ |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
118 |
void setRequestFocusController(RequestFocusController requestController); |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
119 |
|
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
120 |
/** |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
121 |
* Returns the appContext of the component. |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
122 |
*/ |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
123 |
AppContext getAppContext(Component comp); |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
124 |
|
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
125 |
/** |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
126 |
* Sets the appContext of the component. |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
127 |
*/ |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
128 |
void setAppContext(Component comp, AppContext appContext); |
4371
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
129 |
|
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
130 |
/** |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
131 |
* Returns the parent of the component. |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
132 |
*/ |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
133 |
Container getParent(Component comp); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
134 |
|
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
135 |
/** |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
136 |
* Sets the parent of the component to the specified parent. |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
137 |
*/ |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
138 |
void setParent(Component comp, Container parent); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
139 |
|
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
140 |
/** |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
141 |
* Resizes the component to the specified width and height. |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
142 |
*/ |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
143 |
void setSize(Component comp, int width, int height); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
144 |
|
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
145 |
/** |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
146 |
* Returns the location of the component. |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
147 |
*/ |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
148 |
Point getLocation(Component comp); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
149 |
|
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
150 |
/** |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
151 |
* Moves the component to the new location. |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
152 |
*/ |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
153 |
void setLocation(Component comp, int x, int y); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
154 |
|
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
155 |
/** |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
156 |
* Determines whether this component is enabled. |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
157 |
*/ |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
158 |
boolean isEnabled(Component comp); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
159 |
|
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
160 |
/** |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
161 |
* Determines whether this component is displayable. |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
162 |
*/ |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
163 |
boolean isDisplayable(Component comp); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
164 |
|
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
165 |
/** |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
166 |
* Gets the cursor set in the component. |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
167 |
*/ |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
168 |
Cursor getCursor(Component comp); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
169 |
|
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
170 |
/** |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
171 |
* Returns the peer of the component. |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
172 |
*/ |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
173 |
ComponentPeer getPeer(Component comp); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
174 |
|
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
175 |
/** |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
176 |
* Sets the peer of the component to the specified peer. |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
177 |
*/ |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
178 |
void setPeer(Component comp, ComponentPeer peer); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
179 |
|
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
180 |
/** |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
181 |
* Determines whether this component is lightweight. |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
182 |
*/ |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
183 |
boolean isLightweight(Component comp); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
184 |
|
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
185 |
/** |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
186 |
* Returns whether or not paint messages received from |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
187 |
* the operating system should be ignored. |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
188 |
*/ |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
189 |
boolean getIgnoreRepaint(Component comp); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
190 |
|
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
191 |
/** |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
192 |
* Returns the width of the component. |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
193 |
*/ |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
194 |
int getWidth(Component comp); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
195 |
|
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
196 |
/** |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
197 |
* Returns the height of the component. |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
198 |
*/ |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
199 |
int getHeight(Component comp); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
200 |
|
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
201 |
/** |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
202 |
* Returns the x coordinate of the component. |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
203 |
*/ |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
204 |
int getX(Component comp); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
205 |
|
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
206 |
/** |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
207 |
* Returns the y coordinate of the component. |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
208 |
*/ |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
209 |
int getY(Component comp); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
210 |
|
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
211 |
/** |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
212 |
* Gets the foreground color of this component. |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
213 |
*/ |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
214 |
Color getForeground(Component comp); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
215 |
|
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
216 |
/** |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
217 |
* Gets the background color of this component. |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
218 |
*/ |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
219 |
Color getBackground(Component comp); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
220 |
|
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
221 |
/** |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
222 |
* Sets the background of this component to the specified color. |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
223 |
*/ |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
224 |
void setBackground(Component comp, Color background); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
225 |
|
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
226 |
/** |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
227 |
* Gets the font of the component. |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
228 |
*/ |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
229 |
Font getFont(Component comp); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
230 |
|
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
231 |
/** |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
232 |
* Processes events occurring on this component. |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
233 |
*/ |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
234 |
void processEvent(Component comp, AWTEvent e); |
8816
29f983feda95
6907662: System clipboard should ensure access restrictions
denis
parents:
7668
diff
changeset
|
235 |
|
29f983feda95
6907662: System clipboard should ensure access restrictions
denis
parents:
7668
diff
changeset
|
236 |
|
29f983feda95
6907662: System clipboard should ensure access restrictions
denis
parents:
7668
diff
changeset
|
237 |
/* |
29f983feda95
6907662: System clipboard should ensure access restrictions
denis
parents:
7668
diff
changeset
|
238 |
* Returns the acc this component was constructed with. |
29f983feda95
6907662: System clipboard should ensure access restrictions
denis
parents:
7668
diff
changeset
|
239 |
*/ |
29f983feda95
6907662: System clipboard should ensure access restrictions
denis
parents:
7668
diff
changeset
|
240 |
AccessControlContext getAccessControlContext(Component comp); |
29f983feda95
6907662: System clipboard should ensure access restrictions
denis
parents:
7668
diff
changeset
|
241 |
|
20097
a4a07c4ead5f
8023474: First mousepress doesn't start editing in JTree
dmarkov
parents:
17899
diff
changeset
|
242 |
/** |
a4a07c4ead5f
8023474: First mousepress doesn't start editing in JTree
dmarkov
parents:
17899
diff
changeset
|
243 |
* Revalidates the component synchronously. |
a4a07c4ead5f
8023474: First mousepress doesn't start editing in JTree
dmarkov
parents:
17899
diff
changeset
|
244 |
*/ |
a4a07c4ead5f
8023474: First mousepress doesn't start editing in JTree
dmarkov
parents:
17899
diff
changeset
|
245 |
void revalidateSynchronously(Component comp); |
a4a07c4ead5f
8023474: First mousepress doesn't start editing in JTree
dmarkov
parents:
17899
diff
changeset
|
246 |
|
23297 | 247 |
/** |
248 |
* Creates a new strategy for multi-buffering on this component. |
|
249 |
*/ |
|
250 |
void createBufferStrategy(Component comp, int numBuffers, |
|
251 |
BufferCapabilities caps) throws AWTException; |
|
252 |
||
253 |
/** |
|
254 |
* returns the buffer strategy used by this component. |
|
255 |
*/ |
|
256 |
BufferStrategy getBufferStrategy(Component comp); |
|
1978
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
257 |
} |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
258 |
|
2451 | 259 |
/* |
7241
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
260 |
* An interface of accessor for the java.awt.Container class. |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
261 |
*/ |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
262 |
public interface ContainerAccessor { |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
263 |
/** |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
264 |
* Validates the container unconditionally. |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
265 |
*/ |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
266 |
void validateUnconditionally(Container cont); |
20165
75e673bbdba6
8007155: [macosx] Disabled panel takes mouse input in JLayeredPane
alexsch
parents:
20147
diff
changeset
|
267 |
|
75e673bbdba6
8007155: [macosx] Disabled panel takes mouse input in JLayeredPane
alexsch
parents:
20147
diff
changeset
|
268 |
/** |
75e673bbdba6
8007155: [macosx] Disabled panel takes mouse input in JLayeredPane
alexsch
parents:
20147
diff
changeset
|
269 |
* |
75e673bbdba6
8007155: [macosx] Disabled panel takes mouse input in JLayeredPane
alexsch
parents:
20147
diff
changeset
|
270 |
* Access to the private version of findComponentAt method which has |
75e673bbdba6
8007155: [macosx] Disabled panel takes mouse input in JLayeredPane
alexsch
parents:
20147
diff
changeset
|
271 |
* a controllable behavior. Setting 'ignoreEnabled' to 'false' |
75e673bbdba6
8007155: [macosx] Disabled panel takes mouse input in JLayeredPane
alexsch
parents:
20147
diff
changeset
|
272 |
* bypasses disabled Components during the search. |
75e673bbdba6
8007155: [macosx] Disabled panel takes mouse input in JLayeredPane
alexsch
parents:
20147
diff
changeset
|
273 |
*/ |
75e673bbdba6
8007155: [macosx] Disabled panel takes mouse input in JLayeredPane
alexsch
parents:
20147
diff
changeset
|
274 |
Component findComponentAt(Container cont, int x, int y, boolean ignoreEnabled); |
7241
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
275 |
} |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
276 |
|
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
277 |
/* |
2451 | 278 |
* An interface of accessor for java.awt.Window class. |
279 |
*/ |
|
280 |
public interface WindowAccessor { |
|
281 |
/* |
|
282 |
* Get opacity level of the given window. |
|
283 |
*/ |
|
284 |
float getOpacity(Window window); |
|
285 |
/* |
|
286 |
* Set opacity level to the given window. |
|
287 |
*/ |
|
288 |
void setOpacity(Window window, float opacity); |
|
289 |
/* |
|
290 |
* Get a shape assigned to the given window. |
|
291 |
*/ |
|
292 |
Shape getShape(Window window); |
|
293 |
/* |
|
294 |
* Set a shape to the given window. |
|
295 |
*/ |
|
296 |
void setShape(Window window, Shape shape); |
|
297 |
/* |
|
298 |
* Set the opaque preoperty to the given window. |
|
299 |
*/ |
|
300 |
void setOpaque(Window window, boolean isOpaque); |
|
301 |
/* |
|
302 |
* Update the image of a non-opaque (translucent) window. |
|
303 |
*/ |
|
2808
a139a919f645
6794764: Translucent windows are completely repainted on every paint event, on Windows
art
parents:
2472
diff
changeset
|
304 |
void updateWindow(Window window); |
2472
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
305 |
|
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
306 |
/** Get the size of the security warning. |
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
307 |
*/ |
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
308 |
Dimension getSecurityWarningSize(Window w); |
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
309 |
|
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
310 |
/** |
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
311 |
* Set the size of the security warning. |
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
312 |
*/ |
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
313 |
void setSecurityWarningSize(Window w, int width, int height); |
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
314 |
|
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
315 |
/** Set the position of the security warning. |
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
316 |
*/ |
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
317 |
void setSecurityWarningPosition(Window w, Point2D point, |
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
318 |
float alignmentX, float alignmentY); |
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
319 |
|
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
320 |
/** Request to recalculate the new position of the security warning for |
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
321 |
* the given window size/location as reported by the native system. |
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
322 |
*/ |
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
323 |
Point2D calculateSecurityWarningPosition(Window window, |
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
324 |
double x, double y, double w, double h); |
3084
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
325 |
|
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
326 |
/** Sets the synchronous status of focus requests on lightweight |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
327 |
* components in the specified window to the specified value. |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
328 |
*/ |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
329 |
void setLWRequestStatus(Window changed, boolean status); |
4371
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
330 |
|
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
331 |
/** |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
332 |
* Indicates whether this window should receive focus on subsequently |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
333 |
* being shown, or being moved to the front. |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
334 |
*/ |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
335 |
boolean isAutoRequestFocus(Window w); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
336 |
|
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
337 |
/** |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
338 |
* Indicates whether the specified window is an utility window for TrayIcon. |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
339 |
*/ |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
340 |
boolean isTrayIconWindow(Window w); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
341 |
|
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
342 |
/** |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
343 |
* Marks the specified window as an utility window for TrayIcon. |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
344 |
*/ |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
345 |
void setTrayIconWindow(Window w, boolean isTrayIconWindow); |
2451 | 346 |
} |
347 |
||
13604 | 348 |
/** |
2451 | 349 |
* An accessor for the AWTEvent class. |
350 |
*/ |
|
351 |
public interface AWTEventAccessor { |
|
3084
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
352 |
/** |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
353 |
* Marks the event as posted. |
2451 | 354 |
*/ |
3084
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
355 |
void setPosted(AWTEvent ev); |
6826
1fc6a05552f2
6991992: Need to forward-port AWT's part of the fix for 6691674
dcherepanov
parents:
6825
diff
changeset
|
356 |
|
1fc6a05552f2
6991992: Need to forward-port AWT's part of the fix for 6691674
dcherepanov
parents:
6825
diff
changeset
|
357 |
/** |
1fc6a05552f2
6991992: Need to forward-port AWT's part of the fix for 6691674
dcherepanov
parents:
6825
diff
changeset
|
358 |
* Sets the flag on this AWTEvent indicating that it was |
1fc6a05552f2
6991992: Need to forward-port AWT's part of the fix for 6691674
dcherepanov
parents:
6825
diff
changeset
|
359 |
* generated by the system. |
1fc6a05552f2
6991992: Need to forward-port AWT's part of the fix for 6691674
dcherepanov
parents:
6825
diff
changeset
|
360 |
*/ |
1fc6a05552f2
6991992: Need to forward-port AWT's part of the fix for 6691674
dcherepanov
parents:
6825
diff
changeset
|
361 |
void setSystemGenerated(AWTEvent ev); |
1fc6a05552f2
6991992: Need to forward-port AWT's part of the fix for 6691674
dcherepanov
parents:
6825
diff
changeset
|
362 |
|
1fc6a05552f2
6991992: Need to forward-port AWT's part of the fix for 6691674
dcherepanov
parents:
6825
diff
changeset
|
363 |
/** |
1fc6a05552f2
6991992: Need to forward-port AWT's part of the fix for 6691674
dcherepanov
parents:
6825
diff
changeset
|
364 |
* Indicates whether this AWTEvent was generated by the system. |
1fc6a05552f2
6991992: Need to forward-port AWT's part of the fix for 6691674
dcherepanov
parents:
6825
diff
changeset
|
365 |
*/ |
1fc6a05552f2
6991992: Need to forward-port AWT's part of the fix for 6691674
dcherepanov
parents:
6825
diff
changeset
|
366 |
boolean isSystemGenerated(AWTEvent ev); |
8816
29f983feda95
6907662: System clipboard should ensure access restrictions
denis
parents:
7668
diff
changeset
|
367 |
|
13604 | 368 |
/** |
8816
29f983feda95
6907662: System clipboard should ensure access restrictions
denis
parents:
7668
diff
changeset
|
369 |
* Returns the acc this event was constructed with. |
29f983feda95
6907662: System clipboard should ensure access restrictions
denis
parents:
7668
diff
changeset
|
370 |
*/ |
29f983feda95
6907662: System clipboard should ensure access restrictions
denis
parents:
7668
diff
changeset
|
371 |
AccessControlContext getAccessControlContext(AWTEvent ev); |
29f983feda95
6907662: System clipboard should ensure access restrictions
denis
parents:
7668
diff
changeset
|
372 |
|
13604 | 373 |
/** |
374 |
* Returns binary data associated with this event; |
|
375 |
*/ |
|
376 |
byte[] getBData(AWTEvent ev); |
|
377 |
||
378 |
/** |
|
379 |
* Associates binary data with this event; |
|
380 |
*/ |
|
381 |
void setBData(AWTEvent ev, byte[] bdata); |
|
2451 | 382 |
} |
383 |
||
6825 | 384 |
public interface InputEventAccessor { |
385 |
/* |
|
386 |
* Accessor for InputEvent.getButtonDownMasks() |
|
387 |
*/ |
|
388 |
int[] getButtonDownMasks(); |
|
23297 | 389 |
|
390 |
/* |
|
391 |
* Accessor for InputEvent.canAccessSystemClipboard field |
|
392 |
*/ |
|
393 |
boolean canAccessSystemClipboard(InputEvent event); |
|
6825 | 394 |
} |
395 |
||
2451 | 396 |
/* |
2453
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
397 |
* An accessor for the java.awt.Frame class. |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
398 |
*/ |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
399 |
public interface FrameAccessor { |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
400 |
/* |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
401 |
* Sets the state of this frame. |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
402 |
*/ |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
403 |
void setExtendedState(Frame frame, int state); |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
404 |
/* |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
405 |
* Gets the state of this frame. |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
406 |
*/ |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
407 |
int getExtendedState(Frame frame); |
7239
514eb274caa1
6699851: setMaximizedbounds not working properly on dual screen environment
dcherepanov
parents:
6826
diff
changeset
|
408 |
/* |
514eb274caa1
6699851: setMaximizedbounds not working properly on dual screen environment
dcherepanov
parents:
6826
diff
changeset
|
409 |
* Gets the maximized bounds of this frame. |
514eb274caa1
6699851: setMaximizedbounds not working properly on dual screen environment
dcherepanov
parents:
6826
diff
changeset
|
410 |
*/ |
514eb274caa1
6699851: setMaximizedbounds not working properly on dual screen environment
dcherepanov
parents:
6826
diff
changeset
|
411 |
Rectangle getMaximizedBounds(Frame frame); |
2453
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
412 |
} |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
413 |
|
13604 | 414 |
/** |
2465 | 415 |
* An interface of accessor for the java.awt.KeyboardFocusManager class. |
2464
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
416 |
*/ |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
417 |
public interface KeyboardFocusManagerAccessor { |
13604 | 418 |
/** |
2464
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
419 |
* Indicates whether the native implementation should |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
420 |
* proceed with a pending focus request for the heavyweight. |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
421 |
*/ |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
422 |
int shouldNativelyFocusHeavyweight(Component heavyweight, |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
423 |
Component descendant, |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
424 |
boolean temporary, |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
425 |
boolean focusedWindowChangeAllowed, |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
426 |
long time, |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
427 |
CausedFocusEvent.Cause cause); |
13604 | 428 |
/** |
2464
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
429 |
* Delivers focus for the lightweight descendant of the heavyweight |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
430 |
* synchronously. |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
431 |
*/ |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
432 |
boolean processSynchronousLightweightTransfer(Component heavyweight, |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
433 |
Component descendant, |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
434 |
boolean temporary, |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
435 |
boolean focusedWindowChangeAllowed, |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
436 |
long time); |
13604 | 437 |
/** |
2464
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
438 |
* Removes the last focus request for the heavyweight from the queue. |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
439 |
*/ |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
440 |
void removeLastFocusRequest(Component heavyweight); |
6634
439221465ac5
6505819: Provide traverseIn method for sun.awt.EmbeddedFrame
ant
parents:
5506
diff
changeset
|
441 |
|
13604 | 442 |
/** |
6634
439221465ac5
6505819: Provide traverseIn method for sun.awt.EmbeddedFrame
ant
parents:
5506
diff
changeset
|
443 |
* Sets the most recent focus owner in the window. |
439221465ac5
6505819: Provide traverseIn method for sun.awt.EmbeddedFrame
ant
parents:
5506
diff
changeset
|
444 |
*/ |
439221465ac5
6505819: Provide traverseIn method for sun.awt.EmbeddedFrame
ant
parents:
5506
diff
changeset
|
445 |
void setMostRecentFocusOwner(Window window, Component component); |
12047
320a714614e9
7113349: Initial changeset for Macosx port to jdk
michaelm
parents:
10097
diff
changeset
|
446 |
|
13604 | 447 |
/** |
12047
320a714614e9
7113349: Initial changeset for Macosx port to jdk
michaelm
parents:
10097
diff
changeset
|
448 |
* Returns current KFM of the specified AppContext. |
320a714614e9
7113349: Initial changeset for Macosx port to jdk
michaelm
parents:
10097
diff
changeset
|
449 |
*/ |
320a714614e9
7113349: Initial changeset for Macosx port to jdk
michaelm
parents:
10097
diff
changeset
|
450 |
KeyboardFocusManager getCurrentKeyboardFocusManager(AppContext ctx); |
13604 | 451 |
|
452 |
/** |
|
453 |
* Return the current focus cycle root |
|
454 |
*/ |
|
455 |
Container getCurrentFocusCycleRoot(); |
|
2464
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
456 |
} |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
457 |
|
13604 | 458 |
/** |
3084
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
459 |
* An accessor for the MenuComponent class. |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
460 |
*/ |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
461 |
public interface MenuComponentAccessor { |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
462 |
/** |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
463 |
* Returns the appContext of the menu component. |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
464 |
*/ |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
465 |
AppContext getAppContext(MenuComponent menuComp); |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
466 |
|
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
467 |
/** |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
468 |
* Sets the appContext of the menu component. |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
469 |
*/ |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
470 |
void setAppContext(MenuComponent menuComp, AppContext appContext); |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
471 |
|
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
472 |
/** |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
473 |
* Returns the menu container of the menu component |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
474 |
*/ |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
475 |
MenuContainer getParent(MenuComponent menuComp); |
13604 | 476 |
|
477 |
/** |
|
478 |
* Gets the font used for this menu component. |
|
479 |
*/ |
|
480 |
Font getFont_NoClientCode(MenuComponent menuComp); |
|
3084
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
481 |
} |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
482 |
|
13604 | 483 |
/** |
3084
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
484 |
* An accessor for the EventQueue class |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
485 |
*/ |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
486 |
public interface EventQueueAccessor { |
13604 | 487 |
/** |
3084
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
488 |
* Gets the event dispatch thread. |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
489 |
*/ |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
490 |
Thread getDispatchThread(EventQueue eventQueue); |
13604 | 491 |
|
492 |
/** |
|
4365 | 493 |
* Checks if the current thread is EDT for the given EQ. |
494 |
*/ |
|
495 |
public boolean isDispatchThreadImpl(EventQueue eventQueue); |
|
13604 | 496 |
|
497 |
/** |
|
498 |
* Removes any pending events for the specified source object. |
|
499 |
*/ |
|
500 |
void removeSourceEvents(EventQueue eventQueue, Object source, boolean removeAllEvents); |
|
501 |
||
502 |
/** |
|
503 |
* Returns whether an event is pending on any of the separate Queues. |
|
504 |
*/ |
|
505 |
boolean noEvents(EventQueue eventQueue); |
|
506 |
||
507 |
/** |
|
508 |
* Called from PostEventQueue.postEvent to notify that a new event |
|
509 |
* appeared. |
|
510 |
*/ |
|
511 |
void wakeup(EventQueue eventQueue, boolean isShutdown); |
|
16092 | 512 |
|
513 |
/** |
|
514 |
* Static in EventQueue |
|
515 |
*/ |
|
516 |
void invokeAndWait(Object source, Runnable r) |
|
517 |
throws InterruptedException, InvocationTargetException; |
|
17899 | 518 |
|
519 |
/** |
|
520 |
* Sets the delegate for the EventQueue used by FX/AWT single threaded mode |
|
521 |
*/ |
|
522 |
public void setFwDispatcher(EventQueue eventQueue, FwDispatcher dispatcher); |
|
3084
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
523 |
} |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
524 |
|
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
525 |
/* |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
526 |
* An accessor for the PopupMenu class |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
527 |
*/ |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
528 |
public interface PopupMenuAccessor { |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
529 |
/* |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
530 |
* Returns whether the popup menu is attached to a tray |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
531 |
*/ |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
532 |
boolean isTrayIconPopup(PopupMenu popupMenu); |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
533 |
} |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
534 |
|
4913
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
535 |
/* |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
536 |
* An accessor for the FileDialog class |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
537 |
*/ |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
538 |
public interface FileDialogAccessor { |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
539 |
/* |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
540 |
* Sets the files the user selects |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
541 |
*/ |
12653
07d5ca30e79e
7124337: [macosx] FileDialog fails to select multiple files
dcherepanov
parents:
12047
diff
changeset
|
542 |
void setFiles(FileDialog fileDialog, File files[]); |
4913
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
543 |
|
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
544 |
/* |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
545 |
* Sets the file the user selects |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
546 |
*/ |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
547 |
void setFile(FileDialog fileDialog, String file); |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
548 |
|
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
549 |
/* |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
550 |
* Sets the directory the user selects |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
551 |
*/ |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
552 |
void setDirectory(FileDialog fileDialog, String directory); |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
553 |
|
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
554 |
/* |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
555 |
* Returns whether the file dialog allows the multiple file selection. |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
556 |
*/ |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
557 |
boolean isMultipleMode(FileDialog fileDialog); |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
558 |
} |
3084
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
559 |
|
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
560 |
/* |
10097
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
561 |
* An accessor for the ScrollPaneAdjustable class. |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
562 |
*/ |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
563 |
public interface ScrollPaneAdjustableAccessor { |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
564 |
/* |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
565 |
* Sets the value of this scrollbar to the specified value. |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
566 |
*/ |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
567 |
void setTypedValue(final ScrollPaneAdjustable adj, final int v, |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
568 |
final int type); |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
569 |
} |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
570 |
|
13604 | 571 |
/** |
572 |
* An accessor for the CheckboxMenuItem class |
|
573 |
*/ |
|
574 |
public interface CheckboxMenuItemAccessor { |
|
575 |
/** |
|
576 |
* Returns whether menu item is checked |
|
577 |
*/ |
|
578 |
boolean getState(CheckboxMenuItem cmi); |
|
579 |
} |
|
580 |
||
581 |
/** |
|
582 |
* An accessor for the Cursor class |
|
583 |
*/ |
|
584 |
public interface CursorAccessor { |
|
585 |
/** |
|
586 |
* Returns pData of the Cursor class |
|
587 |
*/ |
|
588 |
long getPData(Cursor cursor); |
|
589 |
||
590 |
/** |
|
591 |
* Sets pData to the Cursor class |
|
592 |
*/ |
|
593 |
void setPData(Cursor cursor, long pData); |
|
594 |
||
595 |
/** |
|
596 |
* Return type of the Cursor class |
|
597 |
*/ |
|
598 |
int getType(Cursor cursor); |
|
599 |
} |
|
600 |
||
601 |
/** |
|
602 |
* An accessor for the MenuBar class |
|
603 |
*/ |
|
604 |
public interface MenuBarAccessor { |
|
605 |
/** |
|
606 |
* Returns help menu |
|
607 |
*/ |
|
608 |
Menu getHelpMenu(MenuBar menuBar); |
|
609 |
||
610 |
/** |
|
611 |
* Returns menus |
|
612 |
*/ |
|
613 |
Vector getMenus(MenuBar menuBar); |
|
614 |
} |
|
615 |
||
616 |
/** |
|
617 |
* An accessor for the MenuItem class |
|
618 |
*/ |
|
619 |
public interface MenuItemAccessor { |
|
620 |
/** |
|
621 |
* Returns whether menu item is enabled |
|
622 |
*/ |
|
623 |
boolean isEnabled(MenuItem item); |
|
624 |
||
625 |
/** |
|
626 |
* Gets the command name of the action event that is fired |
|
627 |
* by this menu item. |
|
628 |
*/ |
|
629 |
String getActionCommandImpl(MenuItem item); |
|
630 |
||
631 |
/** |
|
632 |
* Returns true if the item and all its ancestors are |
|
633 |
* enabled, false otherwise |
|
634 |
*/ |
|
635 |
boolean isItemEnabled(MenuItem item); |
|
636 |
||
637 |
/** |
|
638 |
* Returns label |
|
639 |
*/ |
|
640 |
String getLabel(MenuItem item); |
|
641 |
||
642 |
/** |
|
643 |
* Returns shortcut |
|
644 |
*/ |
|
645 |
MenuShortcut getShortcut(MenuItem item); |
|
646 |
} |
|
647 |
||
648 |
/** |
|
649 |
* An accessor for the Menu class |
|
650 |
*/ |
|
651 |
public interface MenuAccessor { |
|
652 |
/** |
|
653 |
* Returns vector of the items that are part of the Menu |
|
654 |
*/ |
|
655 |
Vector getItems(Menu menu); |
|
656 |
} |
|
657 |
||
658 |
/** |
|
659 |
* An accessor for the KeyEvent class |
|
660 |
*/ |
|
661 |
public interface KeyEventAccessor { |
|
662 |
/** |
|
663 |
* Sets rawCode field for KeyEvent |
|
664 |
*/ |
|
665 |
void setRawCode(KeyEvent ev, long rawCode); |
|
666 |
||
667 |
/** |
|
668 |
* Sets primaryLevelUnicode field for KeyEvent |
|
669 |
*/ |
|
670 |
void setPrimaryLevelUnicode(KeyEvent ev, long primaryLevelUnicode); |
|
671 |
||
672 |
/** |
|
673 |
* Sets extendedKeyCode field for KeyEvent |
|
674 |
*/ |
|
675 |
void setExtendedKeyCode(KeyEvent ev, long extendedKeyCode); |
|
14310
708173457cc0
8001633: Wrong alt processing during switching between windows.
alexp
parents:
13656
diff
changeset
|
676 |
|
708173457cc0
8001633: Wrong alt processing during switching between windows.
alexp
parents:
13656
diff
changeset
|
677 |
/** |
708173457cc0
8001633: Wrong alt processing during switching between windows.
alexp
parents:
13656
diff
changeset
|
678 |
* Gets original source for KeyEvent |
708173457cc0
8001633: Wrong alt processing during switching between windows.
alexp
parents:
13656
diff
changeset
|
679 |
*/ |
708173457cc0
8001633: Wrong alt processing during switching between windows.
alexp
parents:
13656
diff
changeset
|
680 |
Component getOriginalSource(KeyEvent ev); |
13604 | 681 |
} |
682 |
||
683 |
/** |
|
684 |
* An accessor for the ClientPropertyKey class |
|
685 |
*/ |
|
686 |
public interface ClientPropertyKeyAccessor { |
|
687 |
/** |
|
688 |
* Retrieves JComponent_TRANSFER_HANDLER enum object |
|
689 |
*/ |
|
690 |
Object getJComponent_TRANSFER_HANDLER(); |
|
691 |
} |
|
692 |
||
693 |
/** |
|
694 |
* An accessor for the SystemTray class |
|
695 |
*/ |
|
696 |
public interface SystemTrayAccessor { |
|
697 |
/** |
|
698 |
* Support for reporting bound property changes for Object properties. |
|
699 |
*/ |
|
700 |
void firePropertyChange(SystemTray tray, String propertyName, Object oldValue, Object newValue); |
|
701 |
} |
|
702 |
||
703 |
/** |
|
704 |
* An accessor for the TrayIcon class |
|
705 |
*/ |
|
706 |
public interface TrayIconAccessor { |
|
707 |
void addNotify(TrayIcon trayIcon) throws AWTException; |
|
708 |
void removeNotify(TrayIcon trayIcon); |
|
709 |
} |
|
710 |
||
711 |
/** |
|
712 |
* An accessor for the DefaultKeyboardFocusManager class |
|
713 |
*/ |
|
714 |
public interface DefaultKeyboardFocusManagerAccessor { |
|
715 |
public void consumeNextKeyTyped(DefaultKeyboardFocusManager dkfm, KeyEvent e); |
|
716 |
} |
|
717 |
||
10097
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
718 |
/* |
13652
42544e68dc39
6981400: Tabbing between textfield do not work properly when ALT+TAB
ant
parents:
12653
diff
changeset
|
719 |
* An accessor for the SequencedEventAccessor class |
42544e68dc39
6981400: Tabbing between textfield do not work properly when ALT+TAB
ant
parents:
12653
diff
changeset
|
720 |
*/ |
42544e68dc39
6981400: Tabbing between textfield do not work properly when ALT+TAB
ant
parents:
12653
diff
changeset
|
721 |
public interface SequencedEventAccessor { |
42544e68dc39
6981400: Tabbing between textfield do not work properly when ALT+TAB
ant
parents:
12653
diff
changeset
|
722 |
/* |
42544e68dc39
6981400: Tabbing between textfield do not work properly when ALT+TAB
ant
parents:
12653
diff
changeset
|
723 |
* Returns the nested event. |
42544e68dc39
6981400: Tabbing between textfield do not work properly when ALT+TAB
ant
parents:
12653
diff
changeset
|
724 |
*/ |
42544e68dc39
6981400: Tabbing between textfield do not work properly when ALT+TAB
ant
parents:
12653
diff
changeset
|
725 |
AWTEvent getNested(AWTEvent sequencedEvent); |
42544e68dc39
6981400: Tabbing between textfield do not work properly when ALT+TAB
ant
parents:
12653
diff
changeset
|
726 |
|
42544e68dc39
6981400: Tabbing between textfield do not work properly when ALT+TAB
ant
parents:
12653
diff
changeset
|
727 |
/* |
42544e68dc39
6981400: Tabbing between textfield do not work properly when ALT+TAB
ant
parents:
12653
diff
changeset
|
728 |
* Returns true if the event is an instances of SequencedEvent. |
42544e68dc39
6981400: Tabbing between textfield do not work properly when ALT+TAB
ant
parents:
12653
diff
changeset
|
729 |
*/ |
42544e68dc39
6981400: Tabbing between textfield do not work properly when ALT+TAB
ant
parents:
12653
diff
changeset
|
730 |
boolean isSequencedEvent(AWTEvent event); |
42544e68dc39
6981400: Tabbing between textfield do not work properly when ALT+TAB
ant
parents:
12653
diff
changeset
|
731 |
} |
42544e68dc39
6981400: Tabbing between textfield do not work properly when ALT+TAB
ant
parents:
12653
diff
changeset
|
732 |
|
42544e68dc39
6981400: Tabbing between textfield do not work properly when ALT+TAB
ant
parents:
12653
diff
changeset
|
733 |
/* |
20147
78e51d8fcb92
7129133: [macosx] Accelerators are displayed as Meta instead of the Command symbol
leonidr
parents:
20097
diff
changeset
|
734 |
* An accessor for the Toolkit class |
78e51d8fcb92
7129133: [macosx] Accelerators are displayed as Meta instead of the Command symbol
leonidr
parents:
20097
diff
changeset
|
735 |
*/ |
78e51d8fcb92
7129133: [macosx] Accelerators are displayed as Meta instead of the Command symbol
leonidr
parents:
20097
diff
changeset
|
736 |
public interface ToolkitAccessor { |
78e51d8fcb92
7129133: [macosx] Accelerators are displayed as Meta instead of the Command symbol
leonidr
parents:
20097
diff
changeset
|
737 |
void setPlatformResources(ResourceBundle bundle); |
78e51d8fcb92
7129133: [macosx] Accelerators are displayed as Meta instead of the Command symbol
leonidr
parents:
20097
diff
changeset
|
738 |
} |
78e51d8fcb92
7129133: [macosx] Accelerators are displayed as Meta instead of the Command symbol
leonidr
parents:
20097
diff
changeset
|
739 |
|
78e51d8fcb92
7129133: [macosx] Accelerators are displayed as Meta instead of the Command symbol
leonidr
parents:
20097
diff
changeset
|
740 |
/* |
21246 | 741 |
* An accessor object for the InvocationEvent class |
742 |
*/ |
|
743 |
public interface InvocationEventAccessor { |
|
744 |
void dispose(InvocationEvent event); |
|
745 |
} |
|
746 |
||
747 |
/* |
|
23268 | 748 |
* An accessor object for the SystemColor class |
749 |
*/ |
|
750 |
public interface SystemColorAccessor { |
|
751 |
void updateSystemColors(); |
|
752 |
} |
|
753 |
||
754 |
/* |
|
7241
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
755 |
* Accessor instances are initialized in the static initializers of |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
756 |
* corresponding AWT classes by using setters defined below. |
1978
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
757 |
*/ |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
758 |
private static ComponentAccessor componentAccessor; |
7241
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
759 |
private static ContainerAccessor containerAccessor; |
2451 | 760 |
private static WindowAccessor windowAccessor; |
761 |
private static AWTEventAccessor awtEventAccessor; |
|
6825 | 762 |
private static InputEventAccessor inputEventAccessor; |
2453
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
763 |
private static FrameAccessor frameAccessor; |
2464
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
764 |
private static KeyboardFocusManagerAccessor kfmAccessor; |
3084
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
765 |
private static MenuComponentAccessor menuComponentAccessor; |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
766 |
private static EventQueueAccessor eventQueueAccessor; |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
767 |
private static PopupMenuAccessor popupMenuAccessor; |
4913
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
768 |
private static FileDialogAccessor fileDialogAccessor; |
10097
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
769 |
private static ScrollPaneAdjustableAccessor scrollPaneAdjustableAccessor; |
13604 | 770 |
private static CheckboxMenuItemAccessor checkboxMenuItemAccessor; |
771 |
private static CursorAccessor cursorAccessor; |
|
772 |
private static MenuBarAccessor menuBarAccessor; |
|
773 |
private static MenuItemAccessor menuItemAccessor; |
|
774 |
private static MenuAccessor menuAccessor; |
|
775 |
private static KeyEventAccessor keyEventAccessor; |
|
776 |
private static ClientPropertyKeyAccessor clientPropertyKeyAccessor; |
|
777 |
private static SystemTrayAccessor systemTrayAccessor; |
|
778 |
private static TrayIconAccessor trayIconAccessor; |
|
779 |
private static DefaultKeyboardFocusManagerAccessor defaultKeyboardFocusManagerAccessor; |
|
13652
42544e68dc39
6981400: Tabbing between textfield do not work properly when ALT+TAB
ant
parents:
12653
diff
changeset
|
780 |
private static SequencedEventAccessor sequencedEventAccessor; |
20147
78e51d8fcb92
7129133: [macosx] Accelerators are displayed as Meta instead of the Command symbol
leonidr
parents:
20097
diff
changeset
|
781 |
private static ToolkitAccessor toolkitAccessor; |
21246 | 782 |
private static InvocationEventAccessor invocationEventAccessor; |
23268 | 783 |
private static SystemColorAccessor systemColorAccessor; |
4913
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
784 |
|
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
785 |
/* |
2451 | 786 |
* Set an accessor object for the java.awt.Component class. |
1978
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
787 |
*/ |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
788 |
public static void setComponentAccessor(ComponentAccessor ca) { |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
789 |
componentAccessor = ca; |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
790 |
} |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
791 |
|
2451 | 792 |
/* |
7241
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
793 |
* Retrieve the accessor object for the java.awt.Component class. |
1978
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
794 |
*/ |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
795 |
public static ComponentAccessor getComponentAccessor() { |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
796 |
if (componentAccessor == null) { |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
797 |
unsafe.ensureClassInitialized(Component.class); |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
798 |
} |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
799 |
|
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
800 |
return componentAccessor; |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
801 |
} |
2451 | 802 |
|
803 |
/* |
|
7241
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
804 |
* Set an accessor object for the java.awt.Container class. |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
805 |
*/ |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
806 |
public static void setContainerAccessor(ContainerAccessor ca) { |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
807 |
containerAccessor = ca; |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
808 |
} |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
809 |
|
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
810 |
/* |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
811 |
* Retrieve the accessor object for the java.awt.Container class. |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
812 |
*/ |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
813 |
public static ContainerAccessor getContainerAccessor() { |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
814 |
if (containerAccessor == null) { |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
815 |
unsafe.ensureClassInitialized(Container.class); |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
816 |
} |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
817 |
|
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
818 |
return containerAccessor; |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
819 |
} |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
820 |
|
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
821 |
/* |
2451 | 822 |
* Set an accessor object for the java.awt.Window class. |
823 |
*/ |
|
824 |
public static void setWindowAccessor(WindowAccessor wa) { |
|
825 |
windowAccessor = wa; |
|
826 |
} |
|
827 |
||
828 |
/* |
|
829 |
* Retrieve the accessor object for the java.awt.Window class. |
|
830 |
*/ |
|
831 |
public static WindowAccessor getWindowAccessor() { |
|
832 |
if (windowAccessor == null) { |
|
833 |
unsafe.ensureClassInitialized(Window.class); |
|
834 |
} |
|
835 |
return windowAccessor; |
|
836 |
} |
|
837 |
||
838 |
/* |
|
839 |
* Set an accessor object for the java.awt.AWTEvent class. |
|
840 |
*/ |
|
841 |
public static void setAWTEventAccessor(AWTEventAccessor aea) { |
|
842 |
awtEventAccessor = aea; |
|
843 |
} |
|
844 |
||
845 |
/* |
|
846 |
* Retrieve the accessor object for the java.awt.AWTEvent class. |
|
847 |
*/ |
|
848 |
public static AWTEventAccessor getAWTEventAccessor() { |
|
3084
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
849 |
if (awtEventAccessor == null) { |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
850 |
unsafe.ensureClassInitialized(AWTEvent.class); |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
851 |
} |
2451 | 852 |
return awtEventAccessor; |
853 |
} |
|
2453
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
854 |
|
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
855 |
/* |
6825 | 856 |
* Set an accessor object for the java.awt.event.InputEvent class. |
857 |
*/ |
|
858 |
public static void setInputEventAccessor(InputEventAccessor iea) { |
|
859 |
inputEventAccessor = iea; |
|
860 |
} |
|
861 |
||
862 |
/* |
|
863 |
* Retrieve the accessor object for the java.awt.event.InputEvent class. |
|
864 |
*/ |
|
865 |
public static InputEventAccessor getInputEventAccessor() { |
|
866 |
if (inputEventAccessor == null) { |
|
867 |
unsafe.ensureClassInitialized(InputEvent.class); |
|
868 |
} |
|
869 |
return inputEventAccessor; |
|
870 |
} |
|
871 |
||
872 |
/* |
|
2453
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
873 |
* Set an accessor object for the java.awt.Frame class. |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
874 |
*/ |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
875 |
public static void setFrameAccessor(FrameAccessor fa) { |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
876 |
frameAccessor = fa; |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
877 |
} |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
878 |
|
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
879 |
/* |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
880 |
* Retrieve the accessor object for the java.awt.Frame class. |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
881 |
*/ |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
882 |
public static FrameAccessor getFrameAccessor() { |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
883 |
if (frameAccessor == null) { |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
884 |
unsafe.ensureClassInitialized(Frame.class); |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
885 |
} |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
886 |
return frameAccessor; |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
887 |
} |
2464
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
888 |
|
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
889 |
/* |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
890 |
* Set an accessor object for the java.awt.KeyboardFocusManager class. |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
891 |
*/ |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
892 |
public static void setKeyboardFocusManagerAccessor(KeyboardFocusManagerAccessor kfma) { |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
893 |
kfmAccessor = kfma; |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
894 |
} |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
895 |
|
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
896 |
/* |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
897 |
* Retrieve the accessor object for the java.awt.KeyboardFocusManager class. |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
898 |
*/ |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
899 |
public static KeyboardFocusManagerAccessor getKeyboardFocusManagerAccessor() { |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
900 |
if (kfmAccessor == null) { |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
901 |
unsafe.ensureClassInitialized(KeyboardFocusManager.class); |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
902 |
} |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
903 |
return kfmAccessor; |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
904 |
} |
3084
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
905 |
|
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
906 |
/* |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
907 |
* Set an accessor object for the java.awt.MenuComponent class. |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
908 |
*/ |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
909 |
public static void setMenuComponentAccessor(MenuComponentAccessor mca) { |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
910 |
menuComponentAccessor = mca; |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
911 |
} |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
912 |
|
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
913 |
/* |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
914 |
* Retrieve the accessor object for the java.awt.MenuComponent class. |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
915 |
*/ |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
916 |
public static MenuComponentAccessor getMenuComponentAccessor() { |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
917 |
if (menuComponentAccessor == null) { |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
918 |
unsafe.ensureClassInitialized(MenuComponent.class); |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
919 |
} |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
920 |
return menuComponentAccessor; |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
921 |
} |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
922 |
|
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
923 |
/* |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
924 |
* Set an accessor object for the java.awt.EventQueue class. |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
925 |
*/ |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
926 |
public static void setEventQueueAccessor(EventQueueAccessor eqa) { |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
927 |
eventQueueAccessor = eqa; |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
928 |
} |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
929 |
|
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
930 |
/* |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
931 |
* Retrieve the accessor object for the java.awt.EventQueue class. |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
932 |
*/ |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
933 |
public static EventQueueAccessor getEventQueueAccessor() { |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
934 |
if (eventQueueAccessor == null) { |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
935 |
unsafe.ensureClassInitialized(EventQueue.class); |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
936 |
} |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
937 |
return eventQueueAccessor; |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
938 |
} |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
939 |
|
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
940 |
/* |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
941 |
* Set an accessor object for the java.awt.PopupMenu class. |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
942 |
*/ |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
943 |
public static void setPopupMenuAccessor(PopupMenuAccessor pma) { |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
944 |
popupMenuAccessor = pma; |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
945 |
} |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
946 |
|
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
947 |
/* |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
948 |
* Retrieve the accessor object for the java.awt.PopupMenu class. |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
949 |
*/ |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
950 |
public static PopupMenuAccessor getPopupMenuAccessor() { |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
951 |
if (popupMenuAccessor == null) { |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
952 |
unsafe.ensureClassInitialized(PopupMenu.class); |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
953 |
} |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
954 |
return popupMenuAccessor; |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
955 |
} |
4913
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
956 |
|
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
957 |
/* |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
958 |
* Set an accessor object for the java.awt.FileDialog class. |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
959 |
*/ |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
960 |
public static void setFileDialogAccessor(FileDialogAccessor fda) { |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
961 |
fileDialogAccessor = fda; |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
962 |
} |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
963 |
|
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
964 |
/* |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
965 |
* Retrieve the accessor object for the java.awt.FileDialog class. |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
966 |
*/ |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
967 |
public static FileDialogAccessor getFileDialogAccessor() { |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
968 |
if (fileDialogAccessor == null) { |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
969 |
unsafe.ensureClassInitialized(FileDialog.class); |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
970 |
} |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
971 |
return fileDialogAccessor; |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
972 |
} |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
973 |
|
10097
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
974 |
/* |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
975 |
* Set an accessor object for the java.awt.ScrollPaneAdjustable class. |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
976 |
*/ |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
977 |
public static void setScrollPaneAdjustableAccessor(ScrollPaneAdjustableAccessor adj) { |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
978 |
scrollPaneAdjustableAccessor = adj; |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
979 |
} |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
980 |
|
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
981 |
/* |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
982 |
* Retrieve the accessor object for the java.awt.ScrollPaneAdjustable |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
983 |
* class. |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
984 |
*/ |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
985 |
public static ScrollPaneAdjustableAccessor getScrollPaneAdjustableAccessor() { |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
986 |
if (scrollPaneAdjustableAccessor == null) { |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
987 |
unsafe.ensureClassInitialized(ScrollPaneAdjustable.class); |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
988 |
} |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
989 |
return scrollPaneAdjustableAccessor; |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
990 |
} |
13604 | 991 |
|
992 |
/** |
|
993 |
* Set an accessor object for the java.awt.CheckboxMenuItem class. |
|
994 |
*/ |
|
995 |
public static void setCheckboxMenuItemAccessor(CheckboxMenuItemAccessor cmia) { |
|
996 |
checkboxMenuItemAccessor = cmia; |
|
997 |
} |
|
998 |
||
999 |
/** |
|
1000 |
* Retrieve the accessor object for the java.awt.CheckboxMenuItem class. |
|
1001 |
*/ |
|
1002 |
public static CheckboxMenuItemAccessor getCheckboxMenuItemAccessor() { |
|
1003 |
if (checkboxMenuItemAccessor == null) { |
|
1004 |
unsafe.ensureClassInitialized(CheckboxMenuItemAccessor.class); |
|
1005 |
} |
|
1006 |
return checkboxMenuItemAccessor; |
|
1007 |
} |
|
1008 |
||
1009 |
/** |
|
1010 |
* Set an accessor object for the java.awt.Cursor class. |
|
1011 |
*/ |
|
1012 |
public static void setCursorAccessor(CursorAccessor ca) { |
|
1013 |
cursorAccessor = ca; |
|
1014 |
} |
|
1015 |
||
1016 |
/** |
|
1017 |
* Retrieve the accessor object for the java.awt.Cursor class. |
|
1018 |
*/ |
|
1019 |
public static CursorAccessor getCursorAccessor() { |
|
1020 |
if (cursorAccessor == null) { |
|
1021 |
unsafe.ensureClassInitialized(CursorAccessor.class); |
|
1022 |
} |
|
1023 |
return cursorAccessor; |
|
1024 |
} |
|
1025 |
||
1026 |
/** |
|
1027 |
* Set an accessor object for the java.awt.MenuBar class. |
|
1028 |
*/ |
|
1029 |
public static void setMenuBarAccessor(MenuBarAccessor mba) { |
|
1030 |
menuBarAccessor = mba; |
|
1031 |
} |
|
1032 |
||
1033 |
/** |
|
1034 |
* Retrieve the accessor object for the java.awt.MenuBar class. |
|
1035 |
*/ |
|
1036 |
public static MenuBarAccessor getMenuBarAccessor() { |
|
1037 |
if (menuBarAccessor == null) { |
|
1038 |
unsafe.ensureClassInitialized(MenuBarAccessor.class); |
|
1039 |
} |
|
1040 |
return menuBarAccessor; |
|
1041 |
} |
|
1042 |
||
1043 |
/** |
|
1044 |
* Set an accessor object for the java.awt.MenuItem class. |
|
1045 |
*/ |
|
1046 |
public static void setMenuItemAccessor(MenuItemAccessor mia) { |
|
1047 |
menuItemAccessor = mia; |
|
1048 |
} |
|
1049 |
||
1050 |
/** |
|
1051 |
* Retrieve the accessor object for the java.awt.MenuItem class. |
|
1052 |
*/ |
|
1053 |
public static MenuItemAccessor getMenuItemAccessor() { |
|
1054 |
if (menuItemAccessor == null) { |
|
1055 |
unsafe.ensureClassInitialized(MenuItemAccessor.class); |
|
1056 |
} |
|
1057 |
return menuItemAccessor; |
|
1058 |
} |
|
1059 |
||
1060 |
/** |
|
1061 |
* Set an accessor object for the java.awt.Menu class. |
|
1062 |
*/ |
|
1063 |
public static void setMenuAccessor(MenuAccessor ma) { |
|
1064 |
menuAccessor = ma; |
|
1065 |
} |
|
1066 |
||
1067 |
/** |
|
1068 |
* Retrieve the accessor object for the java.awt.Menu class. |
|
1069 |
*/ |
|
1070 |
public static MenuAccessor getMenuAccessor() { |
|
1071 |
if (menuAccessor == null) { |
|
1072 |
unsafe.ensureClassInitialized(MenuAccessor.class); |
|
1073 |
} |
|
1074 |
return menuAccessor; |
|
1075 |
} |
|
1076 |
||
1077 |
/** |
|
1078 |
* Set an accessor object for the java.awt.event.KeyEvent class. |
|
1079 |
*/ |
|
1080 |
public static void setKeyEventAccessor(KeyEventAccessor kea) { |
|
1081 |
keyEventAccessor = kea; |
|
1082 |
} |
|
1083 |
||
1084 |
/** |
|
1085 |
* Retrieve the accessor object for the java.awt.event.KeyEvent class. |
|
1086 |
*/ |
|
1087 |
public static KeyEventAccessor getKeyEventAccessor() { |
|
1088 |
if (keyEventAccessor == null) { |
|
1089 |
unsafe.ensureClassInitialized(KeyEventAccessor.class); |
|
1090 |
} |
|
1091 |
return keyEventAccessor; |
|
1092 |
} |
|
1093 |
||
1094 |
/** |
|
1095 |
* Set an accessor object for the javax.swing.ClientPropertyKey class. |
|
1096 |
*/ |
|
1097 |
public static void setClientPropertyKeyAccessor(ClientPropertyKeyAccessor cpka) { |
|
1098 |
clientPropertyKeyAccessor = cpka; |
|
1099 |
} |
|
1100 |
||
1101 |
/** |
|
1102 |
* Retrieve the accessor object for the javax.swing.ClientPropertyKey class. |
|
1103 |
*/ |
|
1104 |
public static ClientPropertyKeyAccessor getClientPropertyKeyAccessor() { |
|
1105 |
if (clientPropertyKeyAccessor == null) { |
|
1106 |
unsafe.ensureClassInitialized(ClientPropertyKeyAccessor.class); |
|
1107 |
} |
|
1108 |
return clientPropertyKeyAccessor; |
|
1109 |
} |
|
1110 |
||
1111 |
/** |
|
1112 |
* Set an accessor object for the java.awt.SystemTray class. |
|
1113 |
*/ |
|
1114 |
public static void setSystemTrayAccessor(SystemTrayAccessor sta) { |
|
1115 |
systemTrayAccessor = sta; |
|
1116 |
} |
|
1117 |
||
1118 |
/** |
|
1119 |
* Retrieve the accessor object for the java.awt.SystemTray class. |
|
1120 |
*/ |
|
1121 |
public static SystemTrayAccessor getSystemTrayAccessor() { |
|
1122 |
if (systemTrayAccessor == null) { |
|
1123 |
unsafe.ensureClassInitialized(SystemTrayAccessor.class); |
|
1124 |
} |
|
1125 |
return systemTrayAccessor; |
|
1126 |
} |
|
1127 |
||
1128 |
/** |
|
1129 |
* Set an accessor object for the java.awt.TrayIcon class. |
|
1130 |
*/ |
|
1131 |
public static void setTrayIconAccessor(TrayIconAccessor tia) { |
|
1132 |
trayIconAccessor = tia; |
|
1133 |
} |
|
1134 |
||
1135 |
/** |
|
1136 |
* Retrieve the accessor object for the java.awt.TrayIcon class. |
|
1137 |
*/ |
|
1138 |
public static TrayIconAccessor getTrayIconAccessor() { |
|
1139 |
if (trayIconAccessor == null) { |
|
1140 |
unsafe.ensureClassInitialized(TrayIconAccessor.class); |
|
1141 |
} |
|
1142 |
return trayIconAccessor; |
|
1143 |
} |
|
1144 |
||
1145 |
/** |
|
1146 |
* Set an accessor object for the java.awt.DefaultKeyboardFocusManager class. |
|
1147 |
*/ |
|
1148 |
public static void setDefaultKeyboardFocusManagerAccessor(DefaultKeyboardFocusManagerAccessor dkfma) { |
|
1149 |
defaultKeyboardFocusManagerAccessor = dkfma; |
|
1150 |
} |
|
1151 |
||
1152 |
/** |
|
1153 |
* Retrieve the accessor object for the java.awt.DefaultKeyboardFocusManager class. |
|
1154 |
*/ |
|
1155 |
public static DefaultKeyboardFocusManagerAccessor getDefaultKeyboardFocusManagerAccessor() { |
|
1156 |
if (defaultKeyboardFocusManagerAccessor == null) { |
|
1157 |
unsafe.ensureClassInitialized(DefaultKeyboardFocusManagerAccessor.class); |
|
1158 |
} |
|
1159 |
return defaultKeyboardFocusManagerAccessor; |
|
1160 |
} |
|
13652
42544e68dc39
6981400: Tabbing between textfield do not work properly when ALT+TAB
ant
parents:
12653
diff
changeset
|
1161 |
/* |
42544e68dc39
6981400: Tabbing between textfield do not work properly when ALT+TAB
ant
parents:
12653
diff
changeset
|
1162 |
* Set an accessor object for the java.awt.SequencedEvent class. |
42544e68dc39
6981400: Tabbing between textfield do not work properly when ALT+TAB
ant
parents:
12653
diff
changeset
|
1163 |
*/ |
42544e68dc39
6981400: Tabbing between textfield do not work properly when ALT+TAB
ant
parents:
12653
diff
changeset
|
1164 |
public static void setSequencedEventAccessor(SequencedEventAccessor sea) { |
42544e68dc39
6981400: Tabbing between textfield do not work properly when ALT+TAB
ant
parents:
12653
diff
changeset
|
1165 |
sequencedEventAccessor = sea; |
42544e68dc39
6981400: Tabbing between textfield do not work properly when ALT+TAB
ant
parents:
12653
diff
changeset
|
1166 |
} |
42544e68dc39
6981400: Tabbing between textfield do not work properly when ALT+TAB
ant
parents:
12653
diff
changeset
|
1167 |
|
42544e68dc39
6981400: Tabbing between textfield do not work properly when ALT+TAB
ant
parents:
12653
diff
changeset
|
1168 |
/* |
42544e68dc39
6981400: Tabbing between textfield do not work properly when ALT+TAB
ant
parents:
12653
diff
changeset
|
1169 |
* Get the accessor object for the java.awt.SequencedEvent class. |
42544e68dc39
6981400: Tabbing between textfield do not work properly when ALT+TAB
ant
parents:
12653
diff
changeset
|
1170 |
*/ |
42544e68dc39
6981400: Tabbing between textfield do not work properly when ALT+TAB
ant
parents:
12653
diff
changeset
|
1171 |
public static SequencedEventAccessor getSequencedEventAccessor() { |
42544e68dc39
6981400: Tabbing between textfield do not work properly when ALT+TAB
ant
parents:
12653
diff
changeset
|
1172 |
// The class is not public. So we can't ensure it's initialized. |
42544e68dc39
6981400: Tabbing between textfield do not work properly when ALT+TAB
ant
parents:
12653
diff
changeset
|
1173 |
// Null returned value means it's not initialized |
42544e68dc39
6981400: Tabbing between textfield do not work properly when ALT+TAB
ant
parents:
12653
diff
changeset
|
1174 |
// (so not a single instance of the event has been created). |
42544e68dc39
6981400: Tabbing between textfield do not work properly when ALT+TAB
ant
parents:
12653
diff
changeset
|
1175 |
return sequencedEventAccessor; |
42544e68dc39
6981400: Tabbing between textfield do not work properly when ALT+TAB
ant
parents:
12653
diff
changeset
|
1176 |
} |
20147
78e51d8fcb92
7129133: [macosx] Accelerators are displayed as Meta instead of the Command symbol
leonidr
parents:
20097
diff
changeset
|
1177 |
|
78e51d8fcb92
7129133: [macosx] Accelerators are displayed as Meta instead of the Command symbol
leonidr
parents:
20097
diff
changeset
|
1178 |
/* |
78e51d8fcb92
7129133: [macosx] Accelerators are displayed as Meta instead of the Command symbol
leonidr
parents:
20097
diff
changeset
|
1179 |
* Set an accessor object for the java.awt.Toolkit class. |
78e51d8fcb92
7129133: [macosx] Accelerators are displayed as Meta instead of the Command symbol
leonidr
parents:
20097
diff
changeset
|
1180 |
*/ |
78e51d8fcb92
7129133: [macosx] Accelerators are displayed as Meta instead of the Command symbol
leonidr
parents:
20097
diff
changeset
|
1181 |
public static void setToolkitAccessor(ToolkitAccessor ta) { |
78e51d8fcb92
7129133: [macosx] Accelerators are displayed as Meta instead of the Command symbol
leonidr
parents:
20097
diff
changeset
|
1182 |
toolkitAccessor = ta; |
78e51d8fcb92
7129133: [macosx] Accelerators are displayed as Meta instead of the Command symbol
leonidr
parents:
20097
diff
changeset
|
1183 |
} |
78e51d8fcb92
7129133: [macosx] Accelerators are displayed as Meta instead of the Command symbol
leonidr
parents:
20097
diff
changeset
|
1184 |
|
78e51d8fcb92
7129133: [macosx] Accelerators are displayed as Meta instead of the Command symbol
leonidr
parents:
20097
diff
changeset
|
1185 |
/* |
78e51d8fcb92
7129133: [macosx] Accelerators are displayed as Meta instead of the Command symbol
leonidr
parents:
20097
diff
changeset
|
1186 |
* Get the accessor object for the java.awt.Toolkit class. |
78e51d8fcb92
7129133: [macosx] Accelerators are displayed as Meta instead of the Command symbol
leonidr
parents:
20097
diff
changeset
|
1187 |
*/ |
78e51d8fcb92
7129133: [macosx] Accelerators are displayed as Meta instead of the Command symbol
leonidr
parents:
20097
diff
changeset
|
1188 |
public static ToolkitAccessor getToolkitAccessor() { |
78e51d8fcb92
7129133: [macosx] Accelerators are displayed as Meta instead of the Command symbol
leonidr
parents:
20097
diff
changeset
|
1189 |
if (toolkitAccessor == null) { |
78e51d8fcb92
7129133: [macosx] Accelerators are displayed as Meta instead of the Command symbol
leonidr
parents:
20097
diff
changeset
|
1190 |
unsafe.ensureClassInitialized(Toolkit.class); |
78e51d8fcb92
7129133: [macosx] Accelerators are displayed as Meta instead of the Command symbol
leonidr
parents:
20097
diff
changeset
|
1191 |
} |
78e51d8fcb92
7129133: [macosx] Accelerators are displayed as Meta instead of the Command symbol
leonidr
parents:
20097
diff
changeset
|
1192 |
|
78e51d8fcb92
7129133: [macosx] Accelerators are displayed as Meta instead of the Command symbol
leonidr
parents:
20097
diff
changeset
|
1193 |
return toolkitAccessor; |
78e51d8fcb92
7129133: [macosx] Accelerators are displayed as Meta instead of the Command symbol
leonidr
parents:
20097
diff
changeset
|
1194 |
} |
21246 | 1195 |
|
1196 |
/* |
|
1197 |
* Get the accessor object for the java.awt.event.InvocationEvent class. |
|
1198 |
*/ |
|
1199 |
public static void setInvocationEventAccessor(InvocationEventAccessor invocationEventAccessor) { |
|
1200 |
AWTAccessor.invocationEventAccessor = invocationEventAccessor; |
|
1201 |
} |
|
1202 |
||
1203 |
/* |
|
1204 |
* Set the accessor object for the java.awt.event.InvocationEvent class. |
|
1205 |
*/ |
|
1206 |
public static InvocationEventAccessor getInvocationEventAccessor() { |
|
1207 |
return invocationEventAccessor; |
|
1208 |
} |
|
23268 | 1209 |
|
1210 |
/* |
|
1211 |
* Get the accessor object for the java.awt.SystemColor class. |
|
1212 |
*/ |
|
1213 |
public static SystemColorAccessor getSystemColorAccessor() { |
|
1214 |
if (systemColorAccessor == null) { |
|
1215 |
unsafe.ensureClassInitialized(SystemColor.class); |
|
1216 |
} |
|
1217 |
||
1218 |
return systemColorAccessor; |
|
1219 |
} |
|
1220 |
||
1221 |
/* |
|
1222 |
* Set the accessor object for the java.awt.SystemColor class. |
|
1223 |
*/ |
|
1224 |
public static void setSystemColorAccessor(SystemColorAccessor systemColorAccessor) { |
|
1225 |
AWTAccessor.systemColorAccessor = systemColorAccessor; |
|
1226 |
} |
|
1978
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
1227 |
} |