4 * Copyright 1998 Patrik Stridvall
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 #define COM_NO_WINDOWS_H
31 #include "oledlg_private.h"
33 #include "wine/debug.h"
35 WINE_DEFAULT_DEBUG_CHANNEL(ole);
37 HINSTANCE OLEDLG_hInstance = 0;
40 UINT cf_embedded_object;
42 UINT cf_object_descriptor;
43 UINT cf_link_src_descriptor;
48 static void register_clipboard_formats(void)
50 /* These used to be declared in olestd.h, but that seems to have been removed from the api */
51 static const WCHAR CF_EMBEDSOURCEW[] = { 'E','m','b','e','d',' ','S','o','u','r','c','e',0 };
52 static const WCHAR CF_EMBEDDEDOBJECTW[] = { 'E','m','b','e','d','d','e','d',' ','O','b','j','e','c','t',0 };
53 static const WCHAR CF_LINKSOURCEW[] = { 'L','i','n','k',' ','S','o','u','r','c','e',0 };
54 static const WCHAR CF_OBJECTDESCRIPTORW[] = { 'O','b','j','e','c','t',' ','D','e','s','c','r','i','p','t','o','r',0 };
55 static const WCHAR CF_LINKSRCDESCRIPTORW[] = { 'L','i','n','k',' ','S','o','u','r','c','e',' ','D','e','s','c','r','i','p','t','o','r',0 };
56 static const WCHAR CF_OWNERLINKW[] = { 'O','w','n','e','r','L','i','n','k',0 };
57 static const WCHAR CF_FILENAMEW[] = { 'F','i','l','e','N','a','m','e',0 };
58 static const WCHAR CF_FILENAMEWW[] = { 'F','i','l','e','N','a','m','e','W',0 };
60 /* Load in the same order as native to make debugging easier */
61 cf_object_descriptor = RegisterClipboardFormatW(CF_OBJECTDESCRIPTORW);
62 cf_link_src_descriptor = RegisterClipboardFormatW(CF_LINKSRCDESCRIPTORW);
63 cf_embed_source = RegisterClipboardFormatW(CF_EMBEDSOURCEW);
64 cf_embedded_object = RegisterClipboardFormatW(CF_EMBEDDEDOBJECTW);
65 cf_link_source = RegisterClipboardFormatW(CF_LINKSOURCEW);
66 cf_ownerlink = RegisterClipboardFormatW(CF_OWNERLINKW);
67 cf_filename = RegisterClipboardFormatW(CF_FILENAMEW);
68 cf_filenamew = RegisterClipboardFormatW(CF_FILENAMEWW);
71 /***********************************************************************
74 BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID fImpLoad)
76 TRACE("%p 0x%x %p\n", hinstDLL, fdwReason, fImpLoad);
79 case DLL_PROCESS_ATTACH:
80 DisableThreadLibraryCalls(hinstDLL);
81 OLEDLG_hInstance = hinstDLL;
82 register_clipboard_formats();
85 case DLL_PROCESS_DETACH:
93 /***********************************************************************
94 * OleUIAddVerbMenuA (OLEDLG.1)
96 BOOL WINAPI OleUIAddVerbMenuA(
97 LPOLEOBJECT lpOleObj, LPCSTR lpszShortType,
98 HMENU hMenu, UINT uPos, UINT uIDVerbMin, UINT uIDVerbMax,
99 BOOL bAddConvert, UINT idConvert, HMENU *lphMenu)
101 FIXME("(%p, %s, %p, %d, %d, %d, %d, %d, %p): stub\n",
102 lpOleObj, debugstr_a(lpszShortType),
103 hMenu, uPos, uIDVerbMin, uIDVerbMax,
104 bAddConvert, idConvert, lphMenu
106 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
110 /***********************************************************************
111 * OleUIAddVerbMenuW (OLEDLG.14)
113 BOOL WINAPI OleUIAddVerbMenuW(
114 LPOLEOBJECT lpOleObj, LPCWSTR lpszShortType,
115 HMENU hMenu, UINT uPos, UINT uIDVerbMin, UINT uIDVerbMax,
116 BOOL bAddConvert, UINT idConvert, HMENU *lphMenu)
118 FIXME("(%p, %s, %p, %d, %d, %d, %d, %d, %p): stub\n",
119 lpOleObj, debugstr_w(lpszShortType),
120 hMenu, uPos, uIDVerbMin, uIDVerbMax,
121 bAddConvert, idConvert, lphMenu
123 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
127 /***********************************************************************
128 * OleUICanConvertOrActivateAs (OLEDLG.2)
130 BOOL WINAPI OleUICanConvertOrActivateAs(
131 REFCLSID rClsid, BOOL fIsLinkedObject, WORD wFormat)
133 FIXME("(%p, %d, %hd): stub\n",
134 rClsid, fIsLinkedObject, wFormat
136 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
140 /***********************************************************************
141 * OleUIInsertObjectW (OLEDLG.20)
143 UINT WINAPI OleUIInsertObjectW(LPOLEUIINSERTOBJECTW lpOleUIInsertObject)
145 FIXME("(%p): stub\n", lpOleUIInsertObject);
146 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
150 /***********************************************************************
151 * OleUIEditLinksA (OLEDLG.5)
153 UINT WINAPI OleUIEditLinksA(LPOLEUIEDITLINKSA lpOleUIEditLinks)
155 FIXME("(%p): stub\n", lpOleUIEditLinks);
156 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
160 /***********************************************************************
161 * OleUIEditLinksW (OLEDLG.19)
163 UINT WINAPI OleUIEditLinksW(LPOLEUIEDITLINKSW lpOleUIEditLinks)
165 FIXME("(%p): stub\n", lpOleUIEditLinks);
166 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
170 /***********************************************************************
171 * OleUIChangeIconA (OLEDLG.6)
173 UINT WINAPI OleUIChangeIconA(
174 LPOLEUICHANGEICONA lpOleUIChangeIcon)
176 FIXME("(%p): stub\n", lpOleUIChangeIcon);
177 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
181 /***********************************************************************
182 * OleUIChangeIconW (OLEDLG.16)
184 UINT WINAPI OleUIChangeIconW(
185 LPOLEUICHANGEICONW lpOleUIChangeIcon)
187 FIXME("(%p): stub\n", lpOleUIChangeIcon);
188 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
192 /***********************************************************************
193 * OleUIConvertA (OLEDLG.7)
195 UINT WINAPI OleUIConvertA(LPOLEUICONVERTA lpOleUIConvert)
197 FIXME("(%p): stub\n", lpOleUIConvert);
198 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
202 /***********************************************************************
203 * OleUIConvertW (OLEDLG.18)
205 UINT WINAPI OleUIConvertW(LPOLEUICONVERTW lpOleUIConvert)
207 FIXME("(%p): stub\n", lpOleUIConvert);
208 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
212 /***********************************************************************
213 * OleUIBusyA (OLEDLG.8)
215 UINT WINAPI OleUIBusyA(LPOLEUIBUSYA lpOleUIBusy)
217 FIXME("(%p): stub\n", lpOleUIBusy);
218 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
222 /***********************************************************************
223 * OleUIBusyW (OLEDLG.15)
225 UINT WINAPI OleUIBusyW(LPOLEUIBUSYW lpOleUIBusy)
227 FIXME("(%p): stub\n", lpOleUIBusy);
228 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
232 /***********************************************************************
233 * OleUIUpdateLinksA (OLEDLG.9)
235 BOOL WINAPI OleUIUpdateLinksA(
236 LPOLEUILINKCONTAINERA lpOleUILinkCntr,
237 HWND hwndParent, LPSTR lpszTitle, INT cLinks)
239 FIXME("(%p, %p, %s, %d): stub\n",
240 lpOleUILinkCntr, hwndParent, debugstr_a(lpszTitle), cLinks
242 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
246 /***********************************************************************
247 * OleUIUpdateLinksW (OLEDLG.23)
249 BOOL WINAPI OleUIUpdateLinksW(
250 LPOLEUILINKCONTAINERW lpOleUILinkCntr,
251 HWND hwndParent, LPWSTR lpszTitle, INT cLinks)
253 FIXME("(%p, %p, %s, %d): stub\n",
254 lpOleUILinkCntr, hwndParent, debugstr_w(lpszTitle), cLinks
256 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
260 /***********************************************************************
261 * OleUIPromptUserA (OLEDLG.10)
263 INT WINAPIV OleUIPromptUserA(
264 INT nTemplate, HWND hwndParent, ...)
266 FIXME("(%d, %p, ...): stub\n", nTemplate, hwndParent);
267 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
271 /***********************************************************************
272 * OleUIPromptUserW (OLEDLG.13)
274 INT WINAPIV OleUIPromptUserW(
275 INT nTemplate, HWND hwndParent, ...)
277 FIXME("(%d, %p, ...): stub\n", nTemplate, hwndParent);
278 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
282 /***********************************************************************
283 * OleUIObjectPropertiesA (OLEDLG.11)
285 UINT WINAPI OleUIObjectPropertiesA(
286 LPOLEUIOBJECTPROPSA lpOleUIObjectProps)
288 FIXME("(%p): stub\n", lpOleUIObjectProps);
289 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
293 /***********************************************************************
294 * OleUIObjectPropertiesW (OLEDLG.21)
296 UINT WINAPI OleUIObjectPropertiesW(
297 LPOLEUIOBJECTPROPSW lpOleUIObjectProps)
299 FIXME("(%p): stub\n", lpOleUIObjectProps);
300 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
304 /***********************************************************************
305 * OleUIChangeSourceA (OLEDLG.12)
307 UINT WINAPI OleUIChangeSourceA(
308 LPOLEUICHANGESOURCEA lpOleUIChangeSource)
310 FIXME("(%p): stub\n", lpOleUIChangeSource);
311 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
315 /***********************************************************************
316 * OleUIChangeSourceW (OLEDLG.17)
318 UINT WINAPI OleUIChangeSourceW(
319 LPOLEUICHANGESOURCEW lpOleUIChangeSource)
321 FIXME("(%p): stub\n", lpOleUIChangeSource);
322 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);