author | leonidr |
Wed, 29 Aug 2012 19:53:35 +0400 | |
changeset 13648 | 90effcfc064f |
parent 12653 | 07d5ca30e79e |
child 13604 | 31089af1a447 |
child 13652 | 42544e68dc39 |
permissions | -rw-r--r-- |
1978
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
1 |
/* |
9035
1255eb81cc2f
7033660: Update copyright year to 2011 on any files changed in 2011
ohair
parents:
8816
diff
changeset
|
2 |
* Copyright (c) 2008, 2011, 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; |
6825 | 32 |
import java.awt.event.InputEvent; |
2451 | 33 |
import java.awt.geom.Point2D; |
3084
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
34 |
import java.awt.peer.ComponentPeer; |
8816
29f983feda95
6907662: System clipboard should ensure access restrictions
denis
parents:
7668
diff
changeset
|
35 |
import java.security.AccessControlContext; |
29f983feda95
6907662: System clipboard should ensure access restrictions
denis
parents:
7668
diff
changeset
|
36 |
|
12653
07d5ca30e79e
7124337: [macosx] FileDialog fails to select multiple files
dcherepanov
parents:
12047
diff
changeset
|
37 |
import java.io.File; |
07d5ca30e79e
7124337: [macosx] FileDialog fails to select multiple files
dcherepanov
parents:
12047
diff
changeset
|
38 |
|
2464
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
39 |
/** |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
40 |
* The AWTAccessor utility class. |
1978
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
41 |
* 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
|
42 |
* 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
|
43 |
* different classes/packages. See sun.misc.SharedSecretes |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
44 |
* for another example. |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
45 |
*/ |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
46 |
public final class AWTAccessor { |
2451 | 47 |
|
1978
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
48 |
private static final Unsafe unsafe = Unsafe.getUnsafe(); |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
49 |
|
2451 | 50 |
/* |
51 |
* 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
|
52 |
* 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
|
53 |
* and interfaces. |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
54 |
*/ |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
55 |
private AWTAccessor() { |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
56 |
} |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
57 |
|
2451 | 58 |
/* |
59 |
* 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
|
60 |
*/ |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
61 |
public interface ComponentAccessor { |
2451 | 62 |
/* |
63 |
* Sets whether the native background erase for a component |
|
64 |
* has been disabled via SunToolkit.disableBackgroundErase(). |
|
65 |
*/ |
|
66 |
void setBackgroundEraseDisabled(Component comp, boolean disabled); |
|
67 |
/* |
|
68 |
* Indicates whether the native background erase for a |
|
69 |
* component has been disabled via |
|
70 |
* SunToolkit.disableBackgroundErase(). |
|
71 |
*/ |
|
72 |
boolean getBackgroundEraseDisabled(Component comp); |
|
73 |
/* |
|
74 |
* |
|
75 |
* Gets the bounds of this component in the form of a |
|
76 |
* <code>Rectangle</code> object. The bounds specify this |
|
77 |
* component's width, height, and location relative to |
|
78 |
* its parent. |
|
79 |
*/ |
|
80 |
Rectangle getBounds(Component comp); |
|
81 |
/* |
|
1978
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
82 |
* Sets the shape of a lw component to cut out from hw components. |
2451 | 83 |
* |
84 |
* 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
|
85 |
*/ |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
86 |
void setMixingCutoutShape(Component comp, Shape shape); |
2459
08f3416ff334
6804747: Ensure consistent graphicsConfig member across components hierarchy
anthony
parents:
2453
diff
changeset
|
87 |
|
08f3416ff334
6804747: Ensure consistent graphicsConfig member across components hierarchy
anthony
parents:
2453
diff
changeset
|
88 |
/** |
08f3416ff334
6804747: Ensure consistent graphicsConfig member across components hierarchy
anthony
parents:
2453
diff
changeset
|
89 |
* Sets GraphicsConfiguration value for the component. |
08f3416ff334
6804747: Ensure consistent graphicsConfig member across components hierarchy
anthony
parents:
2453
diff
changeset
|
90 |
*/ |
08f3416ff334
6804747: Ensure consistent graphicsConfig member across components hierarchy
anthony
parents:
2453
diff
changeset
|
91 |
void setGraphicsConfiguration(Component comp, GraphicsConfiguration gc); |
2464
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
92 |
/* |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
93 |
* Requests focus to the component. |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
94 |
*/ |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
95 |
boolean requestFocus(Component comp, CausedFocusEvent.Cause cause); |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
96 |
/* |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
97 |
* Determines if the component can gain focus. |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
98 |
*/ |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
99 |
boolean canBeFocusOwner(Component comp); |
2472
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
100 |
|
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
101 |
/** |
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
102 |
* Returns whether the component is visible without invoking |
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
103 |
* any client code. |
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
104 |
*/ |
4371
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
105 |
boolean isVisible(Component comp); |
3084
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
106 |
|
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
107 |
/** |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
108 |
* Sets the RequestFocusController. |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
109 |
*/ |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
110 |
void setRequestFocusController(RequestFocusController requestController); |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
111 |
|
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
112 |
/** |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
113 |
* Returns the appContext of the component. |
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 |
AppContext getAppContext(Component comp); |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
116 |
|
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 |
* Sets the appContext of the component. |
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 |
void setAppContext(Component comp, AppContext appContext); |
4371
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
121 |
|
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
122 |
/** |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
123 |
* Returns the parent of the component. |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
124 |
*/ |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
125 |
Container getParent(Component comp); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
126 |
|
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
127 |
/** |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
128 |
* Sets the parent of the component to the specified parent. |
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 |
void setParent(Component comp, Container parent); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
131 |
|
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 |
* Resizes the component to the specified width and height. |
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 |
void setSize(Component comp, int width, int height); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
136 |
|
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 |
* Returns the location of the component. |
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 |
Point getLocation(Component comp); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
141 |
|
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 |
* Moves the component to the new location. |
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 |
void setLocation(Component comp, int x, int y); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
146 |
|
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 |
* Determines whether this component is enabled. |
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 |
boolean isEnabled(Component comp); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
151 |
|
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 |
* Determines whether this component is displayable. |
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 |
boolean isDisplayable(Component comp); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
156 |
|
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 |
* Gets the cursor set in the component. |
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 |
Cursor getCursor(Component comp); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
161 |
|
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 |
* Returns the peer of the component. |
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 |
ComponentPeer getPeer(Component comp); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
166 |
|
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 |
* Sets the peer of the component to the specified peer. |
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 |
void setPeer(Component comp, ComponentPeer peer); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
171 |
|
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 |
* Determines whether this component is lightweight. |
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 |
boolean isLightweight(Component comp); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
176 |
|
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 |
* Returns whether or not paint messages received from |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
179 |
* the operating system should be ignored. |
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 |
boolean getIgnoreRepaint(Component comp); |
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 |
/** |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
184 |
* Returns the width of the component. |
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 |
int getWidth(Component comp); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
187 |
|
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 |
* Returns the height of the component. |
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 |
int getHeight(Component comp); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
192 |
|
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 |
* Returns the x coordinate of the component. |
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 |
int getX(Component comp); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
197 |
|
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 |
* Returns the y coordinate of the component. |
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 |
int getY(Component comp); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
202 |
|
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 |
* Gets the foreground color of this component. |
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 |
Color getForeground(Component comp); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
207 |
|
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 |
* Gets the background color of this component. |
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 |
Color getBackground(Component comp); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
212 |
|
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 |
* Sets the background of this component to the specified color. |
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 |
void setBackground(Component comp, Color background); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
217 |
|
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 |
* Gets the font of the component. |
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 |
Font getFont(Component comp); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
222 |
|
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 |
* Processes events occurring on this component. |
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 |
void processEvent(Component comp, AWTEvent e); |
8816
29f983feda95
6907662: System clipboard should ensure access restrictions
denis
parents:
7668
diff
changeset
|
227 |
|
29f983feda95
6907662: System clipboard should ensure access restrictions
denis
parents:
7668
diff
changeset
|
228 |
|
29f983feda95
6907662: System clipboard should ensure access restrictions
denis
parents:
7668
diff
changeset
|
229 |
/* |
29f983feda95
6907662: System clipboard should ensure access restrictions
denis
parents:
7668
diff
changeset
|
230 |
* Returns the acc this component was constructed with. |
29f983feda95
6907662: System clipboard should ensure access restrictions
denis
parents:
7668
diff
changeset
|
231 |
*/ |
29f983feda95
6907662: System clipboard should ensure access restrictions
denis
parents:
7668
diff
changeset
|
232 |
AccessControlContext getAccessControlContext(Component comp); |
29f983feda95
6907662: System clipboard should ensure access restrictions
denis
parents:
7668
diff
changeset
|
233 |
|
1978
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
234 |
} |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
235 |
|
2451 | 236 |
/* |
7241
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
237 |
* An interface of accessor for the java.awt.Container class. |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
238 |
*/ |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
239 |
public interface ContainerAccessor { |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
240 |
/** |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
241 |
* Validates the container unconditionally. |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
242 |
*/ |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
243 |
void validateUnconditionally(Container cont); |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
244 |
} |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
245 |
|
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
246 |
/* |
2451 | 247 |
* An interface of accessor for java.awt.Window class. |
248 |
*/ |
|
249 |
public interface WindowAccessor { |
|
250 |
/* |
|
251 |
* Get opacity level of the given window. |
|
252 |
*/ |
|
253 |
float getOpacity(Window window); |
|
254 |
/* |
|
255 |
* Set opacity level to the given window. |
|
256 |
*/ |
|
257 |
void setOpacity(Window window, float opacity); |
|
258 |
/* |
|
259 |
* Get a shape assigned to the given window. |
|
260 |
*/ |
|
261 |
Shape getShape(Window window); |
|
262 |
/* |
|
263 |
* Set a shape to the given window. |
|
264 |
*/ |
|
265 |
void setShape(Window window, Shape shape); |
|
266 |
/* |
|
267 |
* Set the opaque preoperty to the given window. |
|
268 |
*/ |
|
269 |
void setOpaque(Window window, boolean isOpaque); |
|
270 |
/* |
|
271 |
* Update the image of a non-opaque (translucent) window. |
|
272 |
*/ |
|
2808
a139a919f645
6794764: Translucent windows are completely repainted on every paint event, on Windows
art
parents:
2472
diff
changeset
|
273 |
void updateWindow(Window window); |
2472
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
274 |
|
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
275 |
/** Get the size of the security warning. |
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
276 |
*/ |
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
277 |
Dimension getSecurityWarningSize(Window w); |
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
278 |
|
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
279 |
/** |
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
280 |
* Set the size of the security warning. |
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
281 |
*/ |
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
282 |
void setSecurityWarningSize(Window w, int width, int height); |
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
283 |
|
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
284 |
/** Set the position of the security warning. |
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
285 |
*/ |
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
286 |
void setSecurityWarningPosition(Window w, Point2D point, |
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
287 |
float alignmentX, float alignmentY); |
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
288 |
|
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
289 |
/** Request to recalculate the new position of the security warning for |
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
290 |
* the given window size/location as reported by the native system. |
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
291 |
*/ |
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
292 |
Point2D calculateSecurityWarningPosition(Window window, |
b7aba00cabb6
6693253: Security Warning appearance requires enhancements
anthony
parents:
2465
diff
changeset
|
293 |
double x, double y, double w, double h); |
3084
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
294 |
|
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
295 |
/** Sets the synchronous status of focus requests on lightweight |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
296 |
* components in the specified window to the specified value. |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
297 |
*/ |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
298 |
void setLWRequestStatus(Window changed, boolean status); |
4371
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
299 |
|
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
300 |
/** |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
301 |
* Indicates whether this window should receive focus on subsequently |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
302 |
* being shown, or being moved to the front. |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
303 |
*/ |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
304 |
boolean isAutoRequestFocus(Window w); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
305 |
|
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
306 |
/** |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
307 |
* Indicates whether the specified window is an utility window for TrayIcon. |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
308 |
*/ |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
309 |
boolean isTrayIconWindow(Window w); |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
310 |
|
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
311 |
/** |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
312 |
* Marks the specified window as an utility window for TrayIcon. |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
313 |
*/ |
dc9dcb8b0ae7
6823138: Need to replace ComponentAccessor with AWTAccessor
dcherepanov
parents:
4365
diff
changeset
|
314 |
void setTrayIconWindow(Window w, boolean isTrayIconWindow); |
2451 | 315 |
} |
316 |
||
317 |
/* |
|
318 |
* An accessor for the AWTEvent class. |
|
319 |
*/ |
|
320 |
public interface AWTEventAccessor { |
|
3084
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
321 |
/** |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
322 |
* Marks the event as posted. |
2451 | 323 |
*/ |
3084
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
324 |
void setPosted(AWTEvent ev); |
6826
1fc6a05552f2
6991992: Need to forward-port AWT's part of the fix for 6691674
dcherepanov
parents:
6825
diff
changeset
|
325 |
|
1fc6a05552f2
6991992: Need to forward-port AWT's part of the fix for 6691674
dcherepanov
parents:
6825
diff
changeset
|
326 |
/** |
1fc6a05552f2
6991992: Need to forward-port AWT's part of the fix for 6691674
dcherepanov
parents:
6825
diff
changeset
|
327 |
* 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
|
328 |
* generated by the system. |
1fc6a05552f2
6991992: Need to forward-port AWT's part of the fix for 6691674
dcherepanov
parents:
6825
diff
changeset
|
329 |
*/ |
1fc6a05552f2
6991992: Need to forward-port AWT's part of the fix for 6691674
dcherepanov
parents:
6825
diff
changeset
|
330 |
void setSystemGenerated(AWTEvent ev); |
1fc6a05552f2
6991992: Need to forward-port AWT's part of the fix for 6691674
dcherepanov
parents:
6825
diff
changeset
|
331 |
|
1fc6a05552f2
6991992: Need to forward-port AWT's part of the fix for 6691674
dcherepanov
parents:
6825
diff
changeset
|
332 |
/** |
1fc6a05552f2
6991992: Need to forward-port AWT's part of the fix for 6691674
dcherepanov
parents:
6825
diff
changeset
|
333 |
* 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
|
334 |
*/ |
1fc6a05552f2
6991992: Need to forward-port AWT's part of the fix for 6691674
dcherepanov
parents:
6825
diff
changeset
|
335 |
boolean isSystemGenerated(AWTEvent ev); |
8816
29f983feda95
6907662: System clipboard should ensure access restrictions
denis
parents:
7668
diff
changeset
|
336 |
|
29f983feda95
6907662: System clipboard should ensure access restrictions
denis
parents:
7668
diff
changeset
|
337 |
|
29f983feda95
6907662: System clipboard should ensure access restrictions
denis
parents:
7668
diff
changeset
|
338 |
/* |
29f983feda95
6907662: System clipboard should ensure access restrictions
denis
parents:
7668
diff
changeset
|
339 |
* Returns the acc this event was constructed with. |
29f983feda95
6907662: System clipboard should ensure access restrictions
denis
parents:
7668
diff
changeset
|
340 |
*/ |
29f983feda95
6907662: System clipboard should ensure access restrictions
denis
parents:
7668
diff
changeset
|
341 |
AccessControlContext getAccessControlContext(AWTEvent ev); |
29f983feda95
6907662: System clipboard should ensure access restrictions
denis
parents:
7668
diff
changeset
|
342 |
|
2451 | 343 |
} |
344 |
||
6825 | 345 |
public interface InputEventAccessor { |
346 |
/* |
|
347 |
* Accessor for InputEvent.getButtonDownMasks() |
|
348 |
*/ |
|
349 |
int[] getButtonDownMasks(); |
|
350 |
} |
|
351 |
||
2451 | 352 |
/* |
2453
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
353 |
* 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
|
354 |
*/ |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
355 |
public interface FrameAccessor { |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
356 |
/* |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
357 |
* 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
|
358 |
*/ |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
359 |
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
|
360 |
/* |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
361 |
* 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
|
362 |
*/ |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
363 |
int getExtendedState(Frame frame); |
7239
514eb274caa1
6699851: setMaximizedbounds not working properly on dual screen environment
dcherepanov
parents:
6826
diff
changeset
|
364 |
/* |
514eb274caa1
6699851: setMaximizedbounds not working properly on dual screen environment
dcherepanov
parents:
6826
diff
changeset
|
365 |
* Gets the maximized bounds of this frame. |
514eb274caa1
6699851: setMaximizedbounds not working properly on dual screen environment
dcherepanov
parents:
6826
diff
changeset
|
366 |
*/ |
514eb274caa1
6699851: setMaximizedbounds not working properly on dual screen environment
dcherepanov
parents:
6826
diff
changeset
|
367 |
Rectangle getMaximizedBounds(Frame frame); |
2453
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
368 |
} |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
369 |
|
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
370 |
/* |
2465 | 371 |
* 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
|
372 |
*/ |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
373 |
public interface KeyboardFocusManagerAccessor { |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
374 |
/* |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
375 |
* Indicates whether the native implementation should |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
376 |
* proceed with a pending focus request for the heavyweight. |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
377 |
*/ |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
378 |
int shouldNativelyFocusHeavyweight(Component heavyweight, |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
379 |
Component descendant, |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
380 |
boolean temporary, |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
381 |
boolean focusedWindowChangeAllowed, |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
382 |
long time, |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
383 |
CausedFocusEvent.Cause cause); |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
384 |
/* |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
385 |
* Delivers focus for the lightweight descendant of the heavyweight |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
386 |
* synchronously. |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
387 |
*/ |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
388 |
boolean processSynchronousLightweightTransfer(Component heavyweight, |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
389 |
Component descendant, |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
390 |
boolean temporary, |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
391 |
boolean focusedWindowChangeAllowed, |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
392 |
long time); |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
393 |
/* |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
394 |
* 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
|
395 |
*/ |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
396 |
void removeLastFocusRequest(Component heavyweight); |
6634
439221465ac5
6505819: Provide traverseIn method for sun.awt.EmbeddedFrame
ant
parents:
5506
diff
changeset
|
397 |
|
439221465ac5
6505819: Provide traverseIn method for sun.awt.EmbeddedFrame
ant
parents:
5506
diff
changeset
|
398 |
/* |
439221465ac5
6505819: Provide traverseIn method for sun.awt.EmbeddedFrame
ant
parents:
5506
diff
changeset
|
399 |
* Sets the most recent focus owner in the window. |
439221465ac5
6505819: Provide traverseIn method for sun.awt.EmbeddedFrame
ant
parents:
5506
diff
changeset
|
400 |
*/ |
439221465ac5
6505819: Provide traverseIn method for sun.awt.EmbeddedFrame
ant
parents:
5506
diff
changeset
|
401 |
void setMostRecentFocusOwner(Window window, Component component); |
12047
320a714614e9
7113349: Initial changeset for Macosx port to jdk
michaelm
parents:
10097
diff
changeset
|
402 |
|
320a714614e9
7113349: Initial changeset for Macosx port to jdk
michaelm
parents:
10097
diff
changeset
|
403 |
/* |
320a714614e9
7113349: Initial changeset for Macosx port to jdk
michaelm
parents:
10097
diff
changeset
|
404 |
* Returns current KFM of the specified AppContext. |
320a714614e9
7113349: Initial changeset for Macosx port to jdk
michaelm
parents:
10097
diff
changeset
|
405 |
*/ |
320a714614e9
7113349: Initial changeset for Macosx port to jdk
michaelm
parents:
10097
diff
changeset
|
406 |
KeyboardFocusManager getCurrentKeyboardFocusManager(AppContext ctx); |
2464
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
407 |
} |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
408 |
|
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
409 |
/* |
3084
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
410 |
* An accessor for the MenuComponent class. |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
411 |
*/ |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
412 |
public interface MenuComponentAccessor { |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
413 |
/** |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
414 |
* Returns the appContext of the menu component. |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
415 |
*/ |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
416 |
AppContext getAppContext(MenuComponent menuComp); |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
417 |
|
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
418 |
/** |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
419 |
* Sets the appContext of the menu component. |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
420 |
*/ |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
421 |
void setAppContext(MenuComponent menuComp, AppContext appContext); |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
422 |
|
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
423 |
/** |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
424 |
* Returns the menu container of the menu component |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
425 |
*/ |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
426 |
MenuContainer getParent(MenuComponent menuComp); |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
427 |
} |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
428 |
|
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
429 |
/* |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
430 |
* An accessor for the EventQueue class |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
431 |
*/ |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
432 |
public interface EventQueueAccessor { |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
433 |
/* |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
434 |
* Gets the event dispatch thread. |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
435 |
*/ |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
436 |
Thread getDispatchThread(EventQueue eventQueue); |
4365 | 437 |
/* |
438 |
* Checks if the current thread is EDT for the given EQ. |
|
439 |
*/ |
|
440 |
public boolean isDispatchThreadImpl(EventQueue eventQueue); |
|
3084
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
441 |
} |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
442 |
|
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
443 |
/* |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
444 |
* An accessor for the PopupMenu class |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
445 |
*/ |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
446 |
public interface PopupMenuAccessor { |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
447 |
/* |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
448 |
* Returns whether the popup menu is attached to a tray |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
449 |
*/ |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
450 |
boolean isTrayIconPopup(PopupMenu popupMenu); |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
451 |
} |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
452 |
|
4913
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
453 |
/* |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
454 |
* An accessor for the FileDialog class |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
455 |
*/ |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
456 |
public interface FileDialogAccessor { |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
457 |
/* |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
458 |
* Sets the files the user selects |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
459 |
*/ |
12653
07d5ca30e79e
7124337: [macosx] FileDialog fails to select multiple files
dcherepanov
parents:
12047
diff
changeset
|
460 |
void setFiles(FileDialog fileDialog, File files[]); |
4913
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
461 |
|
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
462 |
/* |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
463 |
* Sets the file the user selects |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
464 |
*/ |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
465 |
void setFile(FileDialog fileDialog, String file); |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
466 |
|
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
467 |
/* |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
468 |
* Sets the directory the user selects |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
469 |
*/ |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
470 |
void setDirectory(FileDialog fileDialog, String directory); |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
471 |
|
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
472 |
/* |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
473 |
* Returns whether the file dialog allows the multiple file selection. |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
474 |
*/ |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
475 |
boolean isMultipleMode(FileDialog fileDialog); |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
476 |
} |
3084
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
477 |
|
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
478 |
/* |
10097
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
479 |
* 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
|
480 |
*/ |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
481 |
public interface ScrollPaneAdjustableAccessor { |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
482 |
/* |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
483 |
* 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
|
484 |
*/ |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
485 |
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
|
486 |
final int type); |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
487 |
} |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
488 |
|
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
489 |
/* |
7241
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
490 |
* Accessor instances are initialized in the static initializers of |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
491 |
* 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
|
492 |
*/ |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
493 |
private static ComponentAccessor componentAccessor; |
7241
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
494 |
private static ContainerAccessor containerAccessor; |
2451 | 495 |
private static WindowAccessor windowAccessor; |
496 |
private static AWTEventAccessor awtEventAccessor; |
|
6825 | 497 |
private static InputEventAccessor inputEventAccessor; |
2453
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
498 |
private static FrameAccessor frameAccessor; |
2464
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
499 |
private static KeyboardFocusManagerAccessor kfmAccessor; |
3084
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
500 |
private static MenuComponentAccessor menuComponentAccessor; |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
501 |
private static EventQueueAccessor eventQueueAccessor; |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
502 |
private static PopupMenuAccessor popupMenuAccessor; |
4913
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
503 |
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
|
504 |
private static ScrollPaneAdjustableAccessor scrollPaneAdjustableAccessor; |
4913
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
505 |
|
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
506 |
/* |
2451 | 507 |
* 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
|
508 |
*/ |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
509 |
public static void setComponentAccessor(ComponentAccessor ca) { |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
510 |
componentAccessor = ca; |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
511 |
} |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
512 |
|
2451 | 513 |
/* |
7241
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
514 |
* 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
|
515 |
*/ |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
516 |
public static ComponentAccessor getComponentAccessor() { |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
517 |
if (componentAccessor == null) { |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
518 |
unsafe.ensureClassInitialized(Component.class); |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
519 |
} |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
520 |
|
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
521 |
return componentAccessor; |
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
522 |
} |
2451 | 523 |
|
524 |
/* |
|
7241
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
525 |
* Set an accessor object for the java.awt.Container class. |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
526 |
*/ |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
527 |
public static void setContainerAccessor(ContainerAccessor ca) { |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
528 |
containerAccessor = ca; |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
529 |
} |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
530 |
|
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
531 |
/* |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
532 |
* Retrieve the accessor object for the java.awt.Container class. |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
533 |
*/ |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
534 |
public static ContainerAccessor getContainerAccessor() { |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
535 |
if (containerAccessor == null) { |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
536 |
unsafe.ensureClassInitialized(Container.class); |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
537 |
} |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
538 |
|
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
539 |
return containerAccessor; |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
540 |
} |
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
541 |
|
ed85b6040a98
7002856: Provide an accessor for Container.validateUnconditionally()
anthony
parents:
7239
diff
changeset
|
542 |
/* |
2451 | 543 |
* Set an accessor object for the java.awt.Window class. |
544 |
*/ |
|
545 |
public static void setWindowAccessor(WindowAccessor wa) { |
|
546 |
windowAccessor = wa; |
|
547 |
} |
|
548 |
||
549 |
/* |
|
550 |
* Retrieve the accessor object for the java.awt.Window class. |
|
551 |
*/ |
|
552 |
public static WindowAccessor getWindowAccessor() { |
|
553 |
if (windowAccessor == null) { |
|
554 |
unsafe.ensureClassInitialized(Window.class); |
|
555 |
} |
|
556 |
return windowAccessor; |
|
557 |
} |
|
558 |
||
559 |
/* |
|
560 |
* Set an accessor object for the java.awt.AWTEvent class. |
|
561 |
*/ |
|
562 |
public static void setAWTEventAccessor(AWTEventAccessor aea) { |
|
563 |
awtEventAccessor = aea; |
|
564 |
} |
|
565 |
||
566 |
/* |
|
567 |
* Retrieve the accessor object for the java.awt.AWTEvent class. |
|
568 |
*/ |
|
569 |
public static AWTEventAccessor getAWTEventAccessor() { |
|
3084
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
570 |
if (awtEventAccessor == null) { |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
571 |
unsafe.ensureClassInitialized(AWTEvent.class); |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
572 |
} |
2451 | 573 |
return awtEventAccessor; |
574 |
} |
|
2453
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
575 |
|
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
576 |
/* |
6825 | 577 |
* Set an accessor object for the java.awt.event.InputEvent class. |
578 |
*/ |
|
579 |
public static void setInputEventAccessor(InputEventAccessor iea) { |
|
580 |
inputEventAccessor = iea; |
|
581 |
} |
|
582 |
||
583 |
/* |
|
584 |
* Retrieve the accessor object for the java.awt.event.InputEvent class. |
|
585 |
*/ |
|
586 |
public static InputEventAccessor getInputEventAccessor() { |
|
587 |
if (inputEventAccessor == null) { |
|
588 |
unsafe.ensureClassInitialized(InputEvent.class); |
|
589 |
} |
|
590 |
return inputEventAccessor; |
|
591 |
} |
|
592 |
||
593 |
/* |
|
2453
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
594 |
* 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
|
595 |
*/ |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
596 |
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
|
597 |
frameAccessor = fa; |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
598 |
} |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
599 |
|
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
600 |
/* |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
601 |
* 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
|
602 |
*/ |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
603 |
public static FrameAccessor getFrameAccessor() { |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
604 |
if (frameAccessor == null) { |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
605 |
unsafe.ensureClassInitialized(Frame.class); |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
606 |
} |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
607 |
return frameAccessor; |
35e5fab82613
6724890: Deadlock between AWT-EventQueue-1 and AWT-XAWT threads during IDE start
dcherepanov
parents:
2451
diff
changeset
|
608 |
} |
2464
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
609 |
|
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
610 |
/* |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
611 |
* Set an accessor object for the java.awt.KeyboardFocusManager class. |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
612 |
*/ |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
613 |
public static void setKeyboardFocusManagerAccessor(KeyboardFocusManagerAccessor kfma) { |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
614 |
kfmAccessor = kfma; |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
615 |
} |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
616 |
|
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
617 |
/* |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
618 |
* Retrieve the accessor object for the java.awt.KeyboardFocusManager class. |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
619 |
*/ |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
620 |
public static KeyboardFocusManagerAccessor getKeyboardFocusManagerAccessor() { |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
621 |
if (kfmAccessor == null) { |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
622 |
unsafe.ensureClassInitialized(KeyboardFocusManager.class); |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
623 |
} |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
624 |
return kfmAccessor; |
3c6755bdc55f
6806217: implement synthetic focus model for MS Windows
ant
parents:
2459
diff
changeset
|
625 |
} |
3084
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
626 |
|
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
627 |
/* |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
628 |
* Set an accessor object for the java.awt.MenuComponent class. |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
629 |
*/ |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
630 |
public static void setMenuComponentAccessor(MenuComponentAccessor mca) { |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
631 |
menuComponentAccessor = mca; |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
632 |
} |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
633 |
|
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
634 |
/* |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
635 |
* Retrieve the accessor object for the java.awt.MenuComponent class. |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
636 |
*/ |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
637 |
public static MenuComponentAccessor getMenuComponentAccessor() { |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
638 |
if (menuComponentAccessor == null) { |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
639 |
unsafe.ensureClassInitialized(MenuComponent.class); |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
640 |
} |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
641 |
return menuComponentAccessor; |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
642 |
} |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
643 |
|
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
644 |
/* |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
645 |
* Set an accessor object for the java.awt.EventQueue class. |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
646 |
*/ |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
647 |
public static void setEventQueueAccessor(EventQueueAccessor eqa) { |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
648 |
eventQueueAccessor = eqa; |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
649 |
} |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
650 |
|
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
651 |
/* |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
652 |
* Retrieve the accessor object for the java.awt.EventQueue class. |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
653 |
*/ |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
654 |
public static EventQueueAccessor getEventQueueAccessor() { |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
655 |
if (eventQueueAccessor == null) { |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
656 |
unsafe.ensureClassInitialized(EventQueue.class); |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
657 |
} |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
658 |
return eventQueueAccessor; |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
659 |
} |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
660 |
|
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
661 |
/* |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
662 |
* Set an accessor object for the java.awt.PopupMenu class. |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
663 |
*/ |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
664 |
public static void setPopupMenuAccessor(PopupMenuAccessor pma) { |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
665 |
popupMenuAccessor = pma; |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
666 |
} |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
667 |
|
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
668 |
/* |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
669 |
* Retrieve the accessor object for the java.awt.PopupMenu class. |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
670 |
*/ |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
671 |
public static PopupMenuAccessor getPopupMenuAccessor() { |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
672 |
if (popupMenuAccessor == null) { |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
673 |
unsafe.ensureClassInitialized(PopupMenu.class); |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
674 |
} |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
675 |
return popupMenuAccessor; |
67ca55732362
6824169: Need to remove some AWT class dependencies
dcherepanov
parents:
2808
diff
changeset
|
676 |
} |
4913
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
677 |
|
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
678 |
/* |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
679 |
* Set an accessor object for the java.awt.FileDialog class. |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
680 |
*/ |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
681 |
public static void setFileDialogAccessor(FileDialogAccessor fda) { |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
682 |
fileDialogAccessor = fda; |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
683 |
} |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
684 |
|
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
685 |
/* |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
686 |
* Retrieve the accessor object for the java.awt.FileDialog class. |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
687 |
*/ |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
688 |
public static FileDialogAccessor getFileDialogAccessor() { |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
689 |
if (fileDialogAccessor == null) { |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
690 |
unsafe.ensureClassInitialized(FileDialog.class); |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
691 |
} |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
692 |
return fileDialogAccessor; |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
693 |
} |
9b3caa50afcf
6705345: Enable multiple file selection in AWT FileDialog
dcherepanov
parents:
4371
diff
changeset
|
694 |
|
10097
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
695 |
/* |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
696 |
* 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
|
697 |
*/ |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
698 |
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
|
699 |
scrollPaneAdjustableAccessor = adj; |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
700 |
} |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
701 |
|
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
702 |
/* |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
703 |
* 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
|
704 |
* class. |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
705 |
*/ |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
706 |
public static ScrollPaneAdjustableAccessor getScrollPaneAdjustableAccessor() { |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
707 |
if (scrollPaneAdjustableAccessor == null) { |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
708 |
unsafe.ensureClassInitialized(ScrollPaneAdjustable.class); |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
709 |
} |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
710 |
return scrollPaneAdjustableAccessor; |
67449ffe5991
6642728: Use reflection to access ScrollPane's private method from within sun.awt package
serb
parents:
9035
diff
changeset
|
711 |
} |
1978
8b981ce05cd0
6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7
anthony
parents:
diff
changeset
|
712 |
} |