Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

740 lines
27 KiB

  1. //=------------------------------------------------------------------------=
  2. // ObjExt.h
  3. //=------------------------------------------------------------------------=
  4. // Copyright 1995-1997 Microsoft Corporation. All Rights Reserved.
  5. //
  6. // THIS CODE AND INFORMATION IS PROVIDED "AS IS" WITHOUT WARRANTY OF
  7. // ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO
  8. // THE IMPLIED WARRANTIES OF MERCHANTABILITY AND/OR FITNESS FOR A
  9. // PARTICULAR PURPOSE.
  10. //=--------------------------------------------------------------------------=
  11. //
  12. // header file for Object Extensions interfaces
  13. //
  14. #ifndef _OBJEXT_H
  15. #define _OBJEXT_H
  16. #ifndef BEGIN_INTERFACE
  17. #define BEGIN_INTERFACE
  18. #endif
  19. ///////////////////////////////////////////////////////////////////////////
  20. //
  21. // forward declares
  22. //
  23. ///////////////////////////////////////////////////////////////////////////
  24. #ifdef __cplusplus
  25. interface IFilterMembers;
  26. #else // __cplusplus
  27. typedef interface IFilterMembers IFilterMembers;
  28. #endif // __cplusplus
  29. ///////////////////////////////////////////////////////////////////////////
  30. //
  31. // Object Extension Interfaces
  32. //
  33. ///////////////////////////////////////////////////////////////////////////
  34. //-------------------------------------------------------------------------
  35. // IServiceProvider Interface
  36. // This interface is implemented by an object that wish to provide "services"
  37. //
  38. //-------------------------------------------------------------------------
  39. #ifndef __IServiceProvider_INTERFACE_DEFINED
  40. #define __IServiceProvider_INTERFACE_DEFINED
  41. // { 6d5140c1-7436-11ce-8034-00aa006009fa }
  42. DEFINE_GUID(IID_IServiceProvider, 0x6d5140c1, 0x7436, 0x11ce, 0x80, 0x34, 0x00, 0xaa, 0x00, 0x60, 0x09, 0xfa);
  43. #undef INTERFACE
  44. #define INTERFACE IServiceProvider
  45. DECLARE_INTERFACE_(IServiceProvider, IUnknown)
  46. {
  47. BEGIN_INTERFACE
  48. // *** IUnknown methods ***
  49. STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID FAR* ppvObj) PURE;
  50. STDMETHOD_(ULONG, AddRef)(THIS) PURE;
  51. STDMETHOD_(ULONG, Release)(THIS) PURE;
  52. // *** IServiceProvider methods ***
  53. STDMETHOD(QueryService)(THIS_
  54. /* [in] */ REFGUID rsid,
  55. /* [in] */ REFIID iid,
  56. /* [out] */ void ** ppvObj) PURE;
  57. };
  58. #endif // __IServiceProvider_INTERFACE_DEFINED
  59. //-------------------------------------------------------------------------
  60. // IClassDesigner Interface
  61. // This interface is implemented by a class object that can be customized
  62. //
  63. //-------------------------------------------------------------------------
  64. // { 6d5140d3-7436-11ce-8034-00aa006009fa }
  65. DEFINE_GUID(IID_IClassDesigner, 0x6d5140d3, 0x7436, 0x11ce, 0x80, 0x34, 0x00, 0xaa, 0x00, 0x60, 0x09, 0xfa);
  66. typedef DWORD ACTFLAG;
  67. #define ACT_DEFAULT 0x00000000
  68. #define ACT_SHOW 0x00000001
  69. #undef INTERFACE
  70. #define INTERFACE IClassDesigner
  71. DECLARE_INTERFACE_(IClassDesigner, IUnknown)
  72. {
  73. BEGIN_INTERFACE
  74. // *** IUnknown methods ***
  75. STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID FAR* ppvObj) PURE;
  76. STDMETHOD_(ULONG, AddRef)(THIS) PURE;
  77. STDMETHOD_(ULONG, Release)(THIS) PURE;
  78. // *** IClassDesigner methods ***
  79. STDMETHOD(SetSite)(THIS_
  80. /* [in] */ IServiceProvider * pSP) PURE;
  81. STDMETHOD(GetSite)(THIS_
  82. /* [out] */ IServiceProvider** ppSP) PURE;
  83. STDMETHOD(GetCompiler)(THIS_
  84. /* [in] */ REFIID iid,
  85. /* [out] */ void **ppvObj) PURE;
  86. STDMETHOD(ActivateObject)(THIS_ DWORD dwFlags) PURE;
  87. STDMETHOD(IsObjectShowable)(THIS) PURE;
  88. STDMETHOD(GetExtensibilityObject)(THIS_
  89. /* [out] */ IDispatch ** ppDisp) PURE;
  90. };
  91. //-------------------------------------------------------------------------
  92. // IProvideUnmergedClassInfo Interface
  93. // This interface is implemented by an object that is composed of two
  94. // objects. This interface is used to get the typeinfo of the two objects.
  95. //
  96. //-------------------------------------------------------------------------
  97. // { 6d5140da-7436-11ce-8034-00aa006009fa }
  98. DEFINE_GUID(IID_IProvideUnmergedClassInfo, 0x6d5140da, 0x7436, 0x11ce, 0x80, 0x34, 0x00, 0xaa, 0x00, 0x60, 0x09, 0xfa);
  99. #undef INTERFACE
  100. #define INTERFACE IProvideUnmergedClassInfo
  101. DECLARE_INTERFACE_(IProvideUnmergedClassInfo, IUnknown)
  102. {
  103. BEGIN_INTERFACE
  104. // *** IUnknown methods ***
  105. STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID FAR* ppvObj) PURE;
  106. STDMETHOD_(ULONG, AddRef)(THIS) PURE;
  107. STDMETHOD_(ULONG, Release)(THIS) PURE;
  108. // *** IProvideUnmergedClassInfo methods ***
  109. STDMETHOD(GetClassInfos)(THIS_
  110. /* [out] */ ITypeInfo **pptinfoBase,
  111. /* [out] */ ITypeInfo **pptinfoExtender,
  112. /* [out] */ DWORD *pdwCookie) PURE;
  113. };
  114. //UNDONE UNDONE: rip this
  115. // { 6d5140dd-7436-11ce-8034-00aa006009fa }
  116. DEFINE_GUID(IID_IProvideUnmergedClassInfoOLD, 0x6d5140dd, 0x7436, 0x11ce, 0x80, 0x34, 0x00, 0xaa, 0x00, 0x60, 0x09, 0xfa);
  117. #undef INTERFACE
  118. #define INTERFACE IProvideUnmergedClassInfoOLD
  119. DECLARE_INTERFACE_(IProvideUnmergedClassInfoOLD, IUnknown)
  120. {
  121. BEGIN_INTERFACE
  122. // *** IUnknown methods ***
  123. STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID FAR* ppvObj) PURE;
  124. STDMETHOD_(ULONG, AddRef)(THIS) PURE;
  125. STDMETHOD_(ULONG, Release)(THIS) PURE;
  126. // *** IProvideUnmergedClassInfo methods ***
  127. STDMETHOD(GetClassInfos)(THIS_
  128. /* [out] */ ITypeInfo **pptinfoBase,
  129. /* [out] */ ITypeInfo **pptinfoExtender) PURE;
  130. };
  131. //-------------------------------------------------------------------------
  132. // IUnmergedClassFactory Interface
  133. // This interface is implemented by an object that is composed of two
  134. // objects. This interface is used to create instances of the two objects.
  135. //
  136. //-------------------------------------------------------------------------
  137. // { 6d5140d5-7436-11ce-8034-00aa006009fa }
  138. DEFINE_GUID(IID_IUnmergedClassFactory, 0x6d5140d5, 0x7436, 0x11ce, 0x80, 0x34, 0x00, 0xaa, 0x00, 0x60, 0x09, 0xfa);
  139. #undef INTERFACE
  140. #define INTERFACE IUnmergedClassFactory
  141. DECLARE_INTERFACE_(IUnmergedClassFactory, IUnknown)
  142. {
  143. BEGIN_INTERFACE
  144. // *** IUnknown methods ***
  145. STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID FAR* ppvObj) PURE;
  146. STDMETHOD_(ULONG, AddRef)(THIS) PURE;
  147. STDMETHOD_(ULONG, Release)(THIS) PURE;
  148. // *** IUnmergedClassFactory methods ***
  149. STDMETHOD(CreateInstance)(THIS_
  150. /* [in] */ IUnknown *punkOuter,
  151. /* [out] */ IUnknown **ppunkBase,
  152. /* [out] */ IUnknown **ppunkExtender) PURE;
  153. };
  154. ///////////////////////////////////////////////////////////////////////////
  155. //
  156. // Standard Services and Interfaces
  157. //
  158. ///////////////////////////////////////////////////////////////////////////
  159. //-------------------------------------------------------------------------
  160. // SLicensedClassManager
  161. // VBA provides this service to it's components and hosts to optimize
  162. // registry access and to insulate them from licensing concerns
  163. //
  164. // interfaces implemented:
  165. // ILicensedClassManager
  166. //-------------------------------------------------------------------------
  167. // { 6d5140d0-7436-11ce-8034-00aa006009fa }
  168. DEFINE_GUID(IID_IRequireClasses, 0x6d5140d0, 0x7436, 0x11ce, 0x80, 0x34, 0x00, 0xaa, 0x00, 0x60, 0x09, 0xfa);
  169. #undef INTERFACE
  170. #define INTERFACE IRequireClasses
  171. DECLARE_INTERFACE_(IRequireClasses, IUnknown)
  172. {
  173. BEGIN_INTERFACE
  174. // *** IUnknown methods ***
  175. STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID FAR* ppvObj) PURE;
  176. STDMETHOD_(ULONG, AddRef)(THIS) PURE;
  177. STDMETHOD_(ULONG, Release)(THIS) PURE;
  178. // *** IRequireClasses methods ***
  179. STDMETHOD(CountRequiredClasses)(THIS_
  180. /* [out] */ ULONG * pcClasses ) PURE;
  181. STDMETHOD(GetRequiredClasses)(THIS_
  182. /* [in] */ ULONG index,
  183. /* [out] */ CLSID * pclsid ) PURE;
  184. };
  185. // { 6d5140d4-7436-11ce-8034-00aa006009fa }
  186. DEFINE_GUID(IID_ILicensedClassManager, 0x6d5140d4, 0x7436, 0x11ce, 0x80, 0x34, 0x00, 0xaa, 0x00, 0x60, 0x09, 0xfa);
  187. #define SID_SLicensedClassManager IID_ILicensedClassManager
  188. #undef INTERFACE
  189. #define INTERFACE ILicensedClassManager
  190. DECLARE_INTERFACE_(ILicensedClassManager, IUnknown)
  191. {
  192. BEGIN_INTERFACE
  193. // *** IUnknown methods ***
  194. STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID FAR* ppvObj) PURE;
  195. STDMETHOD_(ULONG, AddRef)(THIS) PURE;
  196. STDMETHOD_(ULONG, Release)(THIS) PURE;
  197. // *** ILicensedClassManager methods ***
  198. STDMETHOD(OnChangeInRequiredClasses)(THIS_
  199. /* [in] */ IRequireClasses *pRequireClasses) PURE;
  200. };
  201. //-------------------------------------------------------------------------
  202. // IFilterMembers
  203. // This interface is used during processing of typeinfos
  204. //-------------------------------------------------------------------------
  205. // MX ON
  206. #if 0
  207. // MX OFF
  208. // {49F21D20-1870-11cf-80E8-00AA004BA1C8}
  209. DEFINE_GUID(IID_IFilterMembers,0x49f21d20L, 0x1870, 0x11cf, 0x80, 0xe8, 0x00, 0xaa, 0x00, 0x4b, 0xa1, 0xc8);
  210. // used in IFilterMembers indicating the passed in ptinfo is a source or not
  211. #define FILTERMEMBERS_FSOURCE 0x0001
  212. // used in IFilterMembers indicating the passed in ptinfo is an extender or not
  213. #define FILTERMEMBERS_FEXTENDER 0x0002
  214. #undef INTERFACE
  215. #define INTERFACE IFilterMembers
  216. DECLARE_INTERFACE(IFilterMembers)
  217. {
  218. BEGIN_INTERFACE
  219. // IUnknown methods
  220. STDMETHOD(QueryInterface)(THIS_ REFIID riid, void FAR* FAR* ppv) PURE;
  221. STDMETHOD_(ULONG, AddRef)(THIS) PURE;
  222. STDMETHOD_(ULONG, Release)(THIS) PURE;
  223. // IVbaProvideStorage methods
  224. STDMETHOD(FilterVarDesc)(THIS_ DWORD dwFlags,
  225. ITypeInfo *ptinfo,
  226. UINT index,
  227. VARDESC *pvardesc,
  228. DWORD dwReserved) PURE;
  229. STDMETHOD(FilterFuncDesc)(THIS_ DWORD dwFlags,
  230. ITypeInfo *ptinfo,
  231. UINT index,
  232. FUNCDESC *pfuncdesc,
  233. DWORD dwReserved) PURE;
  234. STDMETHOD(BeginMerge)(THIS_ DWORD dwFlags,
  235. ITypeInfo *ptinfo) PURE;
  236. STDMETHOD(EndMerge)(THIS) PURE;
  237. STDMETHOD(UpdateMergedCoClass)(THIS_ ICreateTypeInfo *pictinfo) PURE;
  238. };
  239. // MX ON
  240. #endif
  241. // MX OFF
  242. //-------------------------------------------------------------------------
  243. // SCreateExtendedTypeLib Service
  244. // This service is used by components to create a typelib
  245. // describing controls merged with their extender
  246. //
  247. // interfaces implemented:
  248. // ICreateExtendedTypeLib
  249. //-------------------------------------------------------------------------
  250. // { 6d5140d6-7436-11ce-8034-00aa006009fa }
  251. DEFINE_GUID(IID_IExtendedTypeLib, 0x6d5140d6, 0x7436, 0x11ce, 0x80, 0x34, 0x00, 0xaa, 0x00, 0x60, 0x09, 0xfa);
  252. #define SID_SExtendedTypeLib IID_IExtendedTypeLib
  253. #undef INTERFACE
  254. #define INTERFACE IExtendedTypeLib
  255. DECLARE_INTERFACE_(IExtendedTypeLib, IUnknown)
  256. {
  257. BEGIN_INTERFACE
  258. // *** IUnknown methods ***
  259. STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID FAR* ppvObj) PURE;
  260. STDMETHOD_(ULONG, AddRef)(THIS) PURE;
  261. STDMETHOD_(ULONG, Release)(THIS) PURE;
  262. // *** IExtendedTypeLib ***
  263. STDMETHOD(CreateExtendedTypeLib)(THIS_
  264. /* [in] */ LPCOLESTR lpstrCtrlLibFileName,
  265. /* [in] */ LPCOLESTR lpstrLibNamePrepend,
  266. /* [in] */ ITypeInfo *ptinfoExtender,
  267. /* [in] */ IFilterMembers *pfilter,
  268. /* [in] */ DWORD dwFlags,
  269. /* [in] */ LPCOLESTR lpstrDirectoryName,
  270. /* [out] */ ITypeLib **pptlib) PURE;
  271. STDMETHOD(AddRefExtendedTypeLib)(THIS_
  272. /* [in] */ LPCOLESTR lpstrCtrlLibFileName,
  273. /* [in] */ LPCOLESTR lpstrLibNamePrepend,
  274. /* [in] */ ITypeInfo *ptinfoExtender,
  275. /* [in] */ IFilterMembers *pfilter,
  276. /* [in] */ DWORD dwFlags,
  277. /* [in] */ LPCOLESTR lpstrDirectoryName,
  278. /* [out] */ ITypeLib **pptlib) PURE;
  279. STDMETHOD(AddRefExtendedTypeLibOfClsid)(THIS_
  280. /* [in] */ REFCLSID rclsidControl,
  281. /* [in] */ LPCOLESTR lpstrLibNamePrepend,
  282. /* [in] */ ITypeInfo *ptinfoExtender,
  283. /* [in] */ IFilterMembers *pfilter,
  284. /* [in] */ DWORD dwFlags,
  285. /* [in] */ LPCOLESTR lpstrDirectoryName,
  286. /* [out] */ ITypeInfo **pptinfo) PURE;
  287. STDMETHOD(SetExtenderInfo)(THIS_
  288. /* [in] */ LPCOLESTR lpstrDirectoryName,
  289. /* [in] */ ITypeInfo *ptinfoExtender,
  290. /* [in] */ IFilterMembers *pfilter) PURE;
  291. };
  292. //-------------------------------------------------------------------------
  293. // SCreateExtension Service
  294. // This service is used by Instance customized objects to
  295. // create the VBA extension
  296. //
  297. // interfaces implemented:
  298. // ICreateExtension
  299. //-------------------------------------------------------------------------
  300. // { 6d5140d2-7436-11ce-8034-00aa006009fa }
  301. DEFINE_GUID(IID_ICreateExtension, 0x6d5140d2, 0x7436, 0x11ce, 0x80, 0x34, 0x00, 0xaa, 0x00, 0x60, 0x09, 0xfa);
  302. #define SID_SCreateExtension IID_ICreateExtension
  303. #undef INTERFACE
  304. #define INTERFACE ICreateExtension
  305. DECLARE_INTERFACE_(ICreateExtension, IUnknown)
  306. {
  307. BEGIN_INTERFACE
  308. // *** IUnknown methods ***
  309. STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID FAR* ppvObj) PURE;
  310. STDMETHOD_(ULONG, AddRef)(THIS) PURE;
  311. STDMETHOD_(ULONG, Release)(THIS) PURE;
  312. // *** ICreateExtension methods ***
  313. STDMETHOD(CreateExtension)(THIS_
  314. /* [in] */ IUnknown *punkOuter,
  315. /* [in] */ IUnknown *punkBase,
  316. /* [in] */ IUnknown *punkExtender,
  317. /* [out] */ IUnknown **ppunkExtension) PURE;
  318. };
  319. //-------------------------------------------------------------------------
  320. // SCodeNavigate Service.
  321. // This service let's an extended object show the code module
  322. // behind it.
  323. //
  324. // interfaces implemented:
  325. // ICodeNavigate
  326. //-------------------------------------------------------------------------
  327. // { 6d5140c4-7436-11ce-8034-00aa006009fa }
  328. DEFINE_GUID(IID_ICodeNavigate, 0x6d5140c4, 0x7436, 0x11ce, 0x80, 0x34, 0x00, 0xaa, 0x00, 0x60, 0x09, 0xfa);
  329. #define SID_SCodeNavigate IID_ICodeNavigate
  330. #undef INTERFACE
  331. #define INTERFACE ICodeNavigate
  332. DECLARE_INTERFACE_(ICodeNavigate, IUnknown)
  333. {
  334. BEGIN_INTERFACE
  335. // *** IUnknown methods ***
  336. STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID FAR* ppvObj) PURE;
  337. STDMETHOD_(ULONG, AddRef)(THIS) PURE;
  338. STDMETHOD_(ULONG, Release)(THIS) PURE;
  339. // *** ICodeNavigate methods ***
  340. STDMETHOD(DisplayDefaultEventHandler)(THIS_ /* [in] */ LPCOLESTR lpstrObjectName) PURE;
  341. };
  342. //-------------------------------------------------------------------------
  343. // STrackSelection Service
  344. // This service is used by the VBA host to help VBA track the
  345. // currently selected object in the host
  346. //
  347. // interfaces implemented:
  348. // ITrackSelection
  349. //-------------------------------------------------------------------------
  350. #define GETOBJS_ALL 1
  351. #define GETOBJS_SELECTED 2
  352. #define SELOBJS_ACTIVATE_WINDOW 1
  353. // { 6d5140c6-7436-11ce-8034-00aa006009fa }
  354. DEFINE_GUID(IID_ISelectionContainer, 0x6d5140c6, 0x7436, 0x11ce, 0x80, 0x34, 0x00, 0xaa, 0x00, 0x60, 0x09, 0xfa);
  355. #undef INTERFACE
  356. #define INTERFACE ISelectionContainer
  357. DECLARE_INTERFACE_(ISelectionContainer, IUnknown)
  358. {
  359. BEGIN_INTERFACE
  360. // *** IUnknown methods ***
  361. STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID FAR* ppvObj) PURE;
  362. STDMETHOD_(ULONG, AddRef)(THIS) PURE;
  363. STDMETHOD_(ULONG, Release)(THIS) PURE;
  364. // *** ISelectionContainer methods ***
  365. STDMETHOD(CountObjects)(THIS_
  366. /* [in] */ DWORD dwFlags,
  367. /* [out] */ ULONG * pc) PURE;
  368. STDMETHOD(GetObjects)(THIS_
  369. /* [in] */ DWORD dwFlags,
  370. /* [in] */ ULONG cObjects,
  371. /* [out] */ IUnknown **apUnkObjects) PURE;
  372. STDMETHOD(SelectObjects)(THIS_
  373. /* [in] */ ULONG cSelect,
  374. /* [in] */ IUnknown **apUnkSelect,
  375. /* [in] */ DWORD dwFlags) PURE;
  376. };
  377. // { 6d5140c5-7436-11ce-8034-00aa006009fa }
  378. DEFINE_GUID(IID_ITrackSelection, 0x6d5140c5, 0x7436, 0x11ce, 0x80, 0x34, 0x00, 0xaa, 0x00, 0x60, 0x09, 0xfa);
  379. #define SID_STrackSelection IID_ITrackSelection
  380. #undef INTERFACE
  381. #define INTERFACE ITrackSelection
  382. DECLARE_INTERFACE_(ITrackSelection, IUnknown)
  383. {
  384. BEGIN_INTERFACE
  385. // *** IUnknown methods ***
  386. STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID FAR* ppvObj) PURE;
  387. STDMETHOD_(ULONG, AddRef)(THIS) PURE;
  388. STDMETHOD_(ULONG, Release)(THIS) PURE;
  389. // *** ITrackSelection methods ***
  390. STDMETHOD(OnSelectChange)(THIS_
  391. /* [in] */ ISelectionContainer * pSC) PURE;
  392. };
  393. //-------------------------------------------------------------------------
  394. // SLocalRegistry Service
  395. // VBA provides this service to it's components and hosts to optimize
  396. // registry access and to insulate them from licensing concerns
  397. //
  398. // interfaces implemented:
  399. // ILocalRegistry
  400. //-------------------------------------------------------------------------
  401. // { 6d5140d3-7436-11ce-8034-00aa006009fa }
  402. DEFINE_GUID(IID_ILocalRegistry, 0x6d5140d3, 0x7436, 0x11ce, 0x80, 0x34, 0x00, 0xaa, 0x00, 0x60, 0x09, 0xfa);
  403. #define SID_SLocalRegistry IID_ILocalRegistry
  404. #undef INTERFACE
  405. #define INTERFACE ILocalRegistry
  406. DECLARE_INTERFACE_(ILocalRegistry, IUnknown)
  407. {
  408. BEGIN_INTERFACE
  409. // *** IUnknown methods ***
  410. STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID FAR* ppvObj) PURE;
  411. STDMETHOD_(ULONG, AddRef)(THIS) PURE;
  412. STDMETHOD_(ULONG, Release)(THIS) PURE;
  413. // *** ILocalRegistry methods ***
  414. STDMETHOD(CreateInstance)(THIS_
  415. /* [in] */ CLSID clsid,
  416. /* [in] */ IUnknown * punkOuter,
  417. /* [in] */ REFIID riid,
  418. /* [in] */ DWORD dwFlags,
  419. /* [out] */ void ** ppvObj ) PURE;
  420. STDMETHOD(GetTypeLibOfClsid)(THIS_
  421. /* [in] */ CLSID clsid,
  422. /* [out] */ ITypeLib ** ptlib ) PURE;
  423. STDMETHOD(GetClassObjectOfClsid)(THIS_
  424. /* [in] */ REFCLSID clsid,
  425. /* [in] */ DWORD dwClsCtx,
  426. /* [in] */ LPVOID lpReserved,
  427. /* [in] */ REFIID riid,
  428. /* [out] */ void ** ppcClassObject ) PURE;
  429. };
  430. //-------------------------------------------------------------------------
  431. // IUIElement interface
  432. // components can implement services to allow external control of pieces
  433. // of their UI by implementing this interface
  434. //
  435. //-------------------------------------------------------------------------
  436. // { 759d0500-d979-11ce-84ec-00aa00614f3e }
  437. DEFINE_GUID(IID_IUIElement, 0x759d0500, 0xd979, 0x11ce, 0x84, 0xec, 0x00, 0xaa, 0x00, 0x61, 0x4f, 0x3e);
  438. #undef INTERFACE
  439. #define INTERFACE IUIElement
  440. DECLARE_INTERFACE_(IUIElement, IUnknown)
  441. {
  442. BEGIN_INTERFACE
  443. // *** IUnknown methods ****
  444. STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID FAR* ppvObj) PURE;
  445. STDMETHOD_(ULONG, AddRef)(THIS) PURE;
  446. STDMETHOD_(ULONG, Release)(THIS) PURE;
  447. // *** IUIElement methods ****
  448. STDMETHOD(Show)(THIS) PURE;
  449. STDMETHOD(Hide)(THIS) PURE;
  450. STDMETHOD(IsVisible)(THIS) PURE;
  451. };
  452. //-------------------------------------------------------------------------
  453. // SProfferService Service
  454. // VBA provides this service to it's components and hosts to allow
  455. // them to dynamically provide services.
  456. //
  457. // interfaces implemented:
  458. // IProfferService
  459. //-------------------------------------------------------------------------
  460. // {CB728B20-F786-11ce-92AD-00AA00A74CD0}
  461. DEFINE_GUID(IID_IProfferService, 0xcb728b20, 0xf786, 0x11ce, 0x92, 0xad, 0x0, 0xaa, 0x0, 0xa7, 0x4c, 0xd0);
  462. #define SID_SProfferService IID_IProfferService
  463. #undef INTERFACE
  464. #define INTERFACE IProfferService
  465. DECLARE_INTERFACE_(IProfferService, IUnknown)
  466. {
  467. BEGIN_INTERFACE
  468. // *** IUnknown methods ***
  469. STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID FAR* ppvObj) PURE;
  470. STDMETHOD_(ULONG, AddRef)(THIS) PURE;
  471. STDMETHOD_(ULONG, Release)(THIS) PURE;
  472. // *** IProfferService methods ***
  473. STDMETHOD(ProfferService)(THIS_
  474. /* [in] */ REFGUID rguidService,
  475. /* [in] */ IServiceProvider * psp,
  476. /* [out] */ DWORD *pdwCookie) PURE;
  477. STDMETHOD(RevokeService)(THIS_ /* [in] */ DWORD dwCookie) PURE;
  478. };
  479. //-------------------------------------------------------------------------
  480. // SProfferTypelib Service
  481. // VBA provides this service to it's components and hosts to allow
  482. // them to add typelibs to the project
  483. //
  484. // interfaces implemented:
  485. // IProfferTypelib
  486. //-------------------------------------------------------------------------
  487. // { 718cc500-0a76-11cf-8045-00aa006009fa }
  488. DEFINE_GUID(IID_IProfferTypeLib, 0x718cc500, 0x0A76, 0x11cf, 0x80, 0x45, 0x00, 0xaa, 0x00, 0x60, 0x09, 0xfa);
  489. #define SID_SProfferTypeLib IID_IProfferTypeLib
  490. #define CONTROLTYPELIB (0x00000001)
  491. #undef INTERFACE
  492. #define INTERFACE IProfferTypeLib
  493. DECLARE_INTERFACE_(IProfferTypeLib, IUnknown)
  494. {
  495. BEGIN_INTERFACE
  496. // *** IUnknown methods ***
  497. STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID FAR* ppvObj) PURE;
  498. STDMETHOD_(ULONG, AddRef)(THIS) PURE;
  499. STDMETHOD_(ULONG, Release)(THIS) PURE;
  500. // *** IProfferTypelib methods ***
  501. STDMETHOD(ProfferTypeLib)(THIS_
  502. /* [in] */ REFGUID guidTypeLib,
  503. /* [in] */ UINT uVerMaj,
  504. /* [in] */ UINT uVerMin,
  505. /* [in] */ DWORD dwFlags) PURE;
  506. };
  507. // UNDONE UNDONE UNDONE UNDONE UNDONE UNDONE UNDONE UNDONE UNDONE UNDONE UNDONE UNDONE UNDONE UNDONE UNDONE
  508. // These interfaces need to be moved to the new olectl.h
  509. //
  510. // UNDONE UNDONE UNDONE UNDONE UNDONE UNDONE UNDONE UNDONE UNDONE UNDONE UNDONE UNDONE UNDONE UNDONE UNDONE
  511. // { 6d5140c0-7436-11ce-8034-00aa006009fa }
  512. DEFINE_GUID(IID_IGangConnectWithDefault, 0x6d5140c0, 0x7436, 0x11ce, 0x80, 0x34, 0x00, 0xaa, 0x00, 0x60, 0x09, 0xfa);
  513. #undef INTERFACE
  514. #define INTERFACE IGangConnectWithDefault
  515. DECLARE_INTERFACE_(IGangConnectWithDefault, IUnknown)
  516. {
  517. BEGIN_INTERFACE
  518. // *** IUnknown methods ***
  519. STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID FAR* ppvObj) PURE;
  520. STDMETHOD_(ULONG, AddRef)(THIS) PURE;
  521. STDMETHOD_(ULONG, Release)(THIS) PURE;
  522. // *** IGangConnectWithDefault ***
  523. STDMETHOD(AdviseWithDefault)(THIS_
  524. ULONG cSinks,
  525. DISPID * adispid,
  526. IUnknown ** apUnkSink,
  527. IUnknown ** apUnkDefaultBO) PURE;
  528. };
  529. // { 6d5140d1-7436-11ce-8034-00aa006009fa }
  530. DEFINE_GUID(IID_IProvideDynamicClassInfo, 0x6d5140d1, 0x7436, 0x11ce, 0x80, 0x34, 0x00, 0xaa, 0x00, 0x60, 0x09, 0xfa);
  531. #undef INTERFACE
  532. #define INTERFACE IProvideDynamicClassInfo
  533. DECLARE_INTERFACE_(IProvideDynamicClassInfo, IProvideClassInfo)
  534. {
  535. BEGIN_INTERFACE
  536. // *** IUnknown methods ***
  537. STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID FAR* ppvObj) PURE;
  538. STDMETHOD_(ULONG, AddRef)(THIS) PURE;
  539. STDMETHOD_(ULONG, Release)(THIS) PURE;
  540. // *** IProvideDynamicClassInfo ***
  541. STDMETHOD(GetDynamicClassInfo_RIP)(THIS_ ITypeInfo ** ppTI) PURE;
  542. STDMETHOD(GetDynamicClassInfo)(THIS_ ITypeInfo ** ppTI, DWORD * pdwCookie) PURE;
  543. STDMETHOD(FreezeShape)(void) PURE;
  544. };
  545. // {4D07FC10-F931-11ce-B001-00AA006884E5}
  546. DEFINE_GUID(IID_ICategorizeProperties, 0x4d07fc10, 0xf931, 0x11ce, 0xb0, 0x1, 0x0, 0xaa, 0x0, 0x68, 0x84, 0xe5);
  547. // NOTE : CATID should no longer be used. Use PROPCAT instead.
  548. // UNDONE,erikc,1/22/96 : remove #ifdef when all components have updated to new typedef.
  549. #ifdef OBJEXT_OLD_CATID
  550. typedef int CATID;
  551. #else
  552. typedef int PROPCAT;
  553. #endif
  554. #undef INTERFACE
  555. #define INTERFACE ICategorizeProperties
  556. DECLARE_INTERFACE_(ICategorizeProperties, IUnknown)
  557. {
  558. BEGIN_INTERFACE
  559. // *** IUnknown methods ***
  560. STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID FAR* ppvObj) PURE;
  561. STDMETHOD_(ULONG, AddRef)(THIS) PURE;
  562. STDMETHOD_(ULONG, Release)(THIS) PURE;
  563. // *** ICategorizeProperties ***
  564. STDMETHOD(MapPropertyToCategory)(THIS_
  565. /* [in] */ DISPID dispid,
  566. /* [out] */ PROPCAT* ppropcat) PURE;
  567. STDMETHOD(GetCategoryName)(THIS_
  568. /* [in] */ PROPCAT propcat,
  569. /* [in] */ LCID lcid,
  570. /* [out] */ BSTR* pbstrName) PURE;
  571. };
  572. typedef ICategorizeProperties FAR* LPCATEGORIZEPROPERTIES;
  573. // category ID: negative values are 'standard' categories, positive are control-specific
  574. // Note! This is a temporary list!
  575. #ifdef OBJEXT_OLD_CATID
  576. // NOTE : The following #defines should no longer be used. Use PROPCAT_ instead.
  577. // UNDONE,erikc,1/22/96 : remove #ifdef when all components have updated to new #defines.
  578. #define CI_Nil -1
  579. #define CI_Misc -2
  580. #define CI_Font -3
  581. #define CI_Position -4
  582. #define CI_Appearance -5
  583. #define CI_Behavior -6
  584. #define CI_Data -7
  585. #define CI_List -8
  586. #define CI_Text -9
  587. #define CI_Scale -10
  588. #define CI_DDE -11
  589. #else
  590. #define PROPCAT_Nil -1
  591. #define PROPCAT_Misc -2
  592. #define PROPCAT_Font -3
  593. #define PROPCAT_Position -4
  594. #define PROPCAT_Appearance -5
  595. #define PROPCAT_Behavior -6
  596. #define PROPCAT_Data -7
  597. #define PROPCAT_List -8
  598. #define PROPCAT_Text -9
  599. #define PROPCAT_Scale -10
  600. #define PROPCAT_DDE -11
  601. #endif
  602. //
  603. // Extra interfaces (chrisz)
  604. //
  605. //+-------------------------------------------------------------------------
  606. //
  607. // Help service. (robbear)
  608. //
  609. //--------------------------------------------------------------------------
  610. #define HELPINFO_WHATS_THIS_MODE_ON 1
  611. // { 6d5140c7-7436-11ce-8034-00aa006009fa }
  612. DEFINE_GUID(SID_SHelp, 0x6d5140c7, 0x7436, 0x11ce, 0x80, 0x34, 0x00, 0xaa, 0x00, 0x60, 0x09, 0xfa);
  613. // { 6d5140c8-7436-11ce-8034-00aa006009fa }
  614. DEFINE_GUID(IID_IHelp, 0x6d5140c8, 0x7436, 0x11ce, 0x80, 0x34, 0x00, 0xaa, 0x00, 0x60, 0x09, 0xfa);
  615. #undef INTERFACE
  616. #define INTERFACE IHelp
  617. DECLARE_INTERFACE_(IHelp, IUnknown)
  618. {
  619. BEGIN_INTERFACE
  620. // *** IUnknown methods ***
  621. STDMETHOD(QueryInterface)(THIS_ REFIID riid, LPVOID FAR* ppvObj) PURE;
  622. STDMETHOD_(ULONG, AddRef)(THIS) PURE;
  623. STDMETHOD_(ULONG, Release)(THIS) PURE;
  624. // *** IHelp methods ***
  625. STDMETHOD(GetHelpFile) (THIS_ BSTR * pbstr) PURE;
  626. STDMETHOD(GetHelpInfo) (THIS_ DWORD * pdwHelpInfo) PURE;
  627. STDMETHOD(ShowHelp) (THIS_
  628. LPOLESTR szHelp,
  629. UINT fuCommand,
  630. DWORD dwHelpContext) PURE;
  631. };
  632. //-------------------------------------------------------------------------
  633. // SApplicationObject Service
  634. // Host applications proffer their application object as this service.
  635. // Various objects implement the "Application" property by returning
  636. // this service.
  637. //
  638. //-------------------------------------------------------------------------
  639. // { 0c539790-12e4-11cf-b661-00aa004cd6d8 }
  640. DEFINE_GUID(SID_SApplicationObject, 0x0c539790, 0x12e4, 0x11cf, 0xb6, 0x61, 0x00, 0xaa, 0x00, 0x4c, 0xd6, 0xd8);
  641. #endif // _OBJEXT_H