OGR
cpl_win32ce_api.h
1 /******************************************************************************
2  * $Id: cpl_win32ce_api.h 10645 2007-01-18 02:22:39Z warmerdam $
3  *
4  * Name: cpl_win32ce_api.h
5  * Project: CPL - Common Portability Library
6  * Purpose: ASCII wrappers around only Unicode Windows CE API.
7  * Author: Mateusz Łoskot, mloskot@taxussi.com.pl
8  *
9  ******************************************************************************
10  * Copyright (c) 2006, Mateusz Łoskot
11  *
12  * Permission is hereby granted, free of charge, to any person obtaining a
13  * copy of this software and associated documentation files (the "Software"),
14  * to deal in the Software without restriction, including without limitation
15  * the rights to use, copy, modify, merge, publish, distribute, sublicense,
16  * and/or sell copies of the Software, and to permit persons to whom the
17  * Software is furnished to do so, subject to the following conditions:
18  *
19  * The above copyright notice and this permission notice shall be included
20  * in all copies or substantial portions of the Software.
21  *
22  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
23  * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
24  * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
25  * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
26  * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
27  * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
28  * DEALINGS IN THE SOFTWARE.
29  ****************************************************************************/
30 #ifndef _CPL_WINCEAPI_H_INCLUDED
31 #define _CPL_WINCEAPI_H_INCLUDED 1
32 
33 #define WIN32CE
34 #if defined(WIN32CE)
35 
36 #include <windows.h>
37 
38 #ifdef __cplusplus
39 extern "C" {
40 #endif /* __cplusplus */
41 
42 /*
43  * Windows CE API non-Unicode Wrappers
44  */
45 
46 HMODULE CE_LoadLibraryA(
47  LPCSTR lpLibFileName
48  );
49 
50 FARPROC CE_GetProcAddressA(
51  HMODULE hModule,
52  LPCSTR lpProcName
53  );
54 
55 
56 DWORD CE_GetModuleFileNameA(
57  HMODULE hModule,
58  LPSTR lpFilename,
59  DWORD nSize
60  );
61 
62 HANDLE CE_CreateFileA(
63  LPCSTR lpFileName,
64  DWORD dwDesiredAccess,
65  DWORD dwShareMode,
66  LPSECURITY_ATTRIBUTES lpSecurityAttributes,
67  DWORD dwCreationDisposition,
68  DWORD dwFlagsAndAttributes,
69  HANDLE hTemplateFile
70  );
71 
72 
73 /* Replace Windows CE API calls with our own non-Unicode equivalents. */
74 
75 
76 /* XXX - mloskot - those defines are quite confusing ! */
77 /*
78 #ifdef LoadLibrary
79 # undef LoadLibrary
80 # define LoadLibrary CE_LoadLibraryA
81 #endif
82 
83 #ifdef GetProcAddress
84 # undef GetProcAddress
85 # define GetProcAddress CE_GetProcAddressA
86 #endif
87 
88 #ifdef GetModuleFileName
89 # undef GetModuleFileName
90 # define GetModuleFileName CE_GetModuleFileNameA
91 #endif
92 
93 #ifdef CreateFile
94 # undef CreateFile
95 # define CreateFile CE_CreateFileA
96 #endif
97 */
98 
99 #ifdef __cplusplus
100 }
101 #endif /* __cplusplus */
102 
103 #endif /* #ifdef WIN32CE */
104 
105 #endif /* #ifndef _CPL_WINCEAPI_H_INCLUDED */

Generated for GDAL by doxygen 1.8.11.