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.

140 lines
5.1 KiB

  1. #include <olectl.h>
  2. // shimgvw.idl : IDL source for shimgvw.dll
  3. //
  4. // This file will be processed by the MIDL tool to
  5. // produce the type library (shimgvw.tlb) and marshalling code.
  6. import "oaidl.idl";
  7. import "ocidl.idl";
  8. cpp_quote("// These bits define which toolbar buttons to show")
  9. cpp_quote("#define PVTB_TOOLBAR 0x00000001")
  10. cpp_quote("#define PVTB_HIDEFULLSCREEN 0x00000002")
  11. cpp_quote("#define PVTB_HIDEPRINTBTN 0x00000004")
  12. cpp_quote("#define PVTB_CONTEXTMENU 0x00000008")
  13. cpp_quote("#define PVTB_ALLOWONLINE 0x00000010")
  14. cpp_quote("#define PVTB_DISABLEEDIT 0x00000020")
  15. [
  16. uuid(50F16B18-467E-11D1-8271-00C04FC3183B),
  17. version(1.0),
  18. helpstring("Preview 1.0 Type Library")
  19. ]
  20. library PREVIEWLib
  21. {
  22. importlib("stdole2.tlb");
  23. // ====================================================
  24. // Interface definitions
  25. // ====================================================
  26. [
  27. object,
  28. uuid(50F16B25-467E-11D1-8271-00C04FC3183B),
  29. dual,
  30. helpstring("IPreview Interface"),
  31. pointer_default(unique)
  32. ]
  33. interface IPreview : IDispatch
  34. {
  35. [id(1), helpstring("method ShowFile")] HRESULT ShowFile(BSTR bstrFileName, int iSelectCount);
  36. [propget, id(2), helpstring("property printable")] HRESULT printable([out, retval] BOOL *pVal);
  37. [propput, id(2), helpstring("property printable")] HRESULT printable([in] BOOL newVal);
  38. [propget, id(3), helpstring("property cxImage")] HRESULT cxImage([out, retval] long *pVal);
  39. [propget, id(4), helpstring("property cyImage")] HRESULT cyImage([out, retval] long *pVal);
  40. [id(5), helpstring("method Show")] HRESULT Show(VARIANT var);
  41. }
  42. [
  43. object,
  44. uuid(0AE0A2B1-3A34-11D3-9626-00C04F8EEC8C),
  45. dual,
  46. helpstring("IPreview2 Interface"),
  47. pointer_default(unique)
  48. ]
  49. interface IPreview2 : IPreview
  50. {
  51. [helpstring("zoom the image")] HRESULT Zoom([in] int iSelectCount);
  52. [helpstring("fit image to window")] HRESULT BestFit();
  53. [helpstring("show image at actual size")] HRESULT ActualSize();
  54. [helpstring("start a slideshow")] HRESULT SlideShow();
  55. }
  56. [
  57. object,
  58. uuid(497431ad-5481-4df7-ae5d-130d9cd50db3),
  59. helpstring("IPreview3 Interface"),
  60. pointer_default(unique)
  61. ]
  62. interface IPreview3 : IUnknown
  63. {
  64. [helpstring("")] HRESULT ShowFile(BSTR bstrFileName);
  65. [helpstring("")] HRESULT Show(VARIANT var);
  66. [helpstring("")] HRESULT Zoom([in] int iSelectCount);
  67. [helpstring("")] HRESULT BestFit();
  68. [helpstring("")] HRESULT ActualSize();
  69. [helpstring("")] HRESULT SlideShow();
  70. [helpstring("")] HRESULT Rotate([in] DWORD dwAngle);
  71. [helpstring("")] HRESULT SetWallpaper([in] BSTR bstrPath);
  72. [helpstring("")] HRESULT SaveAs([in] BSTR bstrPath);
  73. [propget, helpstring("")] HRESULT cxImage([out, retval] long *pVal);
  74. [propget, helpstring("")] HRESULT cyImage([out, retval] long *pVal);
  75. }
  76. [
  77. object,
  78. uuid(FF36E952-72E9-4EA0-92FB-B63FE5037D78),
  79. helpstring("IImgCmdTarget Interface"),
  80. pointer_default(unique)
  81. ]
  82. interface IImgCmdTarget : IUnknown
  83. {
  84. [helpstring("")] HRESULT GetMode(DWORD * pdw);
  85. [helpstring("")] HRESULT GetPageFlags(DWORD * pdw);
  86. [helpstring("")] HRESULT ZoomIn();
  87. [helpstring("")] HRESULT ZoomOut();
  88. [helpstring("")] HRESULT ActualSize();
  89. [helpstring("")] HRESULT BestFit();
  90. [helpstring("")] HRESULT Rotate([in] DWORD dwAngle);
  91. [helpstring("")] HRESULT NextPage();
  92. [helpstring("")] HRESULT PreviousPage();
  93. }
  94. // ====================================================
  95. // Dispatch Interface definitions
  96. // ====================================================
  97. [
  98. uuid(1B490296-50DF-11d1-8B44-00C04FC3183B),
  99. helpstring("Event interface for ThumbCtl")
  100. ]
  101. dispinterface DPreviewEvents
  102. {
  103. properties:
  104. methods:
  105. [id(1), helpstring("The preview is closing."), helpcontext(0x0000)]
  106. void OnClose();
  107. [id(2), helpstring("The preview image has been generated."), helpcontext(0x0000)]
  108. void OnPreviewReady();
  109. [id(3), helpstring("There was an error generating the preview."), helpcontext(0x0000)]
  110. void OnError();
  111. [id(4), helpstring("User chose Best Fit."), helpcontext(0x0000)]
  112. void OnBestFitPress();
  113. [id(5), helpstring("User chose Actual Size."), helpcontext(0x0000)]
  114. void OnActualSizePress();
  115. }
  116. // ====================================================
  117. // CoClass definitions
  118. // ====================================================
  119. [
  120. uuid(50F16B26-467E-11D1-8271-00C04FC3183B),
  121. helpstring("Preview Class")
  122. ]
  123. coclass Preview
  124. {
  125. [default] interface IPreview2;
  126. [default, source] dispinterface DPreviewEvents;
  127. };
  128. };
  129. cpp_quote("#define SID_SImageView IID_IImgCmdTarget")