Release 1.5.29.
[wine] / dlls / wow32 / wow_main.c
1 /*
2  * Win32 Windows-on-Windows support
3  *
4  * Copyright 2005 Alexandre Julliard
5  *
6  * This library is free software; you can redistribute it and/or
7  * modify it under the terms of the GNU Lesser General Public
8  * License as published by the Free Software Foundation; either
9  * version 2.1 of the License, or (at your option) any later version.
10  *
11  * This library is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
14  * Lesser General Public License for more details.
15  *
16  * You should have received a copy of the GNU Lesser General Public
17  * License along with this library; if not, write to the Free Software
18  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
19  */
20
21 #include <stdarg.h>
22 #include "windef.h"
23 #include "winbase.h"
24 #include "wownt32.h"
25
26 #undef WOWCallback16
27 #undef WOWCallback16Ex
28 #undef WOWDirectedYield16
29 #undef WOWGetVDMPointer
30 #undef WOWGetVDMPointerFix
31 #undef WOWGetVDMPointerUnfix
32 #undef WOWGlobalAlloc16
33 #undef WOWGlobalAllocLock16
34 #undef WOWGlobalFree16
35 #undef WOWGlobalLock16
36 #undef WOWGlobalLockSize16
37 #undef WOWGlobalUnlock16
38 #undef WOWGlobalUnlockFree16
39 #undef WOWHandle16
40 #undef WOWHandle32
41 #undef WOWYield16
42
43 BOOL   WINAPI K32WOWGetDescriptor(DWORD,LPLDT_ENTRY);
44
45 /**********************************************************************
46  *           WOWGetDescriptor   (WOW32.1)
47  */
48 BOOL WINAPI WOWGetDescriptor( DWORD segptr, LPLDT_ENTRY ldtent )
49 {
50     return K32WOWGetDescriptor( segptr, ldtent );
51 }
52
53 /**********************************************************************
54  *           WOWGetVDMPointer   (WOW32.@)
55  */
56 LPVOID WINAPI WOWGetVDMPointer( DWORD vp, DWORD dwBytes, BOOL fProtectedMode )
57 {
58     return K32WOWGetVDMPointer( vp, dwBytes, fProtectedMode );
59 }
60
61 /**********************************************************************
62  *           WOWGetVDMPointerFix   (WOW32.@)
63  */
64 LPVOID WINAPI WOWGetVDMPointerFix( DWORD vp, DWORD dwBytes, BOOL fProtectedMode )
65 {
66     return K32WOWGetVDMPointerFix( vp, dwBytes, fProtectedMode );
67 }
68
69 /**********************************************************************
70  *           WOWGetVDMPointerUnfix   (WOW32.@)
71  */
72 void WINAPI WOWGetVDMPointerUnfix( DWORD vp )
73 {
74     K32WOWGetVDMPointerUnfix( vp );
75 }
76
77 /**********************************************************************
78  *           WOWGlobalAlloc16   (WOW32.@)
79  */
80 WORD WINAPI WOWGlobalAlloc16( WORD wFlags, DWORD cb )
81 {
82     return K32WOWGlobalAlloc16( wFlags, cb );
83 }
84
85 /**********************************************************************
86  *           WOWGlobalFree16   (WOW32.@)
87  */
88 WORD WINAPI WOWGlobalFree16( WORD hMem )
89 {
90     return K32WOWGlobalFree16( hMem );
91 }
92
93 /**********************************************************************
94  *           WOWGlobalLock16   (WOW32.@)
95  */
96 DWORD WINAPI WOWGlobalLock16( WORD hMem )
97 {
98     return K32WOWGlobalLock16( hMem );
99 }
100
101 /**********************************************************************
102  *           WOWGlobalUnlock16   (WOW32.@)
103  */
104 BOOL WINAPI WOWGlobalUnlock16( WORD hMem )
105 {
106     return K32WOWGlobalUnlock16( hMem );
107 }
108
109 /**********************************************************************
110  *           WOWGlobalAllocLock16   (WOW32.@)
111  */
112 DWORD WINAPI WOWGlobalAllocLock16( WORD wFlags, DWORD cb, WORD *phMem )
113 {
114     return K32WOWGlobalAllocLock16( wFlags, cb, phMem );
115 }
116
117 /**********************************************************************
118  *           WOWGlobalLockSize16   (WOW32.@)
119  */
120 DWORD WINAPI WOWGlobalLockSize16( WORD hMem, PDWORD pcb )
121 {
122     return K32WOWGlobalLockSize16( hMem, pcb );
123 }
124
125 /**********************************************************************
126  *           WOWGlobalUnlockFree16   (WOW32.@)
127  */
128 WORD WINAPI WOWGlobalUnlockFree16( DWORD vpMem )
129 {
130     return K32WOWGlobalUnlockFree16( vpMem );
131 }
132
133 /**********************************************************************
134  *           WOWYield16   (WOW32.@)
135  */
136 void WINAPI WOWYield16(void)
137 {
138     K32WOWYield16();
139 }
140
141 /**********************************************************************
142  *           WOWDirectedYield16   (WOW32.@)
143  */
144 void WINAPI WOWDirectedYield16( WORD htask16 )
145 {
146     K32WOWDirectedYield16( htask16 );
147 }
148
149 /***********************************************************************
150  *           WOWHandle32   (WOW32.@)
151  */
152 HANDLE WINAPI WOWHandle32( WORD handle, WOW_HANDLE_TYPE type )
153 {
154     return K32WOWHandle32( handle, type );
155 }
156
157 /***********************************************************************
158  *           WOWHandle16   (WOW32.@)
159  */
160 WORD WINAPI WOWHandle16( HANDLE handle, WOW_HANDLE_TYPE type )
161 {
162     return K32WOWHandle16( handle, type );
163 }
164
165 /**********************************************************************
166  *           WOWCallback16Ex   (WOW32.@)
167  */
168 BOOL WINAPI WOWCallback16Ex( DWORD vpfn16, DWORD dwFlags,
169                              DWORD cbArgs, PVOID pArgs, PDWORD pdwRetCode )
170 {
171     return K32WOWCallback16Ex( vpfn16, dwFlags, cbArgs, pArgs, pdwRetCode );
172 }
173
174 /**********************************************************************
175  *           WOWCallback16   (WOW32.@)
176  */
177 DWORD WINAPI WOWCallback16( DWORD vpfn16, DWORD dwParam )
178 {
179     return K32WOWCallback16( vpfn16, dwParam );
180 }