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
0ca051e5
Commit
0ca051e5
authored
Oct 17, 2002
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed wownt32.h to make it usable from inside Wine, and use it to
avoid some duplication of the handle conversion macros.
parent
11e35239
Hide whitespace changes
Inline
Side-by-side
Showing
42 changed files
with
97 additions
and
104 deletions
+97
-104
listbox.c
controls/listbox.c
+1
-0
menu.c
controls/menu.c
+1
-0
static.c
controls/static.c
+1
-0
cdlg.h
dlls/commdlg/cdlg.h
+1
-4
gdi16.c
dlls/gdi/gdi16.c
+1
-14
prtdrv.c
dlls/gdi/win16drv/prtdrv.c
+1
-2
msvideo16.c
dlls/msvideo/msvideo16.c
+0
-2
msvideo_main.c
dlls/msvideo/msvideo_main.c
+0
-1
vfw16.h
dlls/msvideo/vfw16.h
+1
-4
ole2.c
dlls/ole32/ole2.c
+1
-3
setupx_main.c
dlls/setupapi/setupx_main.c
+1
-1
shell.c
dlls/shell32/shell.c
+1
-0
shell32_main.h
dlls/shell32/shell32_main.h
+0
-1
shlexec.c
dlls/shell32/shlexec.c
+1
-0
msg16.c
dlls/user/msg16.c
+1
-0
property.c
dlls/user/property.c
+1
-0
resource.c
dlls/user/resource.c
+1
-0
user16.c
dlls/user/user16.c
+2
-7
wnd16.c
dlls/user/wnd16.c
+2
-14
driver.c
dlls/wineps/driver.c
+1
-2
mcianim.c
dlls/winmm/mcianim/mcianim.c
+1
-2
private_mciavi.h
dlls/winmm/mciavi/private_mciavi.h
+5
-2
mcicda.c
dlls/winmm/mcicda/mcicda.c
+1
-2
mcimidi.c
dlls/winmm/mciseq/mcimidi.c
+1
-2
mciwave.c
dlls/winmm/mciwave/mciwave.c
+1
-2
winemm.h
dlls/winmm/winemm.h
+1
-2
async.c
dlls/winsock/async.c
+1
-0
socket.c
dlls/winsock/socket.c
+1
-0
user.h
include/user.h
+0
-4
win.h
include/win.h
+0
-3
winsock16.h
include/wine/winsock16.h
+0
-3
wownt32.h
include/wownt32.h
+46
-5
class.c
windows/class.c
+1
-0
cursoricon.c
windows/cursoricon.c
+11
-22
dialog.c
windows/dialog.c
+1
-0
hook.c
windows/hook.c
+1
-0
mdi.c
windows/mdi.c
+1
-0
spy.c
windows/spy.c
+1
-0
struct32.c
windows/struct32.c
+1
-0
win.c
windows/win.c
+1
-0
winhelp.c
windows/winhelp.c
+1
-0
winproc.c
windows/winproc.c
+1
-0
No files found.
controls/listbox.c
View file @
0ca051e5
...
...
@@ -25,6 +25,7 @@
#include "wingdi.h"
#include "wine/winuser16.h"
#include "wine/winbase16.h"
#include "wownt32.h"
#include "wine/unicode.h"
#include "winuser.h"
#include "winerror.h"
...
...
controls/menu.c
View file @
0ca051e5
...
...
@@ -39,6 +39,7 @@
#include "wingdi.h"
#include "wine/winbase16.h"
#include "wine/winuser16.h"
#include "wownt32.h"
#include "wine/server.h"
#include "wine/unicode.h"
#include "win.h"
...
...
controls/static.c
View file @
0ca051e5
...
...
@@ -21,6 +21,7 @@
#include "windef.h"
#include "wingdi.h"
#include "wine/winuser16.h"
#include "wownt32.h"
#include "cursoricon.h"
#include "controls.h"
#include "user.h"
...
...
dlls/commdlg/cdlg.h
View file @
0ca051e5
...
...
@@ -23,10 +23,7 @@
#include "dlgs.h"
#include "wine/windef16.h"
/* handle conversions */
#define HWND_16(h32) (LOWORD(h32))
#define HWND_32(h16) ((HWND)(ULONG_PTR)(h16))
#include "wownt32.h"
/*---------------- 16-bit ----------------*/
extern
HINSTANCE16
COMMDLG_hInstance
;
...
...
dlls/gdi/gdi16.c
View file @
0ca051e5
...
...
@@ -20,6 +20,7 @@
#include "winbase.h"
#include "wingdi.h"
#include "wownt32.h"
#include "wine/wingdi16.h"
#include "gdi.h"
#include "wine/debug.h"
...
...
@@ -29,20 +30,6 @@ WINE_DEFAULT_DEBUG_CHANNEL(gdi);
#define HGDIOBJ_32(handle16) ((HGDIOBJ)(ULONG_PTR)(handle16))
#define HGDIOBJ_16(handle32) ((HGDIOBJ16)(ULONG_PTR)(handle32))
#define HDC_32(hdc16) ((HDC)HGDIOBJ_32(hdc16))
#define HRGN_32(hrgn16) ((HRGN)HGDIOBJ_32(hrgn16))
#define HBRUSH_32(hbrush16) ((HBRUSH)HGDIOBJ_32(hbrush16))
#define HBITMAP_32(hbitmap16) ((HBITMAP)HGDIOBJ_32(hbitmap16))
#define HPALETTE_32(hpalette16) ((HPALETTE)HGDIOBJ_32(hpalette16))
#define HDC_16(hdc) ((HDC16)HGDIOBJ_16(hdc))
#define HPEN_16(hpen) ((HPEN16)HGDIOBJ_16(hpen))
#define HRGN_16(hrgn) ((HRGN16)HGDIOBJ_16(hrgn))
#define HFONT_16(hfont) ((HFONT16)HGDIOBJ_16(hfont))
#define HBRUSH_16(hbrush) ((HBRUSH16)HGDIOBJ_16(hbrush))
#define HBITMAP_16(hbitmap) ((HBITMAP16)HGDIOBJ_16(hbitmap))
#define HPALETTE_16(hpalette) ((HPALETTE16)HGDIOBJ_16(hpalette))
/* convert a LOGFONT16 to a LOGFONTW */
static
void
logfont_16_to_W
(
const
LOGFONT16
*
font16
,
LPLOGFONTW
font32
)
...
...
dlls/gdi/win16drv/prtdrv.c
View file @
0ca051e5
...
...
@@ -30,6 +30,7 @@
#include <errno.h>
#include "wine/winbase16.h"
#include "winuser.h"
#include "wownt32.h"
#include "win16drv/win16drv.h"
#include "wine/debug.h"
#include "bitmap.h"
...
...
@@ -63,8 +64,6 @@ extern LONG CALLBACK PRTDRV_CallTo16_long_llwll (FARPROC16,LONG,LONG,WORD,LONG,
/* ### stop build ### */
#define HWND_16(h32) (LOWORD(h32))
#define MAX_PRINTER_DRIVERS 16
static
LOADED_PRINTER_DRIVER
*
gapLoadedPrinterDrivers
[
MAX_PRINTER_DRIVERS
];
...
...
dlls/msvideo/msvideo16.c
View file @
0ca051e5
...
...
@@ -29,12 +29,10 @@
WINE_DEFAULT_DEBUG_CHANNEL
(
msvideo
);
/* handle16 --> handle conversions */
#define HDC_32(h16) ((HDC)(ULONG_PTR)(h16))
#define HDRAWDIB_32(h16) ((HDRAWDIB)(ULONG_PTR)(h16))
#define HIC_32(h16) ((HIC)(ULONG_PTR)(h16))
/* handle --> handle16 conversions */
#define HDC_16(h32) (LOWORD(h32))
#define HDRAWDIB_16(h32) (LOWORD(h32))
#define HIC_16(h32) (LOWORD(h32))
...
...
dlls/msvideo/msvideo_main.c
View file @
0ca051e5
...
...
@@ -47,7 +47,6 @@ void MSVIDEO_UnmapMsg16To32(UINT msg, LPVOID lpv, LPDWORD lParam1, LPDWORD lPara
LRESULT
MSVIDEO_SendMessage
(
HIC
hic
,
UINT
msg
,
DWORD
lParam1
,
DWORD
lParam2
,
BOOL
bFrom32
);
#define HDRVR_16(h32) (LOWORD(h32))
#define HWND_32(h16) ((HWND)(ULONG_PTR)(h16))
/***********************************************************************
...
...
dlls/msvideo/vfw16.h
View file @
0ca051e5
...
...
@@ -20,6 +20,7 @@
#define __WINE_VFW16_H
#include "vfw.h"
#include "wownt32.h"
#include "wine/windef16.h"
#ifdef __cplusplus
...
...
@@ -117,10 +118,6 @@ HIC16 VFWAPI ICOpen16(DWORD,DWORD,UINT16);
HIC16
VFWAPI
ICOpenFunction16
(
DWORD
,
DWORD
,
UINT16
,
FARPROC16
);
LRESULT
VFWAPI
ICSendMessage16
(
HIC16
,
UINT16
,
DWORD
,
DWORD
);
/* handle <-> handle16 conversions */
#define HPALETTE_32(h16) ((HPALETTE)(ULONG_PTR)(h16))
#define HPALETTE_16(h32) (LOWORD(h32))
#ifdef __cplusplus
}
#endif
/* __cplusplus */
...
...
dlls/ole32/ole2.c
View file @
0ca051e5
...
...
@@ -36,6 +36,7 @@
#include "winerror.h"
#include "winuser.h"
#include "winreg.h"
#include "wownt32.h"
#include "wine/obj_clientserver.h"
#include "wine/winbase16.h"
...
...
@@ -48,10 +49,7 @@
WINE_DEFAULT_DEBUG_CHANNEL
(
ole
);
WINE_DECLARE_DEBUG_CHANNEL
(
accel
);
#define HACCEL_16(h32) (LOWORD(h32))
#define HICON_16(h32) (LOWORD(h32))
#define HDC_32(h16) ((HDC)(ULONG_PTR)(h16))
#define HICON_32(h16) ((HICON)(ULONG_PTR)(h16))
/******************************************************************************
...
...
dlls/setupapi/setupx_main.c
View file @
0ca051e5
...
...
@@ -61,6 +61,7 @@
#include "winreg.h"
#include "winerror.h"
#include "wine/winuser16.h"
#include "wownt32.h"
#include "setupapi.h"
#include "setupx16.h"
#include "setupapi_private.h"
...
...
@@ -69,7 +70,6 @@
WINE_DEFAULT_DEBUG_CHANNEL
(
setupapi
);
#define HWND_32(h16) ((HWND)(ULONG_PTR)(h16))
/***********************************************************************
* SURegOpenKey (SETUPX.47)
...
...
dlls/shell32/shell.c
View file @
0ca051e5
...
...
@@ -32,6 +32,7 @@
#include "windef.h"
#include "winerror.h"
#include "winreg.h"
#include "wownt32.h"
#include "dlgs.h"
#include "shellapi.h"
#include "shlobj.h"
...
...
dlls/shell32/shell32_main.h
View file @
0ca051e5
...
...
@@ -200,6 +200,5 @@ inline static void __SHCloneStrWtoA(char ** target, const WCHAR * source)
#define HICON_16(h32) (LOWORD(h32))
#define HICON_32(h16) ((HICON)(ULONG_PTR)(h16))
#define HINSTANCE_32(h16) ((HINSTANCE)(ULONG_PTR)(h16))
#define HWND_32(h16) ((HWND)(ULONG_PTR)(h16))
#endif
dlls/shell32/shlexec.c
View file @
0ca051e5
...
...
@@ -33,6 +33,7 @@
#include "windef.h"
#include "winerror.h"
#include "winreg.h"
#include "wownt32.h"
#include "heap.h"
#include "shellapi.h"
#include "shlobj.h"
...
...
dlls/user/msg16.c
View file @
0ca051e5
...
...
@@ -19,6 +19,7 @@
*/
#include "wine/winuser16.h"
#include "wownt32.h"
#include "winerror.h"
#include "hook.h"
#include "message.h"
...
...
dlls/user/property.c
View file @
0ca051e5
...
...
@@ -22,6 +22,7 @@
#include "windef.h"
#include "wingdi.h"
#include "wownt32.h"
#include "wine/winuser16.h"
#include "wine/server.h"
#include "win.h"
...
...
dlls/user/resource.c
View file @
0ca051e5
...
...
@@ -25,6 +25,7 @@
#include "winnls.h"
#include "wine/winbase16.h"
#include "wine/winuser16.h"
#include "wownt32.h"
#include "user.h"
#include "wine/debug.h"
...
...
dlls/user/user16.c
View file @
0ca051e5
...
...
@@ -20,19 +20,14 @@
#include "wine/winuser16.h"
#include "winbase.h"
#include "wownt32.h"
#include "user.h"
/* handle to handle 16 conversions */
#define HANDLE_16(h32) (LOWORD(h32))
#define HBITMAP_16(h32) (LOWORD(h32))
#define HCURSOR_16(h32) (LOWORD(h32))
#define HICON_16(h32) (LOWORD(h32))
/* handle16 to handle conversions */
#define HANDLE_32(h16) ((HANDLE)(ULONG_PTR)(h16))
#define HBRUSH_32(h16) ((HBRUSH)(ULONG_PTR)(h16))
#define HCURSOR_32(h16) ((HCURSOR)(ULONG_PTR)(h16))
#define HDC_32(h16) ((HDC)(ULONG_PTR)(h16))
#define HICON_32(h16) ((HICON)(ULONG_PTR)(h16))
#define HINSTANCE_32(h16) ((HINSTANCE)(ULONG_PTR)(h16))
WORD
WINAPI
DestroyIcon32
(
HGLOBAL16
,
UINT16
);
...
...
dlls/user/wnd16.c
View file @
0ca051e5
...
...
@@ -19,6 +19,7 @@
*/
#include "wine/winuser16.h"
#include "wownt32.h"
#include "user.h"
#include "win.h"
#include "task.h"
...
...
@@ -26,19 +27,6 @@
/* handle --> handle16 conversions */
#define HANDLE_16(h32) (LOWORD(h32))
#define HDC_16(h32) (LOWORD(h32))
#define HDWP_16(h32) (LOWORD(h32))
#define HMENU_16(h32) (LOWORD(h32))
/* handle16 --> handle conversions */
#define HBITMAP_32(h16) ((HBITMAP)(ULONG_PTR)(h16))
#define HDC_32(h16) ((HDC)(ULONG_PTR)(h16))
#define HDWP_32(h16) ((HDWP)(ULONG_PTR)(h16))
#define HFONT_32(h16) ((HFONT)(ULONG_PTR)(h16))
#define HICON_32(h16) ((HICON)(ULONG_PTR)(h16))
#define HINSTANCE_32(h16) ((HINSTANCE)(ULONG_PTR)(h16))
#define HMENU_32(h16) ((HMENU)(ULONG_PTR)(h16))
#define HRGN_32(h16) ((HRGN)(ULONG_PTR)(h16))
static
HWND16
hwndSysModal
;
...
...
@@ -1667,7 +1655,7 @@ INT16 WINAPI MessageBoxIndirect16( LPMSGBOXPARAMS16 msgbox )
msgbox32
.
cbSize
=
msgbox
->
cbSize
;
msgbox32
.
hwndOwner
=
WIN_Handle32
(
msgbox
->
hwndOwner
);
msgbox32
.
hInstance
=
HINSTANCE_32
(
msgbox
->
hInstance
);
msgbox32
.
hInstance
=
MapHModuleSL
(
msgbox
->
hInstance
);
msgbox32
.
lpszText
=
MapSL
(
msgbox
->
lpszText
);
msgbox32
.
lpszCaption
=
MapSL
(
msgbox
->
lpszCaption
);
msgbox32
.
dwStyle
=
msgbox
->
dwStyle
;
...
...
dlls/wineps/driver.c
View file @
0ca051e5
...
...
@@ -26,14 +26,13 @@
#include "psdrv.h"
#include "wine/debug.h"
#include "winuser.h"
#include "wownt32.h"
#include "winspool.h"
#include "prsht.h"
#include "psdlg.h"
WINE_DEFAULT_DEBUG_CHANNEL
(
psdrv
);
#define HWND_16(h32) (LOWORD(h32))
#define HWND_32(h16) ((HWND)(ULONG_PTR)(h16))
/************************************************************************
*
...
...
dlls/winmm/mcianim/mcianim.c
View file @
0ca051e5
...
...
@@ -24,6 +24,7 @@
#include "winbase.h"
#include "wingdi.h"
#include "winuser.h"
#include "wownt32.h"
#include "mmddk.h"
#include "wine/debug.h"
...
...
@@ -33,8 +34,6 @@ WINE_DEFAULT_DEBUG_CHANNEL(mcianim);
#define ANIMFRAMES_PERMIN 1800
#define SECONDS_PERMIN 60
#define HWND_32(h16) ((HWND)(ULONG_PTR)(h16))
typedef
struct
{
UINT16
wDevID
;
int
nUseCount
;
/* Incremented for each shared open */
...
...
dlls/winmm/mciavi/private_mciavi.h
View file @
0ca051e5
...
...
@@ -20,6 +20,9 @@
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
#ifndef __WINE_PRIVATE_MCIAVI_H
#define __WINE_PRIVATE_MCIAVI_H
#include "windef.h"
#include "winbase.h"
#include "wingdi.h"
...
...
@@ -27,6 +30,7 @@
#include "mmddk.h"
#include "digitalv.h"
#include "vfw.h"
#include "wownt32.h"
#include "mciavi.h"
struct
MMIOPos
{
...
...
@@ -101,5 +105,4 @@ DWORD MCIAVI_mciPut(UINT wDevID, DWORD dwFlags, LPMCI_DGV_PUT_PARMS lpParms);
DWORD
MCIAVI_mciWhere
(
UINT
wDevID
,
DWORD
dwFlags
,
LPMCI_DGV_RECT_PARMS
lpParms
);
DWORD
MCIAVI_mciWindow
(
UINT
wDevID
,
DWORD
dwFlags
,
LPMCI_DGV_WINDOW_PARMSA
lpParms
);
/* handle conversions */
#define HWND_32(h16) ((HWND)(ULONG_PTR)(h16))
#endif
/* __WINE_PRIVATE_MCIAVI_H */
dlls/winmm/mcicda/mcicda.c
View file @
0ca051e5
...
...
@@ -29,6 +29,7 @@
#include "winbase.h"
#include "wingdi.h"
#include "winuser.h"
#include "wownt32.h"
#include "mmddk.h"
#include "winioctl.h"
#include "ntddstor.h"
...
...
@@ -42,8 +43,6 @@ WINE_DEFAULT_DEBUG_CHANNEL(mcicda);
#define FRAME_OF_ADDR(a) ((a)[1] * CDFRAMES_PERMIN + (a)[2] * CDFRAMES_PERSEC + (a)[3])
#define FRAME_OF_TOC(toc, idx) FRAME_OF_ADDR((toc).TrackData[idx - (toc).FirstTrack].Address)
#define HWND_32(h16) ((HWND)(ULONG_PTR)(h16))
typedef
struct
{
UINT
wDevID
;
int
nUseCount
;
/* Incremented for each shared open */
...
...
dlls/winmm/mciseq/mcimidi.c
View file @
0ca051e5
...
...
@@ -37,13 +37,12 @@
#include "winbase.h"
#include "wingdi.h"
#include "winuser.h"
#include "wownt32.h"
#include "mmddk.h"
#include "wine/debug.h"
WINE_DEFAULT_DEBUG_CHANNEL
(
mcimidi
);
#define HWND_32(h16) ((HWND)(ULONG_PTR)(h16))
#define MIDI_NOTEOFF 0x80
#define MIDI_NOTEON 0x90
...
...
dlls/winmm/mciwave/mciwave.c
View file @
0ca051e5
...
...
@@ -27,13 +27,12 @@
#include "wingdi.h"
#include "winuser.h"
#include "mmddk.h"
#include "wownt32.h"
#include "digitalv.h"
#include "wine/debug.h"
WINE_DEFAULT_DEBUG_CHANNEL
(
mciwave
);
#define HWND_32(h16) ((HWND)(ULONG_PTR)(h16))
typedef
struct
{
UINT
wDevID
;
HANDLE
hWave
;
...
...
dlls/winmm/winemm.h
View file @
0ca051e5
...
...
@@ -23,6 +23,7 @@
*/
#include "mmddk.h"
#include "wownt32.h"
typedef
DWORD
(
WINAPI
*
MessageProc16
)(
UINT16
wDevID
,
UINT16
wMsg
,
DWORD
dwUser
,
DWORD
dwParam1
,
DWORD
dwParam2
);
typedef
DWORD
(
WINAPI
*
MessageProc32
)(
UINT
wDevID
,
UINT
wMsg
,
DWORD
dwUser
,
DWORD
dwParam1
,
DWORD
dwParam2
);
...
...
@@ -252,7 +253,6 @@ void TIME_MMTimeStop(void);
#define HWAVE_32(h16) ((HWAVE)(ULONG_PTR)(h16))
#define HWAVEIN_32(h16) ((HWAVEIN)(ULONG_PTR)(h16))
#define HWAVEOUT_32(h16) ((HWAVEOUT)(ULONG_PTR)(h16))
#define HWND_32(h16) ((HWND)(ULONG_PTR)(h16))
/* HANDLE -> HANDLE16 conversions */
#define HDRVR_16(h32) (LOWORD(h32))
...
...
@@ -266,4 +266,3 @@ void TIME_MMTimeStop(void);
#define HWAVE_16(h32) (LOWORD(h32))
#define HWAVEIN_16(h32) (LOWORD(h32))
#define HWAVEOUT_16(h32) (LOWORD(h32))
#define HWND_16(h32) (LOWORD(h32))
dlls/winsock/async.c
View file @
0ca051e5
...
...
@@ -102,6 +102,7 @@
#include "winuser.h"
#include "winsock2.h"
#include "ws2spi.h"
#include "wownt32.h"
#include "wine/winsock16.h"
#include "winnt.h"
...
...
dlls/winsock/socket.c
View file @
0ca051e5
...
...
@@ -114,6 +114,7 @@
#include "wsipx.h"
#include "wine/winsock16.h"
#include "winnt.h"
#include "wownt32.h"
#include "wine/server.h"
#include "wine/debug.h"
...
...
include/user.h
View file @
0ca051e5
...
...
@@ -143,13 +143,9 @@ extern HPEN SYSCOLOR_GetPen( INT index );
extern
DWORD
USER16_AlertableWait
;
/* HANDLE16 <-> HANDLE conversions */
#define HACCEL_16(h32) (LOWORD(h32))
#define HBRUSH_16(h32) (LOWORD(h32))
#define HCURSOR_16(h32) (LOWORD(h32))
#define HICON_16(h32) (LOWORD(h32))
#define HACCEL_32(h16) ((HACCEL)(ULONG_PTR)(h16))
#define HBRUSH_32(h16) ((HBRUSH)(ULONG_PTR)(h16))
#define HCURSOR_32(h16) ((HCURSOR)(ULONG_PTR)(h16))
#define HICON_32(h16) ((HICON)(ULONG_PTR)(h16))
...
...
include/win.h
View file @
0ca051e5
...
...
@@ -120,9 +120,6 @@ inline static HWND WIN_GetFullHandle( HWND hwnd )
return
hwnd
;
}
#define HWND_16(hwnd32) (LOWORD(hwnd32))
#define HWND_32(hwnd16) ((HWND)(ULONG_PTR)(hwnd16))
inline
static
WND
*
WIN_FindWndPtr16
(
HWND16
hwnd
)
{
/* don't bother with full conversion */
...
...
include/wine/winsock16.h
View file @
0ca051e5
...
...
@@ -105,7 +105,4 @@ INT16 WINAPI WSACancelAsyncRequest16(HANDLE16 hAsyncTaskHandle);
INT16
WINAPI
WSAAsyncSelect16
(
SOCKET16
s
,
HWND16
hWnd
,
UINT16
wMsg
,
LONG
lEvent
);
INT16
WINAPI
WSARecvEx16
(
SOCKET16
s
,
char
*
buf
,
INT16
len
,
INT16
*
flags
);
#define HWND_16(h32) (LOWORD(h32))
#define HWND_32(h16) ((HWND)(ULONG_PTR)(h16))
#endif
/* __WINE_WINE_WINSOCK16_H */
include/wownt32.h
View file @
0ca051e5
...
...
@@ -59,6 +59,46 @@ typedef enum
HANDLE
WINAPI
WOWHandle32
(
WORD
,
WOW_HANDLE_TYPE
);
WORD
WINAPI
WOWHandle16
(
HANDLE
,
WOW_HANDLE_TYPE
);
#ifdef __WINE__
/* under Wine use the kernel functions directly so we don't have to import wow32 */
HANDLE
WINAPI
K32WOWHandle32
(
WORD
,
WOW_HANDLE_TYPE
);
WORD
WINAPI
K32WOWHandle16
(
HANDLE
,
WOW_HANDLE_TYPE
);
#define WOWHandle32 K32WOWHandle32
#define WOWHandle16 K32WOWHandle16
#endif
#ifdef __WINE__
/* under Wine we use optimized versions where we can */
#define HWND_32(h16) ((HWND) (ULONG_PTR)(h16))
#define HMENU_32(h16) ((HMENU) (ULONG_PTR)(h16))
#define HDWP_32(h16) ((HDWP) (ULONG_PTR)(h16))
#define HDROP_32(h16) ((HDROP) (ULONG_PTR)(h16))
#define HDC_32(h16) ((HDC) (ULONG_PTR)(h16))
#define HFONT_32(h16) ((HFONT) (ULONG_PTR)(h16))
#define HMETAFILE_32(h16) ((HMETAFILE) (ULONG_PTR)(h16))
#define HRGN_32(h16) ((HRGN) (ULONG_PTR)(h16))
#define HBITMAP_32(h16) ((HBITMAP) (ULONG_PTR)(h16))
#define HBRUSH_32(h16) ((HBRUSH) (ULONG_PTR)(h16))
#define HPALETTE_32(h16) ((HPALETTE) (ULONG_PTR)(h16))
#define HPEN_32(h16) ((HPEN) (ULONG_PTR)(h16))
#define HACCEL_32(h16) ((HACCEL) (ULONG_PTR)(h16))
#define HWND_16(h32) (LOWORD(h32))
#define HMENU_16(h32) (LOWORD(h32))
#define HDWP_16(h32) (LOWORD(h32))
#define HDROP_16(h32) (LOWORD(h32))
#define HDC_16(h32) (LOWORD(h32))
#define HFONT_16(h32) (LOWORD(h32))
#define HMETAFILE_16(h32) (LOWORD(h32))
#define HRGN_16(h32) (LOWORD(h32))
#define HBITMAP_16(h32) (LOWORD(h32))
#define HBRUSH_16(h32) (LOWORD(h32))
#define HPALETTE_16(h32) (LOWORD(h32))
#define HPEN_16(h32) (LOWORD(h32))
#define HACCEL_16(h32) (LOWORD(h32))
#else
/* __WINE__ */
#define HWND_32(h16) ((HWND) (WOWHandle32(h16, WOW_TYPE_HWND)))
#define HMENU_32(h16) ((HMENU) (WOWHandle32(h16, WOW_TYPE_HMENU)))
#define HDWP_32(h16) ((HDWP) (WOWHandle32(h16, WOW_TYPE_HDWP)))
...
...
@@ -72,8 +112,6 @@ WORD WINAPI WOWHandle16(HANDLE,WOW_HANDLE_TYPE);
#define HPALETTE_32(h16) ((HPALETTE) (WOWHandle32(h16, WOW_TYPE_HPALETTE)))
#define HPEN_32(h16) ((HPEN) (WOWHandle32(h16, WOW_TYPE_HPEN)))
#define HACCEL_32(h16) ((HACCEL) (WOWHandle32(h16, WOW_TYPE_HACCEL)))
#define HTASK_32(h16) ((DWORD) (WOWHandle32(h16, WOW_TYPE_HTASK)))
#define FULLHWND_32(h16) ((HWND) (WOWHandle32(h16, WOW_TYPE_FULLHWND)))
#define HWND_16(h32) (WOWHandle16(h32, WOW_TYPE_HWND))
#define HMENU_16(h32) (WOWHandle16(h32, WOW_TYPE_HMENU))
...
...
@@ -88,8 +126,13 @@ WORD WINAPI WOWHandle16(HANDLE,WOW_HANDLE_TYPE);
#define HPALETTE_16(h32) (WOWHandle16(h32, WOW_TYPE_HPALETTE))
#define HPEN_16(h32) (WOWHandle16(h32, WOW_TYPE_HPEN))
#define HACCEL_16(h32) (WOWHandle16(h32, WOW_TYPE_HACCEL))
#define HTASK_16(h32) (WOWHandle16(h32, WOW_TYPE_HTASK))
#endif
/* __WINE__ */
#define FULLHWND_32(h16) ((HWND) (WOWHandle32(h16, WOW_TYPE_FULLHWND)))
#define HTASK_32(h16) ((DWORD)(WOWHandle32(h16, WOW_TYPE_HTASK)))
#define HTASK_16(h32) (WOWHandle16((HANDLE)(h32), WOW_TYPE_HTASK))
#define WCB16_PASCAL 0
#define WCB16_CDECL 1
...
...
@@ -99,5 +142,3 @@ DWORD WINAPI WOWCallback16(DWORD,DWORD);
BOOL
WINAPI
WOWCallback16Ex
(
DWORD
,
DWORD
,
DWORD
,
LPVOID
,
LPDWORD
);
#endif
/* _WOWNT32_H_ */
windows/class.c
View file @
0ca051e5
...
...
@@ -37,6 +37,7 @@
#include "windef.h"
#include "wingdi.h"
#include "wine/winuser16.h"
#include "wownt32.h"
#include "wine/unicode.h"
#include "win.h"
#include "user.h"
...
...
windows/cursoricon.c
View file @
0ca051e5
...
...
@@ -48,6 +48,7 @@
#include "windef.h"
#include "wingdi.h"
#include "wownt32.h"
#include "wine/winbase16.h"
#include "wine/winuser16.h"
#include "wine/exception.h"
...
...
@@ -66,16 +67,6 @@ WINE_DEFAULT_DEBUG_CHANNEL(cursor);
WINE_DECLARE_DEBUG_CHANNEL
(
icon
);
WINE_DECLARE_DEBUG_CHANNEL
(
resource
);
/* handle conversions */
#define HCURSOR_16(h32) (LOWORD(h32))
#define HGLOBAL_16(h32) (LOWORD(h32))
#define HICON_16(h32) (LOWORD(h32))
#define HINSTANCE_16(h32) (LOWORD(h32))
#define HCURSOR_32(h16) ((HCURSOR)(ULONG_PTR)(h16))
#define HICON_32(h16) ((HICON)(ULONG_PTR)(h16))
#define HINSTANCE_32(h16) ((HINSTANCE)(ULONG_PTR)(h16))
#define HMODULE_32(h16) ((HMODULE)(ULONG_PTR)(h16))
static
RECT
CURSOR_ClipRect
;
/* Cursor clipping rect */
...
...
@@ -504,14 +495,13 @@ fail:
* FIXME: Convert to mono when cFlag is LR_MONOCHROME. Do something
* with cbSize parameter as well.
*/
static
HICON
CURSORICON_CreateFromResource
(
H
INSTANCE
hInstance
,
HICON
hObject
,
LPBYTE
bits
,
static
HICON
CURSORICON_CreateFromResource
(
H
MODULE16
hModule
,
HGLOBAL16
hObj
,
LPBYTE
bits
,
UINT
cbSize
,
BOOL
bIcon
,
DWORD
dwVersion
,
INT
width
,
INT
height
,
UINT
loadflags
)
{
static
HDC
hdcMem
;
int
sizeAnd
,
sizeXor
;
HBITMAP
hAndBits
=
0
,
hXorBits
=
0
;
/* error condition for later */
HGLOBAL16
hObj
=
HGLOBAL_16
(
hObject
);
BITMAP
bmpXor
,
bmpAnd
;
POINT16
hotspot
;
BITMAPINFO
*
bmi
;
...
...
@@ -677,8 +667,8 @@ static HICON CURSORICON_CreateFromResource( HINSTANCE hInstance, HICON hObject,
CURSORICONINFO
*
info
;
/* Make it owned by the module */
if
(
h
Instance
)
hInstance
=
GetExePtr
(
hInstanc
e
);
FarSetOwner16
(
hObj
,
h
Instanc
e
);
if
(
h
Module
)
hModule
=
GetExePtr
(
hModul
e
);
FarSetOwner16
(
hObj
,
h
Modul
e
);
info
=
(
CURSORICONINFO
*
)
GlobalLock16
(
hObj
);
info
->
ptHotSpot
.
x
=
hotspot
.
x
;
...
...
@@ -825,11 +815,10 @@ static HICON CURSORICON_Load(HINSTANCE hInstance, LPCWSTR name,
*
* Make a copy of a cursor or icon.
*/
static
HICON
CURSORICON_Copy
(
HINSTANCE
hInst
,
HICON
hIcon
)
static
HICON
CURSORICON_Copy
(
HINSTANCE
16
hInst16
,
HICON
hIcon
)
{
char
*
ptrOld
,
*
ptrNew
;
int
size
;
HINSTANCE16
hInst16
=
HINSTANCE_16
(
hInst
);
HICON16
hOld
=
HICON_16
(
hIcon
);
HICON16
hNew
;
...
...
@@ -1008,7 +997,7 @@ HCURSOR WINAPI CreateCursor( HINSTANCE hInstance,
info
.
bPlanes
=
1
;
info
.
bBitsPerPixel
=
1
;
return
HICON_32
(
CreateCursorIconIndirect16
(
HINSTANCE_16
(
hInstance
),
&
info
,
return
HICON_32
(
CreateCursorIconIndirect16
(
MapHModuleLS
(
hInstance
),
&
info
,
lpANDbits
,
lpXORbits
));
}
...
...
@@ -1099,7 +1088,7 @@ HICON WINAPI CreateIcon(
info
.
bPlanes
=
bPlanes
;
info
.
bBitsPerPixel
=
bBitsPixel
;
hIcon
=
HICON_32
(
CreateCursorIconIndirect16
(
HINSTANCE_16
(
hInstance
),
&
info
,
hIcon
=
HICON_32
(
CreateCursorIconIndirect16
(
MapHModuleLS
(
hInstance
),
&
info
,
lpANDbits
,
lpXORbits
));
}
else
{
ICONINFO
iinfo
;
...
...
@@ -1171,7 +1160,7 @@ HGLOBAL16 WINAPI CreateCursorIconIndirect16( HINSTANCE16 hInstance,
HICON16
WINAPI
CopyIcon16
(
HINSTANCE16
hInstance
,
HICON16
hIcon
)
{
TRACE_
(
icon
)(
"%04x %04x
\n
"
,
hInstance
,
hIcon
);
return
HICON_16
(
CURSORICON_Copy
(
HINSTANCE_32
(
hInstance
)
,
HICON_32
(
hIcon
)));
return
HICON_16
(
CURSORICON_Copy
(
hInstance
,
HICON_32
(
hIcon
)));
}
...
...
@@ -1191,7 +1180,7 @@ HICON WINAPI CopyIcon( HICON hIcon )
HCURSOR16
WINAPI
CopyCursor16
(
HINSTANCE16
hInstance
,
HCURSOR16
hCursor
)
{
TRACE_
(
cursor
)(
"%04x %04x
\n
"
,
hInstance
,
hCursor
);
return
HICON_16
(
CURSORICON_Copy
(
HINSTANCE_32
(
hInstance
)
,
HCURSOR_32
(
hCursor
)));
return
HICON_16
(
CURSORICON_Copy
(
hInstance
,
HCURSOR_32
(
hCursor
)));
}
/**********************************************************************
...
...
@@ -1528,7 +1517,7 @@ HGLOBAL16 WINAPI LoadDIBIconHandler16( HGLOBAL16 hMemObj, HMODULE16 hModule, HRS
{
LPBYTE
bits
=
(
LPBYTE
)
GlobalLock16
(
hMemObj
);
hMemObj
=
HICON_16
(
CURSORICON_CreateFromResource
(
HMODULE_32
(
hModule
),
HICON_32
(
hMemObj
)
,
bits
,
hModule
,
hMemObj
,
bits
,
SizeofResource16
(
hModule
,
hRsrc
),
TRUE
,
0x00030000
,
GetSystemMetrics
(
SM_CXICON
),
GetSystemMetrics
(
SM_CYICON
),
LR_DEFAULTCOLOR
));
...
...
@@ -1548,7 +1537,7 @@ HGLOBAL16 WINAPI LoadDIBCursorHandler16( HGLOBAL16 hMemObj, HMODULE16 hModule, H
{
LPBYTE
bits
=
(
LPBYTE
)
GlobalLock16
(
hMemObj
);
hMemObj
=
HICON_16
(
CURSORICON_CreateFromResource
(
HMODULE_32
(
hModule
),
HICON_32
(
hMemObj
)
,
bits
,
hModule
,
hMemObj
,
bits
,
SizeofResource16
(
hModule
,
hRsrc
),
FALSE
,
0x00030000
,
GetSystemMetrics
(
SM_CXCURSOR
),
GetSystemMetrics
(
SM_CYCURSOR
),
LR_MONOCHROME
));
...
...
windows/dialog.c
View file @
0ca051e5
...
...
@@ -36,6 +36,7 @@
#include "windowsx.h"
#include "wine/winuser16.h"
#include "wine/winbase16.h"
#include "wownt32.h"
#include "wine/unicode.h"
#include "controls.h"
#include "heap.h"
...
...
windows/hook.c
View file @
0ca051e5
...
...
@@ -34,6 +34,7 @@
#include "winuser.h"
#include "wine/winuser16.h"
#include "wine/winbase16.h"
#include "wownt32.h"
#include "hook.h"
#include "win.h"
#include "queue.h"
...
...
windows/mdi.c
View file @
0ca051e5
...
...
@@ -89,6 +89,7 @@
#include "winbase.h"
#include "wingdi.h"
#include "winuser.h"
#include "wownt32.h"
#include "wine/unicode.h"
#include "win.h"
#include "nonclient.h"
...
...
windows/spy.c
View file @
0ca051e5
...
...
@@ -25,6 +25,7 @@
#include "windef.h"
#include "wingdi.h"
#include "winreg.h"
#include "wownt32.h"
#include "wine/winuser16.h"
#include "wine/winbase16.h"
#include "wine/unicode.h"
...
...
windows/struct32.c
View file @
0ca051e5
...
...
@@ -19,6 +19,7 @@
*/
#include "struct32.h"
#include "wownt32.h"
#include "win.h"
#include "winerror.h"
...
...
windows/win.c
View file @
0ca051e5
...
...
@@ -27,6 +27,7 @@
#include "windef.h"
#include "wine/winbase16.h"
#include "wine/winuser16.h"
#include "wownt32.h"
#include "wine/server.h"
#include "wine/unicode.h"
#include "win.h"
...
...
windows/winhelp.c
View file @
0ca051e5
...
...
@@ -29,6 +29,7 @@
#include "wine/debug.h"
#include "windef.h"
#include "wingdi.h"
#include "wownt32.h"
#include "wine/winuser16.h"
#include "wine/winbase16.h"
#include "win.h"
...
...
windows/winproc.c
View file @
0ca051e5
...
...
@@ -27,6 +27,7 @@
#include "windef.h"
#include "winbase.h"
#include "wingdi.h"
#include "wownt32.h"
#include "wine/winbase16.h"
#include "wine/winuser16.h"
#include "stackframe.h"
...
...
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