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
a0a95eb0
Commit
a0a95eb0
authored
May 02, 2012
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
gphoto2.ds: CreateDIBSection doesn't need a DC for the DIB_RGB_COLORS case.
parent
039c8534
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
7 deletions
+2
-7
ds_image.c
dlls/gphoto2.ds/ds_image.c
+2
-7
No files found.
dlls/gphoto2.ds/ds_image.c
View file @
a0a95eb0
...
...
@@ -383,7 +383,6 @@ TW_UINT16 GPHOTO2_ImageNativeXferGet (pTW_IDENTITY pOrigin,
BITMAPINFO
bmpInfo
;
LPBYTE
bits
;
JSAMPROW
samprow
,
oldsamprow
;
HDC
dc
;
FIXME
(
"DG_IMAGE/DAT_IMAGENATIVEXFER/MSG_GET: implemented, but expect program crash due to DIB.
\n
"
);
...
...
@@ -425,8 +424,7 @@ TW_UINT16 GPHOTO2_ImageNativeXferGet (pTW_IDENTITY pOrigin,
bmpInfo
.
bmiHeader
.
biYPelsPerMeter
=
0
;
bmpInfo
.
bmiHeader
.
biClrUsed
=
0
;
bmpInfo
.
bmiHeader
.
biClrImportant
=
0
;
hDIB
=
CreateDIBSection
((
dc
=
GetDC
(
activeDS
.
hwndOwner
)),
&
bmpInfo
,
DIB_RGB_COLORS
,
(
LPVOID
)
&
bits
,
0
,
0
);
hDIB
=
CreateDIBSection
(
0
,
&
bmpInfo
,
DIB_RGB_COLORS
,
(
LPVOID
)
&
bits
,
0
,
0
);
if
(
!
hDIB
)
{
FIXME
(
"Failed creating DIB.
\n
"
);
gp_file_unref
(
activeDS
.
file
);
...
...
@@ -454,7 +452,6 @@ TW_UINT16 GPHOTO2_ImageNativeXferGet (pTW_IDENTITY pOrigin,
HeapFree
(
GetProcessHeap
(),
0
,
samprow
);
gp_file_unref
(
activeDS
.
file
);
activeDS
.
file
=
NULL
;
ReleaseDC
(
activeDS
.
hwndOwner
,
dc
);
*
pHandle
=
(
UINT_PTR
)
hDIB
;
activeDS
.
twCC
=
TWCC_SUCCESS
;
activeDS
.
currentState
=
7
;
...
...
@@ -568,7 +565,6 @@ _get_gphoto2_file_as_DIB(
struct
jpeg_source_mgr
xjsm
;
struct
jpeg_decompress_struct
jd
;
struct
jpeg_error_mgr
jerr
;
HDC
dc
;
BITMAPINFO
bmpInfo
;
LPBYTE
bits
;
JSAMPROW
samprow
,
oldsamprow
;
...
...
@@ -636,7 +632,7 @@ _get_gphoto2_file_as_DIB(
bmpInfo
.
bmiHeader
.
biYPelsPerMeter
=
0
;
bmpInfo
.
bmiHeader
.
biClrUsed
=
0
;
bmpInfo
.
bmiHeader
.
biClrImportant
=
0
;
*
hDIB
=
CreateDIBSection
((
dc
=
GetDC
(
hwnd
))
,
&
bmpInfo
,
DIB_RGB_COLORS
,
(
LPVOID
)
&
bits
,
0
,
0
);
*
hDIB
=
CreateDIBSection
(
0
,
&
bmpInfo
,
DIB_RGB_COLORS
,
(
LPVOID
)
&
bits
,
0
,
0
);
if
(
!*
hDIB
)
{
FIXME
(
"Failed creating DIB.
\n
"
);
gp_file_unref
(
file
);
...
...
@@ -659,7 +655,6 @@ _get_gphoto2_file_as_DIB(
bits
=
(
LPBYTE
)(((
UINT_PTR
)
bits
+
3
)
&
~
3
);
samprow
=
oldsamprow
;
}
if
(
hwnd
)
ReleaseDC
(
hwnd
,
dc
);
HeapFree
(
GetProcessHeap
(),
0
,
samprow
);
gp_file_unref
(
file
);
return
TWRC_SUCCESS
;
...
...
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