Avoid referencing stackframe.h from outside kernel32.
This commit is contained in:
parent
f3d99b2697
commit
827a69f8ca
@ -32,8 +32,8 @@
|
|||||||
#include "ntstatus.h"
|
#include "ntstatus.h"
|
||||||
#include "thread.h" /* FIXME: must be included before winternl.h */
|
#include "thread.h" /* FIXME: must be included before winternl.h */
|
||||||
#include "winternl.h"
|
#include "winternl.h"
|
||||||
|
#include "wine/winbase16.h"
|
||||||
#include "wine/debug.h"
|
#include "wine/debug.h"
|
||||||
#include "stackframe.h"
|
|
||||||
|
|
||||||
WINE_DEFAULT_DEBUG_CHANNEL(dbghelp);
|
WINE_DEFAULT_DEBUG_CHANNEL(dbghelp);
|
||||||
|
|
||||||
|
@ -31,7 +31,6 @@
|
|||||||
#include "wownt32.h"
|
#include "wownt32.h"
|
||||||
#include "wine/winbase16.h"
|
#include "wine/winbase16.h"
|
||||||
#include "wine/winuser16.h"
|
#include "wine/winuser16.h"
|
||||||
#include "stackframe.h"
|
|
||||||
#include "controls.h"
|
#include "controls.h"
|
||||||
#include "win.h"
|
#include "win.h"
|
||||||
#include "winproc.h"
|
#include "winproc.h"
|
||||||
@ -432,9 +431,17 @@ static LRESULT WINAPI WINPROC_CallWndProc16( WNDPROC16 proc, HWND16 hwnd,
|
|||||||
LPARAM lParam )
|
LPARAM lParam )
|
||||||
{
|
{
|
||||||
CONTEXT86 context;
|
CONTEXT86 context;
|
||||||
LRESULT ret;
|
size_t size = 0;
|
||||||
WORD args[5];
|
struct
|
||||||
DWORD offset = 0;
|
{
|
||||||
|
WORD params[5];
|
||||||
|
union
|
||||||
|
{
|
||||||
|
CREATESTRUCT16 cs16;
|
||||||
|
DRAWITEMSTRUCT16 dis16;
|
||||||
|
COMPAREITEMSTRUCT16 cis16;
|
||||||
|
} u;
|
||||||
|
} args;
|
||||||
|
|
||||||
USER_CheckNotLock();
|
USER_CheckNotLock();
|
||||||
|
|
||||||
@ -461,30 +468,26 @@ static LRESULT WINAPI WINPROC_CallWndProc16( WNDPROC16 proc, HWND16 hwnd,
|
|||||||
{
|
{
|
||||||
case WM_CREATE:
|
case WM_CREATE:
|
||||||
case WM_NCCREATE:
|
case WM_NCCREATE:
|
||||||
offset = sizeof(CREATESTRUCT16); break;
|
size = sizeof(CREATESTRUCT16); break;
|
||||||
case WM_DRAWITEM:
|
case WM_DRAWITEM:
|
||||||
offset = sizeof(DRAWITEMSTRUCT16); break;
|
size = sizeof(DRAWITEMSTRUCT16); break;
|
||||||
case WM_COMPAREITEM:
|
case WM_COMPAREITEM:
|
||||||
offset = sizeof(COMPAREITEMSTRUCT16); break;
|
size = sizeof(COMPAREITEMSTRUCT16); break;
|
||||||
}
|
}
|
||||||
if (offset)
|
if (size)
|
||||||
{
|
{
|
||||||
void *s = MapSL(lParam);
|
memcpy( &args.u, MapSL(lParam), size );
|
||||||
lParam = stack16_push( offset );
|
lParam = (SEGPTR)NtCurrentTeb()->WOW32Reserved - size;
|
||||||
memcpy( MapSL(lParam), s, offset );
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
args[4] = hwnd;
|
args.params[4] = hwnd;
|
||||||
args[3] = msg;
|
args.params[3] = msg;
|
||||||
args[2] = wParam;
|
args.params[2] = wParam;
|
||||||
args[1] = HIWORD(lParam);
|
args.params[1] = HIWORD(lParam);
|
||||||
args[0] = LOWORD(lParam);
|
args.params[0] = LOWORD(lParam);
|
||||||
WOWCallback16Ex( 0, WCB16_REGS, sizeof(args), args, (DWORD *)&context );
|
WOWCallback16Ex( 0, WCB16_REGS, sizeof(args.params) + size, &args, (DWORD *)&context );
|
||||||
ret = MAKELONG( LOWORD(context.Eax), LOWORD(context.Edx) );
|
return MAKELONG( LOWORD(context.Eax), LOWORD(context.Edx) );
|
||||||
|
|
||||||
if (offset) stack16_pop( offset );
|
|
||||||
return ret;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -22,7 +22,6 @@
|
|||||||
#include "wownt32.h"
|
#include "wownt32.h"
|
||||||
#include "win.h"
|
#include "win.h"
|
||||||
#include "winproc.h"
|
#include "winproc.h"
|
||||||
#include "stackframe.h"
|
|
||||||
#include "user_private.h"
|
#include "user_private.h"
|
||||||
|
|
||||||
/* handle <--> handle16 conversions */
|
/* handle <--> handle16 conversions */
|
||||||
@ -357,7 +356,8 @@ HWND16 WINAPI GetParent16( HWND16 hwnd )
|
|||||||
*/
|
*/
|
||||||
BOOL16 WINAPI IsWindow16( HWND16 hwnd )
|
BOOL16 WINAPI IsWindow16( HWND16 hwnd )
|
||||||
{
|
{
|
||||||
CURRENT_STACK16->es = USER_HeapSel;
|
STACK16FRAME *frame = MapSL( (SEGPTR)NtCurrentTeb()->WOW32Reserved );
|
||||||
|
frame->es = USER_HeapSel;
|
||||||
/* don't use WIN_Handle32 here, we don't care about the full handle */
|
/* don't use WIN_Handle32 here, we don't care about the full handle */
|
||||||
return IsWindow( HWND_32(hwnd) );
|
return IsWindow( HWND_32(hwnd) );
|
||||||
}
|
}
|
||||||
|
@ -25,8 +25,8 @@
|
|||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
|
|
||||||
#include "debugger.h"
|
#include "debugger.h"
|
||||||
#include "stackframe.h"
|
|
||||||
#include "winbase.h"
|
#include "winbase.h"
|
||||||
|
#include "wine/winbase16.h"
|
||||||
#include "wine/debug.h"
|
#include "wine/debug.h"
|
||||||
#include "tlhelp32.h"
|
#include "tlhelp32.h"
|
||||||
|
|
||||||
|
@ -28,7 +28,7 @@
|
|||||||
#include <ctype.h>
|
#include <ctype.h>
|
||||||
|
|
||||||
#include "thread.h"
|
#include "thread.h"
|
||||||
#include "stackframe.h"
|
#include "wine/winbase16.h"
|
||||||
|
|
||||||
#include "build.h"
|
#include "build.h"
|
||||||
|
|
||||||
|
@ -29,7 +29,7 @@
|
|||||||
#include <ctype.h>
|
#include <ctype.h>
|
||||||
|
|
||||||
#include "wine/exception.h"
|
#include "wine/exception.h"
|
||||||
#include "stackframe.h"
|
#include "wine/winbase16.h"
|
||||||
#include "module.h"
|
#include "module.h"
|
||||||
|
|
||||||
#include "build.h"
|
#include "build.h"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user