makefiles: Don't use standard libs for programs that specify -nodefaultlibs.
[wine/zf.git] / dlls / olesvr32 / olesvr_main.c
blob0ca83ba86e7e6f05bb4c26a3a70b8086c2f4dffd
1 /*
2 * OLESVR library
4 * Copyright 1995 Martin von Loewis
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.
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.
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
21 /* At the moment, these are only empty stubs.
24 #include <stdarg.h>
26 #include "windef.h"
27 #include "winbase.h"
28 #include "objbase.h"
29 #include "wine/debug.h"
31 WINE_DEFAULT_DEBUG_CHANNEL(ole);
33 typedef enum
35 OLE_OK,
36 OLE_WAIT_FOR_RELEASE,
37 OLE_BUSY,
38 OLE_ERROR_PROTECT_ONLY,
39 OLE_ERROR_MEMORY,
40 OLE_ERROR_STREAM,
41 OLE_ERROR_STATIC,
42 OLE_ERROR_BLANK,
43 OLE_ERROR_DRAW,
44 OLE_ERROR_METAFILE,
45 OLE_ERROR_ABORT,
46 OLE_ERROR_CLIPBOARD,
47 OLE_ERROR_FORMAT,
48 OLE_ERROR_OBJECT,
49 OLE_ERROR_OPTION,
50 OLE_ERROR_PROTOCOL,
51 OLE_ERROR_ADDRESS,
52 OLE_ERROR_NOT_EQUAL,
53 OLE_ERROR_HANDLE,
54 OLE_ERROR_GENERIC,
55 OLE_ERROR_CLASS,
56 OLE_ERROR_SYNTAX,
57 OLE_ERROR_DATATYPE,
58 OLE_ERROR_PALETTE,
59 OLE_ERROR_NOT_LINK,
60 OLE_ERROR_NOT_EMPTY,
61 OLE_ERROR_SIZE,
62 OLE_ERROR_DRIVE,
63 OLE_ERROR_NETWORK,
64 OLE_ERROR_NAME,
65 OLE_ERROR_TEMPLATE,
66 OLE_ERROR_NEW,
67 OLE_ERROR_EDIT,
68 OLE_ERROR_OPEN,
69 OLE_ERROR_NOT_OPEN,
70 OLE_ERROR_LAUNCH,
71 OLE_ERROR_COMM,
72 OLE_ERROR_TERMINATE,
73 OLE_ERROR_COMMAND,
74 OLE_ERROR_SHOW,
75 OLE_ERROR_DOVERB,
76 OLE_ERROR_ADVISE_NATIVE,
77 OLE_ERROR_ADVISE_PICT,
78 OLE_ERROR_ADVISE_RENAME,
79 OLE_ERROR_POKE_NATIVE,
80 OLE_ERROR_REQUEST_NATIVE,
81 OLE_ERROR_REQUEST_PICT,
82 OLE_ERROR_SERVER_BLOCKED,
83 OLE_ERROR_REGISTRATION,
84 OLE_ERROR_ALREADY_REGISTERED,
85 OLE_ERROR_TASK,
86 OLE_ERROR_OUTOFDATE,
87 OLE_ERROR_CANT_UPDATE_CLIENT,
88 OLE_ERROR_UPDATE,
89 OLE_ERROR_SETDATA_FORMAT,
90 OLE_ERROR_STATIC_FROM_OTHER_OS,
91 OLE_WARN_DELETE_DATA = 1000
92 } OLESTATUS;
94 typedef enum {
95 OLE_SERVER_MULTI,
96 OLE_SERVER_SINGLE
97 } OLE_SERVER_USE;
99 typedef LONG LHSERVER;
100 typedef LONG LHSERVERDOC;
101 typedef LPCSTR LPCOLESTR16;
103 typedef struct _OLESERVERDOC *LPOLESERVERDOC;
105 struct _OLESERVERDOCVTBL;
106 typedef struct _OLESERVERDOC
108 const struct _OLESERVERDOCVTBL *lpvtbl;
109 /* server provided state info */
110 } OLESERVERDOC;
112 typedef struct _OLESERVER *LPOLESERVER;
113 typedef struct _OLESERVERVTBL
115 OLESTATUS (CALLBACK *Open)(LPOLESERVER,LHSERVERDOC,LPCOLESTR16,LPOLESERVERDOC *);
116 OLESTATUS (CALLBACK *Create)(LPOLESERVER,LHSERVERDOC,LPCOLESTR16,LPCOLESTR16,LPOLESERVERDOC*);
117 OLESTATUS (CALLBACK *CreateFromTemplate)(LPOLESERVER,LHSERVERDOC,LPCOLESTR16,LPCOLESTR16,LPCOLESTR16,LPOLESERVERDOC *);
118 OLESTATUS (CALLBACK *Edit)(LPOLESERVER,LHSERVERDOC,LPCOLESTR16,LPCOLESTR16,LPOLESERVERDOC *);
119 OLESTATUS (CALLBACK *Exit)(LPOLESERVER);
120 OLESTATUS (CALLBACK *Release)(LPOLESERVER);
121 OLESTATUS (CALLBACK *Execute)(LPOLESERVER);
122 } OLESERVERVTBL, *LPOLESERVERVTBL;
124 typedef struct _OLESERVER
126 const OLESERVERVTBL *lpvtbl;
127 /* server specific data */
128 } OLESERVER;
130 static LONG OLE_current_handle;
132 /******************************************************************************
133 * OleBlockServer [OLESVR32.4]
135 OLESTATUS WINAPI OleBlockServer(LHSERVER hServer)
137 FIXME("(%d): stub\n",hServer);
138 return OLE_OK;
141 /******************************************************************************
142 * OleUnblockServer [OLESVR32.5]
144 OLESTATUS WINAPI OleUnblockServer(LHSERVER hServer, BOOL *block)
146 FIXME("(%d): stub\n",hServer);
147 /* no more blocked messages :) */
148 *block=FALSE;
149 return OLE_OK;
152 /******************************************************************************
153 * OleRevokeServerDoc [OLESVR32.7]
155 OLESTATUS WINAPI OleRevokeServerDoc(LHSERVERDOC hServerDoc)
157 FIXME("(%d): stub\n",hServerDoc);
158 return OLE_OK;
161 /******************************************************************************
162 * OleRegisterServer [OLESVR32.2]
164 OLESTATUS WINAPI OleRegisterServer(LPCSTR svrname,LPOLESERVER olesvr,LHSERVER* hRet,HINSTANCE hinst,OLE_SERVER_USE osu) {
165 FIXME("(%s,%p,%p,%p,%d): stub!\n",svrname,olesvr,hRet,hinst,osu);
166 *hRet=++OLE_current_handle;
167 return OLE_OK;
170 /******************************************************************************
171 * OleRegisterServerDoc [OLESVR32.6]
173 OLESTATUS WINAPI OleRegisterServerDoc( LHSERVER hServer, LPCSTR docname,
174 LPOLESERVERDOC document,
175 LHSERVERDOC *hRet)
177 FIXME("(%d,%s): stub\n", hServer, docname);
178 *hRet=++OLE_current_handle;
179 return OLE_OK;
182 /******************************************************************************
183 * OleRenameServerDoc [OLESVR32.8]
186 OLESTATUS WINAPI OleRenameServerDoc(LHSERVERDOC hDoc, LPCSTR newName)
188 FIXME("(%d,%s): stub.\n",hDoc, newName);
189 return OLE_OK;
192 /******************************************************************************
193 * OleRevertServerDoc [OLESVR32.9]
196 OLESTATUS WINAPI OleRevertServerDoc(LHSERVERDOC hDoc)
198 FIXME("(%d): stub.\n", hDoc);
199 return OLE_OK;
202 /******************************************************************************
203 * OleSavedServerDoc [OLESVR32.10]
206 OLESTATUS WINAPI OleSavedServerDoc(LHSERVERDOC hDoc)
208 FIXME("(%d): stub.\n", hDoc);
209 return OLE_OK;
212 /******************************************************************************
213 * OleRevokeServer [OLESVR32.3]
216 OLESTATUS WINAPI OleRevokeServer(LHSERVER hServer)
218 FIXME("(%d): stub.\n", hServer);
219 return OLE_OK;