]> git.proxmox.com Git - rustc.git/blob - vendor/windows/src/Windows/Devices/Input/mod.rs
733cf428d40c6e2a3443630edccb0506877ad572
[rustc.git] / vendor / windows / src / Windows / Devices / Input / mod.rs
1 #[cfg(feature = "Devices_Input_Preview")]
2 pub mod Preview;
3 #[doc(hidden)]
4 #[repr(transparent)]
5 pub struct IKeyboardCapabilities(::windows::core::IUnknown);
6 unsafe impl ::windows::core::Interface for IKeyboardCapabilities {
7 type Vtable = IKeyboardCapabilities_Vtbl;
8 }
9 impl ::core::clone::Clone for IKeyboardCapabilities {
10 fn clone(&self) -> Self {
11 Self(self.0.clone())
12 }
13 }
14 unsafe impl ::windows::core::ComInterface for IKeyboardCapabilities {
15 const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x3a3f9b56_6798_4bbc_833e_0f34b17c65ff);
16 }
17 #[repr(C)]
18 #[doc(hidden)]
19 pub struct IKeyboardCapabilities_Vtbl {
20 pub base__: ::windows::core::IInspectable_Vtbl,
21 pub KeyboardPresent: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut i32) -> ::windows::core::HRESULT,
22 }
23 #[doc(hidden)]
24 #[repr(transparent)]
25 pub struct IMouseCapabilities(::windows::core::IUnknown);
26 unsafe impl ::windows::core::Interface for IMouseCapabilities {
27 type Vtable = IMouseCapabilities_Vtbl;
28 }
29 impl ::core::clone::Clone for IMouseCapabilities {
30 fn clone(&self) -> Self {
31 Self(self.0.clone())
32 }
33 }
34 unsafe impl ::windows::core::ComInterface for IMouseCapabilities {
35 const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xbca5e023_7dd9_4b6b_9a92_55d43cb38f73);
36 }
37 #[repr(C)]
38 #[doc(hidden)]
39 pub struct IMouseCapabilities_Vtbl {
40 pub base__: ::windows::core::IInspectable_Vtbl,
41 pub MousePresent: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut i32) -> ::windows::core::HRESULT,
42 pub VerticalWheelPresent: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut i32) -> ::windows::core::HRESULT,
43 pub HorizontalWheelPresent: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut i32) -> ::windows::core::HRESULT,
44 pub SwapButtons: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut i32) -> ::windows::core::HRESULT,
45 pub NumberOfButtons: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut u32) -> ::windows::core::HRESULT,
46 }
47 #[doc(hidden)]
48 #[repr(transparent)]
49 pub struct IMouseDevice(::windows::core::IUnknown);
50 unsafe impl ::windows::core::Interface for IMouseDevice {
51 type Vtable = IMouseDevice_Vtbl;
52 }
53 impl ::core::clone::Clone for IMouseDevice {
54 fn clone(&self) -> Self {
55 Self(self.0.clone())
56 }
57 }
58 unsafe impl ::windows::core::ComInterface for IMouseDevice {
59 const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x88edf458_f2c8_49f4_be1f_c256b388bc11);
60 }
61 #[repr(C)]
62 #[doc(hidden)]
63 pub struct IMouseDevice_Vtbl {
64 pub base__: ::windows::core::IInspectable_Vtbl,
65 #[cfg(feature = "Foundation")]
66 pub MouseMoved: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, handler: *mut ::core::ffi::c_void, result__: *mut super::super::Foundation::EventRegistrationToken) -> ::windows::core::HRESULT,
67 #[cfg(not(feature = "Foundation"))]
68 MouseMoved: usize,
69 #[cfg(feature = "Foundation")]
70 pub RemoveMouseMoved: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, cookie: super::super::Foundation::EventRegistrationToken) -> ::windows::core::HRESULT,
71 #[cfg(not(feature = "Foundation"))]
72 RemoveMouseMoved: usize,
73 }
74 #[doc(hidden)]
75 #[repr(transparent)]
76 pub struct IMouseDeviceStatics(::windows::core::IUnknown);
77 unsafe impl ::windows::core::Interface for IMouseDeviceStatics {
78 type Vtable = IMouseDeviceStatics_Vtbl;
79 }
80 impl ::core::clone::Clone for IMouseDeviceStatics {
81 fn clone(&self) -> Self {
82 Self(self.0.clone())
83 }
84 }
85 unsafe impl ::windows::core::ComInterface for IMouseDeviceStatics {
86 const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x484a9045_6d70_49db_8e68_46ffbd17d38d);
87 }
88 #[repr(C)]
89 #[doc(hidden)]
90 pub struct IMouseDeviceStatics_Vtbl {
91 pub base__: ::windows::core::IInspectable_Vtbl,
92 pub GetForCurrentView: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT,
93 }
94 #[doc(hidden)]
95 #[repr(transparent)]
96 pub struct IMouseEventArgs(::windows::core::IUnknown);
97 unsafe impl ::windows::core::Interface for IMouseEventArgs {
98 type Vtable = IMouseEventArgs_Vtbl;
99 }
100 impl ::core::clone::Clone for IMouseEventArgs {
101 fn clone(&self) -> Self {
102 Self(self.0.clone())
103 }
104 }
105 unsafe impl ::windows::core::ComInterface for IMouseEventArgs {
106 const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xf625aa5d_2354_4cc7_9230_96941c969fde);
107 }
108 #[repr(C)]
109 #[doc(hidden)]
110 pub struct IMouseEventArgs_Vtbl {
111 pub base__: ::windows::core::IInspectable_Vtbl,
112 pub MouseDelta: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut MouseDelta) -> ::windows::core::HRESULT,
113 }
114 #[doc(hidden)]
115 #[repr(transparent)]
116 pub struct IPenButtonListener(::windows::core::IUnknown);
117 unsafe impl ::windows::core::Interface for IPenButtonListener {
118 type Vtable = IPenButtonListener_Vtbl;
119 }
120 impl ::core::clone::Clone for IPenButtonListener {
121 fn clone(&self) -> Self {
122 Self(self.0.clone())
123 }
124 }
125 unsafe impl ::windows::core::ComInterface for IPenButtonListener {
126 const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x8245c376_1ee3_53f7_b1f7_8334a16f2815);
127 }
128 #[repr(C)]
129 #[doc(hidden)]
130 pub struct IPenButtonListener_Vtbl {
131 pub base__: ::windows::core::IInspectable_Vtbl,
132 pub IsSupported: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut bool) -> ::windows::core::HRESULT,
133 #[cfg(feature = "Foundation")]
134 pub IsSupportedChanged: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, handler: *mut ::core::ffi::c_void, result__: *mut super::super::Foundation::EventRegistrationToken) -> ::windows::core::HRESULT,
135 #[cfg(not(feature = "Foundation"))]
136 IsSupportedChanged: usize,
137 #[cfg(feature = "Foundation")]
138 pub RemoveIsSupportedChanged: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, token: super::super::Foundation::EventRegistrationToken) -> ::windows::core::HRESULT,
139 #[cfg(not(feature = "Foundation"))]
140 RemoveIsSupportedChanged: usize,
141 #[cfg(feature = "Foundation")]
142 pub TailButtonClicked: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, handler: *mut ::core::ffi::c_void, result__: *mut super::super::Foundation::EventRegistrationToken) -> ::windows::core::HRESULT,
143 #[cfg(not(feature = "Foundation"))]
144 TailButtonClicked: usize,
145 #[cfg(feature = "Foundation")]
146 pub RemoveTailButtonClicked: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, token: super::super::Foundation::EventRegistrationToken) -> ::windows::core::HRESULT,
147 #[cfg(not(feature = "Foundation"))]
148 RemoveTailButtonClicked: usize,
149 #[cfg(feature = "Foundation")]
150 pub TailButtonDoubleClicked: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, handler: *mut ::core::ffi::c_void, result__: *mut super::super::Foundation::EventRegistrationToken) -> ::windows::core::HRESULT,
151 #[cfg(not(feature = "Foundation"))]
152 TailButtonDoubleClicked: usize,
153 #[cfg(feature = "Foundation")]
154 pub RemoveTailButtonDoubleClicked: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, token: super::super::Foundation::EventRegistrationToken) -> ::windows::core::HRESULT,
155 #[cfg(not(feature = "Foundation"))]
156 RemoveTailButtonDoubleClicked: usize,
157 #[cfg(feature = "Foundation")]
158 pub TailButtonLongPressed: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, handler: *mut ::core::ffi::c_void, result__: *mut super::super::Foundation::EventRegistrationToken) -> ::windows::core::HRESULT,
159 #[cfg(not(feature = "Foundation"))]
160 TailButtonLongPressed: usize,
161 #[cfg(feature = "Foundation")]
162 pub RemoveTailButtonLongPressed: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, token: super::super::Foundation::EventRegistrationToken) -> ::windows::core::HRESULT,
163 #[cfg(not(feature = "Foundation"))]
164 RemoveTailButtonLongPressed: usize,
165 }
166 #[doc(hidden)]
167 #[repr(transparent)]
168 pub struct IPenButtonListenerStatics(::windows::core::IUnknown);
169 unsafe impl ::windows::core::Interface for IPenButtonListenerStatics {
170 type Vtable = IPenButtonListenerStatics_Vtbl;
171 }
172 impl ::core::clone::Clone for IPenButtonListenerStatics {
173 fn clone(&self) -> Self {
174 Self(self.0.clone())
175 }
176 }
177 unsafe impl ::windows::core::ComInterface for IPenButtonListenerStatics {
178 const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x19a8a584_862f_5f69_bfea_05f6584f133f);
179 }
180 #[repr(C)]
181 #[doc(hidden)]
182 pub struct IPenButtonListenerStatics_Vtbl {
183 pub base__: ::windows::core::IInspectable_Vtbl,
184 pub GetDefault: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT,
185 }
186 #[doc(hidden)]
187 #[repr(transparent)]
188 pub struct IPenDevice(::windows::core::IUnknown);
189 unsafe impl ::windows::core::Interface for IPenDevice {
190 type Vtable = IPenDevice_Vtbl;
191 }
192 impl ::core::clone::Clone for IPenDevice {
193 fn clone(&self) -> Self {
194 Self(self.0.clone())
195 }
196 }
197 unsafe impl ::windows::core::ComInterface for IPenDevice {
198 const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x31856eba_a738_5a8c_b8f6_f97ef68d18ef);
199 }
200 #[repr(C)]
201 #[doc(hidden)]
202 pub struct IPenDevice_Vtbl {
203 pub base__: ::windows::core::IInspectable_Vtbl,
204 pub PenId: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut ::windows::core::GUID) -> ::windows::core::HRESULT,
205 }
206 #[doc(hidden)]
207 #[repr(transparent)]
208 pub struct IPenDevice2(::windows::core::IUnknown);
209 unsafe impl ::windows::core::Interface for IPenDevice2 {
210 type Vtable = IPenDevice2_Vtbl;
211 }
212 impl ::core::clone::Clone for IPenDevice2 {
213 fn clone(&self) -> Self {
214 Self(self.0.clone())
215 }
216 }
217 unsafe impl ::windows::core::ComInterface for IPenDevice2 {
218 const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0207d327_7fb8_5566_8c34_f8342037b7f9);
219 }
220 #[repr(C)]
221 #[doc(hidden)]
222 pub struct IPenDevice2_Vtbl {
223 pub base__: ::windows::core::IInspectable_Vtbl,
224 #[cfg(feature = "Devices_Haptics")]
225 pub SimpleHapticsController: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT,
226 #[cfg(not(feature = "Devices_Haptics"))]
227 SimpleHapticsController: usize,
228 }
229 #[doc(hidden)]
230 #[repr(transparent)]
231 pub struct IPenDeviceStatics(::windows::core::IUnknown);
232 unsafe impl ::windows::core::Interface for IPenDeviceStatics {
233 type Vtable = IPenDeviceStatics_Vtbl;
234 }
235 impl ::core::clone::Clone for IPenDeviceStatics {
236 fn clone(&self) -> Self {
237 Self(self.0.clone())
238 }
239 }
240 unsafe impl ::windows::core::ComInterface for IPenDeviceStatics {
241 const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x9dfbbe01_0966_5180_bcb4_b85060e39479);
242 }
243 #[repr(C)]
244 #[doc(hidden)]
245 pub struct IPenDeviceStatics_Vtbl {
246 pub base__: ::windows::core::IInspectable_Vtbl,
247 pub GetFromPointerId: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, pointerid: u32, result__: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT,
248 }
249 #[doc(hidden)]
250 #[repr(transparent)]
251 pub struct IPenDockListener(::windows::core::IUnknown);
252 unsafe impl ::windows::core::Interface for IPenDockListener {
253 type Vtable = IPenDockListener_Vtbl;
254 }
255 impl ::core::clone::Clone for IPenDockListener {
256 fn clone(&self) -> Self {
257 Self(self.0.clone())
258 }
259 }
260 unsafe impl ::windows::core::ComInterface for IPenDockListener {
261 const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x759f4d90_1dc0_55cb_ad18_b9101456f592);
262 }
263 #[repr(C)]
264 #[doc(hidden)]
265 pub struct IPenDockListener_Vtbl {
266 pub base__: ::windows::core::IInspectable_Vtbl,
267 pub IsSupported: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut bool) -> ::windows::core::HRESULT,
268 #[cfg(feature = "Foundation")]
269 pub IsSupportedChanged: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, handler: *mut ::core::ffi::c_void, result__: *mut super::super::Foundation::EventRegistrationToken) -> ::windows::core::HRESULT,
270 #[cfg(not(feature = "Foundation"))]
271 IsSupportedChanged: usize,
272 #[cfg(feature = "Foundation")]
273 pub RemoveIsSupportedChanged: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, token: super::super::Foundation::EventRegistrationToken) -> ::windows::core::HRESULT,
274 #[cfg(not(feature = "Foundation"))]
275 RemoveIsSupportedChanged: usize,
276 #[cfg(feature = "Foundation")]
277 pub Docked: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, handler: *mut ::core::ffi::c_void, result__: *mut super::super::Foundation::EventRegistrationToken) -> ::windows::core::HRESULT,
278 #[cfg(not(feature = "Foundation"))]
279 Docked: usize,
280 #[cfg(feature = "Foundation")]
281 pub RemoveDocked: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, token: super::super::Foundation::EventRegistrationToken) -> ::windows::core::HRESULT,
282 #[cfg(not(feature = "Foundation"))]
283 RemoveDocked: usize,
284 #[cfg(feature = "Foundation")]
285 pub Undocked: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, handler: *mut ::core::ffi::c_void, result__: *mut super::super::Foundation::EventRegistrationToken) -> ::windows::core::HRESULT,
286 #[cfg(not(feature = "Foundation"))]
287 Undocked: usize,
288 #[cfg(feature = "Foundation")]
289 pub RemoveUndocked: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, token: super::super::Foundation::EventRegistrationToken) -> ::windows::core::HRESULT,
290 #[cfg(not(feature = "Foundation"))]
291 RemoveUndocked: usize,
292 }
293 #[doc(hidden)]
294 #[repr(transparent)]
295 pub struct IPenDockListenerStatics(::windows::core::IUnknown);
296 unsafe impl ::windows::core::Interface for IPenDockListenerStatics {
297 type Vtable = IPenDockListenerStatics_Vtbl;
298 }
299 impl ::core::clone::Clone for IPenDockListenerStatics {
300 fn clone(&self) -> Self {
301 Self(self.0.clone())
302 }
303 }
304 unsafe impl ::windows::core::ComInterface for IPenDockListenerStatics {
305 const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xcab75e9a_0016_5c72_969e_a97e11992a93);
306 }
307 #[repr(C)]
308 #[doc(hidden)]
309 pub struct IPenDockListenerStatics_Vtbl {
310 pub base__: ::windows::core::IInspectable_Vtbl,
311 pub GetDefault: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT,
312 }
313 #[doc(hidden)]
314 #[repr(transparent)]
315 pub struct IPenDockedEventArgs(::windows::core::IUnknown);
316 unsafe impl ::windows::core::Interface for IPenDockedEventArgs {
317 type Vtable = IPenDockedEventArgs_Vtbl;
318 }
319 impl ::core::clone::Clone for IPenDockedEventArgs {
320 fn clone(&self) -> Self {
321 Self(self.0.clone())
322 }
323 }
324 unsafe impl ::windows::core::ComInterface for IPenDockedEventArgs {
325 const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xfd4277c6_ca63_5d4e_9ed3_a28a54521c8c);
326 }
327 #[repr(C)]
328 #[doc(hidden)]
329 pub struct IPenDockedEventArgs_Vtbl {
330 pub base__: ::windows::core::IInspectable_Vtbl,
331 }
332 #[doc(hidden)]
333 #[repr(transparent)]
334 pub struct IPenTailButtonClickedEventArgs(::windows::core::IUnknown);
335 unsafe impl ::windows::core::Interface for IPenTailButtonClickedEventArgs {
336 type Vtable = IPenTailButtonClickedEventArgs_Vtbl;
337 }
338 impl ::core::clone::Clone for IPenTailButtonClickedEventArgs {
339 fn clone(&self) -> Self {
340 Self(self.0.clone())
341 }
342 }
343 unsafe impl ::windows::core::ComInterface for IPenTailButtonClickedEventArgs {
344 const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x5d2fb7b6_6ad3_5d3e_ab29_05ea2410e390);
345 }
346 #[repr(C)]
347 #[doc(hidden)]
348 pub struct IPenTailButtonClickedEventArgs_Vtbl {
349 pub base__: ::windows::core::IInspectable_Vtbl,
350 }
351 #[doc(hidden)]
352 #[repr(transparent)]
353 pub struct IPenTailButtonDoubleClickedEventArgs(::windows::core::IUnknown);
354 unsafe impl ::windows::core::Interface for IPenTailButtonDoubleClickedEventArgs {
355 type Vtable = IPenTailButtonDoubleClickedEventArgs_Vtbl;
356 }
357 impl ::core::clone::Clone for IPenTailButtonDoubleClickedEventArgs {
358 fn clone(&self) -> Self {
359 Self(self.0.clone())
360 }
361 }
362 unsafe impl ::windows::core::ComInterface for IPenTailButtonDoubleClickedEventArgs {
363 const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x846321a2_618a_5478_b04c_b358231da4a7);
364 }
365 #[repr(C)]
366 #[doc(hidden)]
367 pub struct IPenTailButtonDoubleClickedEventArgs_Vtbl {
368 pub base__: ::windows::core::IInspectable_Vtbl,
369 }
370 #[doc(hidden)]
371 #[repr(transparent)]
372 pub struct IPenTailButtonLongPressedEventArgs(::windows::core::IUnknown);
373 unsafe impl ::windows::core::Interface for IPenTailButtonLongPressedEventArgs {
374 type Vtable = IPenTailButtonLongPressedEventArgs_Vtbl;
375 }
376 impl ::core::clone::Clone for IPenTailButtonLongPressedEventArgs {
377 fn clone(&self) -> Self {
378 Self(self.0.clone())
379 }
380 }
381 unsafe impl ::windows::core::ComInterface for IPenTailButtonLongPressedEventArgs {
382 const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xf37c606e_c60a_5f42_b818_a53112406c13);
383 }
384 #[repr(C)]
385 #[doc(hidden)]
386 pub struct IPenTailButtonLongPressedEventArgs_Vtbl {
387 pub base__: ::windows::core::IInspectable_Vtbl,
388 }
389 #[doc(hidden)]
390 #[repr(transparent)]
391 pub struct IPenUndockedEventArgs(::windows::core::IUnknown);
392 unsafe impl ::windows::core::Interface for IPenUndockedEventArgs {
393 type Vtable = IPenUndockedEventArgs_Vtbl;
394 }
395 impl ::core::clone::Clone for IPenUndockedEventArgs {
396 fn clone(&self) -> Self {
397 Self(self.0.clone())
398 }
399 }
400 unsafe impl ::windows::core::ComInterface for IPenUndockedEventArgs {
401 const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xccd09150_261b_59e6_a5d4_c1964cd03feb);
402 }
403 #[repr(C)]
404 #[doc(hidden)]
405 pub struct IPenUndockedEventArgs_Vtbl {
406 pub base__: ::windows::core::IInspectable_Vtbl,
407 }
408 #[doc(hidden)]
409 #[repr(transparent)]
410 pub struct IPointerDevice(::windows::core::IUnknown);
411 unsafe impl ::windows::core::Interface for IPointerDevice {
412 type Vtable = IPointerDevice_Vtbl;
413 }
414 impl ::core::clone::Clone for IPointerDevice {
415 fn clone(&self) -> Self {
416 Self(self.0.clone())
417 }
418 }
419 unsafe impl ::windows::core::ComInterface for IPointerDevice {
420 const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x93c9bafc_ebcb_467e_82c6_276feae36b5a);
421 }
422 #[repr(C)]
423 #[doc(hidden)]
424 pub struct IPointerDevice_Vtbl {
425 pub base__: ::windows::core::IInspectable_Vtbl,
426 pub PointerDeviceType: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut PointerDeviceType) -> ::windows::core::HRESULT,
427 pub IsIntegrated: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut bool) -> ::windows::core::HRESULT,
428 pub MaxContacts: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut u32) -> ::windows::core::HRESULT,
429 #[cfg(feature = "Foundation")]
430 pub PhysicalDeviceRect: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut super::super::Foundation::Rect) -> ::windows::core::HRESULT,
431 #[cfg(not(feature = "Foundation"))]
432 PhysicalDeviceRect: usize,
433 #[cfg(feature = "Foundation")]
434 pub ScreenRect: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut super::super::Foundation::Rect) -> ::windows::core::HRESULT,
435 #[cfg(not(feature = "Foundation"))]
436 ScreenRect: usize,
437 #[cfg(feature = "Foundation_Collections")]
438 pub SupportedUsages: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT,
439 #[cfg(not(feature = "Foundation_Collections"))]
440 SupportedUsages: usize,
441 }
442 #[doc(hidden)]
443 #[repr(transparent)]
444 pub struct IPointerDevice2(::windows::core::IUnknown);
445 unsafe impl ::windows::core::Interface for IPointerDevice2 {
446 type Vtable = IPointerDevice2_Vtbl;
447 }
448 impl ::core::clone::Clone for IPointerDevice2 {
449 fn clone(&self) -> Self {
450 Self(self.0.clone())
451 }
452 }
453 unsafe impl ::windows::core::ComInterface for IPointerDevice2 {
454 const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xf8a6d2a0_c484_489f_ae3e_30d2ee1ffd3e);
455 }
456 #[repr(C)]
457 #[doc(hidden)]
458 pub struct IPointerDevice2_Vtbl {
459 pub base__: ::windows::core::IInspectable_Vtbl,
460 pub MaxPointersWithZDistance: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut u32) -> ::windows::core::HRESULT,
461 }
462 #[doc(hidden)]
463 #[repr(transparent)]
464 pub struct IPointerDeviceStatics(::windows::core::IUnknown);
465 unsafe impl ::windows::core::Interface for IPointerDeviceStatics {
466 type Vtable = IPointerDeviceStatics_Vtbl;
467 }
468 impl ::core::clone::Clone for IPointerDeviceStatics {
469 fn clone(&self) -> Self {
470 Self(self.0.clone())
471 }
472 }
473 unsafe impl ::windows::core::ComInterface for IPointerDeviceStatics {
474 const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xd8b89aa1_d1c6_416e_bd8d_5790914dc563);
475 }
476 #[repr(C)]
477 #[doc(hidden)]
478 pub struct IPointerDeviceStatics_Vtbl {
479 pub base__: ::windows::core::IInspectable_Vtbl,
480 pub GetPointerDevice: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, pointerid: u32, result__: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT,
481 #[cfg(feature = "Foundation_Collections")]
482 pub GetPointerDevices: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT,
483 #[cfg(not(feature = "Foundation_Collections"))]
484 GetPointerDevices: usize,
485 }
486 #[doc(hidden)]
487 #[repr(transparent)]
488 pub struct ITouchCapabilities(::windows::core::IUnknown);
489 unsafe impl ::windows::core::Interface for ITouchCapabilities {
490 type Vtable = ITouchCapabilities_Vtbl;
491 }
492 impl ::core::clone::Clone for ITouchCapabilities {
493 fn clone(&self) -> Self {
494 Self(self.0.clone())
495 }
496 }
497 unsafe impl ::windows::core::ComInterface for ITouchCapabilities {
498 const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x20dd55f9_13f1_46c8_9285_2c05fa3eda6f);
499 }
500 #[repr(C)]
501 #[doc(hidden)]
502 pub struct ITouchCapabilities_Vtbl {
503 pub base__: ::windows::core::IInspectable_Vtbl,
504 pub TouchPresent: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut i32) -> ::windows::core::HRESULT,
505 pub Contacts: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut u32) -> ::windows::core::HRESULT,
506 }
507 #[doc = "*Required features: `\"Devices_Input\"`*"]
508 #[repr(transparent)]
509 pub struct KeyboardCapabilities(::windows::core::IUnknown);
510 impl KeyboardCapabilities {
511 pub fn new() -> ::windows::core::Result<Self> {
512 Self::IActivationFactory(|f| f.ActivateInstance::<Self>())
513 }
514 fn IActivationFactory<R, F: FnOnce(&::windows::imp::IGenericFactory) -> ::windows::core::Result<R>>(callback: F) -> ::windows::core::Result<R> {
515 static SHARED: ::windows::imp::FactoryCache<KeyboardCapabilities, ::windows::imp::IGenericFactory> = ::windows::imp::FactoryCache::new();
516 SHARED.call(callback)
517 }
518 pub fn KeyboardPresent(&self) -> ::windows::core::Result<i32> {
519 let this = self;
520 unsafe {
521 let mut result__ = ::windows::core::zeroed::<i32>();
522 (::windows::core::Interface::vtable(this).KeyboardPresent)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
523 }
524 }
525 }
526 impl ::core::cmp::PartialEq for KeyboardCapabilities {
527 fn eq(&self, other: &Self) -> bool {
528 self.0 == other.0
529 }
530 }
531 impl ::core::cmp::Eq for KeyboardCapabilities {}
532 impl ::core::fmt::Debug for KeyboardCapabilities {
533 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
534 f.debug_tuple("KeyboardCapabilities").field(&self.0).finish()
535 }
536 }
537 impl ::windows::core::RuntimeType for KeyboardCapabilities {
538 const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"rc(Windows.Devices.Input.KeyboardCapabilities;{3a3f9b56-6798-4bbc-833e-0f34b17c65ff})");
539 }
540 impl ::core::clone::Clone for KeyboardCapabilities {
541 fn clone(&self) -> Self {
542 Self(self.0.clone())
543 }
544 }
545 unsafe impl ::windows::core::Interface for KeyboardCapabilities {
546 type Vtable = IKeyboardCapabilities_Vtbl;
547 }
548 unsafe impl ::windows::core::ComInterface for KeyboardCapabilities {
549 const IID: ::windows::core::GUID = <IKeyboardCapabilities as ::windows::core::ComInterface>::IID;
550 }
551 impl ::windows::core::RuntimeName for KeyboardCapabilities {
552 const NAME: &'static str = "Windows.Devices.Input.KeyboardCapabilities";
553 }
554 ::windows::imp::interface_hierarchy!(KeyboardCapabilities, ::windows::core::IUnknown, ::windows::core::IInspectable);
555 unsafe impl ::core::marker::Send for KeyboardCapabilities {}
556 unsafe impl ::core::marker::Sync for KeyboardCapabilities {}
557 #[doc = "*Required features: `\"Devices_Input\"`*"]
558 #[repr(transparent)]
559 pub struct MouseCapabilities(::windows::core::IUnknown);
560 impl MouseCapabilities {
561 pub fn new() -> ::windows::core::Result<Self> {
562 Self::IActivationFactory(|f| f.ActivateInstance::<Self>())
563 }
564 fn IActivationFactory<R, F: FnOnce(&::windows::imp::IGenericFactory) -> ::windows::core::Result<R>>(callback: F) -> ::windows::core::Result<R> {
565 static SHARED: ::windows::imp::FactoryCache<MouseCapabilities, ::windows::imp::IGenericFactory> = ::windows::imp::FactoryCache::new();
566 SHARED.call(callback)
567 }
568 pub fn MousePresent(&self) -> ::windows::core::Result<i32> {
569 let this = self;
570 unsafe {
571 let mut result__ = ::windows::core::zeroed::<i32>();
572 (::windows::core::Interface::vtable(this).MousePresent)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
573 }
574 }
575 pub fn VerticalWheelPresent(&self) -> ::windows::core::Result<i32> {
576 let this = self;
577 unsafe {
578 let mut result__ = ::windows::core::zeroed::<i32>();
579 (::windows::core::Interface::vtable(this).VerticalWheelPresent)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
580 }
581 }
582 pub fn HorizontalWheelPresent(&self) -> ::windows::core::Result<i32> {
583 let this = self;
584 unsafe {
585 let mut result__ = ::windows::core::zeroed::<i32>();
586 (::windows::core::Interface::vtable(this).HorizontalWheelPresent)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
587 }
588 }
589 pub fn SwapButtons(&self) -> ::windows::core::Result<i32> {
590 let this = self;
591 unsafe {
592 let mut result__ = ::windows::core::zeroed::<i32>();
593 (::windows::core::Interface::vtable(this).SwapButtons)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
594 }
595 }
596 pub fn NumberOfButtons(&self) -> ::windows::core::Result<u32> {
597 let this = self;
598 unsafe {
599 let mut result__ = ::windows::core::zeroed::<u32>();
600 (::windows::core::Interface::vtable(this).NumberOfButtons)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
601 }
602 }
603 }
604 impl ::core::cmp::PartialEq for MouseCapabilities {
605 fn eq(&self, other: &Self) -> bool {
606 self.0 == other.0
607 }
608 }
609 impl ::core::cmp::Eq for MouseCapabilities {}
610 impl ::core::fmt::Debug for MouseCapabilities {
611 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
612 f.debug_tuple("MouseCapabilities").field(&self.0).finish()
613 }
614 }
615 impl ::windows::core::RuntimeType for MouseCapabilities {
616 const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"rc(Windows.Devices.Input.MouseCapabilities;{bca5e023-7dd9-4b6b-9a92-55d43cb38f73})");
617 }
618 impl ::core::clone::Clone for MouseCapabilities {
619 fn clone(&self) -> Self {
620 Self(self.0.clone())
621 }
622 }
623 unsafe impl ::windows::core::Interface for MouseCapabilities {
624 type Vtable = IMouseCapabilities_Vtbl;
625 }
626 unsafe impl ::windows::core::ComInterface for MouseCapabilities {
627 const IID: ::windows::core::GUID = <IMouseCapabilities as ::windows::core::ComInterface>::IID;
628 }
629 impl ::windows::core::RuntimeName for MouseCapabilities {
630 const NAME: &'static str = "Windows.Devices.Input.MouseCapabilities";
631 }
632 ::windows::imp::interface_hierarchy!(MouseCapabilities, ::windows::core::IUnknown, ::windows::core::IInspectable);
633 unsafe impl ::core::marker::Send for MouseCapabilities {}
634 unsafe impl ::core::marker::Sync for MouseCapabilities {}
635 #[doc = "*Required features: `\"Devices_Input\"`*"]
636 #[repr(transparent)]
637 pub struct MouseDevice(::windows::core::IUnknown);
638 impl MouseDevice {
639 #[doc = "*Required features: `\"Foundation\"`*"]
640 #[cfg(feature = "Foundation")]
641 pub fn MouseMoved(&self, handler: &super::super::Foundation::TypedEventHandler<MouseDevice, MouseEventArgs>) -> ::windows::core::Result<super::super::Foundation::EventRegistrationToken> {
642 let this = self;
643 unsafe {
644 let mut result__ = ::windows::core::zeroed::<super::super::Foundation::EventRegistrationToken>();
645 (::windows::core::Interface::vtable(this).MouseMoved)(::windows::core::Interface::as_raw(this), ::core::mem::transmute_copy(handler), &mut result__).from_abi(result__)
646 }
647 }
648 #[doc = "*Required features: `\"Foundation\"`*"]
649 #[cfg(feature = "Foundation")]
650 pub fn RemoveMouseMoved(&self, cookie: super::super::Foundation::EventRegistrationToken) -> ::windows::core::Result<()> {
651 let this = self;
652 unsafe { (::windows::core::Interface::vtable(this).RemoveMouseMoved)(::windows::core::Interface::as_raw(this), cookie).ok() }
653 }
654 pub fn GetForCurrentView() -> ::windows::core::Result<MouseDevice> {
655 Self::IMouseDeviceStatics(|this| unsafe {
656 let mut result__ = ::windows::core::zeroed::<MouseDevice>();
657 (::windows::core::Interface::vtable(this).GetForCurrentView)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
658 })
659 }
660 #[doc(hidden)]
661 pub fn IMouseDeviceStatics<R, F: FnOnce(&IMouseDeviceStatics) -> ::windows::core::Result<R>>(callback: F) -> ::windows::core::Result<R> {
662 static SHARED: ::windows::imp::FactoryCache<MouseDevice, IMouseDeviceStatics> = ::windows::imp::FactoryCache::new();
663 SHARED.call(callback)
664 }
665 }
666 impl ::core::cmp::PartialEq for MouseDevice {
667 fn eq(&self, other: &Self) -> bool {
668 self.0 == other.0
669 }
670 }
671 impl ::core::cmp::Eq for MouseDevice {}
672 impl ::core::fmt::Debug for MouseDevice {
673 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
674 f.debug_tuple("MouseDevice").field(&self.0).finish()
675 }
676 }
677 impl ::windows::core::RuntimeType for MouseDevice {
678 const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"rc(Windows.Devices.Input.MouseDevice;{88edf458-f2c8-49f4-be1f-c256b388bc11})");
679 }
680 impl ::core::clone::Clone for MouseDevice {
681 fn clone(&self) -> Self {
682 Self(self.0.clone())
683 }
684 }
685 unsafe impl ::windows::core::Interface for MouseDevice {
686 type Vtable = IMouseDevice_Vtbl;
687 }
688 unsafe impl ::windows::core::ComInterface for MouseDevice {
689 const IID: ::windows::core::GUID = <IMouseDevice as ::windows::core::ComInterface>::IID;
690 }
691 impl ::windows::core::RuntimeName for MouseDevice {
692 const NAME: &'static str = "Windows.Devices.Input.MouseDevice";
693 }
694 ::windows::imp::interface_hierarchy!(MouseDevice, ::windows::core::IUnknown, ::windows::core::IInspectable);
695 #[doc = "*Required features: `\"Devices_Input\"`*"]
696 #[repr(transparent)]
697 pub struct MouseEventArgs(::windows::core::IUnknown);
698 impl MouseEventArgs {
699 pub fn MouseDelta(&self) -> ::windows::core::Result<MouseDelta> {
700 let this = self;
701 unsafe {
702 let mut result__ = ::windows::core::zeroed::<MouseDelta>();
703 (::windows::core::Interface::vtable(this).MouseDelta)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
704 }
705 }
706 }
707 impl ::core::cmp::PartialEq for MouseEventArgs {
708 fn eq(&self, other: &Self) -> bool {
709 self.0 == other.0
710 }
711 }
712 impl ::core::cmp::Eq for MouseEventArgs {}
713 impl ::core::fmt::Debug for MouseEventArgs {
714 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
715 f.debug_tuple("MouseEventArgs").field(&self.0).finish()
716 }
717 }
718 impl ::windows::core::RuntimeType for MouseEventArgs {
719 const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"rc(Windows.Devices.Input.MouseEventArgs;{f625aa5d-2354-4cc7-9230-96941c969fde})");
720 }
721 impl ::core::clone::Clone for MouseEventArgs {
722 fn clone(&self) -> Self {
723 Self(self.0.clone())
724 }
725 }
726 unsafe impl ::windows::core::Interface for MouseEventArgs {
727 type Vtable = IMouseEventArgs_Vtbl;
728 }
729 unsafe impl ::windows::core::ComInterface for MouseEventArgs {
730 const IID: ::windows::core::GUID = <IMouseEventArgs as ::windows::core::ComInterface>::IID;
731 }
732 impl ::windows::core::RuntimeName for MouseEventArgs {
733 const NAME: &'static str = "Windows.Devices.Input.MouseEventArgs";
734 }
735 ::windows::imp::interface_hierarchy!(MouseEventArgs, ::windows::core::IUnknown, ::windows::core::IInspectable);
736 #[doc = "*Required features: `\"Devices_Input\"`*"]
737 #[repr(transparent)]
738 pub struct PenButtonListener(::windows::core::IUnknown);
739 impl PenButtonListener {
740 pub fn IsSupported(&self) -> ::windows::core::Result<bool> {
741 let this = self;
742 unsafe {
743 let mut result__ = ::windows::core::zeroed::<bool>();
744 (::windows::core::Interface::vtable(this).IsSupported)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
745 }
746 }
747 #[doc = "*Required features: `\"Foundation\"`*"]
748 #[cfg(feature = "Foundation")]
749 pub fn IsSupportedChanged(&self, handler: &super::super::Foundation::TypedEventHandler<PenButtonListener, ::windows::core::IInspectable>) -> ::windows::core::Result<super::super::Foundation::EventRegistrationToken> {
750 let this = self;
751 unsafe {
752 let mut result__ = ::windows::core::zeroed::<super::super::Foundation::EventRegistrationToken>();
753 (::windows::core::Interface::vtable(this).IsSupportedChanged)(::windows::core::Interface::as_raw(this), ::core::mem::transmute_copy(handler), &mut result__).from_abi(result__)
754 }
755 }
756 #[doc = "*Required features: `\"Foundation\"`*"]
757 #[cfg(feature = "Foundation")]
758 pub fn RemoveIsSupportedChanged(&self, token: super::super::Foundation::EventRegistrationToken) -> ::windows::core::Result<()> {
759 let this = self;
760 unsafe { (::windows::core::Interface::vtable(this).RemoveIsSupportedChanged)(::windows::core::Interface::as_raw(this), token).ok() }
761 }
762 #[doc = "*Required features: `\"Foundation\"`*"]
763 #[cfg(feature = "Foundation")]
764 pub fn TailButtonClicked(&self, handler: &super::super::Foundation::TypedEventHandler<PenButtonListener, PenTailButtonClickedEventArgs>) -> ::windows::core::Result<super::super::Foundation::EventRegistrationToken> {
765 let this = self;
766 unsafe {
767 let mut result__ = ::windows::core::zeroed::<super::super::Foundation::EventRegistrationToken>();
768 (::windows::core::Interface::vtable(this).TailButtonClicked)(::windows::core::Interface::as_raw(this), ::core::mem::transmute_copy(handler), &mut result__).from_abi(result__)
769 }
770 }
771 #[doc = "*Required features: `\"Foundation\"`*"]
772 #[cfg(feature = "Foundation")]
773 pub fn RemoveTailButtonClicked(&self, token: super::super::Foundation::EventRegistrationToken) -> ::windows::core::Result<()> {
774 let this = self;
775 unsafe { (::windows::core::Interface::vtable(this).RemoveTailButtonClicked)(::windows::core::Interface::as_raw(this), token).ok() }
776 }
777 #[doc = "*Required features: `\"Foundation\"`*"]
778 #[cfg(feature = "Foundation")]
779 pub fn TailButtonDoubleClicked(&self, handler: &super::super::Foundation::TypedEventHandler<PenButtonListener, PenTailButtonDoubleClickedEventArgs>) -> ::windows::core::Result<super::super::Foundation::EventRegistrationToken> {
780 let this = self;
781 unsafe {
782 let mut result__ = ::windows::core::zeroed::<super::super::Foundation::EventRegistrationToken>();
783 (::windows::core::Interface::vtable(this).TailButtonDoubleClicked)(::windows::core::Interface::as_raw(this), ::core::mem::transmute_copy(handler), &mut result__).from_abi(result__)
784 }
785 }
786 #[doc = "*Required features: `\"Foundation\"`*"]
787 #[cfg(feature = "Foundation")]
788 pub fn RemoveTailButtonDoubleClicked(&self, token: super::super::Foundation::EventRegistrationToken) -> ::windows::core::Result<()> {
789 let this = self;
790 unsafe { (::windows::core::Interface::vtable(this).RemoveTailButtonDoubleClicked)(::windows::core::Interface::as_raw(this), token).ok() }
791 }
792 #[doc = "*Required features: `\"Foundation\"`*"]
793 #[cfg(feature = "Foundation")]
794 pub fn TailButtonLongPressed(&self, handler: &super::super::Foundation::TypedEventHandler<PenButtonListener, PenTailButtonLongPressedEventArgs>) -> ::windows::core::Result<super::super::Foundation::EventRegistrationToken> {
795 let this = self;
796 unsafe {
797 let mut result__ = ::windows::core::zeroed::<super::super::Foundation::EventRegistrationToken>();
798 (::windows::core::Interface::vtable(this).TailButtonLongPressed)(::windows::core::Interface::as_raw(this), ::core::mem::transmute_copy(handler), &mut result__).from_abi(result__)
799 }
800 }
801 #[doc = "*Required features: `\"Foundation\"`*"]
802 #[cfg(feature = "Foundation")]
803 pub fn RemoveTailButtonLongPressed(&self, token: super::super::Foundation::EventRegistrationToken) -> ::windows::core::Result<()> {
804 let this = self;
805 unsafe { (::windows::core::Interface::vtable(this).RemoveTailButtonLongPressed)(::windows::core::Interface::as_raw(this), token).ok() }
806 }
807 pub fn GetDefault() -> ::windows::core::Result<PenButtonListener> {
808 Self::IPenButtonListenerStatics(|this| unsafe {
809 let mut result__ = ::windows::core::zeroed::<PenButtonListener>();
810 (::windows::core::Interface::vtable(this).GetDefault)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
811 })
812 }
813 #[doc(hidden)]
814 pub fn IPenButtonListenerStatics<R, F: FnOnce(&IPenButtonListenerStatics) -> ::windows::core::Result<R>>(callback: F) -> ::windows::core::Result<R> {
815 static SHARED: ::windows::imp::FactoryCache<PenButtonListener, IPenButtonListenerStatics> = ::windows::imp::FactoryCache::new();
816 SHARED.call(callback)
817 }
818 }
819 impl ::core::cmp::PartialEq for PenButtonListener {
820 fn eq(&self, other: &Self) -> bool {
821 self.0 == other.0
822 }
823 }
824 impl ::core::cmp::Eq for PenButtonListener {}
825 impl ::core::fmt::Debug for PenButtonListener {
826 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
827 f.debug_tuple("PenButtonListener").field(&self.0).finish()
828 }
829 }
830 impl ::windows::core::RuntimeType for PenButtonListener {
831 const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"rc(Windows.Devices.Input.PenButtonListener;{8245c376-1ee3-53f7-b1f7-8334a16f2815})");
832 }
833 impl ::core::clone::Clone for PenButtonListener {
834 fn clone(&self) -> Self {
835 Self(self.0.clone())
836 }
837 }
838 unsafe impl ::windows::core::Interface for PenButtonListener {
839 type Vtable = IPenButtonListener_Vtbl;
840 }
841 unsafe impl ::windows::core::ComInterface for PenButtonListener {
842 const IID: ::windows::core::GUID = <IPenButtonListener as ::windows::core::ComInterface>::IID;
843 }
844 impl ::windows::core::RuntimeName for PenButtonListener {
845 const NAME: &'static str = "Windows.Devices.Input.PenButtonListener";
846 }
847 ::windows::imp::interface_hierarchy!(PenButtonListener, ::windows::core::IUnknown, ::windows::core::IInspectable);
848 unsafe impl ::core::marker::Send for PenButtonListener {}
849 unsafe impl ::core::marker::Sync for PenButtonListener {}
850 #[doc = "*Required features: `\"Devices_Input\"`*"]
851 #[repr(transparent)]
852 pub struct PenDevice(::windows::core::IUnknown);
853 impl PenDevice {
854 pub fn PenId(&self) -> ::windows::core::Result<::windows::core::GUID> {
855 let this = self;
856 unsafe {
857 let mut result__ = ::windows::core::zeroed::<::windows::core::GUID>();
858 (::windows::core::Interface::vtable(this).PenId)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
859 }
860 }
861 #[doc = "*Required features: `\"Devices_Haptics\"`*"]
862 #[cfg(feature = "Devices_Haptics")]
863 pub fn SimpleHapticsController(&self) -> ::windows::core::Result<super::Haptics::SimpleHapticsController> {
864 let this = &::windows::core::ComInterface::cast::<IPenDevice2>(self)?;
865 unsafe {
866 let mut result__ = ::windows::core::zeroed::<super::Haptics::SimpleHapticsController>();
867 (::windows::core::Interface::vtable(this).SimpleHapticsController)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
868 }
869 }
870 pub fn GetFromPointerId(pointerid: u32) -> ::windows::core::Result<PenDevice> {
871 Self::IPenDeviceStatics(|this| unsafe {
872 let mut result__ = ::windows::core::zeroed::<PenDevice>();
873 (::windows::core::Interface::vtable(this).GetFromPointerId)(::windows::core::Interface::as_raw(this), pointerid, &mut result__).from_abi(result__)
874 })
875 }
876 #[doc(hidden)]
877 pub fn IPenDeviceStatics<R, F: FnOnce(&IPenDeviceStatics) -> ::windows::core::Result<R>>(callback: F) -> ::windows::core::Result<R> {
878 static SHARED: ::windows::imp::FactoryCache<PenDevice, IPenDeviceStatics> = ::windows::imp::FactoryCache::new();
879 SHARED.call(callback)
880 }
881 }
882 impl ::core::cmp::PartialEq for PenDevice {
883 fn eq(&self, other: &Self) -> bool {
884 self.0 == other.0
885 }
886 }
887 impl ::core::cmp::Eq for PenDevice {}
888 impl ::core::fmt::Debug for PenDevice {
889 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
890 f.debug_tuple("PenDevice").field(&self.0).finish()
891 }
892 }
893 impl ::windows::core::RuntimeType for PenDevice {
894 const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"rc(Windows.Devices.Input.PenDevice;{31856eba-a738-5a8c-b8f6-f97ef68d18ef})");
895 }
896 impl ::core::clone::Clone for PenDevice {
897 fn clone(&self) -> Self {
898 Self(self.0.clone())
899 }
900 }
901 unsafe impl ::windows::core::Interface for PenDevice {
902 type Vtable = IPenDevice_Vtbl;
903 }
904 unsafe impl ::windows::core::ComInterface for PenDevice {
905 const IID: ::windows::core::GUID = <IPenDevice as ::windows::core::ComInterface>::IID;
906 }
907 impl ::windows::core::RuntimeName for PenDevice {
908 const NAME: &'static str = "Windows.Devices.Input.PenDevice";
909 }
910 ::windows::imp::interface_hierarchy!(PenDevice, ::windows::core::IUnknown, ::windows::core::IInspectable);
911 unsafe impl ::core::marker::Send for PenDevice {}
912 unsafe impl ::core::marker::Sync for PenDevice {}
913 #[doc = "*Required features: `\"Devices_Input\"`*"]
914 #[repr(transparent)]
915 pub struct PenDockListener(::windows::core::IUnknown);
916 impl PenDockListener {
917 pub fn IsSupported(&self) -> ::windows::core::Result<bool> {
918 let this = self;
919 unsafe {
920 let mut result__ = ::windows::core::zeroed::<bool>();
921 (::windows::core::Interface::vtable(this).IsSupported)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
922 }
923 }
924 #[doc = "*Required features: `\"Foundation\"`*"]
925 #[cfg(feature = "Foundation")]
926 pub fn IsSupportedChanged(&self, handler: &super::super::Foundation::TypedEventHandler<PenDockListener, ::windows::core::IInspectable>) -> ::windows::core::Result<super::super::Foundation::EventRegistrationToken> {
927 let this = self;
928 unsafe {
929 let mut result__ = ::windows::core::zeroed::<super::super::Foundation::EventRegistrationToken>();
930 (::windows::core::Interface::vtable(this).IsSupportedChanged)(::windows::core::Interface::as_raw(this), ::core::mem::transmute_copy(handler), &mut result__).from_abi(result__)
931 }
932 }
933 #[doc = "*Required features: `\"Foundation\"`*"]
934 #[cfg(feature = "Foundation")]
935 pub fn RemoveIsSupportedChanged(&self, token: super::super::Foundation::EventRegistrationToken) -> ::windows::core::Result<()> {
936 let this = self;
937 unsafe { (::windows::core::Interface::vtable(this).RemoveIsSupportedChanged)(::windows::core::Interface::as_raw(this), token).ok() }
938 }
939 #[doc = "*Required features: `\"Foundation\"`*"]
940 #[cfg(feature = "Foundation")]
941 pub fn Docked(&self, handler: &super::super::Foundation::TypedEventHandler<PenDockListener, PenDockedEventArgs>) -> ::windows::core::Result<super::super::Foundation::EventRegistrationToken> {
942 let this = self;
943 unsafe {
944 let mut result__ = ::windows::core::zeroed::<super::super::Foundation::EventRegistrationToken>();
945 (::windows::core::Interface::vtable(this).Docked)(::windows::core::Interface::as_raw(this), ::core::mem::transmute_copy(handler), &mut result__).from_abi(result__)
946 }
947 }
948 #[doc = "*Required features: `\"Foundation\"`*"]
949 #[cfg(feature = "Foundation")]
950 pub fn RemoveDocked(&self, token: super::super::Foundation::EventRegistrationToken) -> ::windows::core::Result<()> {
951 let this = self;
952 unsafe { (::windows::core::Interface::vtable(this).RemoveDocked)(::windows::core::Interface::as_raw(this), token).ok() }
953 }
954 #[doc = "*Required features: `\"Foundation\"`*"]
955 #[cfg(feature = "Foundation")]
956 pub fn Undocked(&self, handler: &super::super::Foundation::TypedEventHandler<PenDockListener, PenUndockedEventArgs>) -> ::windows::core::Result<super::super::Foundation::EventRegistrationToken> {
957 let this = self;
958 unsafe {
959 let mut result__ = ::windows::core::zeroed::<super::super::Foundation::EventRegistrationToken>();
960 (::windows::core::Interface::vtable(this).Undocked)(::windows::core::Interface::as_raw(this), ::core::mem::transmute_copy(handler), &mut result__).from_abi(result__)
961 }
962 }
963 #[doc = "*Required features: `\"Foundation\"`*"]
964 #[cfg(feature = "Foundation")]
965 pub fn RemoveUndocked(&self, token: super::super::Foundation::EventRegistrationToken) -> ::windows::core::Result<()> {
966 let this = self;
967 unsafe { (::windows::core::Interface::vtable(this).RemoveUndocked)(::windows::core::Interface::as_raw(this), token).ok() }
968 }
969 pub fn GetDefault() -> ::windows::core::Result<PenDockListener> {
970 Self::IPenDockListenerStatics(|this| unsafe {
971 let mut result__ = ::windows::core::zeroed::<PenDockListener>();
972 (::windows::core::Interface::vtable(this).GetDefault)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
973 })
974 }
975 #[doc(hidden)]
976 pub fn IPenDockListenerStatics<R, F: FnOnce(&IPenDockListenerStatics) -> ::windows::core::Result<R>>(callback: F) -> ::windows::core::Result<R> {
977 static SHARED: ::windows::imp::FactoryCache<PenDockListener, IPenDockListenerStatics> = ::windows::imp::FactoryCache::new();
978 SHARED.call(callback)
979 }
980 }
981 impl ::core::cmp::PartialEq for PenDockListener {
982 fn eq(&self, other: &Self) -> bool {
983 self.0 == other.0
984 }
985 }
986 impl ::core::cmp::Eq for PenDockListener {}
987 impl ::core::fmt::Debug for PenDockListener {
988 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
989 f.debug_tuple("PenDockListener").field(&self.0).finish()
990 }
991 }
992 impl ::windows::core::RuntimeType for PenDockListener {
993 const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"rc(Windows.Devices.Input.PenDockListener;{759f4d90-1dc0-55cb-ad18-b9101456f592})");
994 }
995 impl ::core::clone::Clone for PenDockListener {
996 fn clone(&self) -> Self {
997 Self(self.0.clone())
998 }
999 }
1000 unsafe impl ::windows::core::Interface for PenDockListener {
1001 type Vtable = IPenDockListener_Vtbl;
1002 }
1003 unsafe impl ::windows::core::ComInterface for PenDockListener {
1004 const IID: ::windows::core::GUID = <IPenDockListener as ::windows::core::ComInterface>::IID;
1005 }
1006 impl ::windows::core::RuntimeName for PenDockListener {
1007 const NAME: &'static str = "Windows.Devices.Input.PenDockListener";
1008 }
1009 ::windows::imp::interface_hierarchy!(PenDockListener, ::windows::core::IUnknown, ::windows::core::IInspectable);
1010 unsafe impl ::core::marker::Send for PenDockListener {}
1011 unsafe impl ::core::marker::Sync for PenDockListener {}
1012 #[doc = "*Required features: `\"Devices_Input\"`*"]
1013 #[repr(transparent)]
1014 pub struct PenDockedEventArgs(::windows::core::IUnknown);
1015 impl PenDockedEventArgs {}
1016 impl ::core::cmp::PartialEq for PenDockedEventArgs {
1017 fn eq(&self, other: &Self) -> bool {
1018 self.0 == other.0
1019 }
1020 }
1021 impl ::core::cmp::Eq for PenDockedEventArgs {}
1022 impl ::core::fmt::Debug for PenDockedEventArgs {
1023 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
1024 f.debug_tuple("PenDockedEventArgs").field(&self.0).finish()
1025 }
1026 }
1027 impl ::windows::core::RuntimeType for PenDockedEventArgs {
1028 const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"rc(Windows.Devices.Input.PenDockedEventArgs;{fd4277c6-ca63-5d4e-9ed3-a28a54521c8c})");
1029 }
1030 impl ::core::clone::Clone for PenDockedEventArgs {
1031 fn clone(&self) -> Self {
1032 Self(self.0.clone())
1033 }
1034 }
1035 unsafe impl ::windows::core::Interface for PenDockedEventArgs {
1036 type Vtable = IPenDockedEventArgs_Vtbl;
1037 }
1038 unsafe impl ::windows::core::ComInterface for PenDockedEventArgs {
1039 const IID: ::windows::core::GUID = <IPenDockedEventArgs as ::windows::core::ComInterface>::IID;
1040 }
1041 impl ::windows::core::RuntimeName for PenDockedEventArgs {
1042 const NAME: &'static str = "Windows.Devices.Input.PenDockedEventArgs";
1043 }
1044 ::windows::imp::interface_hierarchy!(PenDockedEventArgs, ::windows::core::IUnknown, ::windows::core::IInspectable);
1045 unsafe impl ::core::marker::Send for PenDockedEventArgs {}
1046 unsafe impl ::core::marker::Sync for PenDockedEventArgs {}
1047 #[doc = "*Required features: `\"Devices_Input\"`*"]
1048 #[repr(transparent)]
1049 pub struct PenTailButtonClickedEventArgs(::windows::core::IUnknown);
1050 impl PenTailButtonClickedEventArgs {}
1051 impl ::core::cmp::PartialEq for PenTailButtonClickedEventArgs {
1052 fn eq(&self, other: &Self) -> bool {
1053 self.0 == other.0
1054 }
1055 }
1056 impl ::core::cmp::Eq for PenTailButtonClickedEventArgs {}
1057 impl ::core::fmt::Debug for PenTailButtonClickedEventArgs {
1058 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
1059 f.debug_tuple("PenTailButtonClickedEventArgs").field(&self.0).finish()
1060 }
1061 }
1062 impl ::windows::core::RuntimeType for PenTailButtonClickedEventArgs {
1063 const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"rc(Windows.Devices.Input.PenTailButtonClickedEventArgs;{5d2fb7b6-6ad3-5d3e-ab29-05ea2410e390})");
1064 }
1065 impl ::core::clone::Clone for PenTailButtonClickedEventArgs {
1066 fn clone(&self) -> Self {
1067 Self(self.0.clone())
1068 }
1069 }
1070 unsafe impl ::windows::core::Interface for PenTailButtonClickedEventArgs {
1071 type Vtable = IPenTailButtonClickedEventArgs_Vtbl;
1072 }
1073 unsafe impl ::windows::core::ComInterface for PenTailButtonClickedEventArgs {
1074 const IID: ::windows::core::GUID = <IPenTailButtonClickedEventArgs as ::windows::core::ComInterface>::IID;
1075 }
1076 impl ::windows::core::RuntimeName for PenTailButtonClickedEventArgs {
1077 const NAME: &'static str = "Windows.Devices.Input.PenTailButtonClickedEventArgs";
1078 }
1079 ::windows::imp::interface_hierarchy!(PenTailButtonClickedEventArgs, ::windows::core::IUnknown, ::windows::core::IInspectable);
1080 unsafe impl ::core::marker::Send for PenTailButtonClickedEventArgs {}
1081 unsafe impl ::core::marker::Sync for PenTailButtonClickedEventArgs {}
1082 #[doc = "*Required features: `\"Devices_Input\"`*"]
1083 #[repr(transparent)]
1084 pub struct PenTailButtonDoubleClickedEventArgs(::windows::core::IUnknown);
1085 impl PenTailButtonDoubleClickedEventArgs {}
1086 impl ::core::cmp::PartialEq for PenTailButtonDoubleClickedEventArgs {
1087 fn eq(&self, other: &Self) -> bool {
1088 self.0 == other.0
1089 }
1090 }
1091 impl ::core::cmp::Eq for PenTailButtonDoubleClickedEventArgs {}
1092 impl ::core::fmt::Debug for PenTailButtonDoubleClickedEventArgs {
1093 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
1094 f.debug_tuple("PenTailButtonDoubleClickedEventArgs").field(&self.0).finish()
1095 }
1096 }
1097 impl ::windows::core::RuntimeType for PenTailButtonDoubleClickedEventArgs {
1098 const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"rc(Windows.Devices.Input.PenTailButtonDoubleClickedEventArgs;{846321a2-618a-5478-b04c-b358231da4a7})");
1099 }
1100 impl ::core::clone::Clone for PenTailButtonDoubleClickedEventArgs {
1101 fn clone(&self) -> Self {
1102 Self(self.0.clone())
1103 }
1104 }
1105 unsafe impl ::windows::core::Interface for PenTailButtonDoubleClickedEventArgs {
1106 type Vtable = IPenTailButtonDoubleClickedEventArgs_Vtbl;
1107 }
1108 unsafe impl ::windows::core::ComInterface for PenTailButtonDoubleClickedEventArgs {
1109 const IID: ::windows::core::GUID = <IPenTailButtonDoubleClickedEventArgs as ::windows::core::ComInterface>::IID;
1110 }
1111 impl ::windows::core::RuntimeName for PenTailButtonDoubleClickedEventArgs {
1112 const NAME: &'static str = "Windows.Devices.Input.PenTailButtonDoubleClickedEventArgs";
1113 }
1114 ::windows::imp::interface_hierarchy!(PenTailButtonDoubleClickedEventArgs, ::windows::core::IUnknown, ::windows::core::IInspectable);
1115 unsafe impl ::core::marker::Send for PenTailButtonDoubleClickedEventArgs {}
1116 unsafe impl ::core::marker::Sync for PenTailButtonDoubleClickedEventArgs {}
1117 #[doc = "*Required features: `\"Devices_Input\"`*"]
1118 #[repr(transparent)]
1119 pub struct PenTailButtonLongPressedEventArgs(::windows::core::IUnknown);
1120 impl PenTailButtonLongPressedEventArgs {}
1121 impl ::core::cmp::PartialEq for PenTailButtonLongPressedEventArgs {
1122 fn eq(&self, other: &Self) -> bool {
1123 self.0 == other.0
1124 }
1125 }
1126 impl ::core::cmp::Eq for PenTailButtonLongPressedEventArgs {}
1127 impl ::core::fmt::Debug for PenTailButtonLongPressedEventArgs {
1128 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
1129 f.debug_tuple("PenTailButtonLongPressedEventArgs").field(&self.0).finish()
1130 }
1131 }
1132 impl ::windows::core::RuntimeType for PenTailButtonLongPressedEventArgs {
1133 const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"rc(Windows.Devices.Input.PenTailButtonLongPressedEventArgs;{f37c606e-c60a-5f42-b818-a53112406c13})");
1134 }
1135 impl ::core::clone::Clone for PenTailButtonLongPressedEventArgs {
1136 fn clone(&self) -> Self {
1137 Self(self.0.clone())
1138 }
1139 }
1140 unsafe impl ::windows::core::Interface for PenTailButtonLongPressedEventArgs {
1141 type Vtable = IPenTailButtonLongPressedEventArgs_Vtbl;
1142 }
1143 unsafe impl ::windows::core::ComInterface for PenTailButtonLongPressedEventArgs {
1144 const IID: ::windows::core::GUID = <IPenTailButtonLongPressedEventArgs as ::windows::core::ComInterface>::IID;
1145 }
1146 impl ::windows::core::RuntimeName for PenTailButtonLongPressedEventArgs {
1147 const NAME: &'static str = "Windows.Devices.Input.PenTailButtonLongPressedEventArgs";
1148 }
1149 ::windows::imp::interface_hierarchy!(PenTailButtonLongPressedEventArgs, ::windows::core::IUnknown, ::windows::core::IInspectable);
1150 unsafe impl ::core::marker::Send for PenTailButtonLongPressedEventArgs {}
1151 unsafe impl ::core::marker::Sync for PenTailButtonLongPressedEventArgs {}
1152 #[doc = "*Required features: `\"Devices_Input\"`*"]
1153 #[repr(transparent)]
1154 pub struct PenUndockedEventArgs(::windows::core::IUnknown);
1155 impl PenUndockedEventArgs {}
1156 impl ::core::cmp::PartialEq for PenUndockedEventArgs {
1157 fn eq(&self, other: &Self) -> bool {
1158 self.0 == other.0
1159 }
1160 }
1161 impl ::core::cmp::Eq for PenUndockedEventArgs {}
1162 impl ::core::fmt::Debug for PenUndockedEventArgs {
1163 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
1164 f.debug_tuple("PenUndockedEventArgs").field(&self.0).finish()
1165 }
1166 }
1167 impl ::windows::core::RuntimeType for PenUndockedEventArgs {
1168 const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"rc(Windows.Devices.Input.PenUndockedEventArgs;{ccd09150-261b-59e6-a5d4-c1964cd03feb})");
1169 }
1170 impl ::core::clone::Clone for PenUndockedEventArgs {
1171 fn clone(&self) -> Self {
1172 Self(self.0.clone())
1173 }
1174 }
1175 unsafe impl ::windows::core::Interface for PenUndockedEventArgs {
1176 type Vtable = IPenUndockedEventArgs_Vtbl;
1177 }
1178 unsafe impl ::windows::core::ComInterface for PenUndockedEventArgs {
1179 const IID: ::windows::core::GUID = <IPenUndockedEventArgs as ::windows::core::ComInterface>::IID;
1180 }
1181 impl ::windows::core::RuntimeName for PenUndockedEventArgs {
1182 const NAME: &'static str = "Windows.Devices.Input.PenUndockedEventArgs";
1183 }
1184 ::windows::imp::interface_hierarchy!(PenUndockedEventArgs, ::windows::core::IUnknown, ::windows::core::IInspectable);
1185 unsafe impl ::core::marker::Send for PenUndockedEventArgs {}
1186 unsafe impl ::core::marker::Sync for PenUndockedEventArgs {}
1187 #[doc = "*Required features: `\"Devices_Input\"`*"]
1188 #[repr(transparent)]
1189 pub struct PointerDevice(::windows::core::IUnknown);
1190 impl PointerDevice {
1191 pub fn PointerDeviceType(&self) -> ::windows::core::Result<PointerDeviceType> {
1192 let this = self;
1193 unsafe {
1194 let mut result__ = ::windows::core::zeroed::<PointerDeviceType>();
1195 (::windows::core::Interface::vtable(this).PointerDeviceType)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
1196 }
1197 }
1198 pub fn IsIntegrated(&self) -> ::windows::core::Result<bool> {
1199 let this = self;
1200 unsafe {
1201 let mut result__ = ::windows::core::zeroed::<bool>();
1202 (::windows::core::Interface::vtable(this).IsIntegrated)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
1203 }
1204 }
1205 pub fn MaxContacts(&self) -> ::windows::core::Result<u32> {
1206 let this = self;
1207 unsafe {
1208 let mut result__ = ::windows::core::zeroed::<u32>();
1209 (::windows::core::Interface::vtable(this).MaxContacts)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
1210 }
1211 }
1212 #[doc = "*Required features: `\"Foundation\"`*"]
1213 #[cfg(feature = "Foundation")]
1214 pub fn PhysicalDeviceRect(&self) -> ::windows::core::Result<super::super::Foundation::Rect> {
1215 let this = self;
1216 unsafe {
1217 let mut result__ = ::windows::core::zeroed::<super::super::Foundation::Rect>();
1218 (::windows::core::Interface::vtable(this).PhysicalDeviceRect)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
1219 }
1220 }
1221 #[doc = "*Required features: `\"Foundation\"`*"]
1222 #[cfg(feature = "Foundation")]
1223 pub fn ScreenRect(&self) -> ::windows::core::Result<super::super::Foundation::Rect> {
1224 let this = self;
1225 unsafe {
1226 let mut result__ = ::windows::core::zeroed::<super::super::Foundation::Rect>();
1227 (::windows::core::Interface::vtable(this).ScreenRect)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
1228 }
1229 }
1230 #[doc = "*Required features: `\"Foundation_Collections\"`*"]
1231 #[cfg(feature = "Foundation_Collections")]
1232 pub fn SupportedUsages(&self) -> ::windows::core::Result<super::super::Foundation::Collections::IVectorView<PointerDeviceUsage>> {
1233 let this = self;
1234 unsafe {
1235 let mut result__ = ::windows::core::zeroed::<super::super::Foundation::Collections::IVectorView<PointerDeviceUsage>>();
1236 (::windows::core::Interface::vtable(this).SupportedUsages)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
1237 }
1238 }
1239 pub fn MaxPointersWithZDistance(&self) -> ::windows::core::Result<u32> {
1240 let this = &::windows::core::ComInterface::cast::<IPointerDevice2>(self)?;
1241 unsafe {
1242 let mut result__ = ::windows::core::zeroed::<u32>();
1243 (::windows::core::Interface::vtable(this).MaxPointersWithZDistance)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
1244 }
1245 }
1246 pub fn GetPointerDevice(pointerid: u32) -> ::windows::core::Result<PointerDevice> {
1247 Self::IPointerDeviceStatics(|this| unsafe {
1248 let mut result__ = ::windows::core::zeroed::<PointerDevice>();
1249 (::windows::core::Interface::vtable(this).GetPointerDevice)(::windows::core::Interface::as_raw(this), pointerid, &mut result__).from_abi(result__)
1250 })
1251 }
1252 #[doc = "*Required features: `\"Foundation_Collections\"`*"]
1253 #[cfg(feature = "Foundation_Collections")]
1254 pub fn GetPointerDevices() -> ::windows::core::Result<super::super::Foundation::Collections::IVectorView<PointerDevice>> {
1255 Self::IPointerDeviceStatics(|this| unsafe {
1256 let mut result__ = ::windows::core::zeroed::<super::super::Foundation::Collections::IVectorView<PointerDevice>>();
1257 (::windows::core::Interface::vtable(this).GetPointerDevices)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
1258 })
1259 }
1260 #[doc(hidden)]
1261 pub fn IPointerDeviceStatics<R, F: FnOnce(&IPointerDeviceStatics) -> ::windows::core::Result<R>>(callback: F) -> ::windows::core::Result<R> {
1262 static SHARED: ::windows::imp::FactoryCache<PointerDevice, IPointerDeviceStatics> = ::windows::imp::FactoryCache::new();
1263 SHARED.call(callback)
1264 }
1265 }
1266 impl ::core::cmp::PartialEq for PointerDevice {
1267 fn eq(&self, other: &Self) -> bool {
1268 self.0 == other.0
1269 }
1270 }
1271 impl ::core::cmp::Eq for PointerDevice {}
1272 impl ::core::fmt::Debug for PointerDevice {
1273 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
1274 f.debug_tuple("PointerDevice").field(&self.0).finish()
1275 }
1276 }
1277 impl ::windows::core::RuntimeType for PointerDevice {
1278 const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"rc(Windows.Devices.Input.PointerDevice;{93c9bafc-ebcb-467e-82c6-276feae36b5a})");
1279 }
1280 impl ::core::clone::Clone for PointerDevice {
1281 fn clone(&self) -> Self {
1282 Self(self.0.clone())
1283 }
1284 }
1285 unsafe impl ::windows::core::Interface for PointerDevice {
1286 type Vtable = IPointerDevice_Vtbl;
1287 }
1288 unsafe impl ::windows::core::ComInterface for PointerDevice {
1289 const IID: ::windows::core::GUID = <IPointerDevice as ::windows::core::ComInterface>::IID;
1290 }
1291 impl ::windows::core::RuntimeName for PointerDevice {
1292 const NAME: &'static str = "Windows.Devices.Input.PointerDevice";
1293 }
1294 ::windows::imp::interface_hierarchy!(PointerDevice, ::windows::core::IUnknown, ::windows::core::IInspectable);
1295 #[doc = "*Required features: `\"Devices_Input\"`*"]
1296 #[repr(transparent)]
1297 pub struct TouchCapabilities(::windows::core::IUnknown);
1298 impl TouchCapabilities {
1299 pub fn new() -> ::windows::core::Result<Self> {
1300 Self::IActivationFactory(|f| f.ActivateInstance::<Self>())
1301 }
1302 fn IActivationFactory<R, F: FnOnce(&::windows::imp::IGenericFactory) -> ::windows::core::Result<R>>(callback: F) -> ::windows::core::Result<R> {
1303 static SHARED: ::windows::imp::FactoryCache<TouchCapabilities, ::windows::imp::IGenericFactory> = ::windows::imp::FactoryCache::new();
1304 SHARED.call(callback)
1305 }
1306 pub fn TouchPresent(&self) -> ::windows::core::Result<i32> {
1307 let this = self;
1308 unsafe {
1309 let mut result__ = ::windows::core::zeroed::<i32>();
1310 (::windows::core::Interface::vtable(this).TouchPresent)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
1311 }
1312 }
1313 pub fn Contacts(&self) -> ::windows::core::Result<u32> {
1314 let this = self;
1315 unsafe {
1316 let mut result__ = ::windows::core::zeroed::<u32>();
1317 (::windows::core::Interface::vtable(this).Contacts)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
1318 }
1319 }
1320 }
1321 impl ::core::cmp::PartialEq for TouchCapabilities {
1322 fn eq(&self, other: &Self) -> bool {
1323 self.0 == other.0
1324 }
1325 }
1326 impl ::core::cmp::Eq for TouchCapabilities {}
1327 impl ::core::fmt::Debug for TouchCapabilities {
1328 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
1329 f.debug_tuple("TouchCapabilities").field(&self.0).finish()
1330 }
1331 }
1332 impl ::windows::core::RuntimeType for TouchCapabilities {
1333 const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"rc(Windows.Devices.Input.TouchCapabilities;{20dd55f9-13f1-46c8-9285-2c05fa3eda6f})");
1334 }
1335 impl ::core::clone::Clone for TouchCapabilities {
1336 fn clone(&self) -> Self {
1337 Self(self.0.clone())
1338 }
1339 }
1340 unsafe impl ::windows::core::Interface for TouchCapabilities {
1341 type Vtable = ITouchCapabilities_Vtbl;
1342 }
1343 unsafe impl ::windows::core::ComInterface for TouchCapabilities {
1344 const IID: ::windows::core::GUID = <ITouchCapabilities as ::windows::core::ComInterface>::IID;
1345 }
1346 impl ::windows::core::RuntimeName for TouchCapabilities {
1347 const NAME: &'static str = "Windows.Devices.Input.TouchCapabilities";
1348 }
1349 ::windows::imp::interface_hierarchy!(TouchCapabilities, ::windows::core::IUnknown, ::windows::core::IInspectable);
1350 unsafe impl ::core::marker::Send for TouchCapabilities {}
1351 unsafe impl ::core::marker::Sync for TouchCapabilities {}
1352 #[doc = "*Required features: `\"Devices_Input\"`*"]
1353 #[repr(transparent)]
1354 #[derive(::core::cmp::PartialEq, ::core::cmp::Eq)]
1355 pub struct PointerDeviceType(pub i32);
1356 impl PointerDeviceType {
1357 pub const Touch: Self = Self(0i32);
1358 pub const Pen: Self = Self(1i32);
1359 pub const Mouse: Self = Self(2i32);
1360 }
1361 impl ::core::marker::Copy for PointerDeviceType {}
1362 impl ::core::clone::Clone for PointerDeviceType {
1363 fn clone(&self) -> Self {
1364 *self
1365 }
1366 }
1367 impl ::core::default::Default for PointerDeviceType {
1368 fn default() -> Self {
1369 Self(0)
1370 }
1371 }
1372 impl ::windows::core::TypeKind for PointerDeviceType {
1373 type TypeKind = ::windows::core::CopyType;
1374 }
1375 impl ::core::fmt::Debug for PointerDeviceType {
1376 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
1377 f.debug_tuple("PointerDeviceType").field(&self.0).finish()
1378 }
1379 }
1380 impl ::windows::core::RuntimeType for PointerDeviceType {
1381 const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"enum(Windows.Devices.Input.PointerDeviceType;i4)");
1382 }
1383 #[repr(C)]
1384 #[doc = "*Required features: `\"Devices_Input\"`*"]
1385 pub struct MouseDelta {
1386 pub X: i32,
1387 pub Y: i32,
1388 }
1389 impl ::core::marker::Copy for MouseDelta {}
1390 impl ::core::clone::Clone for MouseDelta {
1391 fn clone(&self) -> Self {
1392 *self
1393 }
1394 }
1395 impl ::core::fmt::Debug for MouseDelta {
1396 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
1397 f.debug_struct("MouseDelta").field("X", &self.X).field("Y", &self.Y).finish()
1398 }
1399 }
1400 impl ::windows::core::TypeKind for MouseDelta {
1401 type TypeKind = ::windows::core::CopyType;
1402 }
1403 impl ::windows::core::RuntimeType for MouseDelta {
1404 const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"struct(Windows.Devices.Input.MouseDelta;i4;i4)");
1405 }
1406 impl ::core::cmp::PartialEq for MouseDelta {
1407 fn eq(&self, other: &Self) -> bool {
1408 self.X == other.X && self.Y == other.Y
1409 }
1410 }
1411 impl ::core::cmp::Eq for MouseDelta {}
1412 impl ::core::default::Default for MouseDelta {
1413 fn default() -> Self {
1414 unsafe { ::core::mem::zeroed() }
1415 }
1416 }
1417 #[repr(C)]
1418 #[doc = "*Required features: `\"Devices_Input\"`*"]
1419 pub struct PointerDeviceUsage {
1420 pub UsagePage: u32,
1421 pub Usage: u32,
1422 pub MinLogical: i32,
1423 pub MaxLogical: i32,
1424 pub MinPhysical: i32,
1425 pub MaxPhysical: i32,
1426 pub Unit: u32,
1427 pub PhysicalMultiplier: f32,
1428 }
1429 impl ::core::marker::Copy for PointerDeviceUsage {}
1430 impl ::core::clone::Clone for PointerDeviceUsage {
1431 fn clone(&self) -> Self {
1432 *self
1433 }
1434 }
1435 impl ::core::fmt::Debug for PointerDeviceUsage {
1436 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
1437 f.debug_struct("PointerDeviceUsage").field("UsagePage", &self.UsagePage).field("Usage", &self.Usage).field("MinLogical", &self.MinLogical).field("MaxLogical", &self.MaxLogical).field("MinPhysical", &self.MinPhysical).field("MaxPhysical", &self.MaxPhysical).field("Unit", &self.Unit).field("PhysicalMultiplier", &self.PhysicalMultiplier).finish()
1438 }
1439 }
1440 impl ::windows::core::TypeKind for PointerDeviceUsage {
1441 type TypeKind = ::windows::core::CopyType;
1442 }
1443 impl ::windows::core::RuntimeType for PointerDeviceUsage {
1444 const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"struct(Windows.Devices.Input.PointerDeviceUsage;u4;u4;i4;i4;i4;i4;u4;f4)");
1445 }
1446 impl ::core::cmp::PartialEq for PointerDeviceUsage {
1447 fn eq(&self, other: &Self) -> bool {
1448 self.UsagePage == other.UsagePage && self.Usage == other.Usage && self.MinLogical == other.MinLogical && self.MaxLogical == other.MaxLogical && self.MinPhysical == other.MinPhysical && self.MaxPhysical == other.MaxPhysical && self.Unit == other.Unit && self.PhysicalMultiplier == other.PhysicalMultiplier
1449 }
1450 }
1451 impl ::core::cmp::Eq for PointerDeviceUsage {}
1452 impl ::core::default::Default for PointerDeviceUsage {
1453 fn default() -> Self {
1454 unsafe { ::core::mem::zeroed() }
1455 }
1456 }
1457 #[cfg(feature = "implement")]
1458 ::core::include!("impl.rs");