source: Daodan/MSYS2/mingw32/i686-w64-mingw32/include/directmanipulation.idl@ 1166

Last change on this file since 1166 was 1166, checked in by rossy, 3 years ago

Daodan: Replace MinGW build env with an up-to-date MSYS2 env

File size: 14.7 KB
Line 
1/*
2 * Copyright 2019 Alistair Leslie-Hughes
3 *
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2.1 of the License, or (at your option) any later version.
8 *
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
13 *
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
17 */
18
19import "oaidl.idl";
20import "ocidl.idl";
21
22cpp_quote("#if 0")
23typedef void* HWND;
24cpp_quote("#endif")
25
26interface IDirectManipulationViewportEventHandler;
27
28typedef enum DIRECTMANIPULATION_HITTEST_TYPE
29{
30 DIRECTMANIPULATION_HITTEST_TYPE_ASYNCHRONOUS = 0x00000000,
31 DIRECTMANIPULATION_HITTEST_TYPE_SYNCHRONOUS = 0x00000001,
32 DIRECTMANIPULATION_HITTEST_TYPE_AUTO_SYNCHRONOUS = 0x00000002
33} DIRECTMANIPULATION_HITTEST_TYPE;
34cpp_quote("DEFINE_ENUM_FLAG_OPERATORS(DIRECTMANIPULATION_HITTEST_TYPE)")
35
36typedef enum DIRECTMANIPULATION_STATUS
37{
38 DIRECTMANIPULATION_BUILDING,
39 DIRECTMANIPULATION_ENABLED,
40 DIRECTMANIPULATION_DISABLED,
41 DIRECTMANIPULATION_RUNNING,
42 DIRECTMANIPULATION_INERTIA,
43 DIRECTMANIPULATION_READY,
44 DIRECTMANIPULATION_SUSPENDED
45} DIRECTMANIPULATION_STATUS;
46
47typedef enum DIRECTMANIPULATION_VIEWPORT_OPTIONS
48{
49 DIRECTMANIPULATION_VIEWPORT_OPTIONS_DEFAULT = 0x00000000,
50 DIRECTMANIPULATION_VIEWPORT_OPTIONS_AUTODISABLE = 0x00000001,
51 DIRECTMANIPULATION_VIEWPORT_OPTIONS_MANUALUPDATE = 0x00000002,
52 DIRECTMANIPULATION_VIEWPORT_OPTIONS_INPUT = 0x00000004,
53 DIRECTMANIPULATION_VIEWPORT_OPTIONS_EXPLICITHITTEST = 0x00000008,
54 DIRECTMANIPULATION_VIEWPORT_OPTIONS_DISABLEPIXELSNAPPING = 0x00000010,
55} DIRECTMANIPULATION_VIEWPORT_OPTIONS;
56cpp_quote("DEFINE_ENUM_FLAG_OPERATORS(DIRECTMANIPULATION_VIEWPORT_OPTIONS)")
57
58typedef enum DIRECTMANIPULATION_CONFIGURATION
59{
60 DIRECTMANIPULATION_CONFIGURATION_NONE = 0x00000000,
61 DIRECTMANIPULATION_CONFIGURATION_INTERACTION = 0x00000001,
62 DIRECTMANIPULATION_CONFIGURATION_TRANSLATION_X = 0x00000002,
63 DIRECTMANIPULATION_CONFIGURATION_TRANSLATION_Y = 0x00000004,
64 DIRECTMANIPULATION_CONFIGURATION_SCALING = 0x00000010,
65 DIRECTMANIPULATION_CONFIGURATION_TRANSLATION_INERTIA = 0x00000020,
66 DIRECTMANIPULATION_CONFIGURATION_SCALING_INERTIA = 0x00000080,
67 DIRECTMANIPULATION_CONFIGURATION_RAILS_X = 0x00000100,
68 DIRECTMANIPULATION_CONFIGURATION_RAILS_Y = 0x00000200,
69} DIRECTMANIPULATION_CONFIGURATION;
70cpp_quote("DEFINE_ENUM_FLAG_OPERATORS(DIRECTMANIPULATION_CONFIGURATION)")
71
72typedef enum DIRECTMANIPULATION_GESTURE_CONFIGURATION
73{
74 DIRECTMANIPULATION_GESTURE_NONE = 0x00000000,
75 DIRECTMANIPULATION_GESTURE_DEFAULT = 0x00000000,
76 DIRECTMANIPULATION_GESTURE_CROSS_SLIDE_VERTICAL = 0x00000008,
77 DIRECTMANIPULATION_GESTURE_CROSS_SLIDE_HORIZONTAL = 0x00000010,
78 DIRECTMANIPULATION_GESTURE_PINCH_ZOOM = 0x00000020,
79} DIRECTMANIPULATION_GESTURE_CONFIGURATION;
80cpp_quote("DEFINE_ENUM_FLAG_OPERATORS(DIRECTMANIPULATION_GESTURE_CONFIGURATION)")
81
82typedef enum DIRECTMANIPULATION_MOTION_TYPES
83{
84 DIRECTMANIPULATION_MOTION_NONE = 0x00000000,
85 DIRECTMANIPULATION_MOTION_TRANSLATEX = 0x00000001,
86 DIRECTMANIPULATION_MOTION_TRANSLATEY = 0x00000002,
87 DIRECTMANIPULATION_MOTION_ZOOM = 0x00000004,
88 DIRECTMANIPULATION_MOTION_CENTERX = 0x00000010,
89 DIRECTMANIPULATION_MOTION_CENTERY = 0x00000020,
90 DIRECTMANIPULATION_MOTION_ALL = DIRECTMANIPULATION_MOTION_TRANSLATEX | DIRECTMANIPULATION_MOTION_TRANSLATEY |
91 DIRECTMANIPULATION_MOTION_ZOOM | DIRECTMANIPULATION_MOTION_CENTERX |
92 DIRECTMANIPULATION_MOTION_CENTERY
93} DIRECTMANIPULATION_MOTION_TYPES;
94cpp_quote("DEFINE_ENUM_FLAG_OPERATORS(DIRECTMANIPULATION_MOTION_TYPES)")
95
96typedef enum DIRECTMANIPULATION_SNAPPOINT_TYPE
97{
98 DIRECTMANIPULATION_SNAPPOINT_MANDATORY,
99 DIRECTMANIPULATION_SNAPPOINT_OPTIONAL,
100 DIRECTMANIPULATION_SNAPPOINT_MANDATORY_SINGLE,
101 DIRECTMANIPULATION_SNAPPOINT_OPTIONAL_SINGLE
102} DIRECTMANIPULATION_SNAPPOINT_TYPE;
103
104typedef enum DIRECTMANIPULATION_SNAPPOINT_COORDINATE
105{
106 DIRECTMANIPULATION_COORDINATE_BOUNDARY = 0x00000000,
107 DIRECTMANIPULATION_COORDINATE_ORIGIN = 0x00000001,
108 DIRECTMANIPULATION_COORDINATE_MIRRORED = 0x00000010
109} DIRECTMANIPULATION_SNAPPOINT_COORDINATE;
110cpp_quote("DEFINE_ENUM_FLAG_OPERATORS(DIRECTMANIPULATION_SNAPPOINT_COORDINATE)")
111
112typedef enum DIRECTMANIPULATION_HORIZONTALALIGNMENT
113{
114 DIRECTMANIPULATION_HORIZONTALALIGNMENT_NONE = 0x00000000,
115 DIRECTMANIPULATION_HORIZONTALALIGNMENT_LEFT = 0x00000001,
116 DIRECTMANIPULATION_HORIZONTALALIGNMENT_CENTER = 0x00000002,
117 DIRECTMANIPULATION_HORIZONTALALIGNMENT_RIGHT = 0x00000004,
118 DIRECTMANIPULATION_HORIZONTALALIGNMENT_UNLOCKCENTER = 0x00000008
119} DIRECTMANIPULATION_HORIZONTALALIGNMENT;
120cpp_quote("DEFINE_ENUM_FLAG_OPERATORS(DIRECTMANIPULATION_HORIZONTALALIGNMENT)")
121
122typedef enum DIRECTMANIPULATION_VERTICALALIGNMENT
123{
124 DIRECTMANIPULATION_VERTICALALIGNMENT_NONE = 0x00000000,
125 DIRECTMANIPULATION_VERTICALALIGNMENT_TOP = 0x00000001,
126 DIRECTMANIPULATION_VERTICALALIGNMENT_CENTER = 0x00000002,
127 DIRECTMANIPULATION_VERTICALALIGNMENT_BOTTOM = 0x00000004,
128 DIRECTMANIPULATION_VERTICALALIGNMENT_UNLOCKCENTER = 0x00000008
129} DIRECTMANIPULATION_VERTICALALIGNMENT;
130cpp_quote("DEFINE_ENUM_FLAG_OPERATORS(DIRECTMANIPULATION_VERTICALALIGNMENT)")
131
132typedef enum DIRECTMANIPULATION_INPUT_MODE
133{
134 DIRECTMANIPULATION_INPUT_MODE_AUTOMATIC,
135 DIRECTMANIPULATION_INPUT_MODE_MANUAL
136} DIRECTMANIPULATION_INPUT_MODE;
137
138[
139 local,
140 object,
141 uuid(fb759dba-6f4c-4c01-874e-19c8a05907f9),
142 pointer_default(unique)
143]
144interface IDirectManipulationFrameInfoProvider : IUnknown
145{
146 HRESULT GetNextFrameInfo([out] ULONGLONG *time, [out] ULONGLONG *process, [out] ULONGLONG *composition);
147}
148
149[
150 local,
151 object,
152 uuid(fbf5d3b4-70c7-4163-9322-5a6f660d6fbc),
153 pointer_default(unique)
154]
155interface IDirectManipulationManager : IUnknown
156{
157 HRESULT Activate([in] HWND window);
158
159 HRESULT Deactivate([in] HWND window);
160
161 HRESULT RegisterHitTestTarget([in] HWND window, [in] HWND hittest, [in] DIRECTMANIPULATION_HITTEST_TYPE type);
162
163 HRESULT ProcessInput([in] const MSG *msg, [out, retval] BOOL *handled);
164
165 HRESULT GetUpdateManager([in] REFIID riid, [out, iid_is(riid), retval,] void **obj);
166
167 HRESULT CreateViewport([in] IDirectManipulationFrameInfoProvider *frame, [in] HWND window,
168 [in] REFIID riid, [out, iid_is(riid), retval] void **obj);
169
170 HRESULT CreateContent([in] IDirectManipulationFrameInfoProvider *frame, [in] REFCLSID clsid,
171 [in] REFIID riid, [out, iid_is(riid), retval] void **obj);
172}
173
174[
175 local,
176 object,
177 uuid(b89962cb-3d89-442b-bb58-5098fa0f9f16),
178 pointer_default(unique)
179]
180interface IDirectManipulationContent : IUnknown
181{
182 HRESULT GetContentRect([out] RECT *size);
183
184 HRESULT SetContentRect([in] const RECT *size);
185
186 HRESULT GetViewport([in] REFIID riid, [out, iid_is(riid)] void **object);
187
188 HRESULT GetTag([in] REFIID riid, [out, iid_is(riid)] void **object, [out] UINT32 *id);
189
190 HRESULT SetTag([in, unique] IUnknown *object, [in] UINT32 id);
191
192 HRESULT GetOutputTransform([out] float *matrix, [in] DWORD count);
193
194 HRESULT GetContentTransform([out] float *matrix, [in] DWORD count);
195
196 HRESULT SyncContentTransform([in] const float *matrix, [in] DWORD count);
197}
198
199[
200 local,
201 object,
202 uuid(790b6337-64f8-4ff5-a269-b32bc2af27a7),
203 pointer_default(unique)
204]
205interface IDirectManipulationUpdateHandler : IUnknown
206{
207 HRESULT Update();
208}
209
210[
211 local,
212 object,
213 uuid(b0ae62fd-be34-46e7-9caa-d361facbb9cc),
214 pointer_default(unique)
215]
216interface IDirectManipulationUpdateManager : IUnknown
217{
218 HRESULT RegisterWaitHandleCallback([in] HANDLE handle, [in] IDirectManipulationUpdateHandler *handler,
219 [out] DWORD *cookie);
220
221 HRESULT UnregisterWaitHandleCallback([in] DWORD cookie);
222
223 HRESULT Update([in] IDirectManipulationFrameInfoProvider *provider);
224}
225
226[
227 local,
228 object,
229 uuid(537a0825-0387-4efa-b62f-71eb1f085a7e),
230 pointer_default(unique)
231]
232interface IDirectManipulationCompositor : IUnknown
233{
234 HRESULT AddContent([in] IDirectManipulationContent *content, [in] IUnknown *device,
235 [in] IUnknown *parent, [in] IUnknown *child);
236
237 HRESULT RemoveContent([in] IDirectManipulationContent *content);
238
239 HRESULT SetUpdateManager([in] IDirectManipulationUpdateManager *manager);
240
241 HRESULT Flush();
242}
243
244[
245 local,
246 object,
247 uuid(28b85a3d-60a0-48bd-9ba1-5ce8d9ea3a6d),
248 pointer_default(unique)
249]
250interface IDirectManipulationViewport : IUnknown
251{
252 HRESULT Enable();
253
254 HRESULT Disable();
255
256 HRESULT SetContact([in] UINT32 id);
257
258 HRESULT ReleaseContact([in] UINT32 id);
259
260 HRESULT ReleaseAllContacts();
261
262 HRESULT GetStatus([out] DIRECTMANIPULATION_STATUS *status);
263
264 HRESULT GetTag([in] REFIID riid, [out, iid_is(riid)] void **object, [out] UINT32 *id);
265
266 HRESULT SetTag([in, unique] IUnknown *object, [in] UINT32 id);
267
268 HRESULT GetViewportRect([out, retval] RECT *viewport);
269
270 HRESULT SetViewportRect([in] const RECT *viewport);
271
272 HRESULT ZoomToRect([in] const float left, [in] const float top, [in] const float right,
273 [in] const float bottom, [in] BOOL animate);
274
275 HRESULT SetViewportTransform([in] const float *matrix, [in] DWORD count);
276
277 HRESULT SyncDisplayTransform([in] const float *matrix, [in] DWORD count);
278
279 HRESULT GetPrimaryContent([in] REFIID riid, [out, iid_is(riid)] void **object);
280
281 HRESULT AddContent([in, unique] IDirectManipulationContent *content);
282
283 HRESULT RemoveContent([in, unique] IDirectManipulationContent *content);
284
285 HRESULT SetViewportOptions([in] DIRECTMANIPULATION_VIEWPORT_OPTIONS options);
286
287 HRESULT AddConfiguration([in] DIRECTMANIPULATION_CONFIGURATION configuration);
288
289 HRESULT RemoveConfiguration([in] DIRECTMANIPULATION_CONFIGURATION configuration);
290
291 HRESULT ActivateConfiguration([in] DIRECTMANIPULATION_CONFIGURATION configuration);
292
293 HRESULT SetManualGesture([in] DIRECTMANIPULATION_GESTURE_CONFIGURATION configuration);
294
295 HRESULT SetChaining([in] DIRECTMANIPULATION_MOTION_TYPES enabledTypes);
296
297 HRESULT AddEventHandler([in] HWND window, [in] IDirectManipulationViewportEventHandler *eventHandler,
298 [out, retval] DWORD *cookie);
299
300 HRESULT RemoveEventHandler([in] DWORD cookie);
301
302 HRESULT SetInputMode([in] DIRECTMANIPULATION_INPUT_MODE mode);
303
304 HRESULT SetUpdateMode([in] DIRECTMANIPULATION_INPUT_MODE mode);
305
306 HRESULT Stop();
307
308 HRESULT Abandon();
309}
310
311[
312 local,
313 object,
314 uuid(923ccaac-61e1-4385-b726-017af189882a),
315 pointer_default(unique)
316]
317interface IDirectManipulationViewport2 : IDirectManipulationViewport
318{
319 HRESULT AddBehavior([in] IUnknown *behavior, [out, retval] DWORD *cookie);
320
321 HRESULT RemoveBehavior([in] DWORD cookie);
322
323 HRESULT RemoveAllBehaviors();
324}
325
326[
327 local,
328 object,
329 uuid(952121DA-D69F-45F9-B0F9-F23944321A6D),
330 pointer_default(unique)
331]
332interface IDirectManipulationViewportEventHandler : IUnknown
333{
334 HRESULT OnViewportStatusChanged([in] IDirectManipulationViewport *viewport, [in] DIRECTMANIPULATION_STATUS current,
335 [in] DIRECTMANIPULATION_STATUS previous);
336
337 HRESULT OnViewportUpdated([in] IDirectManipulationViewport *viewport);
338
339 HRESULT OnContentUpdated([in] IDirectManipulationViewport *viewport, [in] IDirectManipulationContent *content);
340}
341
342[
343 local,
344 object,
345 uuid(fa1005e9-3d16-484c-bfc9-62b61e56ec4e),
346 pointer_default(unique)
347]
348interface IDirectManipulationManager2 : IDirectManipulationManager
349{
350 HRESULT CreateBehavior([in] REFCLSID clsid, [in] REFIID riid, [out, iid_is(riid), retval] void **obj);
351}
352
353[
354 local,
355 object,
356 uuid(c12851e4-1698-4625-b9b1-7ca3ec18630b),
357 pointer_default(unique)
358]
359interface IDirectManipulationPrimaryContent : IUnknown
360{
361 HRESULT SetSnapInterval([in] DIRECTMANIPULATION_MOTION_TYPES motion, [in] float interval, [in] float offset);
362
363 HRESULT SetSnapPoints([in] DIRECTMANIPULATION_MOTION_TYPES motion, [in] const float *points, [in] DWORD count);
364
365 HRESULT SetSnapType([in] DIRECTMANIPULATION_MOTION_TYPES motion, [in] DIRECTMANIPULATION_SNAPPOINT_TYPE type);
366
367 HRESULT SetSnapCoordinate([in] DIRECTMANIPULATION_MOTION_TYPES motion, [in] DIRECTMANIPULATION_SNAPPOINT_COORDINATE coordinate,
368 [in] float origin);
369
370 HRESULT SetZoomBoundaries([in] float minimum, [in] float maximum);
371
372 HRESULT SetHorizontalAlignment([in] DIRECTMANIPULATION_HORIZONTALALIGNMENT alignment);
373
374 HRESULT SetVerticalAlignment([in] DIRECTMANIPULATION_VERTICALALIGNMENT alignment);
375
376 HRESULT GetInertiaEndTransform([out] float *matrix, [in] DWORD count);
377
378 HRESULT GetCenterPoint([out] float *x, [out] float *y);
379}
380
381[
382 local,
383 object,
384 uuid(d38c7822-f1cb-43cb-b4b9-ac0c767a412e),
385 pointer_default(unique)
386]
387interface IDirectManipulationCompositor2 : IDirectManipulationCompositor
388{
389 HRESULT AddContentWithCrossProcessChaining([in] IDirectManipulationPrimaryContent *content, [in] IUnknown *device,
390 [in] IUnknown *parentVisual, [in] IUnknown *childVisual);
391}
392
393[
394 uuid(9fbedf98-f6d8-4e3b-b488-fa66dbf5e9f3),
395 version(1.0)
396]
397library DirectManipulation
398{
399 [
400 uuid(54e211b6-3650-4f75-8334-fa359598e1c5)
401 ]
402 coclass DirectManipulationManager
403 {
404 interface IDirectManipulationManager2;
405 [default] interface IDirectManipulationManager;
406 }
407
408 [
409 uuid(99793286-77cc-4b57-96db-3b354f6f9fb5)
410 ]
411 coclass DirectManipulationSharedManager
412 {
413 interface IDirectManipulationManager2;
414 [default] interface IDirectManipulationManager;
415 }
416
417 [
418 uuid(79dea627-a08a-43ac-8ef5-6900b9299126)
419 ]
420 coclass DCompManipulationCompositor
421 {
422 [default] interface IDirectManipulationCompositor;
423 interface IDirectManipulationCompositor2;
424 interface IDirectManipulationFrameInfoProvider;
425 }
426
427 [
428 noncreatable,
429 hidden,
430 uuid(34e211b6-3650-4f75-8334-fa359598e1c5)
431 ]
432 coclass DirectManipulationViewport
433 {
434 interface IDirectManipulationViewport2;
435 [default] interface IDirectManipulationViewport;
436 }
437}
Note: See TracBrowser for help on using the repository browser.