2 * Copyright (C) 1998 Anders Norlander
3 * Copyright (C) 2005 Steven Edwards
5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Lesser General Public
7 * License as published by the Free Software Foundation; either
8 * version 2.1 of the License, or (at your option) any later version.
10 * This library is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Lesser General Public License for more details.
15 * You should have received a copy of the GNU Lesser General Public
16 * License along with this library; if not, write to the Free Software
17 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
24 # define EXTERN_C extern "C"
26 # define EXTERN_C extern
29 #define STDMETHODCALLTYPE WINAPI
30 #define STDMETHODVCALLTYPE WINAPIV
31 #define STDAPICALLTYPE WINAPI
32 #define STDAPIVCALLTYPE WINAPIV
33 #define STDAPI EXTERN_C HRESULT STDAPICALLTYPE
34 #define STDAPI_(t) EXTERN_C t STDAPICALLTYPE
35 #define STDMETHODIMP HRESULT STDMETHODCALLTYPE
36 #define STDMETHODIMP_(t) t STDMETHODCALLTYPE
37 #define STDAPIV EXTERN_C HRESULT STDAPIVCALLTYPE
38 #define STDAPIV_(t) EXTERN_C t STDAPIVCALLTYPE
39 #define STDMETHODIMPV HRESULT STDMETHODVCALLTYPE
40 #define STDMETHODIMPV_(t) t STDMETHODVCALLTYPE
42 #if defined(__cplusplus) && !defined(CINTERFACE)
44 #ifdef COM_STDMETHOD_CAN_THROW
45 # define COM_DECLSPEC_NOTHROW
47 # define COM_DECLSPEC_NOTHROW DECLSPEC_NOTHROW
50 # define interface struct
51 # define STDMETHOD(m) virtual COM_DECLSPEC_NOTHROW HRESULT STDMETHODCALLTYPE m
52 # define STDMETHOD_(t,m) virtual COM_DECLSPEC_NOTHROW t STDMETHODCALLTYPE m
56 # define DECLARE_INTERFACE(i) interface i
57 # define DECLARE_INTERFACE_(i,b) interface i : public b
59 # define STDMETHOD(m) HRESULT (STDMETHODCALLTYPE *m)
60 # define STDMETHOD_(t,m) t (STDMETHODCALLTYPE *m)
62 # define THIS_ INTERFACE *,
63 # define THIS INTERFACE *
65 # define DECLARE_INTERFACE(i) \
66 typedef interface i { const struct i##Vtbl *lpVtbl; } i; \
67 typedef struct i##Vtbl i##Vtbl; \
70 # define DECLARE_INTERFACE(i) \
71 typedef interface i { struct i##Vtbl *lpVtbl; } i; \
72 typedef struct i##Vtbl i##Vtbl; \
75 # define DECLARE_INTERFACE_(i,b) DECLARE_INTERFACE(i)
80 #ifndef _ERROR_STATUS_T_DEFINED
81 typedef unsigned long error_status_t
;
82 #define _ERROR_STATUS_T_DEFINED
85 #ifndef _WCHAR_T_DEFINED
87 typedef unsigned short wchar_t;
89 #define _WCHAR_T_DEFINED
92 #endif /* _BASETYPS_H_ */