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
d50112b4
Commit
d50112b4
authored
Jul 21, 2022
by
Jacek Caban
Committed by
Alexandre Julliard
Jul 25, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
win32u: Use syscall interface for NtUserCreateWindowEx and NtUserDestroyWindow.
parent
43c851c7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
45 additions
and
28 deletions
+45
-28
gdiobj.c
dlls/win32u/gdiobj.c
+0
-2
syscall.c
dlls/win32u/syscall.c
+2
-0
win32u.spec
dlls/win32u/win32u.spec
+2
-2
win32u_private.h
dlls/win32u/win32u_private.h
+0
-6
wrappers.c
dlls/win32u/wrappers.c
+0
-18
syscall.h
dlls/wow64win/syscall.h
+2
-0
user.c
dlls/wow64win/user.c
+39
-0
No files found.
dlls/win32u/gdiobj.c
View file @
d50112b4
...
...
@@ -1136,10 +1136,8 @@ static struct unix_funcs unix_funcs =
NtGdiUnrealizeObject
,
NtGdiUpdateColors
,
NtGdiWidenPath
,
NtUserCreateWindowEx
,
NtUserDeferWindowPosAndBand
,
NtUserDestroyMenu
,
NtUserDestroyWindow
,
NtUserDrawCaptionTemp
,
NtUserDrawMenuBarTemp
,
NtUserEnableMenuItem
,
...
...
dlls/win32u/syscall.c
View file @
d50112b4
...
...
@@ -127,11 +127,13 @@ static void * const syscalls[] =
NtUserCreateCaret
,
NtUserCreateDesktopEx
,
NtUserCreateInputContext
,
NtUserCreateWindowEx
,
NtUserCreateWindowStation
,
NtUserDeleteMenu
,
NtUserDestroyAcceleratorTable
,
NtUserDestroyCursor
,
NtUserDestroyInputContext
,
NtUserDestroyWindow
,
NtUserDisableThreadIme
,
NtUserDispatchMessage
,
NtUserDragDetect
,
...
...
dlls/win32u/win32u.spec
View file @
d50112b4
...
...
@@ -814,7 +814,7 @@
@ stdcall -syscall NtUserCreateInputContext(ptr)
@ stub NtUserCreateLocalMemHandle
@ stub NtUserCreatePalmRejectionDelayZone
@ stdcall NtUserCreateWindowEx(long ptr ptr ptr long long long long long long long long ptr long long long long)
@ stdcall
-syscall
NtUserCreateWindowEx(long ptr ptr ptr long long long long long long long long ptr long long long long)
@ stub NtUserCreateWindowGroup
@ stdcall -syscall NtUserCreateWindowStation(ptr long long long long long long)
@ stub NtUserCtxDisplayIOCtl
...
...
@@ -834,7 +834,7 @@
@ stdcall -syscall NtUserDestroyInputContext(long)
@ stdcall NtUserDestroyMenu(long)
@ stub NtUserDestroyPalmRejectionDelayZone
@ stdcall NtUserDestroyWindow(long)
@ stdcall
-syscall
NtUserDestroyWindow(long)
@ stub NtUserDisableImmersiveOwner
@ stub NtUserDisableProcessWindowFiltering
@ stdcall -syscall NtUserDisableThreadIme(long)
...
...
dlls/win32u/win32u_private.h
View file @
d50112b4
...
...
@@ -186,16 +186,10 @@ struct unix_funcs
BOOL
(
WINAPI
*
pNtGdiUnrealizeObject
)(
HGDIOBJ
obj
);
BOOL
(
WINAPI
*
pNtGdiUpdateColors
)(
HDC
hdc
);
BOOL
(
WINAPI
*
pNtGdiWidenPath
)(
HDC
hdc
);
HWND
(
WINAPI
*
pNtUserCreateWindowEx
)(
DWORD
ex_style
,
UNICODE_STRING
*
class_name
,
UNICODE_STRING
*
version
,
UNICODE_STRING
*
window_name
,
DWORD
style
,
INT
x
,
INT
y
,
INT
width
,
INT
height
,
HWND
parent
,
HMENU
menu
,
HINSTANCE
instance
,
void
*
params
,
DWORD
flags
,
CBT_CREATEWNDW
*
cbtc
,
DWORD
unk
,
BOOL
ansi
);
HDWP
(
WINAPI
*
pNtUserDeferWindowPosAndBand
)(
HDWP
hdwp
,
HWND
hwnd
,
HWND
after
,
INT
x
,
INT
y
,
INT
cx
,
INT
cy
,
UINT
flags
,
UINT
unk1
,
UINT
unk2
);
BOOL
(
WINAPI
*
pNtUserDestroyMenu
)(
HMENU
handle
);
BOOL
(
WINAPI
*
pNtUserDestroyWindow
)(
HWND
hwnd
);
BOOL
(
WINAPI
*
pNtUserDrawCaptionTemp
)(
HWND
hwnd
,
HDC
hdc
,
const
RECT
*
rect
,
HFONT
font
,
HICON
icon
,
const
WCHAR
*
str
,
UINT
flags
);
DWORD
(
WINAPI
*
pNtUserDrawMenuBarTemp
)(
HWND
hwnd
,
HDC
hdc
,
RECT
*
rect
,
HMENU
handle
,
HFONT
font
);
...
...
dlls/win32u/wrappers.c
View file @
d50112b4
...
...
@@ -725,18 +725,6 @@ NTSTATUS WINAPI NtGdiDdDDISetVidPnSourceOwner( const D3DKMT_SETVIDPNSOURCEOWNER
return
unix_funcs
->
pNtGdiDdDDISetVidPnSourceOwner
(
desc
);
}
HWND
WINAPI
NtUserCreateWindowEx
(
DWORD
ex_style
,
UNICODE_STRING
*
class_name
,
UNICODE_STRING
*
version
,
UNICODE_STRING
*
window_name
,
DWORD
style
,
INT
x
,
INT
y
,
INT
width
,
INT
height
,
HWND
parent
,
HMENU
menu
,
HINSTANCE
instance
,
void
*
params
,
DWORD
flags
,
CBT_CREATEWNDW
*
cbtc
,
DWORD
unk
,
BOOL
ansi
)
{
if
(
!
unix_funcs
)
return
0
;
return
unix_funcs
->
pNtUserCreateWindowEx
(
ex_style
,
class_name
,
version
,
window_name
,
style
,
x
,
y
,
width
,
height
,
parent
,
menu
,
instance
,
params
,
flags
,
cbtc
,
unk
,
ansi
);
}
HDWP
WINAPI
NtUserDeferWindowPosAndBand
(
HDWP
hdwp
,
HWND
hwnd
,
HWND
after
,
INT
x
,
INT
y
,
INT
cx
,
INT
cy
,
UINT
flags
,
UINT
unk1
,
UINT
unk2
)
...
...
@@ -752,12 +740,6 @@ BOOL WINAPI NtUserDestroyMenu( HMENU handle )
return
unix_funcs
->
pNtUserDestroyMenu
(
handle
);
}
BOOL
WINAPI
NtUserDestroyWindow
(
HWND
hwnd
)
{
if
(
!
unix_funcs
)
return
FALSE
;
return
unix_funcs
->
pNtUserDestroyWindow
(
hwnd
);
}
BOOL
WINAPI
NtUserDrawCaptionTemp
(
HWND
hwnd
,
HDC
hdc
,
const
RECT
*
rect
,
HFONT
font
,
HICON
icon
,
const
WCHAR
*
str
,
UINT
flags
)
{
...
...
dlls/wow64win/syscall.h
View file @
d50112b4
...
...
@@ -114,11 +114,13 @@
SYSCALL_ENTRY( NtUserCreateCaret ) \
SYSCALL_ENTRY( NtUserCreateDesktopEx ) \
SYSCALL_ENTRY( NtUserCreateInputContext ) \
SYSCALL_ENTRY( NtUserCreateWindowEx ) \
SYSCALL_ENTRY( NtUserCreateWindowStation ) \
SYSCALL_ENTRY( NtUserDeleteMenu ) \
SYSCALL_ENTRY( NtUserDestroyAcceleratorTable ) \
SYSCALL_ENTRY( NtUserDestroyCursor ) \
SYSCALL_ENTRY( NtUserDestroyInputContext ) \
SYSCALL_ENTRY( NtUserDestroyWindow ) \
SYSCALL_ENTRY( NtUserDisableThreadIme ) \
SYSCALL_ENTRY( NtUserDispatchMessage ) \
SYSCALL_ENTRY( NtUserDragDetect ) \
...
...
dlls/wow64win/user.c
View file @
d50112b4
...
...
@@ -411,6 +411,38 @@ NTSTATUS WINAPI wow64_NtUserCreateInputContext( UINT *args )
return
HandleToUlong
(
NtUserCreateInputContext
(
client_ptr
));
}
NTSTATUS
WINAPI
wow64_NtUserCreateWindowEx
(
UINT
*
args
)
{
DWORD
ex_style
=
get_ulong
(
&
args
);
UNICODE_STRING32
*
class_name32
=
get_ptr
(
&
args
);
UNICODE_STRING32
*
version32
=
get_ptr
(
&
args
);
UNICODE_STRING32
*
window_name32
=
get_ptr
(
&
args
);
DWORD
style
=
get_ulong
(
&
args
);
int
x
=
get_ulong
(
&
args
);
int
y
=
get_ulong
(
&
args
);
int
width
=
get_ulong
(
&
args
);
int
height
=
get_ulong
(
&
args
);
HWND
parent
=
get_handle
(
&
args
);
HMENU
menu
=
get_handle
(
&
args
);
HINSTANCE
instance
=
get_handle
(
&
args
);
void
*
params
=
get_ptr
(
&
args
);
DWORD
flags
=
get_ulong
(
&
args
);
void
*
cbtc
=
get_ptr
(
&
args
);
DWORD
unk
=
get_ulong
(
&
args
);
BOOL
ansi
=
get_ulong
(
&
args
);
UNICODE_STRING
class_name
,
version
,
window_name
;
HWND
ret
;
ret
=
NtUserCreateWindowEx
(
ex_style
,
unicode_str_32to64
(
&
class_name
,
class_name32
),
unicode_str_32to64
(
&
version
,
version32
),
unicode_str_32to64
(
&
window_name
,
window_name32
),
style
,
x
,
y
,
width
,
height
,
parent
,
menu
,
instance
,
params
,
flags
,
cbtc
,
unk
,
ansi
);
return
HandleToUlong
(
ret
);
}
NTSTATUS
WINAPI
wow64_NtUserCreateWindowStation
(
UINT
*
args
)
{
OBJECT_ATTRIBUTES32
*
attr32
=
get_ptr
(
&
args
);
...
...
@@ -458,6 +490,13 @@ NTSTATUS WINAPI wow64_NtUserDestroyInputContext( UINT *args )
return
NtUserDestroyInputContext
(
handle
);
}
NTSTATUS
WINAPI
wow64_NtUserDestroyWindow
(
UINT
*
args
)
{
HWND
hwnd
=
get_handle
(
&
args
);
return
NtUserDestroyWindow
(
hwnd
);
}
NTSTATUS
WINAPI
wow64_NtUserDisableThreadIme
(
UINT
*
args
)
{
DWORD
thread_id
=
get_ulong
(
&
args
);
...
...
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