141 lines
5.0 KiB
Plaintext
141 lines
5.0 KiB
Plaintext
|
#include <olectl.h>
|
||
|
// shimgvw.idl : IDL source for shimgvw.dll
|
||
|
//
|
||
|
|
||
|
// This file will be processed by the MIDL tool to
|
||
|
// produce the type library (shimgvw.tlb) and marshalling code.
|
||
|
|
||
|
import "oaidl.idl";
|
||
|
import "ocidl.idl";
|
||
|
|
||
|
cpp_quote("// These bits define which toolbar buttons to show")
|
||
|
cpp_quote("#define PVTB_TOOLBAR 0x00000001")
|
||
|
cpp_quote("#define PVTB_HIDEFULLSCREEN 0x00000002")
|
||
|
cpp_quote("#define PVTB_HIDEPRINTBTN 0x00000004")
|
||
|
cpp_quote("#define PVTB_CONTEXTMENU 0x00000008")
|
||
|
cpp_quote("#define PVTB_ALLOWONLINE 0x00000010")
|
||
|
cpp_quote("#define PVTB_DISABLEEDIT 0x00000020")
|
||
|
|
||
|
[
|
||
|
uuid(50F16B18-467E-11D1-8271-00C04FC3183B),
|
||
|
version(1.0),
|
||
|
helpstring("Preview 1.0 Type Library")
|
||
|
]
|
||
|
library PREVIEWLib
|
||
|
{
|
||
|
importlib("stdole2.tlb");
|
||
|
|
||
|
// ====================================================
|
||
|
// Interface definitions
|
||
|
// ====================================================
|
||
|
[
|
||
|
object,
|
||
|
uuid(50F16B25-467E-11D1-8271-00C04FC3183B),
|
||
|
dual,
|
||
|
helpstring("IPreview Interface"),
|
||
|
pointer_default(unique)
|
||
|
]
|
||
|
interface IPreview : IDispatch
|
||
|
{
|
||
|
[id(1), helpstring("method ShowFile")] HRESULT ShowFile(BSTR bstrFileName, int iSelectCount);
|
||
|
[propget, id(2), helpstring("property printable")] HRESULT printable([out, retval] BOOL *pVal);
|
||
|
[propput, id(2), helpstring("property printable")] HRESULT printable([in] BOOL newVal);
|
||
|
[propget, id(3), helpstring("property cxImage")] HRESULT cxImage([out, retval] long *pVal);
|
||
|
[propget, id(4), helpstring("property cyImage")] HRESULT cyImage([out, retval] long *pVal);
|
||
|
[id(5), helpstring("method Show")] HRESULT Show(VARIANT var);
|
||
|
}
|
||
|
|
||
|
[
|
||
|
object,
|
||
|
uuid(0AE0A2B1-3A34-11D3-9626-00C04F8EEC8C),
|
||
|
dual,
|
||
|
helpstring("IPreview2 Interface"),
|
||
|
pointer_default(unique)
|
||
|
]
|
||
|
interface IPreview2 : IPreview
|
||
|
{
|
||
|
[helpstring("zoom the image")] HRESULT Zoom([in] int iSelectCount);
|
||
|
[helpstring("fit image to window")] HRESULT BestFit();
|
||
|
[helpstring("show image at actual size")] HRESULT ActualSize();
|
||
|
[helpstring("start a slideshow")] HRESULT SlideShow();
|
||
|
}
|
||
|
|
||
|
[
|
||
|
object,
|
||
|
uuid(497431ad-5481-4df7-ae5d-130d9cd50db3),
|
||
|
helpstring("IPreview3 Interface"),
|
||
|
pointer_default(unique)
|
||
|
]
|
||
|
interface IPreview3 : IUnknown
|
||
|
{
|
||
|
[helpstring("")] HRESULT ShowFile(BSTR bstrFileName);
|
||
|
[helpstring("")] HRESULT Show(VARIANT var);
|
||
|
[helpstring("")] HRESULT Zoom([in] int iSelectCount);
|
||
|
[helpstring("")] HRESULT BestFit();
|
||
|
[helpstring("")] HRESULT ActualSize();
|
||
|
[helpstring("")] HRESULT SlideShow();
|
||
|
[helpstring("")] HRESULT Rotate([in] DWORD dwAngle);
|
||
|
[helpstring("")] HRESULT SetWallpaper([in] BSTR bstrPath);
|
||
|
[helpstring("")] HRESULT SaveAs([in] BSTR bstrPath);
|
||
|
[propget, helpstring("")] HRESULT cxImage([out, retval] long *pVal);
|
||
|
[propget, helpstring("")] HRESULT cyImage([out, retval] long *pVal);
|
||
|
}
|
||
|
|
||
|
[
|
||
|
object,
|
||
|
uuid(FF36E952-72E9-4EA0-92FB-B63FE5037D78),
|
||
|
helpstring("IImgCmdTarget Interface"),
|
||
|
pointer_default(unique)
|
||
|
]
|
||
|
interface IImgCmdTarget : IUnknown
|
||
|
{
|
||
|
[helpstring("")] HRESULT GetMode(DWORD * pdw);
|
||
|
[helpstring("")] HRESULT GetPageFlags(DWORD * pdw);
|
||
|
|
||
|
[helpstring("")] HRESULT ZoomIn();
|
||
|
[helpstring("")] HRESULT ZoomOut();
|
||
|
[helpstring("")] HRESULT ActualSize();
|
||
|
[helpstring("")] HRESULT BestFit();
|
||
|
[helpstring("")] HRESULT Rotate([in] DWORD dwAngle);
|
||
|
[helpstring("")] HRESULT NextPage();
|
||
|
[helpstring("")] HRESULT PreviousPage();
|
||
|
}
|
||
|
|
||
|
// ====================================================
|
||
|
// Dispatch Interface definitions
|
||
|
// ====================================================
|
||
|
[
|
||
|
uuid(1B490296-50DF-11d1-8B44-00C04FC3183B),
|
||
|
helpstring("Event interface for ThumbCtl")
|
||
|
]
|
||
|
dispinterface DPreviewEvents
|
||
|
{
|
||
|
properties:
|
||
|
methods:
|
||
|
[id(1), helpstring("The preview is closing."), helpcontext(0x0000)]
|
||
|
void OnClose();
|
||
|
[id(2), helpstring("The preview image has been generated."), helpcontext(0x0000)]
|
||
|
void OnPreviewReady();
|
||
|
[id(3), helpstring("There was an error generating the preview."), helpcontext(0x0000)]
|
||
|
void OnError();
|
||
|
[id(4), helpstring("User chose Best Fit."), helpcontext(0x0000)]
|
||
|
void OnBestFitPress();
|
||
|
[id(5), helpstring("User chose Actual Size."), helpcontext(0x0000)]
|
||
|
void OnActualSizePress();
|
||
|
}
|
||
|
|
||
|
// ====================================================
|
||
|
// CoClass definitions
|
||
|
// ====================================================
|
||
|
[
|
||
|
uuid(50F16B26-467E-11D1-8271-00C04FC3183B),
|
||
|
helpstring("Preview Class")
|
||
|
]
|
||
|
coclass Preview
|
||
|
{
|
||
|
[default] interface IPreview2;
|
||
|
[default, source] dispinterface DPreviewEvents;
|
||
|
};
|
||
|
};
|
||
|
|
||
|
cpp_quote("#define SID_SImageView IID_IImgCmdTarget")
|