xinput/enumerations/
devtype.rs

1use bytemuck::{Pod, Zeroable};
2use winapi::um::xinput::*;
3
4
5
6/// \[[microsoft.com](https://learn.microsoft.com/en-us/windows/win32/api/xinput/ns-xinput-xinput_capabilities)\]
7/// XINPUT_DEVTYPE_\*
8#[derive(Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash)]
9#[derive(Pod, Zeroable)]
10#[repr(transparent)] pub struct DevType(u8);
11
12enumish! { DevType => u8; Gamepad }
13
14#[allow(non_upper_case_globals)] impl DevType {
15    /// The device is a game controller.
16    pub const Gamepad : DevType = DevType(XINPUT_DEVTYPE_GAMEPAD as _); // 1
17}
18
19//#cpp2rust XINPUT_DEVTYPE_GAMEPAD = xinput::DevType::Gamepad