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
502d83b1
Commit
502d83b1
authored
Jul 31, 2001
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed a few problems with DCX_* flags handling.
parent
111ec8d6
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
18 additions
and
17 deletions
+18
-17
user.c
dlls/ddraw/dsurface/user.c
+3
-3
dce.c
windows/dce.c
+15
-14
No files found.
dlls/ddraw/dsurface/user.c
View file @
502d83b1
...
...
@@ -283,7 +283,7 @@ HRESULT User_DirectDrawSurface_get_gamma_ramp(IDirectDrawSurfaceImpl* This,
HDC
hDisplayDC
;
HRESULT
hr
;
hDisplayWnd
=
get_display_window
(
This
,
&
offset
);
hDisplayDC
=
GetDCEx
(
hDisplayWnd
,
0
,
DCX_CLIPSIBLINGS
);
hDisplayDC
=
GetDCEx
(
hDisplayWnd
,
0
,
DCX_CLIPSIBLINGS
|
DCX_CACHE
);
hr
=
GetDeviceGammaRamp
(
hDisplayDC
,
lpGammaRamp
)
?
DD_OK
:
DDERR_UNSUPPORTED
;
ReleaseDC
(
hDisplayWnd
,
hDisplayDC
);
return
hr
;
...
...
@@ -302,7 +302,7 @@ HRESULT User_DirectDrawSurface_set_gamma_ramp(IDirectDrawSurfaceImpl* This,
HDC
hDisplayDC
;
HRESULT
hr
;
hDisplayWnd
=
get_display_window
(
This
,
&
offset
);
hDisplayDC
=
GetDCEx
(
hDisplayWnd
,
0
,
DCX_CLIPSIBLINGS
);
hDisplayDC
=
GetDCEx
(
hDisplayWnd
,
0
,
DCX_CLIPSIBLINGS
|
DCX_CACHE
);
hr
=
SetDeviceGammaRamp
(
hDisplayDC
,
lpGammaRamp
)
?
DD_OK
:
DDERR_UNSUPPORTED
;
ReleaseDC
(
hDisplayWnd
,
hDisplayDC
);
return
hr
;
...
...
@@ -477,7 +477,7 @@ static void User_copy_to_screen(IDirectDrawSurfaceImpl* This, LPCRECT rc)
return
;
hDisplayWnd
=
get_display_window
(
This
,
&
offset
);
hDisplayDC
=
GetDCEx
(
hDisplayWnd
,
0
,
DCX_CLIPSIBLINGS
);
hDisplayDC
=
GetDCEx
(
hDisplayWnd
,
0
,
DCX_CLIPSIBLINGS
|
DCX_CACHE
);
#if 0
/* FIXME: this doesn't work... if users really want to run
* X in 8bpp, then we need to call directly into display.drv
...
...
windows/dce.c
View file @
502d83b1
...
...
@@ -410,7 +410,7 @@ HDC WINAPI GetDCEx( HWND hwnd, HRGN hrgnClip, DWORD flags )
/* fixup flags */
if
(
!
wndPtr
->
dce
)
flags
|=
DCX_CACHE
;
if
(
flags
&
(
DCX_WINDOW
|
DCX_PARENTCLIP
)
)
flags
|=
DCX_CACHE
;
if
(
flags
&
DCX_USESTYLE
)
{
...
...
@@ -425,25 +425,26 @@ HDC WINAPI GetDCEx( HWND hwnd, HRGN hrgnClip, DWORD flags )
if
(
wndPtr
->
dwStyle
&
WS_CLIPCHILDREN
&&
!
(
wndPtr
->
dwStyle
&
WS_MINIMIZE
)
)
flags
|=
DCX_CLIPCHILDREN
;
if
(
!
wndPtr
->
dce
)
flags
|=
DCX_CACHE
;
}
else
flags
|=
DCX_CACHE
;
}
if
(
flags
&
DCX_WINDOW
)
flags
=
(
flags
&
~
DCX_CLIPCHILDREN
)
|
DCX_CACHE
;
if
(
flags
&
DCX_WINDOW
)
flags
&=
~
DCX_CLIPCHILDREN
;
if
(
!
wndPtr
->
parent
||
(
wndPtr
->
parent
->
hwndSelf
==
GetDesktopWindow
()))
flags
=
(
flags
&
~
DCX_PARENTCLIP
)
|
DCX_CLIPSIBLINGS
;
else
if
(
flags
&
DCX_PARENTCLIP
)
/* it seems parent clip is ignored when clipping siblings or children */
if
(
flags
&
(
DCX_CLIPSIBLINGS
|
DCX_CLIPCHILDREN
))
flags
&=
~
DCX_PARENTCLIP
;
if
(
flags
&
DCX_PARENTCLIP
)
{
flags
|=
DCX_CACHE
;
if
(
!
(
flags
&
(
DCX_CLIPSIBLINGS
|
DCX_CLIPCHILDREN
))
)
if
(
(
wndPtr
->
dwStyle
&
WS_VISIBLE
)
&&
(
wndPtr
->
parent
->
dwStyle
&
WS_VISIBLE
)
)
{
flags
&=
~
DCX_CLIPCHILDREN
;
if
(
wndPtr
->
parent
->
dwStyle
&
WS_CLIPSIBLINGS
)
flags
|=
DCX_CLIPSIBLINGS
;
}
if
(
(
wndPtr
->
dwStyle
&
WS_VISIBLE
)
&&
(
wndPtr
->
parent
->
dwStyle
&
WS_VISIBLE
)
)
{
flags
&=
~
DCX_CLIPCHILDREN
;
if
(
wndPtr
->
parent
->
dwStyle
&
WS_CLIPSIBLINGS
)
flags
|=
DCX_CLIPSIBLINGS
;
}
}
/* find a suitable DCE */
...
...
@@ -496,7 +497,7 @@ HDC WINAPI GetDCEx( HWND hwnd, HRGN hrgnClip, DWORD flags )
else
{
dce
=
wndPtr
->
dce
;
if
(
dce
->
hwndCurrent
==
hwnd
)
if
(
dce
&&
dce
->
hwndCurrent
==
hwnd
)
{
TRACE
(
"
\t
skipping hVisRgn update
\n
"
);
bUpdateVisRgn
=
FALSE
;
/* updated automatically, via DCHook() */
...
...
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