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.

68 lines
2.2 KiB

  1. //
  2. // emptyic.h
  3. //
  4. #ifndef EMPTYIC_H
  5. #define EMPTYIC_H
  6. #include "private.h"
  7. #include "globals.h"
  8. #include "compart.h"
  9. class CDocumentInputManager;
  10. class CEmptyInputContext;
  11. CEmptyInputContext *EnsureEmptyContext();
  12. //////////////////////////////////////////////////////////////////////////////
  13. //
  14. // CEmptyInputContext
  15. //
  16. //////////////////////////////////////////////////////////////////////////////
  17. class CEmptyInputContext : public ITfContext,
  18. public CCompartmentMgr,
  19. public CComObjectRootImmx
  20. {
  21. public:
  22. CEmptyInputContext(CDocumentInputManager *dim);
  23. ~CEmptyInputContext();
  24. BEGIN_COM_MAP_IMMX(CEmptyInputContext)
  25. COM_INTERFACE_ENTRY(ITfContext)
  26. COM_INTERFACE_ENTRY(ITfCompartmentMgr)
  27. END_COM_MAP_IMMX()
  28. IMMX_OBJECT_IUNKNOWN_FOR_ATL()
  29. //
  30. // ITfContext
  31. //
  32. STDMETHODIMP RequestEditSession(TfClientId tid, ITfEditSession *pes, DWORD dwFlags, HRESULT *phrSession);
  33. STDMETHODIMP InWriteSession(TfClientId tid, BOOL *pfWriteSession);
  34. STDMETHODIMP GetSelection(TfEditCookie ec, ULONG ulIndex, ULONG ulCount, TF_SELECTION *pSelection, ULONG *pcFetched);
  35. STDMETHODIMP SetSelection(TfEditCookie ec, ULONG ulCount, const TF_SELECTION *pSelection);
  36. STDMETHODIMP GetStart(TfEditCookie ec, ITfRange **ppStart);
  37. STDMETHODIMP GetEnd(TfEditCookie ec, ITfRange **ppEnd);
  38. STDMETHODIMP GetStatus(TS_STATUS *pdcs);
  39. STDMETHODIMP GetActiveView(ITfContextView **ppView);
  40. STDMETHODIMP EnumViews(IEnumTfContextViews **ppEnum);
  41. STDMETHODIMP GetProperty(REFGUID guidProp, ITfProperty **ppv);
  42. STDMETHODIMP GetAppProperty(REFGUID guidProp, ITfReadOnlyProperty **ppProp);
  43. STDMETHODIMP TrackProperties(const GUID **pguidProp, ULONG cProp, const GUID **pguidAppProp, ULONG cAppProp, ITfReadOnlyProperty **ppPropX);
  44. STDMETHODIMP EnumProperties(IEnumTfProperties **ppEnum);
  45. STDMETHODIMP GetDocumentMgr(ITfDocumentMgr **ppDoc);
  46. STDMETHODIMP CreateRangeBackup(TfEditCookie ec, ITfRange *pRange, ITfRangeBackup **ppBackup);
  47. HRESULT Init();
  48. private:
  49. CDocumentInputManager *_dim;
  50. DBG_ID_DECLARE;
  51. };
  52. #endif // EMPTYIC_H