Alexandre Julliard | 0799c1a | 2002-03-09 23:29:33 +0000 | [diff] [blame^] | 1 | /* |
| 2 | * Copyright (C) 1998 François Gouget |
| 3 | * |
| 4 | * This library is free software; you can redistribute it and/or |
| 5 | * modify it under the terms of the GNU Lesser General Public |
| 6 | * License as published by the Free Software Foundation; either |
| 7 | * version 2.1 of the License, or (at your option) any later version. |
| 8 | * |
| 9 | * This library is distributed in the hope that it will be useful, |
| 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
| 12 | * Lesser General Public License for more details. |
| 13 | * |
| 14 | * You should have received a copy of the GNU Lesser General Public |
| 15 | * License along with this library; if not, write to the Free Software |
| 16 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
| 17 | */ |
| 18 | |
François Gouget | d604eb1 | 1998-12-18 16:00:03 +0000 | [diff] [blame] | 19 | #ifndef __WINE_OBJBASE_H |
| 20 | #define __WINE_OBJBASE_H |
| 21 | |
Paul Quinn | aaa8306 | 1999-06-05 15:23:20 +0000 | [diff] [blame] | 22 | #define _OBJBASE_H_ |
François Gouget | d604eb1 | 1998-12-18 16:00:03 +0000 | [diff] [blame] | 23 | |
Francois Gouget | 7188916 | 2000-11-15 22:12:48 +0000 | [diff] [blame] | 24 | #include "unknwn.h" |
Alexandre Julliard | 638f169 | 1999-01-17 16:32:32 +0000 | [diff] [blame] | 25 | |
| 26 | /* the following depend only on obj_base.h */ |
Francois Gouget | 8a25944 | 2001-05-07 18:20:32 +0000 | [diff] [blame] | 27 | #include "wine/obj_base.h" |
Alexandre Julliard | 638f169 | 1999-01-17 16:32:32 +0000 | [diff] [blame] | 28 | #include "wine/obj_misc.h" |
| 29 | #include "wine/obj_channel.h" |
| 30 | #include "wine/obj_clientserver.h" |
Alexandre Julliard | 638f169 | 1999-01-17 16:32:32 +0000 | [diff] [blame] | 31 | #include "wine/obj_storage.h" |
| 32 | |
| 33 | /* the following depend on obj_storage.h */ |
Francois Gouget | 6ccda0d | 1999-02-13 12:25:03 +0000 | [diff] [blame] | 34 | #include "wine/obj_marshal.h" |
Alexandre Julliard | 638f169 | 1999-01-17 16:32:32 +0000 | [diff] [blame] | 35 | #include "wine/obj_moniker.h" |
| 36 | #include "wine/obj_propertystorage.h" |
| 37 | |
| 38 | /* the following depend on obj_moniker.h */ |
| 39 | #include "wine/obj_dataobject.h" |
| 40 | |
Paul Quinn | ea1640f | 1999-03-10 18:03:53 +0000 | [diff] [blame] | 41 | #include "wine/obj_dragdrop.h" |
| 42 | |
Francois Gouget | f2973ca | 2000-09-22 22:17:49 +0000 | [diff] [blame] | 43 | #ifndef RC_INVOKED |
| 44 | /* For compatibility only, at least for now */ |
| 45 | #include <stdlib.h> |
| 46 | #endif |
| 47 | |
Peter Hunnisett | 3d7cd87 | 2001-04-12 21:10:54 +0000 | [diff] [blame] | 48 | #ifndef INITGUID |
François Gouget | 504973d | 2001-01-02 20:55:40 +0000 | [diff] [blame] | 49 | #include "cguid.h" |
Peter Hunnisett | 3d7cd87 | 2001-04-12 21:10:54 +0000 | [diff] [blame] | 50 | #endif |
François Gouget | 504973d | 2001-01-02 20:55:40 +0000 | [diff] [blame] | 51 | |
Francois Gouget | 0062892 | 2000-10-19 20:32:18 +0000 | [diff] [blame] | 52 | #ifdef __cplusplus |
| 53 | extern "C" { |
| 54 | #endif |
| 55 | |
François Gouget | 9a8c2e2 | 2000-12-15 21:29:41 +0000 | [diff] [blame] | 56 | HRESULT WINAPI GetClassFile(LPCOLESTR filePathName,CLSID *pclsid); |
Noomen Hamza | ed494ec | 1999-03-23 13:48:56 +0000 | [diff] [blame] | 57 | |
Francois Gouget | 0062892 | 2000-10-19 20:32:18 +0000 | [diff] [blame] | 58 | #ifdef __cplusplus |
| 59 | } |
| 60 | #endif |
| 61 | |
François Gouget | 42b3ee7 | 2000-12-19 02:09:52 +0000 | [diff] [blame] | 62 | #ifndef __WINE__ |
| 63 | /* These macros are msdev's way of defining COM objects. |
| 64 | * They are provided here for use by Winelib developpers. |
Adrian Thurston | c9105da | 1999-04-22 14:56:14 +0000 | [diff] [blame] | 65 | */ |
Paul Quinn | aaa8306 | 1999-06-05 15:23:20 +0000 | [diff] [blame] | 66 | #define FARSTRUCT |
| 67 | #define HUGEP |
| 68 | |
Paul Quinn | ea1640f | 1999-03-10 18:03:53 +0000 | [diff] [blame] | 69 | #define WINOLEAPI STDAPI |
| 70 | #define WINOLEAPI_(type) STDAPI_(type) |
| 71 | |
Paul Quinn | ea1640f | 1999-03-10 18:03:53 +0000 | [diff] [blame] | 72 | #if defined(__cplusplus) && !defined(CINTERFACE) |
| 73 | #define interface struct |
| 74 | #define STDMETHOD(method) virtual HRESULT STDMETHODCALLTYPE method |
| 75 | #define STDMETHOD_(type,method) virtual type STDMETHODCALLTYPE method |
| 76 | #define PURE = 0 |
| 77 | #define THIS_ |
| 78 | #define THIS void |
| 79 | #define DECLARE_INTERFACE(iface) interface iface |
| 80 | #define DECLARE_INTERFACE_(iface, baseiface) interface iface : public baseiface |
| 81 | |
Adrian Thurston | c9105da | 1999-04-22 14:56:14 +0000 | [diff] [blame] | 82 | #define BEGIN_INTERFACE |
| 83 | #define END_INTERFACE |
Paul Quinn | ea1640f | 1999-03-10 18:03:53 +0000 | [diff] [blame] | 84 | |
| 85 | #else |
| 86 | |
| 87 | #define interface struct |
Francois Gouget | 6fbbe0f | 2000-06-16 21:48:24 +0000 | [diff] [blame] | 88 | #define STDMETHOD(method) HRESULT STDMETHODCALLTYPE (*method) |
| 89 | #define STDMETHOD_(type,method) type STDMETHODCALLTYPE (*method) |
Paul Quinn | ea1640f | 1999-03-10 18:03:53 +0000 | [diff] [blame] | 90 | #define PURE |
| 91 | #define THIS_ INTERFACE FAR* This, |
| 92 | #define THIS INTERFACE FAR* This |
Adrian Thurston | c9105da | 1999-04-22 14:56:14 +0000 | [diff] [blame] | 93 | |
Paul Quinn | ea1640f | 1999-03-10 18:03:53 +0000 | [diff] [blame] | 94 | #ifdef CONST_VTABLE |
| 95 | #undef CONST_VTBL |
| 96 | #define CONST_VTBL const |
Adrian Thurston | c9105da | 1999-04-22 14:56:14 +0000 | [diff] [blame] | 97 | #define DECLARE_INTERFACE(iface) \ |
| 98 | typedef interface iface { const struct iface##Vtbl FAR* lpVtbl; } iface; \ |
| 99 | typedef const struct iface##Vtbl iface##Vtbl; \ |
| 100 | const struct iface##Vtbl |
Paul Quinn | ea1640f | 1999-03-10 18:03:53 +0000 | [diff] [blame] | 101 | #else |
| 102 | #undef CONST_VTBL |
| 103 | #define CONST_VTBL |
Adrian Thurston | c9105da | 1999-04-22 14:56:14 +0000 | [diff] [blame] | 104 | #define DECLARE_INTERFACE(iface) \ |
| 105 | typedef interface iface { struct iface##Vtbl FAR* lpVtbl; } iface; \ |
| 106 | typedef struct iface##Vtbl iface##Vtbl; \ |
| 107 | struct iface##Vtbl |
Paul Quinn | ea1640f | 1999-03-10 18:03:53 +0000 | [diff] [blame] | 108 | #endif |
| 109 | #define DECLARE_INTERFACE_(iface, baseiface) DECLARE_INTERFACE(iface) |
| 110 | |
Adrian Thurston | c9105da | 1999-04-22 14:56:14 +0000 | [diff] [blame] | 111 | #define BEGIN_INTERFACE |
| 112 | #define END_INTERFACE |
| 113 | |
François Gouget | 42b3ee7 | 2000-12-19 02:09:52 +0000 | [diff] [blame] | 114 | #endif /* __cplusplus && !CINTERFACE */ |
| 115 | |
| 116 | #endif /* __WINE__ */ |
François Gouget | d604eb1 | 1998-12-18 16:00:03 +0000 | [diff] [blame] | 117 | |
| 118 | #endif /* __WINE_OBJBASE_H */ |