Leaked source code of windows server 2003
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.

46 lines
985 B

  1. //
  2. // ats.h
  3. //
  4. // Generic ITfActiveLanguageProfileNotifySink object
  5. //
  6. #ifndef ATS_H
  7. #define ATS_H
  8. #include "private.h"
  9. #define ALS_INVALID_COOKIE ((DWORD)(-1))
  10. typedef HRESULT (*ALSCALLBACK)(REFCLSID clsid, REFGUID guidProfile, BOOL fActivated, void *pv);
  11. class CActiveLanguageProfileNotifySink : public ITfActiveLanguageProfileNotifySink
  12. {
  13. public:
  14. CActiveLanguageProfileNotifySink(ALSCALLBACK pfn, void *pv);
  15. //
  16. // IUnknown methods
  17. //
  18. STDMETHODIMP QueryInterface(REFIID riid, void **ppvObj);
  19. STDMETHODIMP_(ULONG) AddRef(void);
  20. STDMETHODIMP_(ULONG) Release(void);
  21. //
  22. // ITfActiveLanguageProfileNotifySink
  23. //
  24. STDMETHODIMP OnActivated(REFCLSID clsid, REFGUID guidProfile, BOOL bActivated);
  25. HRESULT _Advise(ITfThreadMgr *ptim);
  26. HRESULT _Unadvise();
  27. private:
  28. long _cRef;
  29. ITfThreadMgr *_ptim;
  30. DWORD _dwCookie;
  31. ALSCALLBACK _pfn;
  32. void *_pv;
  33. };
  34. #endif // ATS_H