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
0bc4b565
Commit
0bc4b565
authored
Oct 15, 2002
by
Dimitrie O. Paun
Committed by
Alexandre Julliard
Oct 15, 2002
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Do not merge image with garbage background. Based on a patch by Carlos
<clozano@andago.com>.
parent
0ee7073d
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
13 deletions
+9
-13
imagelist.c
dlls/comctl32/imagelist.c
+9
-13
No files found.
dlls/comctl32/imagelist.c
View file @
0bc4b565
...
@@ -1083,7 +1083,7 @@ ImageList_DrawIndirect (IMAGELISTDRAWPARAMS *pimldp)
...
@@ -1083,7 +1083,7 @@ ImageList_DrawIndirect (IMAGELISTDRAWPARAMS *pimldp)
cx
=
(
pimldp
->
cx
==
0
)
?
himl
->
cx
:
pimldp
->
cx
;
cx
=
(
pimldp
->
cx
==
0
)
?
himl
->
cx
:
pimldp
->
cx
;
cy
=
(
pimldp
->
cy
==
0
)
?
himl
->
cy
:
pimldp
->
cy
;
cy
=
(
pimldp
->
cy
==
0
)
?
himl
->
cy
:
pimldp
->
cy
;
clrBk
=
(
pimldp
->
rgbBk
==
CLR_DEFAULT
)
?
himl
->
clrBk
:
pimldp
->
rgbBk
;
clrBk
=
(
pimldp
->
rgbBk
==
CLR_DEFAULT
)
?
himl
->
clrBk
:
pimldp
->
rgbBk
;
bIsTransparent
=
himl
->
hbmMask
&&
((
fStyle
&
ILD_TRANSPARENT
)
||
clrBk
==
CLR_NONE
)
;
bIsTransparent
=
(
fStyle
&
ILD_TRANSPARENT
)
||
clrBk
==
CLR_NONE
;
bBlend
=
fStyle
&
(
ILD_BLEND25
|
ILD_BLEND50
);
bBlend
=
fStyle
&
(
ILD_BLEND25
|
ILD_BLEND50
);
TRACE
(
"hbmMask(0x%08x) iImage(%d) x(%d) y(%d) cx(%d) cy(%d)
\n
"
,
TRACE
(
"hbmMask(0x%08x) iImage(%d) x(%d) y(%d) cx(%d) cy(%d)
\n
"
,
...
@@ -1115,15 +1115,8 @@ ImageList_DrawIndirect (IMAGELISTDRAWPARAMS *pimldp)
...
@@ -1115,15 +1115,8 @@ ImageList_DrawIndirect (IMAGELISTDRAWPARAMS *pimldp)
oldImageFg
=
SetTextColor
(
hImageDC
,
RGB
(
0
,
0
,
0
)
);
oldImageFg
=
SetTextColor
(
hImageDC
,
RGB
(
0
,
0
,
0
)
);
oldImageBk
=
SetBkColor
(
hImageDC
,
RGB
(
0xff
,
0xff
,
0xff
)
);
oldImageBk
=
SetBkColor
(
hImageDC
,
RGB
(
0xff
,
0xff
,
0xff
)
);
/* If we have an opaque image, draw the background */
if
(
!
bIsTransparent
&&
himl
->
hbmMask
)
{
HBRUSH
hOldBrush
=
SelectObject
(
hImageDC
,
CreateSolidBrush
(
clrBk
));
PatBlt
(
hImageDC
,
0
,
0
,
cx
,
cy
,
PATCOPY
);
DeleteObject
(
SelectObject
(
hImageDC
,
hOldBrush
));
}
/*
/*
* Draw
Image over the current background
* Draw
the initial image
*/
*/
if
(
fStyle
&
ILD_MASK
)
{
if
(
fStyle
&
ILD_MASK
)
{
if
(
himl
->
hbmMask
)
{
if
(
himl
->
hbmMask
)
{
...
@@ -1133,12 +1126,15 @@ ImageList_DrawIndirect (IMAGELISTDRAWPARAMS *pimldp)
...
@@ -1133,12 +1126,15 @@ ImageList_DrawIndirect (IMAGELISTDRAWPARAMS *pimldp)
PatBlt
(
hImageDC
,
0
,
0
,
cx
,
cy
,
PATCOPY
);
PatBlt
(
hImageDC
,
0
,
0
,
cx
,
cy
,
PATCOPY
);
SelectObject
(
hImageDC
,
hOldBrush
);
SelectObject
(
hImageDC
,
hOldBrush
);
}
}
}
else
if
(
himl
->
hbmMask
)
{
}
else
if
(
himl
->
hbmMask
&&
!
bIsTransparent
)
{
/* blend the image with the needed solid background */
HBRUSH
hOldBrush
=
SelectObject
(
hImageDC
,
CreateSolidBrush
(
clrBk
));
PatBlt
(
hImageDC
,
0
,
0
,
cx
,
cy
,
PATCOPY
);
BitBlt
(
hImageDC
,
0
,
0
,
cx
,
cy
,
hMaskListDC
,
lx
,
ly
,
SRCAND
);
BitBlt
(
hImageDC
,
0
,
0
,
cx
,
cy
,
hMaskListDC
,
lx
,
ly
,
SRCAND
);
BitBlt
(
hImageDC
,
0
,
0
,
cx
,
cy
,
hImageListDC
,
lx
,
ly
,
SRCPAINT
);
BitBlt
(
hImageDC
,
0
,
0
,
cx
,
cy
,
hImageListDC
,
lx
,
ly
,
SRCPAINT
);
DeleteObject
(
SelectObject
(
hImageDC
,
hOldBrush
));
}
else
{
}
else
{
/* the image is opaque, just copy it */
/* start off with the image, if we have a mask, we'll use it later */
TRACE
(
" - Image is opaque
\n
"
);
BitBlt
(
hImageDC
,
0
,
0
,
cx
,
cy
,
hImageListDC
,
lx
,
ly
,
SRCCOPY
);
BitBlt
(
hImageDC
,
0
,
0
,
cx
,
cy
,
hImageListDC
,
lx
,
ly
,
SRCCOPY
);
}
}
...
@@ -1194,7 +1190,7 @@ ImageList_DrawIndirect (IMAGELISTDRAWPARAMS *pimldp)
...
@@ -1194,7 +1190,7 @@ ImageList_DrawIndirect (IMAGELISTDRAWPARAMS *pimldp)
/* now copy the image to the screen */
/* now copy the image to the screen */
dwRop
=
SRCCOPY
;
dwRop
=
SRCCOPY
;
if
(
bIsTransparent
&&
!
(
fStyle
&
ILD_MASK
))
{
if
(
himl
->
hbmMask
&&
bIsTransparent
&&
!
(
fStyle
&
ILD_MASK
))
{
COLORREF
oldDstFg
=
SetTextColor
(
pimldp
->
hdcDst
,
RGB
(
0
,
0
,
0
)
);
COLORREF
oldDstFg
=
SetTextColor
(
pimldp
->
hdcDst
,
RGB
(
0
,
0
,
0
)
);
COLORREF
oldDstBk
=
SetBkColor
(
pimldp
->
hdcDst
,
RGB
(
0xff
,
0xff
,
0xff
));
COLORREF
oldDstBk
=
SetBkColor
(
pimldp
->
hdcDst
,
RGB
(
0xff
,
0xff
,
0xff
));
BitBlt
(
pimldp
->
hdcDst
,
pimldp
->
x
,
pimldp
->
y
,
cx
,
cy
,
hMaskListDC
,
lx
,
ly
,
SRCAND
);
BitBlt
(
pimldp
->
hdcDst
,
pimldp
->
x
,
pimldp
->
y
,
cx
,
cy
,
hMaskListDC
,
lx
,
ly
,
SRCAND
);
...
...
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