Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openanolis
dragonwell8_jdk
提交
4b688e3f
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看板
提交
4b688e3f
编写于
10月 21, 2015
作者:
A
aivanov
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
8130136: Swing window sometimes fails to repaint partially when it becomes exposed
Reviewed-by: alexp, serb
上级
4e59f93c
变更
4
隐藏空白更改
内联
并排
Showing
4 changed file
with
17 addition
and
14 deletion
+17
-14
src/windows/native/sun/java2d/windows/GDIWindowSurfaceData.cpp
...indows/native/sun/java2d/windows/GDIWindowSurfaceData.cpp
+5
-3
src/windows/native/sun/java2d/windows/GDIWindowSurfaceData.h
src/windows/native/sun/java2d/windows/GDIWindowSurfaceData.h
+2
-1
src/windows/native/sun/windows/awt_Component.cpp
src/windows/native/sun/windows/awt_Component.cpp
+7
-7
src/windows/native/sun/windows/awt_Component.h
src/windows/native/sun/windows/awt_Component.h
+3
-3
未找到文件。
src/windows/native/sun/java2d/windows/GDIWindowSurfaceData.cpp
浏览文件 @
4b688e3f
/*
* Copyright (c) 1999, 201
3
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1999, 201
5
, 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
...
...
@@ -114,8 +114,9 @@ void SetupThreadGraphicsInfo(JNIEnv *env, GDIWinSDOps *wsdo) {
// which may've been disposed by this time, and we have
// no means of checking against it.
if
(
oldhDC
!=
NULL
)
{
MoveDCToPassiveList
(
oldhDC
);
MoveDCToPassiveList
(
oldhDC
,
info
->
hWnd
);
info
->
hDC
=
NULL
;
info
->
hWnd
=
NULL
;
}
if
(
wsdo
->
window
!=
NULL
){
...
...
@@ -150,6 +151,7 @@ void SetupThreadGraphicsInfo(JNIEnv *env, GDIWinSDOps *wsdo) {
// Finally, set these new values in the info for this thread
info
->
hDC
=
hDC
;
info
->
hWnd
=
wsdo
->
window
;
}
// cached brush and pen are not associated with any DC, and can be
...
...
@@ -187,7 +189,7 @@ void DisposeThreadGraphicsInfo(JNIEnv *env, jlong tgi) {
if
(
info
->
hDC
!=
NULL
)
{
// move the DC from the active dcs list to
// the passive dc list to be released later
MoveDCToPassiveList
(
info
->
hDC
);
MoveDCToPassiveList
(
info
->
hDC
,
info
->
hWnd
);
}
if
(
info
->
clip
!=
NULL
)
{
...
...
src/windows/native/sun/java2d/windows/GDIWindowSurfaceData.h
浏览文件 @
4b688e3f
/*
* Copyright (c) 1999, 201
0
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1999, 201
5
, 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
...
...
@@ -196,6 +196,7 @@ extern "C" {
*/
typedef
struct
{
HDC
hDC
;
HWND
hWnd
;
GDIWinSDOps
*
wsdo
;
LONG
wsdoTimeStamp
;
// wsdo creation time stamp.
// Other threads may deallocate wsdo
...
...
src/windows/native/sun/windows/awt_Component.cpp
浏览文件 @
4b688e3f
...
...
@@ -1382,7 +1382,7 @@ LRESULT AwtComponent::WindowProc(UINT message, WPARAM wParam, LPARAM lParam)
case
WM_AWT_RELEASEDC
:
{
HDC
hDC
=
(
HDC
)
wParam
;
MoveDCToPassiveList
(
hDC
);
MoveDCToPassiveList
(
hDC
,
GetHWnd
()
);
ReleaseDCList
(
GetHWnd
(),
passiveDCList
);
mr
=
mrConsume
;
break
;
...
...
@@ -7174,8 +7174,8 @@ void DCList::AddDCItem(DCItem *newItem)
}
/**
* Given a DC
, remove it from the DC list and return
* TRUE if it exists on the current list. Otherwise
* Given a DC
and window handle, remove the DC from the DC list
*
and return
TRUE if it exists on the current list. Otherwise
* return FALSE.
* A DC may not exist on the list because it has already
* been released elsewhere (for example, the window
...
...
@@ -7183,14 +7183,14 @@ void DCList::AddDCItem(DCItem *newItem)
* thread may also want to release a DC when it notices that
* its DC is obsolete for the current window).
*/
DCItem
*
DCList
::
RemoveDC
(
HDC
hDC
)
DCItem
*
DCList
::
RemoveDC
(
HDC
hDC
,
HWND
hWnd
)
{
listLock
.
Enter
();
DCItem
**
prevPtrPtr
=
&
head
;
DCItem
*
listPtr
=
head
;
while
(
listPtr
)
{
DCItem
*
nextPtr
=
listPtr
->
next
;
if
(
listPtr
->
hDC
==
hDC
)
{
if
(
listPtr
->
hDC
==
hDC
&&
listPtr
->
hWnd
==
hWnd
)
{
*
prevPtrPtr
=
nextPtr
;
break
;
}
...
...
@@ -7244,9 +7244,9 @@ void DCList::RealizePalettes(int screen)
listLock
.
Leave
();
}
void
MoveDCToPassiveList
(
HDC
hDC
)
{
void
MoveDCToPassiveList
(
HDC
hDC
,
HWND
hWnd
)
{
DCItem
*
removedDC
;
if
((
removedDC
=
activeDCList
.
RemoveDC
(
hDC
))
!=
NULL
)
{
if
((
removedDC
=
activeDCList
.
RemoveDC
(
hDC
,
hWnd
))
!=
NULL
)
{
passiveDCList
.
AddDCItem
(
removedDC
);
}
}
...
...
src/windows/native/sun/windows/awt_Component.h
浏览文件 @
4b688e3f
/*
* Copyright (c) 1996, 201
3
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1996, 201
5
, 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
...
...
@@ -900,13 +900,13 @@ public:
void
AddDC
(
HDC
hDC
,
HWND
hWnd
);
void
AddDCItem
(
DCItem
*
newItem
);
DCItem
*
RemoveDC
(
HDC
hDC
);
DCItem
*
RemoveDC
(
HDC
hDC
,
HWND
hWnd
);
DCItem
*
RemoveAllDCs
(
HWND
hWnd
);
void
RealizePalettes
(
int
screen
);
};
void
ReleaseDCList
(
HWND
hwnd
,
DCList
&
list
);
void
MoveDCToPassiveList
(
HDC
hDC
);
void
MoveDCToPassiveList
(
HDC
hDC
,
HWND
hWnd
);
namespace
TimeHelper
{
jlong
getMessageTimeUTC
();
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录