DECLARE_INTERFACE_(IDirectManipulationCompositor, IUnknown)
{
STDMETHOD(CreateDevice)(THIS_
_In_ IUnknown *device,
_Out_ IDirectManipulationDevice **newDevice) PURE;
STDMETHOD(CreateDevice2)(THIS_
_In_ IUnknown *device,
_Out_ IDirectManipulationDevice2 **newDevice) PURE;
STDMETHOD(CreateManager)(THIS_
_In_ IDirectManipulationFrameInfoProvider *frameInfo,
_Out_ IDirectManipulationManager **newManager) PURE;
STDMETHOD(EnsureDispatcher)(THIS_
_In_ HWND window) PURE;
STDMETHOD(AddView)(THIS_
_In_ HWND window,
_In_ IDirectManipulationFrameInfoProvider *frameInfo,
_In_ IDirectManipulationManager *manager,
_In_opt_ IUnknown *hitTestProvider,
_In_opt_ IUnknown *manipulationProcessor,
_Out_ IDirectManipulationView **view) PURE;
STDMETHOD(RemoveView)(THIS_
_In_ IDirectManipulationView *view) PURE;
STDMETHOD(AddContent)(THIS_
_In_ IDirectManipulationDevice *device,
_In_ IUnknown *content,
_Out_ DWORD *cookie) PURE;
STDMETHOD(RemoveContent)(THIS_
_In_ DWORD cookie) PURE;
STDMETHOD(AddConfiguration)(THIS_
_In_ DWORD configuration,
_In_ HWND window,
_In_opt_ IUnknown *hitTestProvider,
_In_opt_ IUnknown *manipulationProcessor) PURE;
STDMETHOD(RemoveConfiguration)(THIS_
_In_ DWORD configuration) PURE;
STDMETHOD(ActivateConfiguration)(THIS_
_In_ DWORD configuration) PURE;
STDMETHOD(SetUpdateManager)(THIS_
_In_ IDirectManipulationUpdateManager *updateManager) PURE;
};
这个接口包含了一系列方法,用于创建设备、管理器、视图以及配置,并设置 Direct Manipulation 会话的各种属性。例如:
- CreateDevice 和 CreateDevice2 用于创建 Direct Manipulation 设备对象。
- CreateManager 用于创建 Direct Manipulation 管理器对象。
- EnsureDispatcher 用于确保与指定窗口相关联的 Direct Manipulation 调度程序。
- AddView 和 RemoveView 用于添加和移除 Direct Manipulation 视图。
- AddContent 和 RemoveContent 用于添加和移除 Direct Manipulation 内容。
- AddConfiguration, RemoveConfiguration, 和 ActivateConfiguration 用于添加、移除和激活 Direct Manipulation 配置。
- SetUpdateManager 用于设置 Direct Manipulation 会话的更新管理器。
这些方法提供了对 Direct Manipulation 会话的创建、配置和管理的能力。
转载请注明出处:http://www.zyzy.cn/article/detail/26818/Win32 API/Directmanipulation.h/IDirectManipulationCompositor