Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openanolis
dragonwell8_jdk
提交
ebecd936
D
dragonwell8_jdk
项目概览
openanolis
/
dragonwell8_jdk
通知
3
Star
2
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
D
dragonwell8_jdk
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
ebecd936
编写于
5月 16, 2011
作者:
L
lana
浏览文件
操作
浏览文件
下载
差异文件
Merge
上级
5ae84b42
d8154b7b
变更
15
隐藏空白更改
内联
并排
Showing
15 changed file
with
425 addition
and
179 deletion
+425
-179
make/sun/xawt/mapfile-vers
make/sun/xawt/mapfile-vers
+0
-1
src/share/classes/java/awt/Component.java
src/share/classes/java/awt/Component.java
+6
-5
src/share/classes/java/awt/Container.java
src/share/classes/java/awt/Container.java
+25
-9
src/share/classes/java/awt/Toolkit.java
src/share/classes/java/awt/Toolkit.java
+27
-41
src/solaris/classes/sun/awt/X11/XRobotPeer.java
src/solaris/classes/sun/awt/X11/XRobotPeer.java
+1
-2
src/solaris/native/sun/awt/awt_Robot.c
src/solaris/native/sun/awt/awt_Robot.c
+3
-104
src/windows/classes/sun/awt/windows/WFramePeer.java
src/windows/classes/sun/awt/windows/WFramePeer.java
+10
-2
src/windows/native/sun/java2d/d3d/D3DPipelineManager.cpp
src/windows/native/sun/java2d/d3d/D3DPipelineManager.cpp
+8
-0
src/windows/native/sun/windows/Devices.h
src/windows/native/sun/windows/Devices.h
+1
-1
src/windows/native/sun/windows/awt_Choice.cpp
src/windows/native/sun/windows/awt_Choice.cpp
+6
-0
src/windows/native/sun/windows/awt_Component.cpp
src/windows/native/sun/windows/awt_Component.cpp
+0
-1
src/windows/native/sun/windows/awt_Frame.cpp
src/windows/native/sun/windows/awt_Frame.cpp
+0
-11
test/java/awt/Component/Revalidate/Revalidate.java
test/java/awt/Component/Revalidate/Revalidate.java
+1
-1
test/java/awt/Container/ValidateRoot/InvalidateMustRespectValidateRoots.java
...iner/ValidateRoot/InvalidateMustRespectValidateRoots.java
+1
-1
test/java/awt/Toolkit/Headless/ExceptionContract/ExceptionContract.java
...Toolkit/Headless/ExceptionContract/ExceptionContract.java
+336
-0
未找到文件。
make/sun/xawt/mapfile-vers
浏览文件 @
ebecd936
...
@@ -158,7 +158,6 @@ SUNWprivate_1.1 {
...
@@ -158,7 +158,6 @@ SUNWprivate_1.1 {
Java_sun_awt_X11_XRobotPeer_mouseReleaseImpl;
Java_sun_awt_X11_XRobotPeer_mouseReleaseImpl;
Java_sun_awt_X11_XRobotPeer_mouseWheelImpl;
Java_sun_awt_X11_XRobotPeer_mouseWheelImpl;
Java_sun_awt_X11_XRobotPeer_setup;
Java_sun_awt_X11_XRobotPeer_setup;
Java_sun_awt_X11_XRobotPeer__1dispose;
Java_sun_awt_X11_XToolkit_getNumberOfButtonsImpl;
Java_sun_awt_X11_XToolkit_getNumberOfButtonsImpl;
Java_java_awt_Component_initIDs;
Java_java_awt_Component_initIDs;
Java_java_awt_Container_initIDs;
Java_java_awt_Container_initIDs;
...
...
src/share/classes/java/awt/Component.java
浏览文件 @
ebecd936
...
@@ -2887,11 +2887,12 @@ public abstract class Component implements ImageObserver, MenuContainer,
...
@@ -2887,11 +2887,12 @@ public abstract class Component implements ImageObserver, MenuContainer,
/**
/**
* Invalidates this component and its ancestors.
* Invalidates this component and its ancestors.
* <p>
* <p>
* All the ancestors of this component up to the nearest validate root are
* By default, all the ancestors of the component up to the top-most
* marked invalid also. If there is no a validate root container for this
* container of the hierarchy are marked invalid. If the {@code
* component, all of its ancestors up to the root of the hierarchy are
* java.awt.smartInvalidate} system property is set to {@code true},
* marked invalid as well. Marking a container <i>invalid</i> indicates
* invalidation stops on the nearest validate root of this component.
* that the container needs to be laid out.
* Marking a container <i>invalid</i> indicates that the container needs to
* be laid out.
* <p>
* <p>
* This method is called automatically when any layout-related information
* This method is called automatically when any layout-related information
* changes (e.g. setting the bounds of the component, or adding the
* changes (e.g. setting the bounds of the component, or adding the
...
...
src/share/classes/java/awt/Container.java
浏览文件 @
ebecd936
...
@@ -41,6 +41,8 @@ import java.io.ObjectStreamField;
...
@@ -41,6 +41,8 @@ import java.io.ObjectStreamField;
import
java.io.PrintStream
;
import
java.io.PrintStream
;
import
java.io.PrintWriter
;
import
java.io.PrintWriter
;
import
java.security.AccessController
;
import
java.util.Arrays
;
import
java.util.Arrays
;
import
java.util.EventListener
;
import
java.util.EventListener
;
import
java.util.HashSet
;
import
java.util.HashSet
;
...
@@ -60,6 +62,8 @@ import sun.awt.dnd.SunDropTargetEvent;
...
@@ -60,6 +62,8 @@ import sun.awt.dnd.SunDropTargetEvent;
import
sun.java2d.pipe.Region
;
import
sun.java2d.pipe.Region
;
import
sun.security.action.GetBooleanAction
;
/**
/**
* A generic Abstract Window Toolkit(AWT) container object is a component
* A generic Abstract Window Toolkit(AWT) container object is a component
* that can contain other AWT components.
* that can contain other AWT components.
...
@@ -1506,12 +1510,18 @@ public class Container extends Component {
...
@@ -1506,12 +1510,18 @@ public class Container extends Component {
* Layout-related changes, such as bounds of the validate root descendants,
* Layout-related changes, such as bounds of the validate root descendants,
* do not affect the layout of the validate root parent. This peculiarity
* do not affect the layout of the validate root parent. This peculiarity
* enables the {@code invalidate()} method to stop invalidating the
* enables the {@code invalidate()} method to stop invalidating the
* component hierarchy when the method encounters a validate root.
* component hierarchy when the method encounters a validate root. However,
* to preserve backward compatibility this new optimized behavior is
* enabled only when the {@code java.awt.smartInvalidate} system property
* value is set to {@code true}.
* <p>
* <p>
* If a component hierarchy contains validate roots, the {@code validate()}
* If a component hierarchy contains validate roots and the new optimized
* method must be invoked on the validate root of a previously invalidated
* {@code invalidate()} behavior is enabled, the {@code validate()} method
* component, rather than on the top-level container (such as a {@code
* must be invoked on the validate root of a previously invalidated
* Frame} object) to restore the validity of the hierarchy later.
* component to restore the validity of the hierarchy later. Otherwise,
* calling the {@code validate()} method on the top-level container (such
* as a {@code Frame} object) should be used to restore the validity of the
* component hierarchy.
* <p>
* <p>
* The {@code Window} class and the {@code Applet} class are the validate
* The {@code Window} class and the {@code Applet} class are the validate
* roots in AWT. Swing introduces more validate roots.
* roots in AWT. Swing introduces more validate roots.
...
@@ -1527,13 +1537,20 @@ public class Container extends Component {
...
@@ -1527,13 +1537,20 @@ public class Container extends Component {
return
false
;
return
false
;
}
}
private
static
final
boolean
isJavaAwtSmartInvalidate
;
static
{
// Don't lazy-read because every app uses invalidate()
isJavaAwtSmartInvalidate
=
AccessController
.
doPrivileged
(
new
GetBooleanAction
(
"java.awt.smartInvalidate"
));
}
/**
/**
* Invalidates the parent of the container unless the container
* Invalidates the parent of the container unless the container
* is a validate root.
* is a validate root.
*/
*/
@Override
@Override
void
invalidateParent
()
{
void
invalidateParent
()
{
if
(!
isValidateRoot
())
{
if
(!
is
JavaAwtSmartInvalidate
||
!
is
ValidateRoot
())
{
super
.
invalidateParent
();
super
.
invalidateParent
();
}
}
}
}
...
@@ -1572,9 +1589,8 @@ public class Container extends Component {
...
@@ -1572,9 +1589,8 @@ public class Container extends Component {
* automatically. Note that the ancestors of the container may be
* automatically. Note that the ancestors of the container may be
* invalidated also (see {@link Component#invalidate} for details.)
* invalidated also (see {@link Component#invalidate} for details.)
* Therefore, to restore the validity of the hierarchy, the {@code
* Therefore, to restore the validity of the hierarchy, the {@code
* validate()} method should be invoked on a validate root of an
* validate()} method should be invoked on the top-most invalid
* invalidated component, or on the top-most container if the hierarchy
* container of the hierarchy.
* does not contain validate roots.
* <p>
* <p>
* Validating the container may be a quite time-consuming operation. For
* Validating the container may be a quite time-consuming operation. For
* performance reasons a developer may postpone the validation of the
* performance reasons a developer may postpone the validation of the
...
...
src/share/classes/java/awt/Toolkit.java
浏览文件 @
ebecd936
...
@@ -466,10 +466,7 @@ public abstract class Toolkit {
...
@@ -466,10 +466,7 @@ public abstract class Toolkit {
*/
*/
protected
void
loadSystemColors
(
int
[]
systemColors
)
protected
void
loadSystemColors
(
int
[]
systemColors
)
throws
HeadlessException
{
throws
HeadlessException
{
if
(
GraphicsEnvironment
.
isHeadless
()){
GraphicsEnvironment
.
checkHeadless
();
throw
new
HeadlessException
();
}
}
}
/**
/**
...
@@ -504,10 +501,7 @@ public abstract class Toolkit {
...
@@ -504,10 +501,7 @@ public abstract class Toolkit {
*/
*/
public
void
setDynamicLayout
(
boolean
dynamic
)
public
void
setDynamicLayout
(
boolean
dynamic
)
throws
HeadlessException
{
throws
HeadlessException
{
if
(
GraphicsEnvironment
.
isHeadless
()){
GraphicsEnvironment
.
checkHeadless
();
throw
new
HeadlessException
();
}
}
}
/**
/**
...
@@ -531,9 +525,8 @@ public abstract class Toolkit {
...
@@ -531,9 +525,8 @@ public abstract class Toolkit {
*/
*/
protected
boolean
isDynamicLayoutSet
()
protected
boolean
isDynamicLayoutSet
()
throws
HeadlessException
{
throws
HeadlessException
{
if
(
GraphicsEnvironment
.
isHeadless
()){
GraphicsEnvironment
.
checkHeadless
();
throw
new
HeadlessException
();
}
if
(
this
!=
Toolkit
.
getDefaultToolkit
())
{
if
(
this
!=
Toolkit
.
getDefaultToolkit
())
{
return
Toolkit
.
getDefaultToolkit
().
isDynamicLayoutSet
();
return
Toolkit
.
getDefaultToolkit
().
isDynamicLayoutSet
();
}
else
{
}
else
{
...
@@ -569,9 +562,8 @@ public abstract class Toolkit {
...
@@ -569,9 +562,8 @@ public abstract class Toolkit {
*/
*/
public
boolean
isDynamicLayoutActive
()
public
boolean
isDynamicLayoutActive
()
throws
HeadlessException
{
throws
HeadlessException
{
if
(
GraphicsEnvironment
.
isHeadless
()){
GraphicsEnvironment
.
checkHeadless
();
throw
new
HeadlessException
();
}
if
(
this
!=
Toolkit
.
getDefaultToolkit
())
{
if
(
this
!=
Toolkit
.
getDefaultToolkit
())
{
return
Toolkit
.
getDefaultToolkit
().
isDynamicLayoutActive
();
return
Toolkit
.
getDefaultToolkit
().
isDynamicLayoutActive
();
}
else
{
}
else
{
...
@@ -615,9 +607,7 @@ public abstract class Toolkit {
...
@@ -615,9 +607,7 @@ public abstract class Toolkit {
*/
*/
public
Insets
getScreenInsets
(
GraphicsConfiguration
gc
)
public
Insets
getScreenInsets
(
GraphicsConfiguration
gc
)
throws
HeadlessException
{
throws
HeadlessException
{
if
(
GraphicsEnvironment
.
isHeadless
()){
GraphicsEnvironment
.
checkHeadless
();
throw
new
HeadlessException
();
}
if
(
this
!=
Toolkit
.
getDefaultToolkit
())
{
if
(
this
!=
Toolkit
.
getDefaultToolkit
())
{
return
Toolkit
.
getDefaultToolkit
().
getScreenInsets
(
gc
);
return
Toolkit
.
getDefaultToolkit
().
getScreenInsets
(
gc
);
}
else
{
}
else
{
...
@@ -1200,10 +1190,7 @@ public abstract class Toolkit {
...
@@ -1200,10 +1190,7 @@ public abstract class Toolkit {
* security manager's <code>checkPermission</code> method with a <code>
* security manager's <code>checkPermission</code> method with a <code>
* RuntimePermission("queuePrintJob")</code> permission.
* RuntimePermission("queuePrintJob")</code> permission.
*
*
* @param frame the parent of the print dialog. May be null if and only
* @param frame the parent of the print dialog. May not be null.
* if jobAttributes is not null and jobAttributes.getDialog()
* returns JobAttributes.DialogType.NONE or
* JobAttributes.DialogType.COMMON.
* @param jobtitle the title of the PrintJob. A null title is equivalent
* @param jobtitle the title of the PrintJob. A null title is equivalent
* to "".
* to "".
* @param jobAttributes a set of job attributes which will control the
* @param jobAttributes a set of job attributes which will control the
...
@@ -1359,9 +1346,8 @@ public abstract class Toolkit {
...
@@ -1359,9 +1346,8 @@ public abstract class Toolkit {
* @since 1.4
* @since 1.4
*/
*/
public
Clipboard
getSystemSelection
()
throws
HeadlessException
{
public
Clipboard
getSystemSelection
()
throws
HeadlessException
{
if
(
GraphicsEnvironment
.
isHeadless
()){
GraphicsEnvironment
.
checkHeadless
();
throw
new
HeadlessException
();
}
if
(
this
!=
Toolkit
.
getDefaultToolkit
())
{
if
(
this
!=
Toolkit
.
getDefaultToolkit
())
{
return
Toolkit
.
getDefaultToolkit
().
getSystemSelection
();
return
Toolkit
.
getDefaultToolkit
().
getSystemSelection
();
}
else
{
}
else
{
...
@@ -1391,9 +1377,7 @@ public abstract class Toolkit {
...
@@ -1391,9 +1377,7 @@ public abstract class Toolkit {
* @since JDK1.1
* @since JDK1.1
*/
*/
public
int
getMenuShortcutKeyMask
()
throws
HeadlessException
{
public
int
getMenuShortcutKeyMask
()
throws
HeadlessException
{
if
(
GraphicsEnvironment
.
isHeadless
()){
GraphicsEnvironment
.
checkHeadless
();
throw
new
HeadlessException
();
}
return
Event
.
CTRL_MASK
;
return
Event
.
CTRL_MASK
;
}
}
...
@@ -1418,7 +1402,10 @@ public abstract class Toolkit {
...
@@ -1418,7 +1402,10 @@ public abstract class Toolkit {
* @since 1.3
* @since 1.3
*/
*/
public
boolean
getLockingKeyState
(
int
keyCode
)
public
boolean
getLockingKeyState
(
int
keyCode
)
throws
UnsupportedOperationException
{
throws
UnsupportedOperationException
{
GraphicsEnvironment
.
checkHeadless
();
if
(!
(
keyCode
==
KeyEvent
.
VK_CAPS_LOCK
||
keyCode
==
KeyEvent
.
VK_NUM_LOCK
||
if
(!
(
keyCode
==
KeyEvent
.
VK_CAPS_LOCK
||
keyCode
==
KeyEvent
.
VK_NUM_LOCK
||
keyCode
==
KeyEvent
.
VK_SCROLL_LOCK
||
keyCode
==
KeyEvent
.
VK_KANA_LOCK
))
{
keyCode
==
KeyEvent
.
VK_SCROLL_LOCK
||
keyCode
==
KeyEvent
.
VK_KANA_LOCK
))
{
throw
new
IllegalArgumentException
(
"invalid key for Toolkit.getLockingKeyState"
);
throw
new
IllegalArgumentException
(
"invalid key for Toolkit.getLockingKeyState"
);
...
@@ -1449,7 +1436,10 @@ public abstract class Toolkit {
...
@@ -1449,7 +1436,10 @@ public abstract class Toolkit {
* @since 1.3
* @since 1.3
*/
*/
public
void
setLockingKeyState
(
int
keyCode
,
boolean
on
)
public
void
setLockingKeyState
(
int
keyCode
,
boolean
on
)
throws
UnsupportedOperationException
{
throws
UnsupportedOperationException
{
GraphicsEnvironment
.
checkHeadless
();
if
(!
(
keyCode
==
KeyEvent
.
VK_CAPS_LOCK
||
keyCode
==
KeyEvent
.
VK_NUM_LOCK
||
if
(!
(
keyCode
==
KeyEvent
.
VK_CAPS_LOCK
||
keyCode
==
KeyEvent
.
VK_NUM_LOCK
||
keyCode
==
KeyEvent
.
VK_SCROLL_LOCK
||
keyCode
==
KeyEvent
.
VK_KANA_LOCK
))
{
keyCode
==
KeyEvent
.
VK_SCROLL_LOCK
||
keyCode
==
KeyEvent
.
VK_KANA_LOCK
))
{
throw
new
IllegalArgumentException
(
"invalid key for Toolkit.setLockingKeyState"
);
throw
new
IllegalArgumentException
(
"invalid key for Toolkit.setLockingKeyState"
);
...
@@ -1523,9 +1513,8 @@ public abstract class Toolkit {
...
@@ -1523,9 +1513,8 @@ public abstract class Toolkit {
*/
*/
public
Dimension
getBestCursorSize
(
int
preferredWidth
,
public
Dimension
getBestCursorSize
(
int
preferredWidth
,
int
preferredHeight
)
throws
HeadlessException
{
int
preferredHeight
)
throws
HeadlessException
{
if
(
GraphicsEnvironment
.
isHeadless
()){
GraphicsEnvironment
.
checkHeadless
();
throw
new
HeadlessException
();
}
// Override to implement custom cursor support.
// Override to implement custom cursor support.
if
(
this
!=
Toolkit
.
getDefaultToolkit
())
{
if
(
this
!=
Toolkit
.
getDefaultToolkit
())
{
return
Toolkit
.
getDefaultToolkit
().
return
Toolkit
.
getDefaultToolkit
().
...
@@ -1553,9 +1542,8 @@ public abstract class Toolkit {
...
@@ -1553,9 +1542,8 @@ public abstract class Toolkit {
* @since 1.2
* @since 1.2
*/
*/
public
int
getMaximumCursorColors
()
throws
HeadlessException
{
public
int
getMaximumCursorColors
()
throws
HeadlessException
{
if
(
GraphicsEnvironment
.
isHeadless
()){
GraphicsEnvironment
.
checkHeadless
();
throw
new
HeadlessException
();
}
// Override to implement custom cursor support.
// Override to implement custom cursor support.
if
(
this
!=
Toolkit
.
getDefaultToolkit
())
{
if
(
this
!=
Toolkit
.
getDefaultToolkit
())
{
return
Toolkit
.
getDefaultToolkit
().
getMaximumCursorColors
();
return
Toolkit
.
getDefaultToolkit
().
getMaximumCursorColors
();
...
@@ -1605,9 +1593,8 @@ public abstract class Toolkit {
...
@@ -1605,9 +1593,8 @@ public abstract class Toolkit {
public
boolean
isFrameStateSupported
(
int
state
)
public
boolean
isFrameStateSupported
(
int
state
)
throws
HeadlessException
throws
HeadlessException
{
{
if
(
GraphicsEnvironment
.
isHeadless
()){
GraphicsEnvironment
.
checkHeadless
();
throw
new
HeadlessException
();
}
if
(
this
!=
Toolkit
.
getDefaultToolkit
())
{
if
(
this
!=
Toolkit
.
getDefaultToolkit
())
{
return
Toolkit
.
getDefaultToolkit
().
return
Toolkit
.
getDefaultToolkit
().
isFrameStateSupported
(
state
);
isFrameStateSupported
(
state
);
...
@@ -2614,9 +2601,8 @@ public abstract class Toolkit {
...
@@ -2614,9 +2601,8 @@ public abstract class Toolkit {
* @since 1.7
* @since 1.7
*/
*/
public
boolean
areExtraMouseButtonsEnabled
()
throws
HeadlessException
{
public
boolean
areExtraMouseButtonsEnabled
()
throws
HeadlessException
{
if
(
GraphicsEnvironment
.
isHeadless
()){
GraphicsEnvironment
.
checkHeadless
();
throw
new
HeadlessException
();
}
return
Toolkit
.
getDefaultToolkit
().
areExtraMouseButtonsEnabled
();
return
Toolkit
.
getDefaultToolkit
().
areExtraMouseButtonsEnabled
();
}
}
}
}
src/solaris/classes/sun/awt/X11/XRobotPeer.java
浏览文件 @
ebecd936
...
@@ -48,7 +48,7 @@ class XRobotPeer implements RobotPeer {
...
@@ -48,7 +48,7 @@ class XRobotPeer implements RobotPeer {
}
}
public
void
dispose
()
{
public
void
dispose
()
{
_dispose
();
// does nothing
}
}
public
void
mouseMove
(
int
x
,
int
y
)
{
public
void
mouseMove
(
int
x
,
int
y
)
{
...
@@ -88,7 +88,6 @@ class XRobotPeer implements RobotPeer {
...
@@ -88,7 +88,6 @@ class XRobotPeer implements RobotPeer {
}
}
private
static
native
synchronized
void
setup
(
int
numberOfButtons
,
int
[]
buttonDownMasks
);
private
static
native
synchronized
void
setup
(
int
numberOfButtons
,
int
[]
buttonDownMasks
);
private
static
native
synchronized
void
_dispose
();
private
static
native
synchronized
void
mouseMoveImpl
(
X11GraphicsConfig
xgc
,
int
x
,
int
y
);
private
static
native
synchronized
void
mouseMoveImpl
(
X11GraphicsConfig
xgc
,
int
x
,
int
y
);
private
static
native
synchronized
void
mousePressImpl
(
int
buttons
);
private
static
native
synchronized
void
mousePressImpl
(
int
buttons
);
...
...
src/solaris/native/sun/awt/awt_Robot.c
浏览文件 @
ebecd936
...
@@ -48,28 +48,12 @@
...
@@ -48,28 +48,12 @@
#ifdef __linux__
#ifdef __linux__
#include <sys/socket.h>
#include <sys/socket.h>
#endif
#endif
#include <dlfcn.h>
extern
struct
X11GraphicsConfigIDs
x11GraphicsConfigIDs
;
extern
struct
X11GraphicsConfigIDs
x11GraphicsConfigIDs
;
static
jint
*
masks
;
static
jint
*
masks
;
static
jint
num_buttons
;
static
jint
num_buttons
;
static
unsigned
int
s_robotInstanceCounter
=
0
;
static
void
*
xcompositeLibHandle
=
NULL
;
static
Bool
xcompositeExtAvailable
=
False
;
static
Bool
xcompositeExtTested
=
False
;
typedef
Status
(
*
T_XCompositeQueryVersion
)(
Display
*
dpy
,
int
*
major_versionp
,
int
*
minor_versionp
);
typedef
Window
(
*
T_XCompositeGetOverlayWindow
)(
Display
*
dpy
,
Window
window
);
typedef
void
(
*
T_XCompositeReleaseOverlayWindow
)(
Display
*
dpy
,
Window
window
);
static
T_XCompositeQueryVersion
XCompositeQueryVersion
=
NULL
;
static
T_XCompositeGetOverlayWindow
XCompositeGetOverlayWindow
=
NULL
;
static
T_XCompositeReleaseOverlayWindow
XCompositeReleaseOverlayWindow
=
NULL
;
static
int32_t
isXTestAvailable
()
{
static
int32_t
isXTestAvailable
()
{
int32_t
major_opcode
,
first_event
,
first_error
;
int32_t
major_opcode
,
first_event
,
first_error
;
int32_t
event_basep
,
error_basep
,
majorp
,
minorp
;
int32_t
event_basep
,
error_basep
,
majorp
,
minorp
;
...
@@ -210,80 +194,8 @@ Java_sun_awt_X11_XRobotPeer_setup (JNIEnv * env, jclass cls, jint numberOfButton
...
@@ -210,80 +194,8 @@ Java_sun_awt_X11_XRobotPeer_setup (JNIEnv * env, jclass cls, jint numberOfButton
}
}
AWT_UNLOCK
();
AWT_UNLOCK
();
s_robotInstanceCounter
++
;
}
}
JNIEXPORT
void
JNICALL
Java_sun_awt_X11_XRobotPeer__1dispose
(
JNIEnv
*
env
,
jclass
cls
)
{
if
(
--
s_robotInstanceCounter
)
{
return
;
}
// This is the last instance of the XRobotPeer being released
if
(
xcompositeExtTested
&&
xcompositeExtAvailable
&&
xcompositeLibHandle
)
{
// The lib is loaded in IsXCompositeAvailable(). Unload under AWT_LOCK
// so that the shutdown function of the lib behaves correctly.
AWT_LOCK
();
dlclose
(
xcompositeLibHandle
);
AWT_UNLOCK
();
}
xcompositeExtTested
=
False
;
xcompositeExtAvailable
=
False
;
xcompositeLibHandle
=
NULL
;
}
/*
* Returns True only if XCOMPOSITE is of version 0.3 or higher.
* The functions that we need are available since that version.
*
* Must be invoked under AWT_LOCK.
*
* Leaves the library loaded if the version is correct.
*/
static
Bool
IsXCompositeAvailable
()
{
if
(
!
xcompositeExtTested
)
{
int
opcode
,
eventb
,
errorb
;
if
(
XQueryExtension
(
awt_display
,
"Composite"
,
&
opcode
,
&
eventb
,
&
errorb
))
{
xcompositeLibHandle
=
dlopen
(
"libXcomposite.so.1"
,
RTLD_LAZY
|
RTLD_GLOBAL
);
#ifndef __linux__
/* SOLARIS */
if
(
xcompositeLibHandle
==
NULL
)
{
xcompositeLibHandle
=
dlopen
(
"/usr/sfw/lib/libXcomposite.so.1"
,
RTLD_LAZY
|
RTLD_GLOBAL
);
}
#endif
if
(
xcompositeLibHandle
)
{
int
major
,
minor
;
XCompositeQueryVersion
=
(
T_XCompositeQueryVersion
)
dlsym
(
xcompositeLibHandle
,
"XCompositeQueryVersion"
);
if
(
XCompositeQueryVersion
&&
XCompositeQueryVersion
(
awt_display
,
&
major
,
&
minor
))
{
if
(
major
>=
0
&&
minor
>=
3
)
{
XCompositeGetOverlayWindow
=
(
T_XCompositeGetOverlayWindow
)
dlsym
(
xcompositeLibHandle
,
"XCompositeGetOverlayWindow"
);
XCompositeReleaseOverlayWindow
=
(
T_XCompositeReleaseOverlayWindow
)
dlsym
(
xcompositeLibHandle
,
"XCompositeReleaseOverlayWindow"
);
if
(
XCompositeGetOverlayWindow
&&
XCompositeReleaseOverlayWindow
)
{
xcompositeExtAvailable
=
True
;
}
}
}
if
(
!
xcompositeExtAvailable
)
{
dlclose
(
xcompositeLibHandle
);
}
/* else the lib is unloaded in _dispose() */
}
}
xcompositeExtTested
=
True
;
}
return
xcompositeExtAvailable
;
}
JNIEXPORT
void
JNICALL
JNIEXPORT
void
JNICALL
Java_sun_awt_X11_XRobotPeer_getRGBPixelsImpl
(
JNIEnv
*
env
,
Java_sun_awt_X11_XRobotPeer_getRGBPixelsImpl
(
JNIEnv
*
env
,
...
@@ -299,7 +211,7 @@ Java_sun_awt_X11_XRobotPeer_getRGBPixelsImpl( JNIEnv *env,
...
@@ -299,7 +211,7 @@ Java_sun_awt_X11_XRobotPeer_getRGBPixelsImpl( JNIEnv *env,
jint
*
ary
;
/* Array of jints for sending pixel values back
jint
*
ary
;
/* Array of jints for sending pixel values back
* to parent process.
* to parent process.
*/
*/
Window
w
indow
;
Window
rootW
indow
;
AwtGraphicsConfigDataPtr
adata
;
AwtGraphicsConfigDataPtr
adata
;
DTRACE_PRINTLN6
(
"RobotPeer: getRGBPixelsImpl(%lx, %d, %d, %d, %d, %x)"
,
xgc
,
x
,
y
,
width
,
height
,
pixelArray
);
DTRACE_PRINTLN6
(
"RobotPeer: getRGBPixelsImpl(%lx, %d, %d, %d, %d, %x)"
,
xgc
,
x
,
y
,
width
,
height
,
pixelArray
);
...
@@ -316,24 +228,14 @@ Java_sun_awt_X11_XRobotPeer_getRGBPixelsImpl( JNIEnv *env,
...
@@ -316,24 +228,14 @@ Java_sun_awt_X11_XRobotPeer_getRGBPixelsImpl( JNIEnv *env,
adata
=
(
AwtGraphicsConfigDataPtr
)
JNU_GetLongFieldAsPtr
(
env
,
xgc
,
x11GraphicsConfigIDs
.
aData
);
adata
=
(
AwtGraphicsConfigDataPtr
)
JNU_GetLongFieldAsPtr
(
env
,
xgc
,
x11GraphicsConfigIDs
.
aData
);
DASSERT
(
adata
!=
NULL
);
DASSERT
(
adata
!=
NULL
);
window
=
XRootWindow
(
awt_display
,
adata
->
awt_visInfo
.
screen
);
rootWindow
=
XRootWindow
(
awt_display
,
adata
->
awt_visInfo
.
screen
);
image
=
getWindowImage
(
awt_display
,
rootWindow
,
x
,
y
,
width
,
height
);
if
(
IsXCompositeAvailable
())
{
// Use 'composite overlay window' instead of the root window.
// See 6903034 for details.
window
=
XCompositeGetOverlayWindow
(
awt_display
,
window
);
}
image
=
getWindowImage
(
awt_display
,
window
,
x
,
y
,
width
,
height
);
/* Array to use to crunch around the pixel values */
/* Array to use to crunch around the pixel values */
ary
=
(
jint
*
)
malloc
(
width
*
height
*
sizeof
(
jint
));
ary
=
(
jint
*
)
malloc
(
width
*
height
*
sizeof
(
jint
));
if
(
ary
==
NULL
)
{
if
(
ary
==
NULL
)
{
JNU_ThrowOutOfMemoryError
(
env
,
"OutOfMemoryError"
);
JNU_ThrowOutOfMemoryError
(
env
,
"OutOfMemoryError"
);
XDestroyImage
(
image
);
XDestroyImage
(
image
);
if
(
IsXCompositeAvailable
())
{
XCompositeReleaseOverlayWindow
(
awt_display
,
window
);
}
AWT_UNLOCK
();
AWT_UNLOCK
();
return
;
return
;
}
}
...
@@ -354,9 +256,6 @@ Java_sun_awt_X11_XRobotPeer_getRGBPixelsImpl( JNIEnv *env,
...
@@ -354,9 +256,6 @@ Java_sun_awt_X11_XRobotPeer_getRGBPixelsImpl( JNIEnv *env,
free
(
ary
);
free
(
ary
);
XDestroyImage
(
image
);
XDestroyImage
(
image
);
if
(
IsXCompositeAvailable
())
{
XCompositeReleaseOverlayWindow
(
awt_display
,
window
);
}
AWT_UNLOCK
();
AWT_UNLOCK
();
}
}
...
...
src/windows/classes/sun/awt/windows/WFramePeer.java
浏览文件 @
ebecd936
...
@@ -107,8 +107,16 @@ class WFramePeer extends WWindowPeer implements FramePeer {
...
@@ -107,8 +107,16 @@ class WFramePeer extends WWindowPeer implements FramePeer {
Rectangle
currentDevBounds
=
currentDevGC
.
getBounds
();
Rectangle
currentDevBounds
=
currentDevGC
.
getBounds
();
Rectangle
primaryDevBounds
=
primaryDevGC
.
getBounds
();
Rectangle
primaryDevBounds
=
primaryDevGC
.
getBounds
();
b
.
width
-=
(
currentDevBounds
.
width
-
primaryDevBounds
.
width
);
boolean
isCurrentDevLarger
=
b
.
height
-=
(
currentDevBounds
.
height
-
primaryDevBounds
.
height
);
((
currentDevBounds
.
width
-
primaryDevBounds
.
width
>
0
)
||
(
currentDevBounds
.
height
-
primaryDevBounds
.
height
>
0
));
// the window manager doesn't seem to compensate for differences when
// the primary monitor is larger than the monitor that display the window
if
(
isCurrentDevLarger
)
{
b
.
width
-=
(
currentDevBounds
.
width
-
primaryDevBounds
.
width
);
b
.
height
-=
(
currentDevBounds
.
height
-
primaryDevBounds
.
height
);
}
}
}
}
}
...
...
src/windows/native/sun/java2d/d3d/D3DPipelineManager.cpp
浏览文件 @
ebecd936
...
@@ -192,6 +192,14 @@ void D3DPipelineManager::NotifyAdapterEventListeners(UINT adapter,
...
@@ -192,6 +192,14 @@ void D3DPipelineManager::NotifyAdapterEventListeners(UINT adapter,
pMgr
=
D3DPipelineManager
::
GetInstance
();
pMgr
=
D3DPipelineManager
::
GetInstance
();
RETURN_IF_NULL
(
pMgr
);
RETURN_IF_NULL
(
pMgr
);
hMon
=
pMgr
->
pd3d9
->
GetAdapterMonitor
(
adapter
);
hMon
=
pMgr
->
pd3d9
->
GetAdapterMonitor
(
adapter
);
/*
* If we don't have devices initialized yet, no sense to clear them.
*/
if
(
!
Devices
::
GetInstance
()){
return
;
}
gdiScreen
=
AwtWin32GraphicsDevice
::
GetScreenFromHMONITOR
(
hMon
);
gdiScreen
=
AwtWin32GraphicsDevice
::
GetScreenFromHMONITOR
(
hMon
);
JNU_CallStaticMethodByName
(
env
,
NULL
,
JNU_CallStaticMethodByName
(
env
,
NULL
,
...
...
src/windows/native/sun/windows/Devices.h
浏览文件 @
ebecd936
...
@@ -36,6 +36,7 @@ class AwtWin32GraphicsDevice;
...
@@ -36,6 +36,7 @@ class AwtWin32GraphicsDevice;
class
Devices
{
class
Devices
{
public:
public:
static
Devices
*
GetInstance
();
static
BOOL
UpdateInstance
(
JNIEnv
*
env
);
static
BOOL
UpdateInstance
(
JNIEnv
*
env
);
int
GetNumDevices
()
{
return
numDevices
;
}
int
GetNumDevices
()
{
return
numDevices
;
}
AwtWin32GraphicsDevice
*
GetDeviceReference
(
int
index
,
BOOL
adjust
=
TRUE
);
AwtWin32GraphicsDevice
*
GetDeviceReference
(
int
index
,
BOOL
adjust
=
TRUE
);
...
@@ -59,7 +60,6 @@ friend class InstanceAccess;
...
@@ -59,7 +60,6 @@ friend class InstanceAccess;
private:
private:
Devices
(
int
numElements
);
Devices
(
int
numElements
);
void
AddReference
();
void
AddReference
();
static
Devices
*
GetInstance
();
AwtWin32GraphicsDevice
**
devices
;
AwtWin32GraphicsDevice
**
devices
;
int
refCount
;
int
refCount
;
...
...
src/windows/native/sun/windows/awt_Choice.cpp
浏览文件 @
ebecd936
...
@@ -396,6 +396,12 @@ LRESULT CALLBACK AwtChoice::ListWindowProc(HWND hwnd, UINT message,
...
@@ -396,6 +396,12 @@ LRESULT CALLBACK AwtChoice::ListWindowProc(HWND hwnd, UINT message,
DASSERT
(
::
IsWindow
(
hwnd
));
DASSERT
(
::
IsWindow
(
hwnd
));
// This branch is required for the proper work of AwtComponent::GetComponent() method
// while hovering drop-down list
if
(
message
==
WmAwtIsComponent
)
{
return
(
LRESULT
)
TRUE
;
}
switch
(
message
)
{
switch
(
message
)
{
case
WM_LBUTTONDOWN
:
{
case
WM_LBUTTONDOWN
:
{
DWORD
curPos
=
::
GetMessagePos
();
DWORD
curPos
=
::
GetMessagePos
();
...
...
src/windows/native/sun/windows/awt_Component.cpp
浏览文件 @
ebecd936
...
@@ -364,7 +364,6 @@ AwtComponent* AwtComponent::GetComponentImpl(HWND hWnd) {
...
@@ -364,7 +364,6 @@ AwtComponent* AwtComponent::GetComponentImpl(HWND hWnd) {
AwtComponent
*
component
=
AwtComponent
*
component
=
(
AwtComponent
*
)
::
GetWindowLongPtr
(
hWnd
,
GWLP_USERDATA
);
(
AwtComponent
*
)
::
GetWindowLongPtr
(
hWnd
,
GWLP_USERDATA
);
DASSERT
(
!
component
||
!
IsBadReadPtr
(
component
,
sizeof
(
AwtComponent
))
);
DASSERT
(
!
component
||
!
IsBadReadPtr
(
component
,
sizeof
(
AwtComponent
))
);
DASSERT
(
!
component
||
component
->
GetHWnd
()
==
hWnd
);
return
component
;
return
component
;
}
}
...
...
src/windows/native/sun/windows/awt_Frame.cpp
浏览文件 @
ebecd936
...
@@ -344,17 +344,6 @@ LRESULT AwtFrame::ProxyWindowProc(UINT message, WPARAM wParam, LPARAM lParam, Ms
...
@@ -344,17 +344,6 @@ LRESULT AwtFrame::ProxyWindowProc(UINT message, WPARAM wParam, LPARAM lParam, Ms
SetImeTargetComponent
(
NULL
);
SetImeTargetComponent
(
NULL
);
}
}
break
;
break
;
// TODO: when a Choice's list is dropped down and we're scrolling in
// the list WM_MOUSEWHEEL messages come to the poxy, not to the list. Why?
case
WM_MOUSEWHEEL
:
focusOwner
=
AwtComponent
::
GetComponent
(
sm_focusOwner
);
if
(
focusOwner
!=
NULL
&&
focusOwner
!=
this
)
// avoid recursive calls
{
retValue
=
focusOwner
->
WindowProc
(
message
,
wParam
,
lParam
);
mr
=
mrConsume
;
}
break
;
case
WM_SETFOCUS
:
case
WM_SETFOCUS
:
if
(
sm_inSynthesizeFocus
)
break
;
// pass it up the WindowProc chain
if
(
sm_inSynthesizeFocus
)
break
;
// pass it up the WindowProc chain
...
...
test/java/awt/Component/Revalidate/Revalidate.java
浏览文件 @
ebecd936
...
@@ -26,7 +26,7 @@
...
@@ -26,7 +26,7 @@
@bug 7036669
@bug 7036669
@summary Test Component.revalidate() method
@summary Test Component.revalidate() method
@author anthony.petrov@oracle.com: area=awt.component
@author anthony.petrov@oracle.com: area=awt.component
@run main Revalidate
@run main
/othervm -Djava.awt.smartInvalidate=true
Revalidate
*/
*/
import
java.awt.*
;
import
java.awt.*
;
...
...
test/java/awt/Container/ValidateRoot/InvalidateMustRespectValidateRoots.java
浏览文件 @
ebecd936
...
@@ -26,7 +26,7 @@
...
@@ -26,7 +26,7 @@
@bug 6852592
@bug 6852592
@summary invalidate() must stop when it encounters a validate root
@summary invalidate() must stop when it encounters a validate root
@author anthony.petrov@sun.com
@author anthony.petrov@sun.com
@run main InvalidateMustRespectValidateRoots
@run main
/othervm -Djava.awt.smartInvalidate=true
InvalidateMustRespectValidateRoots
*/
*/
import
javax.swing.*
;
import
javax.swing.*
;
...
...
test/java/awt/Toolkit/Headless/ExceptionContract/ExceptionContract.java
0 → 100644
浏览文件 @
ebecd936
/*
* Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation. Oracle designates this
* particular file as subject to the "Classpath" exception as provided
* by Oracle in the LICENSE file that accompanied this code.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
/*
@test
@bug 7040577
@library ../../../regtesthelpers
@build Sysout
@summary Default implementation of Toolkit.loadSystemColors(int[]) and many others doesn't throw HE in hl env
@author andrei dmitriev: area=awt.headless
@run main/othervm -Djava.awt.headless=true ExceptionContract
*/
import
java.awt.*
;
import
java.util.Properties
;
import
test.java.awt.regtesthelpers.Sysout
;
import
java.awt.datatransfer.Clipboard
;
import
java.awt.dnd.*
;
import
java.awt.dnd.peer.DragSourceContextPeer
;
import
java.awt.font.TextAttribute
;
import
java.awt.im.InputMethodHighlight
;
import
java.awt.image.*
;
import
java.awt.peer.*
;
import
java.net.URL
;
import
java.util.Map
;
import
java.util.Properties
;
public
class
ExceptionContract
{
private
static
boolean
passed
=
false
;
public
static
void
main
(
String
[]
args
)
{
//Case1
try
{
new
_Toolkit
().
getLockingKeyState
(
1
);
}
catch
(
HeadlessException
he
){
passed
=
true
;
}
if
(!
passed
){
throw
new
RuntimeException
(
"Tk.getLockingKeyState() didn't throw HeadlessException while in the headless mode."
);
}
passed
=
false
;
//Case2
try
{
new
_Toolkit
().
setLockingKeyState
(
1
,
true
);
}
catch
(
HeadlessException
he
){
passed
=
true
;
}
if
(!
passed
){
throw
new
RuntimeException
(
"Tk.setLockingKeyState() didn't throw HeadlessException while in the headless mode."
);
}
passed
=
false
;
//Case3
try
{
new
_Toolkit
().
createCustomCursor
(
new
BufferedImage
(
16
,
16
,
BufferedImage
.
TYPE_INT_RGB
),
new
Point
(
0
,
0
),
"Custom cursor"
);
}
catch
(
HeadlessException
he
){
he
.
printStackTrace
();
passed
=
true
;
}
if
(!
passed
){
throw
new
RuntimeException
(
"Tk.createCustomCursor(args) didn't throw HeadlessException while in the headless mode."
);
}
}
static
class
_Toolkit
extends
Toolkit
{
@Override
public
Cursor
createCustomCursor
(
Image
cursor
,
Point
hotSpot
,
String
name
)
throws
IndexOutOfBoundsException
,
HeadlessException
{
return
super
.
createCustomCursor
(
cursor
,
hotSpot
,
name
);
}
@Override
public
void
setLockingKeyState
(
int
keyCode
,
boolean
on
)
throws
UnsupportedOperationException
{
super
.
setLockingKeyState
(
keyCode
,
on
);
}
@Override
public
boolean
getLockingKeyState
(
int
keyCode
)
throws
UnsupportedOperationException
{
return
super
.
getLockingKeyState
(
keyCode
);
}
@Override
public
void
loadSystemColors
(
int
[]
systemColors
)
throws
HeadlessException
{
return
;
}
@Override
protected
DesktopPeer
createDesktopPeer
(
Desktop
target
)
throws
HeadlessException
{
return
null
;
}
@Override
protected
ButtonPeer
createButton
(
Button
target
)
throws
HeadlessException
{
return
null
;
}
@Override
protected
TextFieldPeer
createTextField
(
TextField
target
)
throws
HeadlessException
{
return
null
;
}
@Override
protected
LabelPeer
createLabel
(
Label
target
)
throws
HeadlessException
{
return
null
;
}
@Override
protected
ListPeer
createList
(
List
target
)
throws
HeadlessException
{
return
null
;
}
@Override
protected
CheckboxPeer
createCheckbox
(
Checkbox
target
)
throws
HeadlessException
{
return
null
;
}
@Override
protected
ScrollbarPeer
createScrollbar
(
Scrollbar
target
)
throws
HeadlessException
{
return
null
;
}
@Override
protected
ScrollPanePeer
createScrollPane
(
ScrollPane
target
)
throws
HeadlessException
{
return
null
;
}
@Override
protected
TextAreaPeer
createTextArea
(
TextArea
target
)
throws
HeadlessException
{
return
null
;
}
@Override
protected
ChoicePeer
createChoice
(
Choice
target
)
throws
HeadlessException
{
return
null
;
}
@Override
protected
FramePeer
createFrame
(
Frame
target
)
throws
HeadlessException
{
return
null
;
}
@Override
protected
CanvasPeer
createCanvas
(
Canvas
target
)
{
return
null
;
}
@Override
protected
PanelPeer
createPanel
(
Panel
target
)
{
return
null
;
}
@Override
protected
WindowPeer
createWindow
(
Window
target
)
throws
HeadlessException
{
return
null
;
}
@Override
protected
DialogPeer
createDialog
(
Dialog
target
)
throws
HeadlessException
{
return
null
;
}
@Override
protected
MenuBarPeer
createMenuBar
(
MenuBar
target
)
throws
HeadlessException
{
return
null
;
}
@Override
protected
MenuPeer
createMenu
(
Menu
target
)
throws
HeadlessException
{
return
null
;
}
@Override
protected
PopupMenuPeer
createPopupMenu
(
PopupMenu
target
)
throws
HeadlessException
{
return
null
;
}
@Override
protected
MenuItemPeer
createMenuItem
(
MenuItem
target
)
throws
HeadlessException
{
return
null
;
}
@Override
protected
FileDialogPeer
createFileDialog
(
FileDialog
target
)
throws
HeadlessException
{
return
null
;
}
@Override
protected
CheckboxMenuItemPeer
createCheckboxMenuItem
(
CheckboxMenuItem
target
)
throws
HeadlessException
{
return
null
;
}
@Override
protected
FontPeer
getFontPeer
(
String
name
,
int
style
)
{
return
null
;
}
@Override
public
Dimension
getScreenSize
()
throws
HeadlessException
{
return
null
;
}
@Override
public
int
getScreenResolution
()
throws
HeadlessException
{
return
0
;
}
@Override
public
ColorModel
getColorModel
()
throws
HeadlessException
{
return
null
;
}
@Override
public
String
[]
getFontList
()
{
return
new
String
[
0
];
}
@Override
public
FontMetrics
getFontMetrics
(
Font
font
)
{
return
null
;
}
@Override
public
void
sync
()
{
}
@Override
public
Image
getImage
(
String
filename
)
{
return
null
;
}
@Override
public
Image
getImage
(
URL
url
)
{
return
null
;
}
@Override
public
Image
createImage
(
String
filename
)
{
return
null
;
}
@Override
public
Image
createImage
(
URL
url
)
{
return
null
;
}
@Override
public
boolean
prepareImage
(
Image
image
,
int
width
,
int
height
,
ImageObserver
observer
)
{
return
false
;
}
@Override
public
int
checkImage
(
Image
image
,
int
width
,
int
height
,
ImageObserver
observer
)
{
return
0
;
}
@Override
public
Image
createImage
(
ImageProducer
producer
)
{
return
null
;
}
@Override
public
Image
createImage
(
byte
[]
imagedata
,
int
imageoffset
,
int
imagelength
)
{
return
null
;
}
@Override
public
PrintJob
getPrintJob
(
Frame
frame
,
String
jobtitle
,
Properties
props
)
{
return
null
;
}
@Override
public
void
beep
()
{
}
@Override
public
Clipboard
getSystemClipboard
()
throws
HeadlessException
{
return
null
;
}
@Override
protected
EventQueue
getSystemEventQueueImpl
()
{
return
null
;
}
@Override
public
DragSourceContextPeer
createDragSourceContextPeer
(
DragGestureEvent
dge
)
throws
InvalidDnDOperationException
{
return
null
;
}
@Override
public
boolean
isModalityTypeSupported
(
Dialog
.
ModalityType
modalityType
)
{
return
false
;
}
@Override
public
boolean
isModalExclusionTypeSupported
(
Dialog
.
ModalExclusionType
modalExclusionType
)
{
return
false
;
}
@Override
public
Map
<
TextAttribute
,
?>
mapInputMethodHighlight
(
InputMethodHighlight
highlight
)
throws
HeadlessException
{
return
null
;
}
}
}
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录