Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
704412b4
Commit
704412b4
authored
Mar 03, 2013
by
Daniel Jelinski
Committed by
Alexandre Julliard
Mar 04, 2013
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
comctl32/listview: Fix custom draw prepaint handling.
parent
0ee1df59
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
14 deletions
+5
-14
listview.c
dlls/comctl32/listview.c
+1
-13
listview.c
dlls/comctl32/tests/listview.c
+4
-1
No files found.
dlls/comctl32/listview.c
View file @
704412b4
...
...
@@ -5037,7 +5037,7 @@ static void LISTVIEW_RefreshList(LISTVIEW_INFO *infoPtr, ITERATOR *i, HDC hdc, D
*/
static
void
LISTVIEW_Refresh
(
LISTVIEW_INFO
*
infoPtr
,
HDC
hdc
,
const
RECT
*
prcErase
)
{
COLORREF
oldTextColor
=
0
,
oldBkColor
=
0
,
oldClrTextBk
,
oldClrText
;
COLORREF
oldTextColor
=
0
,
oldBkColor
=
0
;
NMLVCUSTOMDRAW
nmlvcd
;
HFONT
hOldFont
=
0
;
DWORD
cdmode
;
...
...
@@ -5094,21 +5094,12 @@ static void LISTVIEW_Refresh(LISTVIEW_INFO *infoPtr, HDC hdc, const RECT *prcEra
hdcOrig
,
infoPtr
->
rcList
.
left
,
infoPtr
->
rcList
.
top
,
SRCCOPY
);
}
/* FIXME: Shouldn't need to do this */
oldClrTextBk
=
infoPtr
->
clrTextBk
;
oldClrText
=
infoPtr
->
clrText
;
infoPtr
->
cditemmode
=
CDRF_DODEFAULT
;
GetClientRect
(
infoPtr
->
hwndSelf
,
&
rcClient
);
customdraw_fill
(
&
nmlvcd
,
infoPtr
,
hdc
,
&
rcClient
,
0
);
cdmode
=
notify_customdraw
(
infoPtr
,
CDDS_PREPAINT
,
&
nmlvcd
);
if
(
cdmode
&
CDRF_SKIPDEFAULT
)
goto
enddraw
;
prepaint_setup
(
infoPtr
,
hdc
,
&
nmlvcd
,
FALSE
);
/* Use these colors to draw the items */
infoPtr
->
clrTextBk
=
nmlvcd
.
clrTextBk
;
infoPtr
->
clrText
=
nmlvcd
.
clrText
;
/* nothing to draw */
if
(
infoPtr
->
nItemCount
==
0
)
goto
enddraw
;
...
...
@@ -5157,9 +5148,6 @@ enddraw:
if
(
cdmode
&
CDRF_NOTIFYPOSTPAINT
)
notify_postpaint
(
infoPtr
,
&
nmlvcd
);
infoPtr
->
clrTextBk
=
oldClrTextBk
;
infoPtr
->
clrText
=
oldClrText
;
if
(
hbmp
)
{
BitBlt
(
hdcOrig
,
infoPtr
->
rcList
.
left
,
infoPtr
->
rcList
.
top
,
infoPtr
->
rcList
.
right
-
infoPtr
->
rcList
.
left
,
...
...
dlls/comctl32/tests/listview.c
View file @
704412b4
...
...
@@ -1765,7 +1765,10 @@ static LRESULT WINAPI cd_wndproc(HWND hwnd, UINT msg, WPARAM wp, LPARAM lp)
return
CDRF_NOTIFYSUBITEMDRAW
;
case
CDDS_ITEMPREPAINT
|
CDDS_SUBITEM
:
clr
=
GetBkColor
(
nmlvcd
->
nmcd
.
hdc
);
todo_wine
ok
(
clr
==
c0ffee
,
"clr=%.8x
\n
"
,
clr
);
if
(
nmlvcd
->
iSubItem
)
todo_wine
ok
(
clr
==
c0ffee
,
"clr=%.8x
\n
"
,
clr
);
else
ok
(
clr
==
c0ffee
,
"clr=%.8x
\n
"
,
clr
);
return
CDRF_NOTIFYPOSTPAINT
;
case
CDDS_ITEMPOSTPAINT
|
CDDS_SUBITEM
:
clr
=
GetBkColor
(
nmlvcd
->
nmcd
.
hdc
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment