]> git.proxmox.com Git - rustc.git/blame - vendor/windows/src/Windows/UI/Input/Preview/Injection/mod.rs
New upstream version 1.70.0+dfsg1
[rustc.git] / vendor / windows / src / Windows / UI / Input / Preview / Injection / mod.rs
CommitLineData
353b0b11
FG
1#[doc(hidden)]
2#[repr(transparent)]
3pub struct IInjectedInputGamepadInfo(::windows::core::IUnknown);
4unsafe impl ::windows::core::Interface for IInjectedInputGamepadInfo {
5 type Vtable = IInjectedInputGamepadInfo_Vtbl;
6}
7impl ::core::clone::Clone for IInjectedInputGamepadInfo {
8 fn clone(&self) -> Self {
9 Self(self.0.clone())
10 }
11}
12unsafe impl ::windows::core::ComInterface for IInjectedInputGamepadInfo {
13 const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x20ae9a3f_df11_4572_a9ab_d75b8a5e48ad);
14}
15#[repr(C)]
16#[doc(hidden)]
17pub struct IInjectedInputGamepadInfo_Vtbl {
18 pub base__: ::windows::core::IInspectable_Vtbl,
19 #[cfg(feature = "Gaming_Input")]
20 pub Buttons: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut super::super::super::super::Gaming::Input::GamepadButtons) -> ::windows::core::HRESULT,
21 #[cfg(not(feature = "Gaming_Input"))]
22 Buttons: usize,
23 #[cfg(feature = "Gaming_Input")]
24 pub SetButtons: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, value: super::super::super::super::Gaming::Input::GamepadButtons) -> ::windows::core::HRESULT,
25 #[cfg(not(feature = "Gaming_Input"))]
26 SetButtons: usize,
27 pub LeftThumbstickX: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut f64) -> ::windows::core::HRESULT,
28 pub SetLeftThumbstickX: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, value: f64) -> ::windows::core::HRESULT,
29 pub LeftThumbstickY: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut f64) -> ::windows::core::HRESULT,
30 pub SetLeftThumbstickY: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, value: f64) -> ::windows::core::HRESULT,
31 pub LeftTrigger: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut f64) -> ::windows::core::HRESULT,
32 pub SetLeftTrigger: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, value: f64) -> ::windows::core::HRESULT,
33 pub RightThumbstickX: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut f64) -> ::windows::core::HRESULT,
34 pub SetRightThumbstickX: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, value: f64) -> ::windows::core::HRESULT,
35 pub RightThumbstickY: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut f64) -> ::windows::core::HRESULT,
36 pub SetRightThumbstickY: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, value: f64) -> ::windows::core::HRESULT,
37 pub RightTrigger: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut f64) -> ::windows::core::HRESULT,
38 pub SetRightTrigger: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, value: f64) -> ::windows::core::HRESULT,
39}
40#[doc(hidden)]
41#[repr(transparent)]
42pub struct IInjectedInputGamepadInfoFactory(::windows::core::IUnknown);
43unsafe impl ::windows::core::Interface for IInjectedInputGamepadInfoFactory {
44 type Vtable = IInjectedInputGamepadInfoFactory_Vtbl;
45}
46impl ::core::clone::Clone for IInjectedInputGamepadInfoFactory {
47 fn clone(&self) -> Self {
48 Self(self.0.clone())
49 }
50}
51unsafe impl ::windows::core::ComInterface for IInjectedInputGamepadInfoFactory {
52 const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x59596876_6c39_4ec4_8b2a_29ef7de18aca);
53}
54#[repr(C)]
55#[doc(hidden)]
56pub struct IInjectedInputGamepadInfoFactory_Vtbl {
57 pub base__: ::windows::core::IInspectable_Vtbl,
58 #[cfg(feature = "Gaming_Input")]
59 pub CreateInstanceFromGamepadReading: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, reading: super::super::super::super::Gaming::Input::GamepadReading, result__: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT,
60 #[cfg(not(feature = "Gaming_Input"))]
61 CreateInstanceFromGamepadReading: usize,
62}
63#[doc(hidden)]
64#[repr(transparent)]
65pub struct IInjectedInputKeyboardInfo(::windows::core::IUnknown);
66unsafe impl ::windows::core::Interface for IInjectedInputKeyboardInfo {
67 type Vtable = IInjectedInputKeyboardInfo_Vtbl;
68}
69impl ::core::clone::Clone for IInjectedInputKeyboardInfo {
70 fn clone(&self) -> Self {
71 Self(self.0.clone())
72 }
73}
74unsafe impl ::windows::core::ComInterface for IInjectedInputKeyboardInfo {
75 const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x4b46d140_2b6a_5ffa_7eae_bd077b052acd);
76}
77#[repr(C)]
78#[doc(hidden)]
79pub struct IInjectedInputKeyboardInfo_Vtbl {
80 pub base__: ::windows::core::IInspectable_Vtbl,
81 pub KeyOptions: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut InjectedInputKeyOptions) -> ::windows::core::HRESULT,
82 pub SetKeyOptions: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, value: InjectedInputKeyOptions) -> ::windows::core::HRESULT,
83 pub ScanCode: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut u16) -> ::windows::core::HRESULT,
84 pub SetScanCode: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, value: u16) -> ::windows::core::HRESULT,
85 pub VirtualKey: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut u16) -> ::windows::core::HRESULT,
86 pub SetVirtualKey: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, value: u16) -> ::windows::core::HRESULT,
87}
88#[doc(hidden)]
89#[repr(transparent)]
90pub struct IInjectedInputMouseInfo(::windows::core::IUnknown);
91unsafe impl ::windows::core::Interface for IInjectedInputMouseInfo {
92 type Vtable = IInjectedInputMouseInfo_Vtbl;
93}
94impl ::core::clone::Clone for IInjectedInputMouseInfo {
95 fn clone(&self) -> Self {
96 Self(self.0.clone())
97 }
98}
99unsafe impl ::windows::core::ComInterface for IInjectedInputMouseInfo {
100 const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x96f56e6b_e47a_5cf4_418d_8a5fb9670c7d);
101}
102#[repr(C)]
103#[doc(hidden)]
104pub struct IInjectedInputMouseInfo_Vtbl {
105 pub base__: ::windows::core::IInspectable_Vtbl,
106 pub MouseOptions: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut InjectedInputMouseOptions) -> ::windows::core::HRESULT,
107 pub SetMouseOptions: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, value: InjectedInputMouseOptions) -> ::windows::core::HRESULT,
108 pub MouseData: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut u32) -> ::windows::core::HRESULT,
109 pub SetMouseData: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, value: u32) -> ::windows::core::HRESULT,
110 pub DeltaY: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut i32) -> ::windows::core::HRESULT,
111 pub SetDeltaY: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, value: i32) -> ::windows::core::HRESULT,
112 pub DeltaX: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut i32) -> ::windows::core::HRESULT,
113 pub SetDeltaX: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, value: i32) -> ::windows::core::HRESULT,
114 pub TimeOffsetInMilliseconds: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut u32) -> ::windows::core::HRESULT,
115 pub SetTimeOffsetInMilliseconds: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, value: u32) -> ::windows::core::HRESULT,
116}
117#[doc(hidden)]
118#[repr(transparent)]
119pub struct IInjectedInputPenInfo(::windows::core::IUnknown);
120unsafe impl ::windows::core::Interface for IInjectedInputPenInfo {
121 type Vtable = IInjectedInputPenInfo_Vtbl;
122}
123impl ::core::clone::Clone for IInjectedInputPenInfo {
124 fn clone(&self) -> Self {
125 Self(self.0.clone())
126 }
127}
128unsafe impl ::windows::core::ComInterface for IInjectedInputPenInfo {
129 const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x6b40ad03_ca1e_5527_7e02_2828540bb1d4);
130}
131#[repr(C)]
132#[doc(hidden)]
133pub struct IInjectedInputPenInfo_Vtbl {
134 pub base__: ::windows::core::IInspectable_Vtbl,
135 pub PointerInfo: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut InjectedInputPointerInfo) -> ::windows::core::HRESULT,
136 pub SetPointerInfo: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, value: InjectedInputPointerInfo) -> ::windows::core::HRESULT,
137 pub PenButtons: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut InjectedInputPenButtons) -> ::windows::core::HRESULT,
138 pub SetPenButtons: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, value: InjectedInputPenButtons) -> ::windows::core::HRESULT,
139 pub PenParameters: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut InjectedInputPenParameters) -> ::windows::core::HRESULT,
140 pub SetPenParameters: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, value: InjectedInputPenParameters) -> ::windows::core::HRESULT,
141 pub Pressure: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut f64) -> ::windows::core::HRESULT,
142 pub SetPressure: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, value: f64) -> ::windows::core::HRESULT,
143 pub Rotation: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut f64) -> ::windows::core::HRESULT,
144 pub SetRotation: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, value: f64) -> ::windows::core::HRESULT,
145 pub TiltX: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut i32) -> ::windows::core::HRESULT,
146 pub SetTiltX: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, value: i32) -> ::windows::core::HRESULT,
147 pub TiltY: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut i32) -> ::windows::core::HRESULT,
148 pub SetTiltY: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, value: i32) -> ::windows::core::HRESULT,
149}
150#[doc(hidden)]
151#[repr(transparent)]
152pub struct IInjectedInputTouchInfo(::windows::core::IUnknown);
153unsafe impl ::windows::core::Interface for IInjectedInputTouchInfo {
154 type Vtable = IInjectedInputTouchInfo_Vtbl;
155}
156impl ::core::clone::Clone for IInjectedInputTouchInfo {
157 fn clone(&self) -> Self {
158 Self(self.0.clone())
159 }
160}
161unsafe impl ::windows::core::ComInterface for IInjectedInputTouchInfo {
162 const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x224fd1df_43e8_5ef5_510a_69ca8c9b4c28);
163}
164#[repr(C)]
165#[doc(hidden)]
166pub struct IInjectedInputTouchInfo_Vtbl {
167 pub base__: ::windows::core::IInspectable_Vtbl,
168 pub Contact: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut InjectedInputRectangle) -> ::windows::core::HRESULT,
169 pub SetContact: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, value: InjectedInputRectangle) -> ::windows::core::HRESULT,
170 pub Orientation: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut i32) -> ::windows::core::HRESULT,
171 pub SetOrientation: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, value: i32) -> ::windows::core::HRESULT,
172 pub PointerInfo: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut InjectedInputPointerInfo) -> ::windows::core::HRESULT,
173 pub SetPointerInfo: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, value: InjectedInputPointerInfo) -> ::windows::core::HRESULT,
174 pub Pressure: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut f64) -> ::windows::core::HRESULT,
175 pub SetPressure: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, value: f64) -> ::windows::core::HRESULT,
176 pub TouchParameters: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut InjectedInputTouchParameters) -> ::windows::core::HRESULT,
177 pub SetTouchParameters: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, value: InjectedInputTouchParameters) -> ::windows::core::HRESULT,
178}
179#[doc(hidden)]
180#[repr(transparent)]
181pub struct IInputInjector(::windows::core::IUnknown);
182unsafe impl ::windows::core::Interface for IInputInjector {
183 type Vtable = IInputInjector_Vtbl;
184}
185impl ::core::clone::Clone for IInputInjector {
186 fn clone(&self) -> Self {
187 Self(self.0.clone())
188 }
189}
190unsafe impl ::windows::core::ComInterface for IInputInjector {
191 const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x8ec26f84_0b02_4bd2_ad7a_3d4658be3e18);
192}
193#[repr(C)]
194#[doc(hidden)]
195pub struct IInputInjector_Vtbl {
196 pub base__: ::windows::core::IInspectable_Vtbl,
197 #[cfg(feature = "Foundation_Collections")]
198 pub InjectKeyboardInput: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, input: *mut ::core::ffi::c_void) -> ::windows::core::HRESULT,
199 #[cfg(not(feature = "Foundation_Collections"))]
200 InjectKeyboardInput: usize,
201 #[cfg(feature = "Foundation_Collections")]
202 pub InjectMouseInput: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, input: *mut ::core::ffi::c_void) -> ::windows::core::HRESULT,
203 #[cfg(not(feature = "Foundation_Collections"))]
204 InjectMouseInput: usize,
205 pub InitializeTouchInjection: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, visualmode: InjectedInputVisualizationMode) -> ::windows::core::HRESULT,
206 #[cfg(feature = "Foundation_Collections")]
207 pub InjectTouchInput: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, input: *mut ::core::ffi::c_void) -> ::windows::core::HRESULT,
208 #[cfg(not(feature = "Foundation_Collections"))]
209 InjectTouchInput: usize,
210 pub UninitializeTouchInjection: unsafe extern "system" fn(this: *mut ::core::ffi::c_void) -> ::windows::core::HRESULT,
211 pub InitializePenInjection: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, visualmode: InjectedInputVisualizationMode) -> ::windows::core::HRESULT,
212 pub InjectPenInput: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, input: *mut ::core::ffi::c_void) -> ::windows::core::HRESULT,
213 pub UninitializePenInjection: unsafe extern "system" fn(this: *mut ::core::ffi::c_void) -> ::windows::core::HRESULT,
214 pub InjectShortcut: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, shortcut: InjectedInputShortcut) -> ::windows::core::HRESULT,
215}
216#[doc(hidden)]
217#[repr(transparent)]
218pub struct IInputInjector2(::windows::core::IUnknown);
219unsafe impl ::windows::core::Interface for IInputInjector2 {
220 type Vtable = IInputInjector2_Vtbl;
221}
222impl ::core::clone::Clone for IInputInjector2 {
223 fn clone(&self) -> Self {
224 Self(self.0.clone())
225 }
226}
227unsafe impl ::windows::core::ComInterface for IInputInjector2 {
228 const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x8e7a905d_1453_43a7_9bcb_06d6d7b305f7);
229}
230#[repr(C)]
231#[doc(hidden)]
232pub struct IInputInjector2_Vtbl {
233 pub base__: ::windows::core::IInspectable_Vtbl,
234 pub InitializeGamepadInjection: unsafe extern "system" fn(this: *mut ::core::ffi::c_void) -> ::windows::core::HRESULT,
235 pub InjectGamepadInput: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, input: *mut ::core::ffi::c_void) -> ::windows::core::HRESULT,
236 pub UninitializeGamepadInjection: unsafe extern "system" fn(this: *mut ::core::ffi::c_void) -> ::windows::core::HRESULT,
237}
238#[doc(hidden)]
239#[repr(transparent)]
240pub struct IInputInjectorStatics(::windows::core::IUnknown);
241unsafe impl ::windows::core::Interface for IInputInjectorStatics {
242 type Vtable = IInputInjectorStatics_Vtbl;
243}
244impl ::core::clone::Clone for IInputInjectorStatics {
245 fn clone(&self) -> Self {
246 Self(self.0.clone())
247 }
248}
249unsafe impl ::windows::core::ComInterface for IInputInjectorStatics {
250 const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xdeae6943_7402_4141_a5c6_0c01aa57b16a);
251}
252#[repr(C)]
253#[doc(hidden)]
254pub struct IInputInjectorStatics_Vtbl {
255 pub base__: ::windows::core::IInspectable_Vtbl,
256 pub TryCreate: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT,
257}
258#[doc(hidden)]
259#[repr(transparent)]
260pub struct IInputInjectorStatics2(::windows::core::IUnknown);
261unsafe impl ::windows::core::Interface for IInputInjectorStatics2 {
262 type Vtable = IInputInjectorStatics2_Vtbl;
263}
264impl ::core::clone::Clone for IInputInjectorStatics2 {
265 fn clone(&self) -> Self {
266 Self(self.0.clone())
267 }
268}
269unsafe impl ::windows::core::ComInterface for IInputInjectorStatics2 {
270 const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xa4db38fb_dd8c_414f_95ea_f87ef4c0ae6c);
271}
272#[repr(C)]
273#[doc(hidden)]
274pub struct IInputInjectorStatics2_Vtbl {
275 pub base__: ::windows::core::IInspectable_Vtbl,
276 pub TryCreateForAppBroadcastOnly: unsafe extern "system" fn(this: *mut ::core::ffi::c_void, result__: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT,
277}
278#[doc = "*Required features: `\"UI_Input_Preview_Injection\"`*"]
279#[repr(transparent)]
280pub struct InjectedInputGamepadInfo(::windows::core::IUnknown);
281impl InjectedInputGamepadInfo {
282 pub fn new() -> ::windows::core::Result<Self> {
283 Self::IActivationFactory(|f| f.ActivateInstance::<Self>())
284 }
285 fn IActivationFactory<R, F: FnOnce(&::windows::imp::IGenericFactory) -> ::windows::core::Result<R>>(callback: F) -> ::windows::core::Result<R> {
286 static SHARED: ::windows::imp::FactoryCache<InjectedInputGamepadInfo, ::windows::imp::IGenericFactory> = ::windows::imp::FactoryCache::new();
287 SHARED.call(callback)
288 }
289 #[doc = "*Required features: `\"Gaming_Input\"`*"]
290 #[cfg(feature = "Gaming_Input")]
291 pub fn Buttons(&self) -> ::windows::core::Result<super::super::super::super::Gaming::Input::GamepadButtons> {
292 let this = self;
293 unsafe {
294 let mut result__ = ::windows::core::zeroed::<super::super::super::super::Gaming::Input::GamepadButtons>();
295 (::windows::core::Interface::vtable(this).Buttons)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
296 }
297 }
298 #[doc = "*Required features: `\"Gaming_Input\"`*"]
299 #[cfg(feature = "Gaming_Input")]
300 pub fn SetButtons(&self, value: super::super::super::super::Gaming::Input::GamepadButtons) -> ::windows::core::Result<()> {
301 let this = self;
302 unsafe { (::windows::core::Interface::vtable(this).SetButtons)(::windows::core::Interface::as_raw(this), value).ok() }
303 }
304 pub fn LeftThumbstickX(&self) -> ::windows::core::Result<f64> {
305 let this = self;
306 unsafe {
307 let mut result__ = ::windows::core::zeroed::<f64>();
308 (::windows::core::Interface::vtable(this).LeftThumbstickX)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
309 }
310 }
311 pub fn SetLeftThumbstickX(&self, value: f64) -> ::windows::core::Result<()> {
312 let this = self;
313 unsafe { (::windows::core::Interface::vtable(this).SetLeftThumbstickX)(::windows::core::Interface::as_raw(this), value).ok() }
314 }
315 pub fn LeftThumbstickY(&self) -> ::windows::core::Result<f64> {
316 let this = self;
317 unsafe {
318 let mut result__ = ::windows::core::zeroed::<f64>();
319 (::windows::core::Interface::vtable(this).LeftThumbstickY)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
320 }
321 }
322 pub fn SetLeftThumbstickY(&self, value: f64) -> ::windows::core::Result<()> {
323 let this = self;
324 unsafe { (::windows::core::Interface::vtable(this).SetLeftThumbstickY)(::windows::core::Interface::as_raw(this), value).ok() }
325 }
326 pub fn LeftTrigger(&self) -> ::windows::core::Result<f64> {
327 let this = self;
328 unsafe {
329 let mut result__ = ::windows::core::zeroed::<f64>();
330 (::windows::core::Interface::vtable(this).LeftTrigger)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
331 }
332 }
333 pub fn SetLeftTrigger(&self, value: f64) -> ::windows::core::Result<()> {
334 let this = self;
335 unsafe { (::windows::core::Interface::vtable(this).SetLeftTrigger)(::windows::core::Interface::as_raw(this), value).ok() }
336 }
337 pub fn RightThumbstickX(&self) -> ::windows::core::Result<f64> {
338 let this = self;
339 unsafe {
340 let mut result__ = ::windows::core::zeroed::<f64>();
341 (::windows::core::Interface::vtable(this).RightThumbstickX)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
342 }
343 }
344 pub fn SetRightThumbstickX(&self, value: f64) -> ::windows::core::Result<()> {
345 let this = self;
346 unsafe { (::windows::core::Interface::vtable(this).SetRightThumbstickX)(::windows::core::Interface::as_raw(this), value).ok() }
347 }
348 pub fn RightThumbstickY(&self) -> ::windows::core::Result<f64> {
349 let this = self;
350 unsafe {
351 let mut result__ = ::windows::core::zeroed::<f64>();
352 (::windows::core::Interface::vtable(this).RightThumbstickY)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
353 }
354 }
355 pub fn SetRightThumbstickY(&self, value: f64) -> ::windows::core::Result<()> {
356 let this = self;
357 unsafe { (::windows::core::Interface::vtable(this).SetRightThumbstickY)(::windows::core::Interface::as_raw(this), value).ok() }
358 }
359 pub fn RightTrigger(&self) -> ::windows::core::Result<f64> {
360 let this = self;
361 unsafe {
362 let mut result__ = ::windows::core::zeroed::<f64>();
363 (::windows::core::Interface::vtable(this).RightTrigger)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
364 }
365 }
366 pub fn SetRightTrigger(&self, value: f64) -> ::windows::core::Result<()> {
367 let this = self;
368 unsafe { (::windows::core::Interface::vtable(this).SetRightTrigger)(::windows::core::Interface::as_raw(this), value).ok() }
369 }
370 #[doc = "*Required features: `\"Gaming_Input\"`*"]
371 #[cfg(feature = "Gaming_Input")]
372 pub fn CreateInstanceFromGamepadReading(reading: super::super::super::super::Gaming::Input::GamepadReading) -> ::windows::core::Result<InjectedInputGamepadInfo> {
373 Self::IInjectedInputGamepadInfoFactory(|this| unsafe {
374 let mut result__ = ::windows::core::zeroed::<InjectedInputGamepadInfo>();
375 (::windows::core::Interface::vtable(this).CreateInstanceFromGamepadReading)(::windows::core::Interface::as_raw(this), reading, &mut result__).from_abi(result__)
376 })
377 }
378 #[doc(hidden)]
379 pub fn IInjectedInputGamepadInfoFactory<R, F: FnOnce(&IInjectedInputGamepadInfoFactory) -> ::windows::core::Result<R>>(callback: F) -> ::windows::core::Result<R> {
380 static SHARED: ::windows::imp::FactoryCache<InjectedInputGamepadInfo, IInjectedInputGamepadInfoFactory> = ::windows::imp::FactoryCache::new();
381 SHARED.call(callback)
382 }
383}
384impl ::core::cmp::PartialEq for InjectedInputGamepadInfo {
385 fn eq(&self, other: &Self) -> bool {
386 self.0 == other.0
387 }
388}
389impl ::core::cmp::Eq for InjectedInputGamepadInfo {}
390impl ::core::fmt::Debug for InjectedInputGamepadInfo {
391 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
392 f.debug_tuple("InjectedInputGamepadInfo").field(&self.0).finish()
393 }
394}
395impl ::windows::core::RuntimeType for InjectedInputGamepadInfo {
396 const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"rc(Windows.UI.Input.Preview.Injection.InjectedInputGamepadInfo;{20ae9a3f-df11-4572-a9ab-d75b8a5e48ad})");
397}
398impl ::core::clone::Clone for InjectedInputGamepadInfo {
399 fn clone(&self) -> Self {
400 Self(self.0.clone())
401 }
402}
403unsafe impl ::windows::core::Interface for InjectedInputGamepadInfo {
404 type Vtable = IInjectedInputGamepadInfo_Vtbl;
405}
406unsafe impl ::windows::core::ComInterface for InjectedInputGamepadInfo {
407 const IID: ::windows::core::GUID = <IInjectedInputGamepadInfo as ::windows::core::ComInterface>::IID;
408}
409impl ::windows::core::RuntimeName for InjectedInputGamepadInfo {
410 const NAME: &'static str = "Windows.UI.Input.Preview.Injection.InjectedInputGamepadInfo";
411}
412::windows::imp::interface_hierarchy!(InjectedInputGamepadInfo, ::windows::core::IUnknown, ::windows::core::IInspectable);
413#[doc = "*Required features: `\"UI_Input_Preview_Injection\"`*"]
414#[repr(transparent)]
415pub struct InjectedInputKeyboardInfo(::windows::core::IUnknown);
416impl InjectedInputKeyboardInfo {
417 pub fn new() -> ::windows::core::Result<Self> {
418 Self::IActivationFactory(|f| f.ActivateInstance::<Self>())
419 }
420 fn IActivationFactory<R, F: FnOnce(&::windows::imp::IGenericFactory) -> ::windows::core::Result<R>>(callback: F) -> ::windows::core::Result<R> {
421 static SHARED: ::windows::imp::FactoryCache<InjectedInputKeyboardInfo, ::windows::imp::IGenericFactory> = ::windows::imp::FactoryCache::new();
422 SHARED.call(callback)
423 }
424 pub fn KeyOptions(&self) -> ::windows::core::Result<InjectedInputKeyOptions> {
425 let this = self;
426 unsafe {
427 let mut result__ = ::windows::core::zeroed::<InjectedInputKeyOptions>();
428 (::windows::core::Interface::vtable(this).KeyOptions)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
429 }
430 }
431 pub fn SetKeyOptions(&self, value: InjectedInputKeyOptions) -> ::windows::core::Result<()> {
432 let this = self;
433 unsafe { (::windows::core::Interface::vtable(this).SetKeyOptions)(::windows::core::Interface::as_raw(this), value).ok() }
434 }
435 pub fn ScanCode(&self) -> ::windows::core::Result<u16> {
436 let this = self;
437 unsafe {
438 let mut result__ = ::windows::core::zeroed::<u16>();
439 (::windows::core::Interface::vtable(this).ScanCode)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
440 }
441 }
442 pub fn SetScanCode(&self, value: u16) -> ::windows::core::Result<()> {
443 let this = self;
444 unsafe { (::windows::core::Interface::vtable(this).SetScanCode)(::windows::core::Interface::as_raw(this), value).ok() }
445 }
446 pub fn VirtualKey(&self) -> ::windows::core::Result<u16> {
447 let this = self;
448 unsafe {
449 let mut result__ = ::windows::core::zeroed::<u16>();
450 (::windows::core::Interface::vtable(this).VirtualKey)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
451 }
452 }
453 pub fn SetVirtualKey(&self, value: u16) -> ::windows::core::Result<()> {
454 let this = self;
455 unsafe { (::windows::core::Interface::vtable(this).SetVirtualKey)(::windows::core::Interface::as_raw(this), value).ok() }
456 }
457}
458impl ::core::cmp::PartialEq for InjectedInputKeyboardInfo {
459 fn eq(&self, other: &Self) -> bool {
460 self.0 == other.0
461 }
462}
463impl ::core::cmp::Eq for InjectedInputKeyboardInfo {}
464impl ::core::fmt::Debug for InjectedInputKeyboardInfo {
465 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
466 f.debug_tuple("InjectedInputKeyboardInfo").field(&self.0).finish()
467 }
468}
469impl ::windows::core::RuntimeType for InjectedInputKeyboardInfo {
470 const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"rc(Windows.UI.Input.Preview.Injection.InjectedInputKeyboardInfo;{4b46d140-2b6a-5ffa-7eae-bd077b052acd})");
471}
472impl ::core::clone::Clone for InjectedInputKeyboardInfo {
473 fn clone(&self) -> Self {
474 Self(self.0.clone())
475 }
476}
477unsafe impl ::windows::core::Interface for InjectedInputKeyboardInfo {
478 type Vtable = IInjectedInputKeyboardInfo_Vtbl;
479}
480unsafe impl ::windows::core::ComInterface for InjectedInputKeyboardInfo {
481 const IID: ::windows::core::GUID = <IInjectedInputKeyboardInfo as ::windows::core::ComInterface>::IID;
482}
483impl ::windows::core::RuntimeName for InjectedInputKeyboardInfo {
484 const NAME: &'static str = "Windows.UI.Input.Preview.Injection.InjectedInputKeyboardInfo";
485}
486::windows::imp::interface_hierarchy!(InjectedInputKeyboardInfo, ::windows::core::IUnknown, ::windows::core::IInspectable);
487#[doc = "*Required features: `\"UI_Input_Preview_Injection\"`*"]
488#[repr(transparent)]
489pub struct InjectedInputMouseInfo(::windows::core::IUnknown);
490impl InjectedInputMouseInfo {
491 pub fn new() -> ::windows::core::Result<Self> {
492 Self::IActivationFactory(|f| f.ActivateInstance::<Self>())
493 }
494 fn IActivationFactory<R, F: FnOnce(&::windows::imp::IGenericFactory) -> ::windows::core::Result<R>>(callback: F) -> ::windows::core::Result<R> {
495 static SHARED: ::windows::imp::FactoryCache<InjectedInputMouseInfo, ::windows::imp::IGenericFactory> = ::windows::imp::FactoryCache::new();
496 SHARED.call(callback)
497 }
498 pub fn MouseOptions(&self) -> ::windows::core::Result<InjectedInputMouseOptions> {
499 let this = self;
500 unsafe {
501 let mut result__ = ::windows::core::zeroed::<InjectedInputMouseOptions>();
502 (::windows::core::Interface::vtable(this).MouseOptions)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
503 }
504 }
505 pub fn SetMouseOptions(&self, value: InjectedInputMouseOptions) -> ::windows::core::Result<()> {
506 let this = self;
507 unsafe { (::windows::core::Interface::vtable(this).SetMouseOptions)(::windows::core::Interface::as_raw(this), value).ok() }
508 }
509 pub fn MouseData(&self) -> ::windows::core::Result<u32> {
510 let this = self;
511 unsafe {
512 let mut result__ = ::windows::core::zeroed::<u32>();
513 (::windows::core::Interface::vtable(this).MouseData)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
514 }
515 }
516 pub fn SetMouseData(&self, value: u32) -> ::windows::core::Result<()> {
517 let this = self;
518 unsafe { (::windows::core::Interface::vtable(this).SetMouseData)(::windows::core::Interface::as_raw(this), value).ok() }
519 }
520 pub fn DeltaY(&self) -> ::windows::core::Result<i32> {
521 let this = self;
522 unsafe {
523 let mut result__ = ::windows::core::zeroed::<i32>();
524 (::windows::core::Interface::vtable(this).DeltaY)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
525 }
526 }
527 pub fn SetDeltaY(&self, value: i32) -> ::windows::core::Result<()> {
528 let this = self;
529 unsafe { (::windows::core::Interface::vtable(this).SetDeltaY)(::windows::core::Interface::as_raw(this), value).ok() }
530 }
531 pub fn DeltaX(&self) -> ::windows::core::Result<i32> {
532 let this = self;
533 unsafe {
534 let mut result__ = ::windows::core::zeroed::<i32>();
535 (::windows::core::Interface::vtable(this).DeltaX)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
536 }
537 }
538 pub fn SetDeltaX(&self, value: i32) -> ::windows::core::Result<()> {
539 let this = self;
540 unsafe { (::windows::core::Interface::vtable(this).SetDeltaX)(::windows::core::Interface::as_raw(this), value).ok() }
541 }
542 pub fn TimeOffsetInMilliseconds(&self) -> ::windows::core::Result<u32> {
543 let this = self;
544 unsafe {
545 let mut result__ = ::windows::core::zeroed::<u32>();
546 (::windows::core::Interface::vtable(this).TimeOffsetInMilliseconds)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
547 }
548 }
549 pub fn SetTimeOffsetInMilliseconds(&self, value: u32) -> ::windows::core::Result<()> {
550 let this = self;
551 unsafe { (::windows::core::Interface::vtable(this).SetTimeOffsetInMilliseconds)(::windows::core::Interface::as_raw(this), value).ok() }
552 }
553}
554impl ::core::cmp::PartialEq for InjectedInputMouseInfo {
555 fn eq(&self, other: &Self) -> bool {
556 self.0 == other.0
557 }
558}
559impl ::core::cmp::Eq for InjectedInputMouseInfo {}
560impl ::core::fmt::Debug for InjectedInputMouseInfo {
561 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
562 f.debug_tuple("InjectedInputMouseInfo").field(&self.0).finish()
563 }
564}
565impl ::windows::core::RuntimeType for InjectedInputMouseInfo {
566 const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"rc(Windows.UI.Input.Preview.Injection.InjectedInputMouseInfo;{96f56e6b-e47a-5cf4-418d-8a5fb9670c7d})");
567}
568impl ::core::clone::Clone for InjectedInputMouseInfo {
569 fn clone(&self) -> Self {
570 Self(self.0.clone())
571 }
572}
573unsafe impl ::windows::core::Interface for InjectedInputMouseInfo {
574 type Vtable = IInjectedInputMouseInfo_Vtbl;
575}
576unsafe impl ::windows::core::ComInterface for InjectedInputMouseInfo {
577 const IID: ::windows::core::GUID = <IInjectedInputMouseInfo as ::windows::core::ComInterface>::IID;
578}
579impl ::windows::core::RuntimeName for InjectedInputMouseInfo {
580 const NAME: &'static str = "Windows.UI.Input.Preview.Injection.InjectedInputMouseInfo";
581}
582::windows::imp::interface_hierarchy!(InjectedInputMouseInfo, ::windows::core::IUnknown, ::windows::core::IInspectable);
583#[doc = "*Required features: `\"UI_Input_Preview_Injection\"`*"]
584#[repr(transparent)]
585pub struct InjectedInputPenInfo(::windows::core::IUnknown);
586impl InjectedInputPenInfo {
587 pub fn new() -> ::windows::core::Result<Self> {
588 Self::IActivationFactory(|f| f.ActivateInstance::<Self>())
589 }
590 fn IActivationFactory<R, F: FnOnce(&::windows::imp::IGenericFactory) -> ::windows::core::Result<R>>(callback: F) -> ::windows::core::Result<R> {
591 static SHARED: ::windows::imp::FactoryCache<InjectedInputPenInfo, ::windows::imp::IGenericFactory> = ::windows::imp::FactoryCache::new();
592 SHARED.call(callback)
593 }
594 pub fn PointerInfo(&self) -> ::windows::core::Result<InjectedInputPointerInfo> {
595 let this = self;
596 unsafe {
597 let mut result__ = ::windows::core::zeroed::<InjectedInputPointerInfo>();
598 (::windows::core::Interface::vtable(this).PointerInfo)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
599 }
600 }
601 pub fn SetPointerInfo(&self, value: InjectedInputPointerInfo) -> ::windows::core::Result<()> {
602 let this = self;
603 unsafe { (::windows::core::Interface::vtable(this).SetPointerInfo)(::windows::core::Interface::as_raw(this), value).ok() }
604 }
605 pub fn PenButtons(&self) -> ::windows::core::Result<InjectedInputPenButtons> {
606 let this = self;
607 unsafe {
608 let mut result__ = ::windows::core::zeroed::<InjectedInputPenButtons>();
609 (::windows::core::Interface::vtable(this).PenButtons)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
610 }
611 }
612 pub fn SetPenButtons(&self, value: InjectedInputPenButtons) -> ::windows::core::Result<()> {
613 let this = self;
614 unsafe { (::windows::core::Interface::vtable(this).SetPenButtons)(::windows::core::Interface::as_raw(this), value).ok() }
615 }
616 pub fn PenParameters(&self) -> ::windows::core::Result<InjectedInputPenParameters> {
617 let this = self;
618 unsafe {
619 let mut result__ = ::windows::core::zeroed::<InjectedInputPenParameters>();
620 (::windows::core::Interface::vtable(this).PenParameters)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
621 }
622 }
623 pub fn SetPenParameters(&self, value: InjectedInputPenParameters) -> ::windows::core::Result<()> {
624 let this = self;
625 unsafe { (::windows::core::Interface::vtable(this).SetPenParameters)(::windows::core::Interface::as_raw(this), value).ok() }
626 }
627 pub fn Pressure(&self) -> ::windows::core::Result<f64> {
628 let this = self;
629 unsafe {
630 let mut result__ = ::windows::core::zeroed::<f64>();
631 (::windows::core::Interface::vtable(this).Pressure)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
632 }
633 }
634 pub fn SetPressure(&self, value: f64) -> ::windows::core::Result<()> {
635 let this = self;
636 unsafe { (::windows::core::Interface::vtable(this).SetPressure)(::windows::core::Interface::as_raw(this), value).ok() }
637 }
638 pub fn Rotation(&self) -> ::windows::core::Result<f64> {
639 let this = self;
640 unsafe {
641 let mut result__ = ::windows::core::zeroed::<f64>();
642 (::windows::core::Interface::vtable(this).Rotation)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
643 }
644 }
645 pub fn SetRotation(&self, value: f64) -> ::windows::core::Result<()> {
646 let this = self;
647 unsafe { (::windows::core::Interface::vtable(this).SetRotation)(::windows::core::Interface::as_raw(this), value).ok() }
648 }
649 pub fn TiltX(&self) -> ::windows::core::Result<i32> {
650 let this = self;
651 unsafe {
652 let mut result__ = ::windows::core::zeroed::<i32>();
653 (::windows::core::Interface::vtable(this).TiltX)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
654 }
655 }
656 pub fn SetTiltX(&self, value: i32) -> ::windows::core::Result<()> {
657 let this = self;
658 unsafe { (::windows::core::Interface::vtable(this).SetTiltX)(::windows::core::Interface::as_raw(this), value).ok() }
659 }
660 pub fn TiltY(&self) -> ::windows::core::Result<i32> {
661 let this = self;
662 unsafe {
663 let mut result__ = ::windows::core::zeroed::<i32>();
664 (::windows::core::Interface::vtable(this).TiltY)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
665 }
666 }
667 pub fn SetTiltY(&self, value: i32) -> ::windows::core::Result<()> {
668 let this = self;
669 unsafe { (::windows::core::Interface::vtable(this).SetTiltY)(::windows::core::Interface::as_raw(this), value).ok() }
670 }
671}
672impl ::core::cmp::PartialEq for InjectedInputPenInfo {
673 fn eq(&self, other: &Self) -> bool {
674 self.0 == other.0
675 }
676}
677impl ::core::cmp::Eq for InjectedInputPenInfo {}
678impl ::core::fmt::Debug for InjectedInputPenInfo {
679 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
680 f.debug_tuple("InjectedInputPenInfo").field(&self.0).finish()
681 }
682}
683impl ::windows::core::RuntimeType for InjectedInputPenInfo {
684 const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"rc(Windows.UI.Input.Preview.Injection.InjectedInputPenInfo;{6b40ad03-ca1e-5527-7e02-2828540bb1d4})");
685}
686impl ::core::clone::Clone for InjectedInputPenInfo {
687 fn clone(&self) -> Self {
688 Self(self.0.clone())
689 }
690}
691unsafe impl ::windows::core::Interface for InjectedInputPenInfo {
692 type Vtable = IInjectedInputPenInfo_Vtbl;
693}
694unsafe impl ::windows::core::ComInterface for InjectedInputPenInfo {
695 const IID: ::windows::core::GUID = <IInjectedInputPenInfo as ::windows::core::ComInterface>::IID;
696}
697impl ::windows::core::RuntimeName for InjectedInputPenInfo {
698 const NAME: &'static str = "Windows.UI.Input.Preview.Injection.InjectedInputPenInfo";
699}
700::windows::imp::interface_hierarchy!(InjectedInputPenInfo, ::windows::core::IUnknown, ::windows::core::IInspectable);
701#[doc = "*Required features: `\"UI_Input_Preview_Injection\"`*"]
702#[repr(transparent)]
703pub struct InjectedInputTouchInfo(::windows::core::IUnknown);
704impl InjectedInputTouchInfo {
705 pub fn new() -> ::windows::core::Result<Self> {
706 Self::IActivationFactory(|f| f.ActivateInstance::<Self>())
707 }
708 fn IActivationFactory<R, F: FnOnce(&::windows::imp::IGenericFactory) -> ::windows::core::Result<R>>(callback: F) -> ::windows::core::Result<R> {
709 static SHARED: ::windows::imp::FactoryCache<InjectedInputTouchInfo, ::windows::imp::IGenericFactory> = ::windows::imp::FactoryCache::new();
710 SHARED.call(callback)
711 }
712 pub fn Contact(&self) -> ::windows::core::Result<InjectedInputRectangle> {
713 let this = self;
714 unsafe {
715 let mut result__ = ::windows::core::zeroed::<InjectedInputRectangle>();
716 (::windows::core::Interface::vtable(this).Contact)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
717 }
718 }
719 pub fn SetContact(&self, value: InjectedInputRectangle) -> ::windows::core::Result<()> {
720 let this = self;
721 unsafe { (::windows::core::Interface::vtable(this).SetContact)(::windows::core::Interface::as_raw(this), value).ok() }
722 }
723 pub fn Orientation(&self) -> ::windows::core::Result<i32> {
724 let this = self;
725 unsafe {
726 let mut result__ = ::windows::core::zeroed::<i32>();
727 (::windows::core::Interface::vtable(this).Orientation)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
728 }
729 }
730 pub fn SetOrientation(&self, value: i32) -> ::windows::core::Result<()> {
731 let this = self;
732 unsafe { (::windows::core::Interface::vtable(this).SetOrientation)(::windows::core::Interface::as_raw(this), value).ok() }
733 }
734 pub fn PointerInfo(&self) -> ::windows::core::Result<InjectedInputPointerInfo> {
735 let this = self;
736 unsafe {
737 let mut result__ = ::windows::core::zeroed::<InjectedInputPointerInfo>();
738 (::windows::core::Interface::vtable(this).PointerInfo)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
739 }
740 }
741 pub fn SetPointerInfo(&self, value: InjectedInputPointerInfo) -> ::windows::core::Result<()> {
742 let this = self;
743 unsafe { (::windows::core::Interface::vtable(this).SetPointerInfo)(::windows::core::Interface::as_raw(this), value).ok() }
744 }
745 pub fn Pressure(&self) -> ::windows::core::Result<f64> {
746 let this = self;
747 unsafe {
748 let mut result__ = ::windows::core::zeroed::<f64>();
749 (::windows::core::Interface::vtable(this).Pressure)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
750 }
751 }
752 pub fn SetPressure(&self, value: f64) -> ::windows::core::Result<()> {
753 let this = self;
754 unsafe { (::windows::core::Interface::vtable(this).SetPressure)(::windows::core::Interface::as_raw(this), value).ok() }
755 }
756 pub fn TouchParameters(&self) -> ::windows::core::Result<InjectedInputTouchParameters> {
757 let this = self;
758 unsafe {
759 let mut result__ = ::windows::core::zeroed::<InjectedInputTouchParameters>();
760 (::windows::core::Interface::vtable(this).TouchParameters)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
761 }
762 }
763 pub fn SetTouchParameters(&self, value: InjectedInputTouchParameters) -> ::windows::core::Result<()> {
764 let this = self;
765 unsafe { (::windows::core::Interface::vtable(this).SetTouchParameters)(::windows::core::Interface::as_raw(this), value).ok() }
766 }
767}
768impl ::core::cmp::PartialEq for InjectedInputTouchInfo {
769 fn eq(&self, other: &Self) -> bool {
770 self.0 == other.0
771 }
772}
773impl ::core::cmp::Eq for InjectedInputTouchInfo {}
774impl ::core::fmt::Debug for InjectedInputTouchInfo {
775 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
776 f.debug_tuple("InjectedInputTouchInfo").field(&self.0).finish()
777 }
778}
779impl ::windows::core::RuntimeType for InjectedInputTouchInfo {
780 const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"rc(Windows.UI.Input.Preview.Injection.InjectedInputTouchInfo;{224fd1df-43e8-5ef5-510a-69ca8c9b4c28})");
781}
782impl ::core::clone::Clone for InjectedInputTouchInfo {
783 fn clone(&self) -> Self {
784 Self(self.0.clone())
785 }
786}
787unsafe impl ::windows::core::Interface for InjectedInputTouchInfo {
788 type Vtable = IInjectedInputTouchInfo_Vtbl;
789}
790unsafe impl ::windows::core::ComInterface for InjectedInputTouchInfo {
791 const IID: ::windows::core::GUID = <IInjectedInputTouchInfo as ::windows::core::ComInterface>::IID;
792}
793impl ::windows::core::RuntimeName for InjectedInputTouchInfo {
794 const NAME: &'static str = "Windows.UI.Input.Preview.Injection.InjectedInputTouchInfo";
795}
796::windows::imp::interface_hierarchy!(InjectedInputTouchInfo, ::windows::core::IUnknown, ::windows::core::IInspectable);
797#[doc = "*Required features: `\"UI_Input_Preview_Injection\"`*"]
798#[repr(transparent)]
799pub struct InputInjector(::windows::core::IUnknown);
800impl InputInjector {
801 #[doc = "*Required features: `\"Foundation_Collections\"`*"]
802 #[cfg(feature = "Foundation_Collections")]
803 pub fn InjectKeyboardInput<P0>(&self, input: P0) -> ::windows::core::Result<()>
804 where
805 P0: ::windows::core::TryIntoParam<super::super::super::super::Foundation::Collections::IIterable<InjectedInputKeyboardInfo>>,
806 {
807 let this = self;
808 unsafe { (::windows::core::Interface::vtable(this).InjectKeyboardInput)(::windows::core::Interface::as_raw(this), input.try_into_param()?.abi()).ok() }
809 }
810 #[doc = "*Required features: `\"Foundation_Collections\"`*"]
811 #[cfg(feature = "Foundation_Collections")]
812 pub fn InjectMouseInput<P0>(&self, input: P0) -> ::windows::core::Result<()>
813 where
814 P0: ::windows::core::TryIntoParam<super::super::super::super::Foundation::Collections::IIterable<InjectedInputMouseInfo>>,
815 {
816 let this = self;
817 unsafe { (::windows::core::Interface::vtable(this).InjectMouseInput)(::windows::core::Interface::as_raw(this), input.try_into_param()?.abi()).ok() }
818 }
819 pub fn InitializeTouchInjection(&self, visualmode: InjectedInputVisualizationMode) -> ::windows::core::Result<()> {
820 let this = self;
821 unsafe { (::windows::core::Interface::vtable(this).InitializeTouchInjection)(::windows::core::Interface::as_raw(this), visualmode).ok() }
822 }
823 #[doc = "*Required features: `\"Foundation_Collections\"`*"]
824 #[cfg(feature = "Foundation_Collections")]
825 pub fn InjectTouchInput<P0>(&self, input: P0) -> ::windows::core::Result<()>
826 where
827 P0: ::windows::core::TryIntoParam<super::super::super::super::Foundation::Collections::IIterable<InjectedInputTouchInfo>>,
828 {
829 let this = self;
830 unsafe { (::windows::core::Interface::vtable(this).InjectTouchInput)(::windows::core::Interface::as_raw(this), input.try_into_param()?.abi()).ok() }
831 }
832 pub fn UninitializeTouchInjection(&self) -> ::windows::core::Result<()> {
833 let this = self;
834 unsafe { (::windows::core::Interface::vtable(this).UninitializeTouchInjection)(::windows::core::Interface::as_raw(this)).ok() }
835 }
836 pub fn InitializePenInjection(&self, visualmode: InjectedInputVisualizationMode) -> ::windows::core::Result<()> {
837 let this = self;
838 unsafe { (::windows::core::Interface::vtable(this).InitializePenInjection)(::windows::core::Interface::as_raw(this), visualmode).ok() }
839 }
840 pub fn InjectPenInput(&self, input: &InjectedInputPenInfo) -> ::windows::core::Result<()> {
841 let this = self;
842 unsafe { (::windows::core::Interface::vtable(this).InjectPenInput)(::windows::core::Interface::as_raw(this), ::core::mem::transmute_copy(input)).ok() }
843 }
844 pub fn UninitializePenInjection(&self) -> ::windows::core::Result<()> {
845 let this = self;
846 unsafe { (::windows::core::Interface::vtable(this).UninitializePenInjection)(::windows::core::Interface::as_raw(this)).ok() }
847 }
848 pub fn InjectShortcut(&self, shortcut: InjectedInputShortcut) -> ::windows::core::Result<()> {
849 let this = self;
850 unsafe { (::windows::core::Interface::vtable(this).InjectShortcut)(::windows::core::Interface::as_raw(this), shortcut).ok() }
851 }
852 pub fn InitializeGamepadInjection(&self) -> ::windows::core::Result<()> {
853 let this = &::windows::core::ComInterface::cast::<IInputInjector2>(self)?;
854 unsafe { (::windows::core::Interface::vtable(this).InitializeGamepadInjection)(::windows::core::Interface::as_raw(this)).ok() }
855 }
856 pub fn InjectGamepadInput(&self, input: &InjectedInputGamepadInfo) -> ::windows::core::Result<()> {
857 let this = &::windows::core::ComInterface::cast::<IInputInjector2>(self)?;
858 unsafe { (::windows::core::Interface::vtable(this).InjectGamepadInput)(::windows::core::Interface::as_raw(this), ::core::mem::transmute_copy(input)).ok() }
859 }
860 pub fn UninitializeGamepadInjection(&self) -> ::windows::core::Result<()> {
861 let this = &::windows::core::ComInterface::cast::<IInputInjector2>(self)?;
862 unsafe { (::windows::core::Interface::vtable(this).UninitializeGamepadInjection)(::windows::core::Interface::as_raw(this)).ok() }
863 }
864 pub fn TryCreate() -> ::windows::core::Result<InputInjector> {
865 Self::IInputInjectorStatics(|this| unsafe {
866 let mut result__ = ::windows::core::zeroed::<InputInjector>();
867 (::windows::core::Interface::vtable(this).TryCreate)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
868 })
869 }
870 pub fn TryCreateForAppBroadcastOnly() -> ::windows::core::Result<InputInjector> {
871 Self::IInputInjectorStatics2(|this| unsafe {
872 let mut result__ = ::windows::core::zeroed::<InputInjector>();
873 (::windows::core::Interface::vtable(this).TryCreateForAppBroadcastOnly)(::windows::core::Interface::as_raw(this), &mut result__).from_abi(result__)
874 })
875 }
876 #[doc(hidden)]
877 pub fn IInputInjectorStatics<R, F: FnOnce(&IInputInjectorStatics) -> ::windows::core::Result<R>>(callback: F) -> ::windows::core::Result<R> {
878 static SHARED: ::windows::imp::FactoryCache<InputInjector, IInputInjectorStatics> = ::windows::imp::FactoryCache::new();
879 SHARED.call(callback)
880 }
881 #[doc(hidden)]
882 pub fn IInputInjectorStatics2<R, F: FnOnce(&IInputInjectorStatics2) -> ::windows::core::Result<R>>(callback: F) -> ::windows::core::Result<R> {
883 static SHARED: ::windows::imp::FactoryCache<InputInjector, IInputInjectorStatics2> = ::windows::imp::FactoryCache::new();
884 SHARED.call(callback)
885 }
886}
887impl ::core::cmp::PartialEq for InputInjector {
888 fn eq(&self, other: &Self) -> bool {
889 self.0 == other.0
890 }
891}
892impl ::core::cmp::Eq for InputInjector {}
893impl ::core::fmt::Debug for InputInjector {
894 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
895 f.debug_tuple("InputInjector").field(&self.0).finish()
896 }
897}
898impl ::windows::core::RuntimeType for InputInjector {
899 const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"rc(Windows.UI.Input.Preview.Injection.InputInjector;{8ec26f84-0b02-4bd2-ad7a-3d4658be3e18})");
900}
901impl ::core::clone::Clone for InputInjector {
902 fn clone(&self) -> Self {
903 Self(self.0.clone())
904 }
905}
906unsafe impl ::windows::core::Interface for InputInjector {
907 type Vtable = IInputInjector_Vtbl;
908}
909unsafe impl ::windows::core::ComInterface for InputInjector {
910 const IID: ::windows::core::GUID = <IInputInjector as ::windows::core::ComInterface>::IID;
911}
912impl ::windows::core::RuntimeName for InputInjector {
913 const NAME: &'static str = "Windows.UI.Input.Preview.Injection.InputInjector";
914}
915::windows::imp::interface_hierarchy!(InputInjector, ::windows::core::IUnknown, ::windows::core::IInspectable);
916#[doc = "*Required features: `\"UI_Input_Preview_Injection\"`*"]
917#[repr(transparent)]
918#[derive(::core::cmp::PartialEq, ::core::cmp::Eq)]
919pub struct InjectedInputButtonChangeKind(pub i32);
920impl InjectedInputButtonChangeKind {
921 pub const None: Self = Self(0i32);
922 pub const FirstButtonDown: Self = Self(1i32);
923 pub const FirstButtonUp: Self = Self(2i32);
924 pub const SecondButtonDown: Self = Self(3i32);
925 pub const SecondButtonUp: Self = Self(4i32);
926 pub const ThirdButtonDown: Self = Self(5i32);
927 pub const ThirdButtonUp: Self = Self(6i32);
928 pub const FourthButtonDown: Self = Self(7i32);
929 pub const FourthButtonUp: Self = Self(8i32);
930 pub const FifthButtonDown: Self = Self(9i32);
931 pub const FifthButtonUp: Self = Self(10i32);
932}
933impl ::core::marker::Copy for InjectedInputButtonChangeKind {}
934impl ::core::clone::Clone for InjectedInputButtonChangeKind {
935 fn clone(&self) -> Self {
936 *self
937 }
938}
939impl ::core::default::Default for InjectedInputButtonChangeKind {
940 fn default() -> Self {
941 Self(0)
942 }
943}
944impl ::windows::core::TypeKind for InjectedInputButtonChangeKind {
945 type TypeKind = ::windows::core::CopyType;
946}
947impl ::core::fmt::Debug for InjectedInputButtonChangeKind {
948 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
949 f.debug_tuple("InjectedInputButtonChangeKind").field(&self.0).finish()
950 }
951}
952impl ::windows::core::RuntimeType for InjectedInputButtonChangeKind {
953 const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"enum(Windows.UI.Input.Preview.Injection.InjectedInputButtonChangeKind;i4)");
954}
955#[doc = "*Required features: `\"UI_Input_Preview_Injection\"`*"]
956#[repr(transparent)]
957#[derive(::core::cmp::PartialEq, ::core::cmp::Eq)]
958pub struct InjectedInputKeyOptions(pub u32);
959impl InjectedInputKeyOptions {
960 pub const None: Self = Self(0u32);
961 pub const ExtendedKey: Self = Self(1u32);
962 pub const KeyUp: Self = Self(2u32);
963 pub const ScanCode: Self = Self(8u32);
964 pub const Unicode: Self = Self(4u32);
965}
966impl ::core::marker::Copy for InjectedInputKeyOptions {}
967impl ::core::clone::Clone for InjectedInputKeyOptions {
968 fn clone(&self) -> Self {
969 *self
970 }
971}
972impl ::core::default::Default for InjectedInputKeyOptions {
973 fn default() -> Self {
974 Self(0)
975 }
976}
977impl ::windows::core::TypeKind for InjectedInputKeyOptions {
978 type TypeKind = ::windows::core::CopyType;
979}
980impl ::core::fmt::Debug for InjectedInputKeyOptions {
981 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
982 f.debug_tuple("InjectedInputKeyOptions").field(&self.0).finish()
983 }
984}
985impl InjectedInputKeyOptions {
986 pub const fn contains(&self, other: Self) -> bool {
987 self.0 & other.0 == other.0
988 }
989}
990impl ::core::ops::BitOr for InjectedInputKeyOptions {
991 type Output = Self;
992 fn bitor(self, other: Self) -> Self {
993 Self(self.0 | other.0)
994 }
995}
996impl ::core::ops::BitAnd for InjectedInputKeyOptions {
997 type Output = Self;
998 fn bitand(self, other: Self) -> Self {
999 Self(self.0 & other.0)
1000 }
1001}
1002impl ::core::ops::BitOrAssign for InjectedInputKeyOptions {
1003 fn bitor_assign(&mut self, other: Self) {
1004 self.0.bitor_assign(other.0)
1005 }
1006}
1007impl ::core::ops::BitAndAssign for InjectedInputKeyOptions {
1008 fn bitand_assign(&mut self, other: Self) {
1009 self.0.bitand_assign(other.0)
1010 }
1011}
1012impl ::core::ops::Not for InjectedInputKeyOptions {
1013 type Output = Self;
1014 fn not(self) -> Self {
1015 Self(self.0.not())
1016 }
1017}
1018impl ::windows::core::RuntimeType for InjectedInputKeyOptions {
1019 const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"enum(Windows.UI.Input.Preview.Injection.InjectedInputKeyOptions;u4)");
1020}
1021#[doc = "*Required features: `\"UI_Input_Preview_Injection\"`*"]
1022#[repr(transparent)]
1023#[derive(::core::cmp::PartialEq, ::core::cmp::Eq)]
1024pub struct InjectedInputMouseOptions(pub u32);
1025impl InjectedInputMouseOptions {
1026 pub const None: Self = Self(0u32);
1027 pub const Move: Self = Self(1u32);
1028 pub const LeftDown: Self = Self(2u32);
1029 pub const LeftUp: Self = Self(4u32);
1030 pub const RightDown: Self = Self(8u32);
1031 pub const RightUp: Self = Self(16u32);
1032 pub const MiddleDown: Self = Self(32u32);
1033 pub const MiddleUp: Self = Self(64u32);
1034 pub const XDown: Self = Self(128u32);
1035 pub const XUp: Self = Self(256u32);
1036 pub const Wheel: Self = Self(2048u32);
1037 pub const HWheel: Self = Self(4096u32);
1038 pub const MoveNoCoalesce: Self = Self(8192u32);
1039 pub const VirtualDesk: Self = Self(16384u32);
1040 pub const Absolute: Self = Self(32768u32);
1041}
1042impl ::core::marker::Copy for InjectedInputMouseOptions {}
1043impl ::core::clone::Clone for InjectedInputMouseOptions {
1044 fn clone(&self) -> Self {
1045 *self
1046 }
1047}
1048impl ::core::default::Default for InjectedInputMouseOptions {
1049 fn default() -> Self {
1050 Self(0)
1051 }
1052}
1053impl ::windows::core::TypeKind for InjectedInputMouseOptions {
1054 type TypeKind = ::windows::core::CopyType;
1055}
1056impl ::core::fmt::Debug for InjectedInputMouseOptions {
1057 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
1058 f.debug_tuple("InjectedInputMouseOptions").field(&self.0).finish()
1059 }
1060}
1061impl InjectedInputMouseOptions {
1062 pub const fn contains(&self, other: Self) -> bool {
1063 self.0 & other.0 == other.0
1064 }
1065}
1066impl ::core::ops::BitOr for InjectedInputMouseOptions {
1067 type Output = Self;
1068 fn bitor(self, other: Self) -> Self {
1069 Self(self.0 | other.0)
1070 }
1071}
1072impl ::core::ops::BitAnd for InjectedInputMouseOptions {
1073 type Output = Self;
1074 fn bitand(self, other: Self) -> Self {
1075 Self(self.0 & other.0)
1076 }
1077}
1078impl ::core::ops::BitOrAssign for InjectedInputMouseOptions {
1079 fn bitor_assign(&mut self, other: Self) {
1080 self.0.bitor_assign(other.0)
1081 }
1082}
1083impl ::core::ops::BitAndAssign for InjectedInputMouseOptions {
1084 fn bitand_assign(&mut self, other: Self) {
1085 self.0.bitand_assign(other.0)
1086 }
1087}
1088impl ::core::ops::Not for InjectedInputMouseOptions {
1089 type Output = Self;
1090 fn not(self) -> Self {
1091 Self(self.0.not())
1092 }
1093}
1094impl ::windows::core::RuntimeType for InjectedInputMouseOptions {
1095 const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"enum(Windows.UI.Input.Preview.Injection.InjectedInputMouseOptions;u4)");
1096}
1097#[doc = "*Required features: `\"UI_Input_Preview_Injection\"`*"]
1098#[repr(transparent)]
1099#[derive(::core::cmp::PartialEq, ::core::cmp::Eq)]
1100pub struct InjectedInputPenButtons(pub u32);
1101impl InjectedInputPenButtons {
1102 pub const None: Self = Self(0u32);
1103 pub const Barrel: Self = Self(1u32);
1104 pub const Inverted: Self = Self(2u32);
1105 pub const Eraser: Self = Self(4u32);
1106}
1107impl ::core::marker::Copy for InjectedInputPenButtons {}
1108impl ::core::clone::Clone for InjectedInputPenButtons {
1109 fn clone(&self) -> Self {
1110 *self
1111 }
1112}
1113impl ::core::default::Default for InjectedInputPenButtons {
1114 fn default() -> Self {
1115 Self(0)
1116 }
1117}
1118impl ::windows::core::TypeKind for InjectedInputPenButtons {
1119 type TypeKind = ::windows::core::CopyType;
1120}
1121impl ::core::fmt::Debug for InjectedInputPenButtons {
1122 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
1123 f.debug_tuple("InjectedInputPenButtons").field(&self.0).finish()
1124 }
1125}
1126impl InjectedInputPenButtons {
1127 pub const fn contains(&self, other: Self) -> bool {
1128 self.0 & other.0 == other.0
1129 }
1130}
1131impl ::core::ops::BitOr for InjectedInputPenButtons {
1132 type Output = Self;
1133 fn bitor(self, other: Self) -> Self {
1134 Self(self.0 | other.0)
1135 }
1136}
1137impl ::core::ops::BitAnd for InjectedInputPenButtons {
1138 type Output = Self;
1139 fn bitand(self, other: Self) -> Self {
1140 Self(self.0 & other.0)
1141 }
1142}
1143impl ::core::ops::BitOrAssign for InjectedInputPenButtons {
1144 fn bitor_assign(&mut self, other: Self) {
1145 self.0.bitor_assign(other.0)
1146 }
1147}
1148impl ::core::ops::BitAndAssign for InjectedInputPenButtons {
1149 fn bitand_assign(&mut self, other: Self) {
1150 self.0.bitand_assign(other.0)
1151 }
1152}
1153impl ::core::ops::Not for InjectedInputPenButtons {
1154 type Output = Self;
1155 fn not(self) -> Self {
1156 Self(self.0.not())
1157 }
1158}
1159impl ::windows::core::RuntimeType for InjectedInputPenButtons {
1160 const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"enum(Windows.UI.Input.Preview.Injection.InjectedInputPenButtons;u4)");
1161}
1162#[doc = "*Required features: `\"UI_Input_Preview_Injection\"`*"]
1163#[repr(transparent)]
1164#[derive(::core::cmp::PartialEq, ::core::cmp::Eq)]
1165pub struct InjectedInputPenParameters(pub u32);
1166impl InjectedInputPenParameters {
1167 pub const None: Self = Self(0u32);
1168 pub const Pressure: Self = Self(1u32);
1169 pub const Rotation: Self = Self(2u32);
1170 pub const TiltX: Self = Self(4u32);
1171 pub const TiltY: Self = Self(8u32);
1172}
1173impl ::core::marker::Copy for InjectedInputPenParameters {}
1174impl ::core::clone::Clone for InjectedInputPenParameters {
1175 fn clone(&self) -> Self {
1176 *self
1177 }
1178}
1179impl ::core::default::Default for InjectedInputPenParameters {
1180 fn default() -> Self {
1181 Self(0)
1182 }
1183}
1184impl ::windows::core::TypeKind for InjectedInputPenParameters {
1185 type TypeKind = ::windows::core::CopyType;
1186}
1187impl ::core::fmt::Debug for InjectedInputPenParameters {
1188 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
1189 f.debug_tuple("InjectedInputPenParameters").field(&self.0).finish()
1190 }
1191}
1192impl InjectedInputPenParameters {
1193 pub const fn contains(&self, other: Self) -> bool {
1194 self.0 & other.0 == other.0
1195 }
1196}
1197impl ::core::ops::BitOr for InjectedInputPenParameters {
1198 type Output = Self;
1199 fn bitor(self, other: Self) -> Self {
1200 Self(self.0 | other.0)
1201 }
1202}
1203impl ::core::ops::BitAnd for InjectedInputPenParameters {
1204 type Output = Self;
1205 fn bitand(self, other: Self) -> Self {
1206 Self(self.0 & other.0)
1207 }
1208}
1209impl ::core::ops::BitOrAssign for InjectedInputPenParameters {
1210 fn bitor_assign(&mut self, other: Self) {
1211 self.0.bitor_assign(other.0)
1212 }
1213}
1214impl ::core::ops::BitAndAssign for InjectedInputPenParameters {
1215 fn bitand_assign(&mut self, other: Self) {
1216 self.0.bitand_assign(other.0)
1217 }
1218}
1219impl ::core::ops::Not for InjectedInputPenParameters {
1220 type Output = Self;
1221 fn not(self) -> Self {
1222 Self(self.0.not())
1223 }
1224}
1225impl ::windows::core::RuntimeType for InjectedInputPenParameters {
1226 const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"enum(Windows.UI.Input.Preview.Injection.InjectedInputPenParameters;u4)");
1227}
1228#[doc = "*Required features: `\"UI_Input_Preview_Injection\"`*"]
1229#[repr(transparent)]
1230#[derive(::core::cmp::PartialEq, ::core::cmp::Eq)]
1231pub struct InjectedInputPointerOptions(pub u32);
1232impl InjectedInputPointerOptions {
1233 pub const None: Self = Self(0u32);
1234 pub const New: Self = Self(1u32);
1235 pub const InRange: Self = Self(2u32);
1236 pub const InContact: Self = Self(4u32);
1237 pub const FirstButton: Self = Self(16u32);
1238 pub const SecondButton: Self = Self(32u32);
1239 pub const Primary: Self = Self(8192u32);
1240 pub const Confidence: Self = Self(16384u32);
1241 pub const Canceled: Self = Self(32768u32);
1242 pub const PointerDown: Self = Self(65536u32);
1243 pub const Update: Self = Self(131072u32);
1244 pub const PointerUp: Self = Self(262144u32);
1245 pub const CaptureChanged: Self = Self(2097152u32);
1246}
1247impl ::core::marker::Copy for InjectedInputPointerOptions {}
1248impl ::core::clone::Clone for InjectedInputPointerOptions {
1249 fn clone(&self) -> Self {
1250 *self
1251 }
1252}
1253impl ::core::default::Default for InjectedInputPointerOptions {
1254 fn default() -> Self {
1255 Self(0)
1256 }
1257}
1258impl ::windows::core::TypeKind for InjectedInputPointerOptions {
1259 type TypeKind = ::windows::core::CopyType;
1260}
1261impl ::core::fmt::Debug for InjectedInputPointerOptions {
1262 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
1263 f.debug_tuple("InjectedInputPointerOptions").field(&self.0).finish()
1264 }
1265}
1266impl InjectedInputPointerOptions {
1267 pub const fn contains(&self, other: Self) -> bool {
1268 self.0 & other.0 == other.0
1269 }
1270}
1271impl ::core::ops::BitOr for InjectedInputPointerOptions {
1272 type Output = Self;
1273 fn bitor(self, other: Self) -> Self {
1274 Self(self.0 | other.0)
1275 }
1276}
1277impl ::core::ops::BitAnd for InjectedInputPointerOptions {
1278 type Output = Self;
1279 fn bitand(self, other: Self) -> Self {
1280 Self(self.0 & other.0)
1281 }
1282}
1283impl ::core::ops::BitOrAssign for InjectedInputPointerOptions {
1284 fn bitor_assign(&mut self, other: Self) {
1285 self.0.bitor_assign(other.0)
1286 }
1287}
1288impl ::core::ops::BitAndAssign for InjectedInputPointerOptions {
1289 fn bitand_assign(&mut self, other: Self) {
1290 self.0.bitand_assign(other.0)
1291 }
1292}
1293impl ::core::ops::Not for InjectedInputPointerOptions {
1294 type Output = Self;
1295 fn not(self) -> Self {
1296 Self(self.0.not())
1297 }
1298}
1299impl ::windows::core::RuntimeType for InjectedInputPointerOptions {
1300 const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"enum(Windows.UI.Input.Preview.Injection.InjectedInputPointerOptions;u4)");
1301}
1302#[doc = "*Required features: `\"UI_Input_Preview_Injection\"`*"]
1303#[repr(transparent)]
1304#[derive(::core::cmp::PartialEq, ::core::cmp::Eq)]
1305pub struct InjectedInputShortcut(pub i32);
1306impl InjectedInputShortcut {
1307 pub const Back: Self = Self(0i32);
1308 pub const Start: Self = Self(1i32);
1309 pub const Search: Self = Self(2i32);
1310}
1311impl ::core::marker::Copy for InjectedInputShortcut {}
1312impl ::core::clone::Clone for InjectedInputShortcut {
1313 fn clone(&self) -> Self {
1314 *self
1315 }
1316}
1317impl ::core::default::Default for InjectedInputShortcut {
1318 fn default() -> Self {
1319 Self(0)
1320 }
1321}
1322impl ::windows::core::TypeKind for InjectedInputShortcut {
1323 type TypeKind = ::windows::core::CopyType;
1324}
1325impl ::core::fmt::Debug for InjectedInputShortcut {
1326 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
1327 f.debug_tuple("InjectedInputShortcut").field(&self.0).finish()
1328 }
1329}
1330impl ::windows::core::RuntimeType for InjectedInputShortcut {
1331 const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"enum(Windows.UI.Input.Preview.Injection.InjectedInputShortcut;i4)");
1332}
1333#[doc = "*Required features: `\"UI_Input_Preview_Injection\"`*"]
1334#[repr(transparent)]
1335#[derive(::core::cmp::PartialEq, ::core::cmp::Eq)]
1336pub struct InjectedInputTouchParameters(pub u32);
1337impl InjectedInputTouchParameters {
1338 pub const None: Self = Self(0u32);
1339 pub const Contact: Self = Self(1u32);
1340 pub const Orientation: Self = Self(2u32);
1341 pub const Pressure: Self = Self(4u32);
1342}
1343impl ::core::marker::Copy for InjectedInputTouchParameters {}
1344impl ::core::clone::Clone for InjectedInputTouchParameters {
1345 fn clone(&self) -> Self {
1346 *self
1347 }
1348}
1349impl ::core::default::Default for InjectedInputTouchParameters {
1350 fn default() -> Self {
1351 Self(0)
1352 }
1353}
1354impl ::windows::core::TypeKind for InjectedInputTouchParameters {
1355 type TypeKind = ::windows::core::CopyType;
1356}
1357impl ::core::fmt::Debug for InjectedInputTouchParameters {
1358 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
1359 f.debug_tuple("InjectedInputTouchParameters").field(&self.0).finish()
1360 }
1361}
1362impl InjectedInputTouchParameters {
1363 pub const fn contains(&self, other: Self) -> bool {
1364 self.0 & other.0 == other.0
1365 }
1366}
1367impl ::core::ops::BitOr for InjectedInputTouchParameters {
1368 type Output = Self;
1369 fn bitor(self, other: Self) -> Self {
1370 Self(self.0 | other.0)
1371 }
1372}
1373impl ::core::ops::BitAnd for InjectedInputTouchParameters {
1374 type Output = Self;
1375 fn bitand(self, other: Self) -> Self {
1376 Self(self.0 & other.0)
1377 }
1378}
1379impl ::core::ops::BitOrAssign for InjectedInputTouchParameters {
1380 fn bitor_assign(&mut self, other: Self) {
1381 self.0.bitor_assign(other.0)
1382 }
1383}
1384impl ::core::ops::BitAndAssign for InjectedInputTouchParameters {
1385 fn bitand_assign(&mut self, other: Self) {
1386 self.0.bitand_assign(other.0)
1387 }
1388}
1389impl ::core::ops::Not for InjectedInputTouchParameters {
1390 type Output = Self;
1391 fn not(self) -> Self {
1392 Self(self.0.not())
1393 }
1394}
1395impl ::windows::core::RuntimeType for InjectedInputTouchParameters {
1396 const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"enum(Windows.UI.Input.Preview.Injection.InjectedInputTouchParameters;u4)");
1397}
1398#[doc = "*Required features: `\"UI_Input_Preview_Injection\"`*"]
1399#[repr(transparent)]
1400#[derive(::core::cmp::PartialEq, ::core::cmp::Eq)]
1401pub struct InjectedInputVisualizationMode(pub i32);
1402impl InjectedInputVisualizationMode {
1403 pub const None: Self = Self(0i32);
1404 pub const Default: Self = Self(1i32);
1405 pub const Indirect: Self = Self(2i32);
1406}
1407impl ::core::marker::Copy for InjectedInputVisualizationMode {}
1408impl ::core::clone::Clone for InjectedInputVisualizationMode {
1409 fn clone(&self) -> Self {
1410 *self
1411 }
1412}
1413impl ::core::default::Default for InjectedInputVisualizationMode {
1414 fn default() -> Self {
1415 Self(0)
1416 }
1417}
1418impl ::windows::core::TypeKind for InjectedInputVisualizationMode {
1419 type TypeKind = ::windows::core::CopyType;
1420}
1421impl ::core::fmt::Debug for InjectedInputVisualizationMode {
1422 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
1423 f.debug_tuple("InjectedInputVisualizationMode").field(&self.0).finish()
1424 }
1425}
1426impl ::windows::core::RuntimeType for InjectedInputVisualizationMode {
1427 const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"enum(Windows.UI.Input.Preview.Injection.InjectedInputVisualizationMode;i4)");
1428}
1429#[repr(C)]
1430#[doc = "*Required features: `\"UI_Input_Preview_Injection\"`*"]
1431pub struct InjectedInputPoint {
1432 pub PositionX: i32,
1433 pub PositionY: i32,
1434}
1435impl ::core::marker::Copy for InjectedInputPoint {}
1436impl ::core::clone::Clone for InjectedInputPoint {
1437 fn clone(&self) -> Self {
1438 *self
1439 }
1440}
1441impl ::core::fmt::Debug for InjectedInputPoint {
1442 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
1443 f.debug_struct("InjectedInputPoint").field("PositionX", &self.PositionX).field("PositionY", &self.PositionY).finish()
1444 }
1445}
1446impl ::windows::core::TypeKind for InjectedInputPoint {
1447 type TypeKind = ::windows::core::CopyType;
1448}
1449impl ::windows::core::RuntimeType for InjectedInputPoint {
1450 const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"struct(Windows.UI.Input.Preview.Injection.InjectedInputPoint;i4;i4)");
1451}
1452impl ::core::cmp::PartialEq for InjectedInputPoint {
1453 fn eq(&self, other: &Self) -> bool {
1454 self.PositionX == other.PositionX && self.PositionY == other.PositionY
1455 }
1456}
1457impl ::core::cmp::Eq for InjectedInputPoint {}
1458impl ::core::default::Default for InjectedInputPoint {
1459 fn default() -> Self {
1460 unsafe { ::core::mem::zeroed() }
1461 }
1462}
1463#[repr(C)]
1464#[doc = "*Required features: `\"UI_Input_Preview_Injection\"`*"]
1465pub struct InjectedInputPointerInfo {
1466 pub PointerId: u32,
1467 pub PointerOptions: InjectedInputPointerOptions,
1468 pub PixelLocation: InjectedInputPoint,
1469 pub TimeOffsetInMilliseconds: u32,
1470 pub PerformanceCount: u64,
1471}
1472impl ::core::marker::Copy for InjectedInputPointerInfo {}
1473impl ::core::clone::Clone for InjectedInputPointerInfo {
1474 fn clone(&self) -> Self {
1475 *self
1476 }
1477}
1478impl ::core::fmt::Debug for InjectedInputPointerInfo {
1479 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
1480 f.debug_struct("InjectedInputPointerInfo").field("PointerId", &self.PointerId).field("PointerOptions", &self.PointerOptions).field("PixelLocation", &self.PixelLocation).field("TimeOffsetInMilliseconds", &self.TimeOffsetInMilliseconds).field("PerformanceCount", &self.PerformanceCount).finish()
1481 }
1482}
1483impl ::windows::core::TypeKind for InjectedInputPointerInfo {
1484 type TypeKind = ::windows::core::CopyType;
1485}
1486impl ::windows::core::RuntimeType for InjectedInputPointerInfo {
1487 const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"struct(Windows.UI.Input.Preview.Injection.InjectedInputPointerInfo;u4;enum(Windows.UI.Input.Preview.Injection.InjectedInputPointerOptions;u4);struct(Windows.UI.Input.Preview.Injection.InjectedInputPoint;i4;i4);u4;u8)");
1488}
1489impl ::core::cmp::PartialEq for InjectedInputPointerInfo {
1490 fn eq(&self, other: &Self) -> bool {
1491 self.PointerId == other.PointerId && self.PointerOptions == other.PointerOptions && self.PixelLocation == other.PixelLocation && self.TimeOffsetInMilliseconds == other.TimeOffsetInMilliseconds && self.PerformanceCount == other.PerformanceCount
1492 }
1493}
1494impl ::core::cmp::Eq for InjectedInputPointerInfo {}
1495impl ::core::default::Default for InjectedInputPointerInfo {
1496 fn default() -> Self {
1497 unsafe { ::core::mem::zeroed() }
1498 }
1499}
1500#[repr(C)]
1501#[doc = "*Required features: `\"UI_Input_Preview_Injection\"`*"]
1502pub struct InjectedInputRectangle {
1503 pub Left: i32,
1504 pub Top: i32,
1505 pub Bottom: i32,
1506 pub Right: i32,
1507}
1508impl ::core::marker::Copy for InjectedInputRectangle {}
1509impl ::core::clone::Clone for InjectedInputRectangle {
1510 fn clone(&self) -> Self {
1511 *self
1512 }
1513}
1514impl ::core::fmt::Debug for InjectedInputRectangle {
1515 fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
1516 f.debug_struct("InjectedInputRectangle").field("Left", &self.Left).field("Top", &self.Top).field("Bottom", &self.Bottom).field("Right", &self.Right).finish()
1517 }
1518}
1519impl ::windows::core::TypeKind for InjectedInputRectangle {
1520 type TypeKind = ::windows::core::CopyType;
1521}
1522impl ::windows::core::RuntimeType for InjectedInputRectangle {
1523 const SIGNATURE: ::windows::imp::ConstBuffer = ::windows::imp::ConstBuffer::from_slice(b"struct(Windows.UI.Input.Preview.Injection.InjectedInputRectangle;i4;i4;i4;i4)");
1524}
1525impl ::core::cmp::PartialEq for InjectedInputRectangle {
1526 fn eq(&self, other: &Self) -> bool {
1527 self.Left == other.Left && self.Top == other.Top && self.Bottom == other.Bottom && self.Right == other.Right
1528 }
1529}
1530impl ::core::cmp::Eq for InjectedInputRectangle {}
1531impl ::core::default::Default for InjectedInputRectangle {
1532 fn default() -> Self {
1533 unsafe { ::core::mem::zeroed() }
1534 }
1535}
1536#[cfg(feature = "implement")]
1537::core::include!("impl.rs");