IDocHostUIHandler.cs 3.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. using System;
  2. using System.Runtime.InteropServices;
  3. using System.Runtime.InteropServices.ComTypes;
  4. namespace LYFZ.OtherExpansion.Win32.Com
  5. {
  6. [ComVisible(true), Guid("bd3f23c0-d43e-11cf-893b-00aa00bdce1a"), InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
  7. [ComImport]
  8. public interface IDocHostUIHandler
  9. {
  10. [PreserveSig]
  11. [return: MarshalAs(UnmanagedType.I4)]
  12. int ShowContextMenu([MarshalAs(UnmanagedType.U4)] [In] uint dwID, [MarshalAs(UnmanagedType.Struct)] [In] ref tagPOINT pt, [MarshalAs(UnmanagedType.IUnknown)] [In] object pcmdtReserved, [MarshalAs(UnmanagedType.IDispatch)] [In] object pdispReserved);
  13. [PreserveSig]
  14. [return: MarshalAs(UnmanagedType.I4)]
  15. int GetHostInfo([MarshalAs(UnmanagedType.Struct)] [In] [Out] ref DOCHOSTUIINFO info);
  16. [PreserveSig]
  17. [return: MarshalAs(UnmanagedType.I4)]
  18. int ShowUI([MarshalAs(UnmanagedType.I4)] [In] int dwID, [MarshalAs(UnmanagedType.Interface)] [In] IOleInPlaceActiveObject activeObject, [MarshalAs(UnmanagedType.Interface)] [In] IOleCommandTarget commandTarget, [MarshalAs(UnmanagedType.Interface)] [In] IOleInPlaceFrame frame, [MarshalAs(UnmanagedType.Interface)] [In] IOleInPlaceUIWindow doc);
  19. [PreserveSig]
  20. [return: MarshalAs(UnmanagedType.I4)]
  21. int HideUI();
  22. [PreserveSig]
  23. [return: MarshalAs(UnmanagedType.I4)]
  24. int UpdateUI();
  25. [PreserveSig]
  26. [return: MarshalAs(UnmanagedType.I4)]
  27. int EnableModeless([MarshalAs(UnmanagedType.Bool)] [In] bool fEnable);
  28. [PreserveSig]
  29. [return: MarshalAs(UnmanagedType.I4)]
  30. int OnDocWindowActivate([MarshalAs(UnmanagedType.Bool)] [In] bool fActivate);
  31. [PreserveSig]
  32. [return: MarshalAs(UnmanagedType.I4)]
  33. int OnFrameWindowActivate([MarshalAs(UnmanagedType.Bool)] [In] bool fActivate);
  34. [PreserveSig]
  35. [return: MarshalAs(UnmanagedType.I4)]
  36. int ResizeBorder([MarshalAs(UnmanagedType.Struct)] [In] ref tagRECT rect, [MarshalAs(UnmanagedType.Interface)] [In] IOleInPlaceUIWindow doc, [MarshalAs(UnmanagedType.Bool)] [In] bool fFrameWindow);
  37. [PreserveSig]
  38. [return: MarshalAs(UnmanagedType.I4)]
  39. int TranslateAccelerator([MarshalAs(UnmanagedType.Struct)] [In] ref tagMSG msg, [In] ref Guid group, [MarshalAs(UnmanagedType.U4)] [In] uint nCmdID);
  40. [PreserveSig]
  41. [return: MarshalAs(UnmanagedType.I4)]
  42. int GetOptionKeyPath([MarshalAs(UnmanagedType.LPWStr)] out string pbstrKey, [MarshalAs(UnmanagedType.U4)] [In] uint dw);
  43. [PreserveSig]
  44. [return: MarshalAs(UnmanagedType.I4)]
  45. int GetDropTarget([MarshalAs(UnmanagedType.Interface)] [In] IDropTarget pDropTarget, [MarshalAs(UnmanagedType.Interface)] out IDropTarget ppDropTarget);
  46. [PreserveSig]
  47. [return: MarshalAs(UnmanagedType.I4)]
  48. int GetExternal([MarshalAs(UnmanagedType.IDispatch)] out object ppDispatch);
  49. [PreserveSig]
  50. [return: MarshalAs(UnmanagedType.I4)]
  51. int TranslateUrl([MarshalAs(UnmanagedType.U4)] [In] uint dwTranslate, [MarshalAs(UnmanagedType.LPWStr)] [In] string strURLIn, [MarshalAs(UnmanagedType.LPWStr)] out string pstrURLOut);
  52. [PreserveSig]
  53. [return: MarshalAs(UnmanagedType.I4)]
  54. int FilterDataObject([MarshalAs(UnmanagedType.Interface)] [In] IDataObject pDO, [MarshalAs(UnmanagedType.Interface)] out IDataObject ppDORet);
  55. }
  56. }