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.

44 lines
1.3 KiB

  1. #ifndef __DSPSPRT_H__
  2. #define __DSPSPRT_H__
  3. // get ITypeInfo uuid/lcid out of type library
  4. STDAPI GetTypeInfoFromLibId(LCID lcid, REFGUID libid,
  5. USHORT wVerMajor, USHORT wVerMinor,
  6. REFGUID uuid, ITypeInfo **ppITypeInfo);
  7. //
  8. // Helper C++ class used to share code for the IDispatch implementations
  9. //
  10. // Inherit from this class passing this IDispatch's IID to the ctor
  11. //
  12. class CImpIDispatch
  13. {
  14. public:
  15. // We need access to the virtual QI -- define it PURE here
  16. virtual STDMETHODIMP QueryInterface(REFIID riid, LPVOID * ppvObj) PURE;
  17. protected:
  18. CImpIDispatch(REFGUID libid, USHORT wVerMajor, USHORT wVerMinor, REFIID riid);
  19. virtual ~CImpIDispatch(void);
  20. // For raising exceptions
  21. void Exception(WORD);
  22. // IDispatch members
  23. STDMETHODIMP GetTypeInfoCount(UINT *);
  24. STDMETHODIMP GetTypeInfo(UINT, LCID, ITypeInfo **);
  25. STDMETHODIMP GetIDsOfNames(REFIID, OLECHAR **, UINT, LCID, DISPID *);
  26. STDMETHODIMP Invoke(DISPID, REFIID, LCID, WORD, DISPPARAMS *, VARIANT *, EXCEPINFO *, UINT *);
  27. private:
  28. REFIID m_riid;
  29. REFGUID m_libid;
  30. USHORT m_wVerMajor;
  31. USHORT m_wVerMinor;
  32. ITypeInfo *m_pITINeutral; // Cached Type information
  33. };
  34. #endif // __DSPSPRT_H__