Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openanolis
dragonwell8_jdk
提交
e1149860
D
dragonwell8_jdk
项目概览
openanolis
/
dragonwell8_jdk
通知
4
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看板
提交
e1149860
编写于
5月 13, 2008
作者:
P
prr
浏览文件
操作
浏览文件
下载
差异文件
Merge
上级
32cce5fa
6db9f186
变更
1
隐藏空白更改
内联
并排
Showing
1 changed file
with
40 addition
and
9 deletion
+40
-9
src/solaris/native/sun/awt/awt_GraphicsEnv.c
src/solaris/native/sun/awt/awt_GraphicsEnv.c
+40
-9
未找到文件。
src/solaris/native/sun/awt/awt_GraphicsEnv.c
浏览文件 @
e1149860
...
...
@@ -1626,6 +1626,8 @@ Java_sun_awt_X11GraphicsEnvironment_getXineramaCenterPoint(JNIEnv *env,
#define BIT_DEPTH_MULTI java_awt_DisplayMode_BIT_DEPTH_MULTI
typedef
Status
(
*
XRRQueryVersionType
)
(
Display
*
dpy
,
int
*
major_versionp
,
int
*
minor_versionp
);
typedef
XRRScreenConfiguration
*
(
*
XRRGetScreenInfoType
)(
Display
*
dpy
,
Drawable
root
);
typedef
void
...
...
@@ -1650,6 +1652,7 @@ typedef Status
short
rate
,
Time
timestamp
);
static
XRRQueryVersionType
awt_XRRQueryVersion
;
static
XRRGetScreenInfoType
awt_XRRGetScreenInfo
;
static
XRRFreeScreenConfigInfoType
awt_XRRFreeScreenConfigInfo
;
static
XRRConfigRatesType
awt_XRRConfigRates
;
...
...
@@ -1672,6 +1675,8 @@ static XRRSetScreenConfigAndRateType awt_XRRSetScreenConfigAndRate;
static
jboolean
X11GD_InitXrandrFuncs
(
JNIEnv
*
env
)
{
int
rr_maj_ver
=
0
,
rr_min_ver
=
0
;
void
*
pLibRandR
=
dlopen
(
"libXrandr.so.2"
,
RTLD_LAZY
|
RTLD_LOCAL
);
if
(
pLibRandR
==
NULL
)
{
J2dRlsTraceLn
(
J2D_TRACE_ERROR
,
...
...
@@ -1679,6 +1684,41 @@ X11GD_InitXrandrFuncs(JNIEnv *env)
return
JNI_FALSE
;
}
LOAD_XRANDR_FUNC
(
XRRQueryVersion
);
if
(
!
(
*
awt_XRRQueryVersion
)(
awt_display
,
&
rr_maj_ver
,
&
rr_min_ver
))
{
J2dRlsTraceLn
(
J2D_TRACE_ERROR
,
"X11GD_InitXrandrFuncs: XRRQueryVersion returned an error status"
);
dlclose
(
pLibRandR
);
return
JNI_FALSE
;
}
if
(
usingXinerama
)
{
/*
* We can proceed as long as this is RANDR 1.2 or above.
* As of Xorg server 1.3 onwards the Xinerama backend may actually be
* a fake one provided by RANDR itself. See Java bug 6636469 for info.
*/
if
(
!
(
rr_maj_ver
>
1
||
(
rr_maj_ver
==
1
&&
rr_min_ver
>=
2
)))
{
J2dRlsTraceLn2
(
J2D_TRACE_INFO
,
"X11GD_InitXrandrFuncs: Can't use Xrandr. "
"Xinerama is active and Xrandr version is %d.%d"
,
rr_maj_ver
,
rr_min_ver
);
dlclose
(
pLibRandR
);
return
JNI_FALSE
;
}
/*
* REMIND: Fullscreen mode doesn't work quite right with multi-monitor
* setups and RANDR 1.2. So for now we also require a single screen.
*/
if
(
awt_numScreens
>
1
)
{
J2dRlsTraceLn
(
J2D_TRACE_INFO
,
"X11GD_InitXrandrFuncs: Can't use Xrandr. "
"Multiple screens in use"
);
dlclose
(
pLibRandR
);
return
JNI_FALSE
;
}
}
LOAD_XRANDR_FUNC
(
XRRGetScreenInfo
);
LOAD_XRANDR_FUNC
(
XRRFreeScreenConfigInfo
);
LOAD_XRANDR_FUNC
(
XRRConfigRates
);
...
...
@@ -1814,15 +1854,6 @@ Java_sun_awt_X11GraphicsDevice_initXrandrExtension
int
opcode
=
0
,
firstEvent
=
0
,
firstError
=
0
;
jboolean
ret
;
if
(
usingXinerama
)
{
/*
* REMIND: we'll just punt if Xinerama is enabled; we can remove this
* restriction in the future if we find Xinerama and XRandR playing
* well together...
*/
return
JNI_FALSE
;
}
AWT_LOCK
();
ret
=
(
jboolean
)
XQueryExtension
(
awt_display
,
"RANDR"
,
&
opcode
,
&
firstEvent
,
&
firstError
);
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录