Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
1e0ab160
Commit
1e0ab160
authored
Dec 16, 2011
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
oleaut32: Fix IPicture::SelectPicture to not try to select a bitmap into two DCs at the same time.
parent
430c8aa9
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
2 deletions
+4
-2
olepicture.c
dlls/oleaut32/olepicture.c
+4
-2
No files found.
dlls/oleaut32/olepicture.c
View file @
1e0ab160
...
...
@@ -141,6 +141,7 @@ typedef struct OLEPictureImpl {
BOOL
keepOrigFormat
;
HDC
hDCCur
;
HBITMAP
stock_bitmap
;
/* Bitmap transparency mask */
HBITMAP
hbmMask
;
...
...
@@ -219,6 +220,7 @@ static void OLEPictureImpl_SetBitmap(OLEPictureImpl *This)
This
->
himetricWidth
=
xpixels_to_himetric
(
bm
.
bmWidth
,
hdcRef
);
This
->
himetricHeight
=
ypixels_to_himetric
(
bm
.
bmHeight
,
hdcRef
);
This
->
stock_bitmap
=
GetCurrentObject
(
hdcRef
,
OBJ_BITMAP
);
DeleteDC
(
hdcRef
);
}
...
...
@@ -769,10 +771,10 @@ static HRESULT WINAPI OLEPictureImpl_SelectPicture(IPicture *iface,
OLEPictureImpl
*
This
=
impl_from_IPicture
(
iface
);
TRACE
(
"(%p)->(%p, %p, %p)
\n
"
,
This
,
hdcIn
,
phdcOut
,
phbmpOut
);
if
(
This
->
desc
.
picType
==
PICTYPE_BITMAP
)
{
SelectObject
(
hdcIn
,
This
->
desc
.
u
.
bmp
.
hbitmap
);
if
(
phdcOut
)
*
phdcOut
=
This
->
hDCCur
;
if
(
This
->
hDCCur
)
SelectObject
(
This
->
hDCCur
,
This
->
stock_bitmap
);
if
(
hdcIn
)
SelectObject
(
hdcIn
,
This
->
desc
.
u
.
bmp
.
hbitmap
);
This
->
hDCCur
=
hdcIn
;
if
(
phbmpOut
)
*
phbmpOut
=
HandleToUlong
(
This
->
desc
.
u
.
bmp
.
hbitmap
);
...
...
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