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
c0faca07
Commit
c0faca07
authored
Jan 13, 2004
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Avoid direct access to the palette structure.
parent
21973119
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
11 deletions
+6
-11
dib.c
dlls/x11drv/dib.c
+6
-11
No files found.
dlls/x11drv/dib.c
View file @
c0faca07
...
@@ -40,7 +40,6 @@
...
@@ -40,7 +40,6 @@
#include "x11drv.h"
#include "x11drv.h"
#include "wine/debug.h"
#include "wine/debug.h"
#include "gdi.h"
#include "gdi.h"
#include "palette.h"
WINE_DEFAULT_DEBUG_CHANNEL
(
bitmap
);
WINE_DEFAULT_DEBUG_CHANNEL
(
bitmap
);
WINE_DECLARE_DEBUG_CHANNEL
(
x11drv
);
WINE_DECLARE_DEBUG_CHANNEL
(
x11drv
);
...
@@ -3731,18 +3730,15 @@ INT X11DRV_GetDIBits( X11DRV_PDEVICE *physDev, HBITMAP hbitmap, UINT startscan,
...
@@ -3731,18 +3730,15 @@ INT X11DRV_GetDIBits( X11DRV_PDEVICE *physDev, HBITMAP hbitmap, UINT startscan,
{
{
X11DRV_DIBSECTION
*
dib
;
X11DRV_DIBSECTION
*
dib
;
X11DRV_DIB_IMAGEBITS_DESCR
descr
;
X11DRV_DIB_IMAGEBITS_DESCR
descr
;
PALETTE
OBJ
*
palette
;
PALETTE
ENTRY
palette
[
256
]
;
BITMAPOBJ
*
bmp
;
BITMAPOBJ
*
bmp
;
int
height
;
int
height
;
DC
*
dc
=
physDev
->
dc
;
DC
*
dc
=
physDev
->
dc
;
if
(
!
(
palette
=
(
PALETTEOBJ
*
)
GDI_GetObjPtr
(
dc
->
hPalette
,
PALETTE_MAGIC
)))
GetPaletteEntries
(
dc
->
hPalette
,
0
,
256
,
palette
);
return
0
;
if
(
!
(
bmp
=
(
BITMAPOBJ
*
)
GDI_GetObjPtr
(
hbitmap
,
BITMAP_MAGIC
)))
if
(
!
(
bmp
=
(
BITMAPOBJ
*
)
GDI_GetObjPtr
(
hbitmap
,
BITMAP_MAGIC
)))
return
0
;
{
GDI_ReleaseObj
(
dc
->
hPalette
);
return
0
;
}
dib
=
(
X11DRV_DIBSECTION
*
)
bmp
->
dib
;
dib
=
(
X11DRV_DIBSECTION
*
)
bmp
->
dib
;
TRACE
(
"%u scanlines of (%i,%i) -> (%i,%i) starting from %u
\n
"
,
TRACE
(
"%u scanlines of (%i,%i) -> (%i,%i) starting from %u
\n
"
,
...
@@ -3798,7 +3794,7 @@ INT X11DRV_GetDIBits( X11DRV_PDEVICE *physDev, HBITMAP hbitmap, UINT startscan,
...
@@ -3798,7 +3794,7 @@ INT X11DRV_GetDIBits( X11DRV_PDEVICE *physDev, HBITMAP hbitmap, UINT startscan,
}
}
descr
.
physDev
=
physDev
;
descr
.
physDev
=
physDev
;
descr
.
palentry
=
palette
->
logpalette
.
palPalEntry
;
descr
.
palentry
=
palette
;
descr
.
bits
=
bits
;
descr
.
bits
=
bits
;
descr
.
image
=
NULL
;
descr
.
image
=
NULL
;
descr
.
lines
=
lines
;
descr
.
lines
=
lines
;
...
@@ -3852,7 +3848,6 @@ INT X11DRV_GetDIBits( X11DRV_PDEVICE *physDev, HBITMAP hbitmap, UINT startscan,
...
@@ -3852,7 +3848,6 @@ INT X11DRV_GetDIBits( X11DRV_PDEVICE *physDev, HBITMAP hbitmap, UINT startscan,
}
}
done:
done:
GDI_ReleaseObj
(
dc
->
hPalette
);
GDI_ReleaseObj
(
hbitmap
);
GDI_ReleaseObj
(
hbitmap
);
return
lines
;
return
lines
;
}
}
...
...
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