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
31c7a715
Commit
31c7a715
authored
Jan 26, 2018
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
winex11: Default to an ARGB visual when depth is set to 32.
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
e40ff92e
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
20 additions
and
16 deletions
+20
-16
x11drv_main.c
dlls/winex11.drv/x11drv_main.c
+20
-16
No files found.
dlls/winex11.drv/x11drv_main.c
View file @
31c7a715
...
...
@@ -484,11 +484,29 @@ static void init_visuals( Display *display, int screen )
int
count
;
XVisualInfo
*
info
;
argb_visual
.
screen
=
screen
;
argb_visual
.
class
=
TrueColor
;
argb_visual
.
depth
=
32
;
argb_visual
.
red_mask
=
0xff0000
;
argb_visual
.
green_mask
=
0x00ff00
;
argb_visual
.
blue_mask
=
0x0000ff
;
if
((
info
=
XGetVisualInfo
(
display
,
VisualScreenMask
|
VisualDepthMask
|
VisualClassMask
|
VisualRedMaskMask
|
VisualGreenMaskMask
|
VisualBlueMaskMask
,
&
argb_visual
,
&
count
)))
{
argb_visual
=
*
info
;
XFree
(
info
);
}
default_visual
.
screen
=
screen
;
if
(
default_visual
.
depth
)
/* depth specified */
{
info
=
XGetVisualInfo
(
display
,
VisualScreenMask
|
VisualDepthMask
,
&
default_visual
,
&
count
);
if
(
info
)
if
(
default_visual
.
depth
==
32
&&
argb_visual
.
visual
)
{
default_visual
=
argb_visual
;
}
else
if
((
info
=
XGetVisualInfo
(
display
,
VisualScreenMask
|
VisualDepthMask
,
&
default_visual
,
&
count
)))
{
default_visual
=
*
info
;
XFree
(
info
);
...
...
@@ -510,20 +528,6 @@ static void init_visuals( Display *display, int screen )
}
default_colormap
=
XCreateColormap
(
display
,
root_window
,
default_visual
.
visual
,
AllocNone
);
argb_visual
.
screen
=
screen
;
argb_visual
.
class
=
TrueColor
;
argb_visual
.
depth
=
32
;
argb_visual
.
red_mask
=
0xff0000
;
argb_visual
.
green_mask
=
0x00ff00
;
argb_visual
.
blue_mask
=
0x0000ff
;
if
((
info
=
XGetVisualInfo
(
display
,
VisualScreenMask
|
VisualDepthMask
|
VisualClassMask
|
VisualRedMaskMask
|
VisualGreenMaskMask
|
VisualBlueMaskMask
,
&
argb_visual
,
&
count
)))
{
argb_visual
=
*
info
;
XFree
(
info
);
}
TRACE
(
"default visual %lx class %u argb %lx
\n
"
,
default_visual
.
visualid
,
default_visual
.
class
,
argb_visual
.
visualid
);
}
...
...
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