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
fcef0261
Commit
fcef0261
authored
Jul 18, 2001
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Reject pointer messages in SendNotifyMessage[AW] and
SendMessageCallback[AW]. Fixed prototypes.
parent
d2cb1d14
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
71 additions
and
60 deletions
+71
-60
winuser.h
include/winuser.h
+3
-3
message.c
windows/message.c
+68
-57
No files found.
include/winuser.h
View file @
fcef0261
...
...
@@ -27,7 +27,7 @@ typedef BOOL CALLBACK (*PROPENUMPROCA)(HWND,LPCSTR,HANDLE);
typedef
BOOL
CALLBACK
(
*
PROPENUMPROCW
)(
HWND
,
LPCWSTR
,
HANDLE
);
typedef
BOOL
CALLBACK
(
*
PROPENUMPROCEXA
)(
HWND
,
LPCSTR
,
HANDLE
,
DWORD
);
typedef
BOOL
CALLBACK
(
*
PROPENUMPROCEXW
)(
HWND
,
LPCWSTR
,
HANDLE
,
DWORD
);
typedef
VOID
CALLBACK
(
*
SENDASYNCPROC
)(
HWND
,
UINT
,
DWORD
,
LRESULT
);
typedef
VOID
CALLBACK
(
*
SENDASYNCPROC
)(
HWND
,
UINT
,
ULONG_PTR
,
LRESULT
);
typedef
VOID
CALLBACK
(
*
TIMERPROC
)(
HWND
,
UINT
,
UINT
,
DWORD
);
typedef
BOOL
CALLBACK
(
*
WNDENUMPROC
)(
HWND
,
LPARAM
);
#else
...
...
@@ -3261,8 +3261,8 @@ BOOL WINAPI RegisterHotKey(HWND,INT,UINT,UINT);
HDEVNOTIFY
WINAPI
RegisterDeviceNotificationA
(
HANDLE
,
LPVOID
,
DWORD
);
HDEVNOTIFY
WINAPI
RegisterDeviceNotificationW
(
HANDLE
,
LPVOID
,
DWORD
);
#define RegisterDeviceNotification WINELIB_NAME_AW(RegisterDeviceNotification)
BOOL
WINAPI
SendMessageCallbackA
(
HWND
,
UINT
,
WPARAM
,
LPARAM
,
FARPROC
,
DWORD
);
BOOL
WINAPI
SendMessageCallbackW
(
HWND
,
UINT
,
WPARAM
,
LPARAM
,
FARPROC
,
DWORD
);
BOOL
WINAPI
SendMessageCallbackA
(
HWND
,
UINT
,
WPARAM
,
LPARAM
,
SENDASYNCPROC
,
ULONG_PTR
);
BOOL
WINAPI
SendMessageCallbackW
(
HWND
,
UINT
,
WPARAM
,
LPARAM
,
SENDASYNCPROC
,
ULONG_PTR
);
#define SendMessageCallback WINELIB_NAME_AW(SendMessageCallback)
BOOL
WINAPI
SendNotifyMessageA
(
HWND
,
UINT
,
WPARAM
,
LPARAM
);
BOOL
WINAPI
SendNotifyMessageW
(
HWND
,
UINT
,
WPARAM
,
LPARAM
);
...
...
windows/message.c
View file @
fcef0261
...
...
@@ -1865,6 +1865,74 @@ LRESULT WINAPI SendMessageTimeoutW( HWND hwnd, UINT msg, WPARAM wParam,
/***********************************************************************
* SendNotifyMessageA (USER32.@)
*/
BOOL
WINAPI
SendNotifyMessageA
(
HWND
hwnd
,
UINT
msg
,
WPARAM
wParam
,
LPARAM
lParam
)
{
return
SendNotifyMessageW
(
hwnd
,
msg
,
map_wparam_AtoW
(
msg
,
wParam
),
lParam
);
}
/***********************************************************************
* SendNotifyMessageW (USER32.@)
*/
BOOL
WINAPI
SendNotifyMessageW
(
HWND
hwnd
,
UINT
msg
,
WPARAM
wParam
,
LPARAM
lParam
)
{
if
(
is_pointer_message
(
msg
))
{
SetLastError
(
ERROR_INVALID_PARAMETER
);
return
FALSE
;
}
return
MSG_SendMessage
(
hwnd
,
msg
,
wParam
,
lParam
,
INFINITE
,
QMSG_WIN32W
,
NULL
);
}
/***********************************************************************
* SendMessageCallbackA (USER32.@)
*/
BOOL
WINAPI
SendMessageCallbackA
(
HWND
hwnd
,
UINT
msg
,
WPARAM
wParam
,
LPARAM
lParam
,
SENDASYNCPROC
callback
,
ULONG_PTR
data
)
{
return
SendMessageCallbackW
(
hwnd
,
msg
,
map_wparam_AtoW
(
msg
,
wParam
),
lParam
,
callback
,
data
);
}
/***********************************************************************
* SendMessageCallbackW (USER32.@)
*
* FIXME: It's like PostMessage. The callback gets called when the message
* is processed. We have to modify the message processing for an exact
* implementation...
* The callback is only called when the thread that called us calls one of
* Get/Peek/WaitMessage.
*/
BOOL
WINAPI
SendMessageCallbackW
(
HWND
hwnd
,
UINT
msg
,
WPARAM
wParam
,
LPARAM
lParam
,
SENDASYNCPROC
callback
,
ULONG_PTR
data
)
{
LRESULT
result
;
if
(
is_pointer_message
(
msg
))
{
SetLastError
(
ERROR_INVALID_PARAMETER
);
return
FALSE
;
}
FIXME
(
"(0x%04x,0x%04x,0x%08x,0x%08lx,%p,0x%08x),stub!
\n
"
,
hwnd
,
msg
,
wParam
,
lParam
,
callback
,
data
);
if
(
hwnd
==
HWND_BROADCAST
)
{
PostMessageW
(
hwnd
,
msg
,
wParam
,
lParam
);
FIXME
(
"Broadcast: Callback will not be called!
\n
"
);
return
TRUE
;
}
result
=
SendMessageW
(
hwnd
,
msg
,
wParam
,
lParam
);
callback
(
hwnd
,
msg
,
data
,
result
);
return
TRUE
;
}
/***********************************************************************
* WaitMessage (USER.112) Suspend thread pending messages
* WaitMessage (USER32.@) Suspend thread pending messages
*
...
...
@@ -2531,60 +2599,3 @@ LONG WINAPI BroadcastSystemMessage(
);
return
0
;
}
/***********************************************************************
* SendNotifyMessageA (USER32.@)
*/
BOOL
WINAPI
SendNotifyMessageA
(
HWND
hwnd
,
UINT
msg
,
WPARAM
wParam
,
LPARAM
lParam
)
{
return
MSG_SendMessage
(
hwnd
,
msg
,
wParam
,
lParam
,
INFINITE
,
QMSG_WIN32A
,
NULL
);
}
/***********************************************************************
* SendNotifyMessageW (USER32.@)
*/
BOOL
WINAPI
SendNotifyMessageW
(
HWND
hwnd
,
UINT
msg
,
WPARAM
wParam
,
LPARAM
lParam
)
{
return
MSG_SendMessage
(
hwnd
,
msg
,
wParam
,
lParam
,
INFINITE
,
QMSG_WIN32W
,
NULL
);
}
/***********************************************************************
* SendMessageCallbackA (USER32.@)
* FIXME: It's like PostMessage. The callback gets called when the message
* is processed. We have to modify the message processing for an exact
* implementation...
* The callback is only called when the thread that called us calls one of
* Get/Peek/WaitMessage.
*/
BOOL
WINAPI
SendMessageCallbackA
(
HWND
hWnd
,
UINT
Msg
,
WPARAM
wParam
,
LPARAM
lParam
,
FARPROC
lpResultCallBack
,
DWORD
dwData
)
{
FIXME
(
"(0x%04x,0x%04x,0x%08x,0x%08lx,%p,0x%08lx),stub!
\n
"
,
hWnd
,
Msg
,
wParam
,
lParam
,
lpResultCallBack
,
dwData
);
if
(
hWnd
==
HWND_BROADCAST
)
{
PostMessageA
(
hWnd
,
Msg
,
wParam
,
lParam
);
FIXME
(
"Broadcast: Callback will not be called!
\n
"
);
return
TRUE
;
}
(
lpResultCallBack
)(
hWnd
,
Msg
,
dwData
,
SendMessageA
(
hWnd
,
Msg
,
wParam
,
lParam
));
return
TRUE
;
}
/***********************************************************************
* SendMessageCallbackW (USER32.@)
* FIXME: see SendMessageCallbackA.
*/
BOOL
WINAPI
SendMessageCallbackW
(
HWND
hWnd
,
UINT
Msg
,
WPARAM
wParam
,
LPARAM
lParam
,
FARPROC
lpResultCallBack
,
DWORD
dwData
)
{
FIXME
(
"(0x%04x,0x%04x,0x%08x,0x%08lx,%p,0x%08lx),stub!
\n
"
,
hWnd
,
Msg
,
wParam
,
lParam
,
lpResultCallBack
,
dwData
);
if
(
hWnd
==
HWND_BROADCAST
)
{
PostMessageW
(
hWnd
,
Msg
,
wParam
,
lParam
);
FIXME
(
"Broadcast: Callback will not be called!
\n
"
);
return
TRUE
;
}
(
lpResultCallBack
)(
hWnd
,
Msg
,
dwData
,
SendMessageA
(
hWnd
,
Msg
,
wParam
,
lParam
));
return
TRUE
;
}
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