[INFO] cloning repository https://github.com/rlabrecque/rl-audio-device-hotkey [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/rlabrecque/rl-audio-device-hotkey" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Frlabrecque%2Frl-audio-device-hotkey", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Frlabrecque%2Frl-audio-device-hotkey'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] f7735bb37eda1844fbd158a1f93dc330758b0b5c [INFO] checking rlabrecque/rl-audio-device-hotkey against master#1f12b9b0fdbe735968ac002792a720f0ba4faca6 for crater-rollup-uwu [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Frlabrecque%2Frl-audio-device-hotkey" "/workspace/builds/worker-6-tc1/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-6-tc1/source'... [INFO] [stderr] done. [INFO] validating manifest of git repo https://github.com/rlabrecque/rl-audio-device-hotkey on toolchain 1f12b9b0fdbe735968ac002792a720f0ba4faca6 [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+1f12b9b0fdbe735968ac002792a720f0ba4faca6" "metadata" "--manifest-path" "Cargo.toml" "--no-deps", kill_on_drop: false }` [INFO] started tweaking git repo https://github.com/rlabrecque/rl-audio-device-hotkey [INFO] finished tweaking git repo https://github.com/rlabrecque/rl-audio-device-hotkey [INFO] tweaked toml for git repo https://github.com/rlabrecque/rl-audio-device-hotkey written to /workspace/builds/worker-6-tc1/source/Cargo.toml [INFO] crate git repo https://github.com/rlabrecque/rl-audio-device-hotkey already has a lockfile, it will not be regenerated [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+1f12b9b0fdbe735968ac002792a720f0ba4faca6" "fetch" "--manifest-path" "Cargo.toml", kill_on_drop: false }` [INFO] [stderr] Updating crates.io index [INFO] [stderr] Downloading crates ... [INFO] [stderr] Downloaded windows v0.7.0 [INFO] [stderr] Downloaded windows_macros v0.7.0 [INFO] [stderr] Downloaded squote v0.1.2 [INFO] [stderr] Downloaded windows_gen v0.7.0 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-6-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-6-tc1/source:/opt/rustwide/workdir:ro,Z" "-v" "/var/lib/crater-agent-workspace/cargo-home:/opt/rustwide/cargo-home:ro,Z" "-v" "/var/lib/crater-agent-workspace/rustup-home:/opt/rustwide/rustup-home:ro,Z" "-e" "SOURCE_DIR=/opt/rustwide/workdir" "-e" "CARGO_TARGET_DIR=/opt/rustwide/target" "-e" "CARGO_HOME=/opt/rustwide/cargo-home" "-e" "RUSTUP_HOME=/opt/rustwide/rustup-home" "-w" "/opt/rustwide/workdir" "-m" "1610612736" "--user" "0:0" "--network" "none" "ghcr.io/rust-lang/crates-build-env/linux@sha256:923055f121b5182466d55868a8b05e67af8ba4a3a3f6bad814e953ca3cd3ac2a" "/opt/rustwide/cargo-home/bin/cargo" "+1f12b9b0fdbe735968ac002792a720f0ba4faca6" "metadata" "--no-deps" "--format-version=1", kill_on_drop: false }` [INFO] [stdout] 8490ba8471f3b1e0b1404d2d15ec64b1c3d932fbc55d3b701fef94954d7574a0 [INFO] running `Command { std: "docker" "start" "-a" "8490ba8471f3b1e0b1404d2d15ec64b1c3d932fbc55d3b701fef94954d7574a0", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "8490ba8471f3b1e0b1404d2d15ec64b1c3d932fbc55d3b701fef94954d7574a0", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "8490ba8471f3b1e0b1404d2d15ec64b1c3d932fbc55d3b701fef94954d7574a0", kill_on_drop: false }` [INFO] [stdout] 8490ba8471f3b1e0b1404d2d15ec64b1c3d932fbc55d3b701fef94954d7574a0 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-6-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-6-tc1/source:/opt/rustwide/workdir:ro,Z" "-v" "/var/lib/crater-agent-workspace/cargo-home:/opt/rustwide/cargo-home:ro,Z" "-v" "/var/lib/crater-agent-workspace/rustup-home:/opt/rustwide/rustup-home:ro,Z" "-e" "SOURCE_DIR=/opt/rustwide/workdir" "-e" "CARGO_TARGET_DIR=/opt/rustwide/target" "-e" "CARGO_INCREMENTAL=0" "-e" "RUST_BACKTRACE=full" "-e" "RUSTFLAGS=--cap-lints=forbid" "-e" "RUSTDOCFLAGS=--cap-lints=forbid" "-e" "CARGO_HOME=/opt/rustwide/cargo-home" "-e" "RUSTUP_HOME=/opt/rustwide/rustup-home" "-w" "/opt/rustwide/workdir" "-m" "1610612736" "--user" "0:0" "--network" "none" "ghcr.io/rust-lang/crates-build-env/linux@sha256:923055f121b5182466d55868a8b05e67af8ba4a3a3f6bad814e953ca3cd3ac2a" "/opt/rustwide/cargo-home/bin/cargo" "+1f12b9b0fdbe735968ac002792a720f0ba4faca6" "check" "--frozen" "--all" "--all-targets" "--message-format=json", kill_on_drop: false }` [INFO] [stdout] 082e163047b465586b36cee4e3591ae726e14f278345636f52618d3f64a599fa [INFO] running `Command { std: "docker" "start" "-a" "082e163047b465586b36cee4e3591ae726e14f278345636f52618d3f64a599fa", kill_on_drop: false }` [INFO] [stderr] Compiling proc-macro2 v1.0.26 [INFO] [stderr] Compiling syn v1.0.69 [INFO] [stderr] Compiling unicode-xid v0.2.1 [INFO] [stderr] Compiling squote v0.1.2 [INFO] [stderr] Compiling const-sha1 v0.2.0 [INFO] [stderr] Checking widestring v0.4.3 [INFO] [stderr] Checking quote v1.0.9 [INFO] [stderr] Checking windows_gen v0.7.0 [INFO] [stderr] Compiling windows_macros v0.7.0 [INFO] [stderr] Compiling windows v0.7.0 [INFO] [stderr] Compiling bindings v0.1.0 (/opt/rustwide/workdir/bindings) [INFO] [stdout] warning: unused return value of `Box::::from_raw` that must be used [INFO] [stdout] --> /opt/rustwide/target/debug/build/bindings-082b36382e0f0520/out/windows.rs:1:17322 [INFO] [stdout] | [INFO] [stdout] 1 | ... { if ! value . 0 . is_null ( ) { unsafe { :: std :: boxed :: Box :: from_raw ( value . 0 ) ; } } } } } impl < 'a > :: windows :: Into... [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: call `drop(Box::from_raw(ptr))` if you intend to drop the `Box` [INFO] [stdout] = note: `#[warn(unused_must_use)]` on by default [INFO] [stdout] help: use `let _ = ...` to ignore the resulting value [INFO] [stdout] | [INFO] [stdout] 1 | # [ allow ( unused_variables , non_upper_case_globals , non_snake_case , unused_unsafe , non_camel_case_types , dead_code , clippy :: all ) ] pub mod Windows { # [ allow ( unused_variables , non_upper_case_globals , non_snake_case , unused_unsafe , non_camel_case_types , dead_code , clippy :: all ) ] pub mod Win32 { # [ allow ( unused_variables , non_upper_case_globals , non_snake_case , unused_unsafe , non_camel_case_types , dead_code , clippy :: all ) ] pub mod CoreAudio { # [ derive ( :: std :: cmp :: PartialEq , :: std :: cmp :: Eq , :: std :: marker :: Copy , :: std :: clone :: Clone , :: std :: default :: Default , :: std :: fmt :: Debug ) ] # [ repr ( transparent ) ] pub struct EDataFlow ( pub i32 ) ; impl EDataFlow { pub const eRender : Self = Self ( 0i32 ) ; pub const eCapture : Self = Self ( 1i32 ) ; pub const eAll : Self = Self ( 2i32 ) ; pub const EDataFlow_enum_count : Self = Self ( 3i32 ) ; } impl :: std :: convert :: From < i32 > for EDataFlow { fn from ( value : i32 ) -> Self { Self ( value ) } } unsafe impl :: windows :: Abi for EDataFlow { type Abi = Self ; } # [ derive ( :: std :: cmp :: PartialEq , :: std :: cmp :: Eq , :: std :: marker :: Copy , :: std :: clone :: Clone , :: std :: default :: Default , :: std :: fmt :: Debug ) ] # [ repr ( transparent ) ] pub struct ERole ( pub i32 ) ; impl ERole { pub const eConsole : Self = Self ( 0i32 ) ; pub const eMultimedia : Self = Self ( 1i32 ) ; pub const eCommunications : Self = Self ( 2i32 ) ; pub const ERole_enum_count : Self = Self ( 3i32 ) ; } impl :: std :: convert :: From < i32 > for ERole { fn from ( value : i32 ) -> Self { Self ( value ) } } unsafe impl :: windows :: Abi for ERole { type Abi = Self ; } # [ repr ( transparent ) ] # [ derive ( :: std :: cmp :: PartialEq , :: std :: cmp :: Eq , :: std :: clone :: Clone , :: std :: fmt :: Debug ) ] pub struct IMMDevice ( :: windows :: IUnknown ) ; impl IMMDevice { } unsafe impl :: windows :: Interface for IMMDevice { type Vtable = IMMDevice_abi ; const IID : :: windows :: Guid = :: windows :: Guid :: from_values ( 3597010495 ,5511 ,20035 , [ 129 ,241 ,185 ,72 ,232 ,7 ,54 ,63 ] , ) ; } impl IMMDevice { pub unsafe fn GetId < > ( & self , ppstrid : * mut super :: SystemServices :: PWSTR , ) -> :: windows :: ErrorCode { ( :: windows :: Interface :: vtable ( self ) .5 ) ( :: windows :: Abi :: abi ( self ) , :: std :: mem :: transmute ( ppstrid ) , ) } pub unsafe fn GetState < > ( & self , pdwstate : * mut u32 , ) -> :: windows :: ErrorCode { ( :: windows :: Interface :: vtable ( self ) .6 ) ( :: windows :: Abi :: abi ( self ) , :: std :: mem :: transmute ( pdwstate ) , ) } } impl :: std :: convert :: From < IMMDevice > for :: windows :: IUnknown { fn from ( value : IMMDevice ) -> Self { unsafe { :: std :: mem :: transmute ( value ) } } } impl :: std :: convert :: From < & IMMDevice > for :: windows :: IUnknown { fn from ( value : & IMMDevice ) -> Self { :: std :: convert :: From :: from ( :: std :: clone :: Clone :: clone ( value ) ) } } impl < 'a > :: windows :: IntoParam < 'a , :: windows :: IUnknown > for IMMDevice { fn into_param ( self ) -> :: windows :: Param < 'a , :: windows :: IUnknown > { :: windows :: Param :: Owned ( :: std :: convert :: Into :: < :: windows :: IUnknown > :: into ( self ) ) } } impl < 'a > :: windows :: IntoParam < 'a , :: windows :: IUnknown > for & 'a IMMDevice { fn into_param ( self ) -> :: windows :: Param < 'a , :: windows :: IUnknown > { :: windows :: Param :: Owned ( :: std :: convert :: Into :: < :: windows :: IUnknown > :: into ( :: std :: clone :: Clone :: clone ( self ) ) ) } } # [ repr ( C ) ] # [ doc ( hidden ) ] pub struct IMMDevice_abi ( pub unsafe extern "system" fn ( this : :: windows :: RawPtr , iid : & :: windows :: Guid , interface : * mut :: windows :: RawPtr ) -> :: windows :: ErrorCode , pub unsafe extern "system" fn ( this : :: windows :: RawPtr ) -> u32 , pub unsafe extern "system" fn ( this : :: windows :: RawPtr ) -> u32 , pub unsafe extern "system" fn ( ) , pub unsafe extern "system" fn ( ) , pub unsafe extern "system" fn ( this : :: windows :: RawPtr , ppstrid : * mut super :: SystemServices :: PWSTR , ) -> :: windows :: ErrorCode , pub unsafe extern "system" fn ( this : :: windows :: RawPtr , pdwstate : * mut u32 , ) -> :: windows :: ErrorCode , ) ; # [ repr ( transparent ) ] # [ derive ( :: std :: cmp :: PartialEq , :: std :: cmp :: Eq , :: std :: clone :: Clone , :: std :: fmt :: Debug ) ] pub struct IMMDeviceCollection ( :: windows :: IUnknown ) ; impl IMMDeviceCollection { } unsafe impl :: windows :: Interface for IMMDeviceCollection { type Vtable = IMMDeviceCollection_abi ; const IID : :: windows :: Guid = :: windows :: Guid :: from_values ( 198681022 ,31258 ,17627 , [ 131 ,151 ,204 ,83 ,146 ,56 ,123 ,94 ] , ) ; } impl IMMDeviceCollection { pub unsafe fn GetCount < > ( & self , pcdevices : * mut u32 , ) -> :: windows :: ErrorCode { ( :: windows :: Interface :: vtable ( self ) .3 ) ( :: windows :: Abi :: abi ( self ) , :: std :: mem :: transmute ( pcdevices ) , ) } pub unsafe fn Item < > ( & self , ndevice : u32 , ppdevice : * mut :: std :: option :: Option < IMMDevice > , ) -> :: windows :: ErrorCode { ( :: windows :: Interface :: vtable ( self ) .4 ) ( :: windows :: Abi :: abi ( self ) , :: std :: mem :: transmute ( ndevice ) , :: std :: mem :: transmute ( ppdevice ) , ) } } impl :: std :: convert :: From < IMMDeviceCollection > for :: windows :: IUnknown { fn from ( value : IMMDeviceCollection ) -> Self { unsafe { :: std :: mem :: transmute ( value ) } } } impl :: std :: convert :: From < & IMMDeviceCollection > for :: windows :: IUnknown { fn from ( value : & IMMDeviceCollection ) -> Self { :: std :: convert :: From :: from ( :: std :: clone :: Clone :: clone ( value ) ) } } impl < 'a > :: windows :: IntoParam < 'a , :: windows :: IUnknown > for IMMDeviceCollection { fn into_param ( self ) -> :: windows :: Param < 'a , :: windows :: IUnknown > { :: windows :: Param :: Owned ( :: std :: convert :: Into :: < :: windows :: IUnknown > :: into ( self ) ) } } impl < 'a > :: windows :: IntoParam < 'a , :: windows :: IUnknown > for & 'a IMMDeviceCollection { fn into_param ( self ) -> :: windows :: Param < 'a , :: windows :: IUnknown > { :: windows :: Param :: Owned ( :: std :: convert :: Into :: < :: windows :: IUnknown > :: into ( :: std :: clone :: Clone :: clone ( self ) ) ) } } # [ repr ( C ) ] # [ doc ( hidden ) ] pub struct IMMDeviceCollection_abi ( pub unsafe extern "system" fn ( this : :: windows :: RawPtr , iid : & :: windows :: Guid , interface : * mut :: windows :: RawPtr ) -> :: windows :: ErrorCode , pub unsafe extern "system" fn ( this : :: windows :: RawPtr ) -> u32 , pub unsafe extern "system" fn ( this : :: windows :: RawPtr ) -> u32 , pub unsafe extern "system" fn ( this : :: windows :: RawPtr , pcdevices : * mut u32 , ) -> :: windows :: ErrorCode , pub unsafe extern "system" fn ( this : :: windows :: RawPtr , ndevice : u32 , ppdevice : * mut :: windows :: RawPtr , ) -> :: windows :: ErrorCode , ) ; # [ repr ( transparent ) ] # [ derive ( :: std :: cmp :: PartialEq , :: std :: cmp :: Eq , :: std :: clone :: Clone , :: std :: fmt :: Debug ) ] pub struct IMMDeviceEnumerator ( :: windows :: IUnknown ) ; impl IMMDeviceEnumerator { } unsafe impl :: windows :: Interface for IMMDeviceEnumerator { type Vtable = IMMDeviceEnumerator_abi ; const IID : :: windows :: Guid = :: windows :: Guid :: from_values ( 2841011410 ,38420 ,20277 , [ 167 ,70 ,222 ,141 ,182 ,54 ,23 ,230 ] , ) ; } impl IMMDeviceEnumerator { pub unsafe fn EnumAudioEndpoints < > ( & self , dataflow : EDataFlow , dwstatemask : u32 , ppdevices : * mut :: std :: option :: Option < IMMDeviceCollection > , ) -> :: windows :: ErrorCode { ( :: windows :: Interface :: vtable ( self ) .3 ) ( :: windows :: Abi :: abi ( self ) , :: std :: mem :: transmute ( dataflow ) , :: std :: mem :: transmute ( dwstatemask ) , :: std :: mem :: transmute ( ppdevices ) , ) } pub unsafe fn GetDefaultAudioEndpoint < > ( & self , dataflow : EDataFlow , role : ERole , ppendpoint : * mut :: std :: option :: Option < IMMDevice > , ) -> :: windows :: ErrorCode { ( :: windows :: Interface :: vtable ( self ) .4 ) ( :: windows :: Abi :: abi ( self ) , :: std :: mem :: transmute ( dataflow ) , :: std :: mem :: transmute ( role ) , :: std :: mem :: transmute ( ppendpoint ) , ) } pub unsafe fn GetDevice < 'a , T0__ : :: windows :: IntoParam < 'a , super :: SystemServices :: PWSTR > , > ( & self , pwstrid : T0__ , ppdevice : * mut :: std :: option :: Option < IMMDevice > , ) -> :: windows :: ErrorCode { ( :: windows :: Interface :: vtable ( self ) .5 ) ( :: windows :: Abi :: abi ( self ) , pwstrid . into_param ( ) . abi ( ) , :: std :: mem :: transmute ( ppdevice ) , ) } } impl :: std :: convert :: From < IMMDeviceEnumerator > for :: windows :: IUnknown { fn from ( value : IMMDeviceEnumerator ) -> Self { unsafe { :: std :: mem :: transmute ( value ) } } } impl :: std :: convert :: From < & IMMDeviceEnumerator > for :: windows :: IUnknown { fn from ( value : & IMMDeviceEnumerator ) -> Self { :: std :: convert :: From :: from ( :: std :: clone :: Clone :: clone ( value ) ) } } impl < 'a > :: windows :: IntoParam < 'a , :: windows :: IUnknown > for IMMDeviceEnumerator { fn into_param ( self ) -> :: windows :: Param < 'a , :: windows :: IUnknown > { :: windows :: Param :: Owned ( :: std :: convert :: Into :: < :: windows :: IUnknown > :: into ( self ) ) } } impl < 'a > :: windows :: IntoParam < 'a , :: windows :: IUnknown > for & 'a IMMDeviceEnumerator { fn into_param ( self ) -> :: windows :: Param < 'a , :: windows :: IUnknown > { :: windows :: Param :: Owned ( :: std :: convert :: Into :: < :: windows :: IUnknown > :: into ( :: std :: clone :: Clone :: clone ( self ) ) ) } } # [ repr ( C ) ] # [ doc ( hidden ) ] pub struct IMMDeviceEnumerator_abi ( pub unsafe extern "system" fn ( this : :: windows :: RawPtr , iid : & :: windows :: Guid , interface : * mut :: windows :: RawPtr ) -> :: windows :: ErrorCode , pub unsafe extern "system" fn ( this : :: windows :: RawPtr ) -> u32 , pub unsafe extern "system" fn ( this : :: windows :: RawPtr ) -> u32 , pub unsafe extern "system" fn ( this : :: windows :: RawPtr , dataflow : EDataFlow , dwstatemask : u32 , ppdevices : * mut :: windows :: RawPtr , ) -> :: windows :: ErrorCode , pub unsafe extern "system" fn ( this : :: windows :: RawPtr , dataflow : EDataFlow , role : ERole , ppendpoint : * mut :: windows :: RawPtr , ) -> :: windows :: ErrorCode , pub unsafe extern "system" fn ( this : :: windows :: RawPtr , pwstrid : super :: SystemServices :: PWSTR , ppdevice : * mut :: windows :: RawPtr , ) -> :: windows :: ErrorCode , pub unsafe extern "system" fn ( ) , pub unsafe extern "system" fn ( ) , ) ; pub const MMDeviceEnumerator : :: windows :: Guid = :: windows :: Guid :: from_values ( 3168666517 ,58671 ,18044 , [ 142 ,61 ,196 ,87 ,146 ,145 ,105 ,46 ] , ) ; pub const DEVICE_STATE_ACTIVE : u32 = 1u32 ; } # [ allow ( unused_variables , non_upper_case_globals , non_snake_case , unused_unsafe , non_camel_case_types , dead_code , clippy :: all ) ] pub mod Debug { pub unsafe fn GetLastError < > ( ) -> u32 { panic ! ( "Unsupported target OS" ) ; } } # [ allow ( unused_variables , non_upper_case_globals , non_snake_case , unused_unsafe , non_camel_case_types , dead_code , clippy :: all ) ] pub mod DisplayDevices { # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy ) ] pub struct POINT { pub x : i32 , pub y : i32 } impl POINT { } impl :: std :: default :: Default for POINT { fn default ( ) -> Self { Self { x : 0 , y : 0 } } } impl :: std :: fmt :: Debug for POINT { fn fmt ( & self , fmt : & mut :: std :: fmt :: Formatter < '_ > ) -> :: std :: fmt :: Result { fmt . debug_struct ( "POINT" ) . field ( "x" , & format_args ! ( "{:?}" , self . x ) ) . field ( "y" , & format_args ! ( "{:?}" , self . y ) ) . finish ( ) } } impl :: std :: cmp :: PartialEq for POINT { fn eq ( & self , other : & Self ) -> bool { self . x == other . x && self . y == other . y } } impl :: std :: cmp :: Eq for POINT { } unsafe impl :: windows :: Abi for POINT { type Abi = Self ; } } # [ allow ( unused_variables , non_upper_case_globals , non_snake_case , unused_unsafe , non_camel_case_types , dead_code , clippy :: all ) ] pub mod Gdi { # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy ) ] pub struct HGDIOBJ ( pub isize ) ; impl HGDIOBJ { } impl :: std :: default :: Default for HGDIOBJ { fn default ( ) -> Self { Self ( 0 ) } } impl :: std :: fmt :: Debug for HGDIOBJ { fn fmt ( & self , fmt : & mut :: std :: fmt :: Formatter < '_ > ) -> :: std :: fmt :: Result { fmt . debug_struct ( "HGDIOBJ" ) . field ( "Value" , & format_args ! ( "{:?}" , self .0 ) ) . finish ( ) } } impl :: std :: cmp :: PartialEq for HGDIOBJ { fn eq ( & self , other : & Self ) -> bool { self .0 == other .0 } } impl :: std :: cmp :: Eq for HGDIOBJ { } unsafe impl :: windows :: Abi for HGDIOBJ { type Abi = Self ; } # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy ) ] pub struct HBRUSH ( pub isize ) ; impl HBRUSH { } impl :: std :: default :: Default for HBRUSH { fn default ( ) -> Self { Self ( 0 ) } } impl :: std :: fmt :: Debug for HBRUSH { fn fmt ( & self , fmt : & mut :: std :: fmt :: Formatter < '_ > ) -> :: std :: fmt :: Result { fmt . debug_struct ( "HBRUSH" ) . field ( "Value" , & format_args ! ( "{:?}" , self .0 ) ) . finish ( ) } } impl :: std :: cmp :: PartialEq for HBRUSH { fn eq ( & self , other : & Self ) -> bool { self .0 == other .0 } } impl :: std :: cmp :: Eq for HBRUSH { } unsafe impl :: windows :: Abi for HBRUSH { type Abi = Self ; } impl < 'a > :: windows :: IntoParam < 'a , HGDIOBJ > for HBRUSH { fn into_param ( self ) -> :: windows :: Param < 'a , HGDIOBJ > { :: windows :: Param :: Owned ( HGDIOBJ ( self . 0 ) ) } } } # [ allow ( unused_variables , non_upper_case_globals , non_snake_case , unused_unsafe , non_camel_case_types , dead_code , clippy :: all ) ] pub mod KeyboardAndMouseInput { pub unsafe fn GetKeyState < > ( nvirtkey : i32 , ) -> i16 { panic ! ( "Unsupported target OS" ) ; } } # [ allow ( unused_variables , non_upper_case_globals , non_snake_case , unused_unsafe , non_camel_case_types , dead_code , clippy :: all ) ] pub mod MenusAndResources { # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy ) ] pub struct HMENU ( pub isize ) ; impl HMENU { } impl :: std :: default :: Default for HMENU { fn default ( ) -> Self { Self ( 0 ) } } impl :: std :: fmt :: Debug for HMENU { fn fmt ( & self , fmt : & mut :: std :: fmt :: Formatter < '_ > ) -> :: std :: fmt :: Result { fmt . debug_struct ( "HMENU" ) . field ( "Value" , & format_args ! ( "{:?}" , self .0 ) ) . finish ( ) } } impl :: std :: cmp :: PartialEq for HMENU { fn eq ( & self , other : & Self ) -> bool { self .0 == other .0 } } impl :: std :: cmp :: Eq for HMENU { } unsafe impl :: windows :: Abi for HMENU { type Abi = Self ; } # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy ) ] pub struct HICON ( pub isize ) ; impl HICON { } impl :: std :: default :: Default for HICON { fn default ( ) -> Self { Self ( 0 ) } } impl :: std :: fmt :: Debug for HICON { fn fmt ( & self , fmt : & mut :: std :: fmt :: Formatter < '_ > ) -> :: std :: fmt :: Result { fmt . debug_struct ( "HICON" ) . field ( "Value" , & format_args ! ( "{:?}" , self .0 ) ) . finish ( ) } } impl :: std :: cmp :: PartialEq for HICON { fn eq ( & self , other : & Self ) -> bool { self .0 == other .0 } } impl :: std :: cmp :: Eq for HICON { } unsafe impl :: windows :: Abi for HICON { type Abi = Self ; } # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy ) ] pub struct HCURSOR ( pub isize ) ; impl HCURSOR { } impl :: std :: default :: Default for HCURSOR { fn default ( ) -> Self { Self ( 0 ) } } impl :: std :: fmt :: Debug for HCURSOR { fn fmt ( & self , fmt : & mut :: std :: fmt :: Formatter < '_ > ) -> :: std :: fmt :: Result { fmt . debug_struct ( "HCURSOR" ) . field ( "Value" , & format_args ! ( "{:?}" , self .0 ) ) . finish ( ) } } impl :: std :: cmp :: PartialEq for HCURSOR { fn eq ( & self , other : & Self ) -> bool { self .0 == other .0 } } impl :: std :: cmp :: Eq for HCURSOR { } unsafe impl :: windows :: Abi for HCURSOR { type Abi = Self ; } impl < 'a > :: windows :: IntoParam < 'a , HICON > for HCURSOR { fn into_param ( self ) -> :: windows :: Param < 'a , HICON > { :: windows :: Param :: Owned ( HICON ( self . 0 ) ) } } } # [ allow ( unused_variables , non_upper_case_globals , non_snake_case , unused_unsafe , non_camel_case_types , dead_code , clippy :: all ) ] pub mod SystemServices { # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy , :: std :: cmp :: Eq , :: std :: fmt :: Debug ) ] pub struct PSTR ( pub * mut u8 ) ; impl :: std :: default :: Default for PSTR { fn default ( ) -> Self { Self ( :: std :: ptr :: null_mut ( ) ) } } impl :: std :: cmp :: PartialEq for PSTR { fn eq ( & self , other : & Self ) -> bool { self . 0 == other . 0 } } unsafe impl :: windows :: Abi for PSTR { type Abi = Self ; fn drop_param ( param : & mut :: windows :: Param < Self > ) { if let :: windows :: Param :: Boxed ( value ) = param { if ! value . 0 . is_null ( ) { unsafe { let _ = :: std :: boxed :: Box :: from_raw ( value . 0 ) ; } } } } } impl < 'a > :: windows :: IntoParam < 'a , PSTR > for & 'a str { fn into_param ( self ) -> :: windows :: Param < 'a , PSTR > { :: windows :: Param :: Boxed ( PSTR ( :: std :: boxed :: Box :: < [ u8 ] > :: into_raw ( self . bytes ( ) . chain ( :: std :: iter :: once ( 0 ) ) . collect :: < std :: vec :: Vec < u8 >> ( ) . into_boxed_slice ( ) ) as _ ) ) } } impl < 'a > :: windows :: IntoParam < 'a , PSTR > for String { fn into_param ( self ) -> :: windows :: Param < 'a , PSTR > { :: windows :: Param :: Boxed ( PSTR ( :: std :: boxed :: Box :: < [ u8 ] > :: into_raw ( self . bytes ( ) . chain ( :: std :: iter :: once ( 0 ) ) . collect :: < std :: vec :: Vec < u8 >> ( ) . into_boxed_slice ( ) ) as _ ) ) } } pub unsafe fn GetModuleHandleA < 'a , T0__ : :: windows :: IntoParam < 'a , PSTR > , > ( lpmodulename : T0__ , ) -> isize { panic ! ( "Unsupported target OS" ) ; } # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy ) ] pub struct HINSTANCE ( pub isize ) ; impl HINSTANCE { } impl :: std :: default :: Default for HINSTANCE { fn default ( ) -> Self { Self ( 0 ) } } impl :: std :: fmt :: Debug for HINSTANCE { fn fmt ( & self , fmt : & mut :: std :: fmt :: Formatter < '_ > ) -> :: std :: fmt :: Result { fmt . debug_struct ( "HINSTANCE" ) . field ( "Value" , & format_args ! ( "{:?}" , self .0 ) ) . finish ( ) } } impl :: std :: cmp :: PartialEq for HINSTANCE { fn eq ( & self , other : & Self ) -> bool { self .0 == other .0 } } impl :: std :: cmp :: Eq for HINSTANCE { } unsafe impl :: windows :: Abi for HINSTANCE { type Abi = Self ; } # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy ) ] pub struct LRESULT ( pub i32 ) ; impl LRESULT { } impl :: std :: default :: Default for LRESULT { fn default ( ) -> Self { Self ( 0 ) } } impl :: std :: fmt :: Debug for LRESULT { fn fmt ( & self , fmt : & mut :: std :: fmt :: Formatter < '_ > ) -> :: std :: fmt :: Result { fmt . debug_struct ( "LRESULT" ) . field ( "Value" , & format_args ! ( "{:?}" , self .0 ) ) . finish ( ) } } impl :: std :: cmp :: PartialEq for LRESULT { fn eq ( & self , other : & Self ) -> bool { self .0 == other .0 } } impl :: std :: cmp :: Eq for LRESULT { } unsafe impl :: windows :: Abi for LRESULT { type Abi = Self ; } # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy , :: std :: cmp :: Eq , :: std :: fmt :: Debug ) ] pub struct PWSTR ( pub * mut u16 ) ; impl :: std :: default :: Default for PWSTR { fn default ( ) -> Self { Self ( :: std :: ptr :: null_mut ( ) ) } } impl :: std :: cmp :: PartialEq for PWSTR { fn eq ( & self , other : & Self ) -> bool { self . 0 == other . 0 } } unsafe impl :: windows :: Abi for PWSTR { type Abi = Self ; fn drop_param ( param : & mut :: windows :: Param < Self > ) { if let :: windows :: Param :: Boxed ( value ) = param { if ! value . 0 . is_null ( ) { unsafe { :: std :: boxed :: Box :: from_raw ( value . 0 ) ; } } } } } impl < 'a > :: windows :: IntoParam < 'a , PWSTR > for & 'a str { fn into_param ( self ) -> :: windows :: Param < 'a , PWSTR > { :: windows :: Param :: Boxed ( PWSTR ( :: std :: boxed :: Box :: < [ u16 ] > :: into_raw ( self . encode_utf16 ( ) . chain ( :: std :: iter :: once ( 0 ) ) . collect :: < std :: vec :: Vec < u16 >> ( ) . into_boxed_slice ( ) ) as _ ) ) } } impl < 'a > :: windows :: IntoParam < 'a , PWSTR > for String { fn into_param ( self ) -> :: windows :: Param < 'a , PWSTR > { :: windows :: Param :: Boxed ( PWSTR ( :: std :: boxed :: Box :: < [ u16 ] > :: into_raw ( self . encode_utf16 ( ) . chain ( :: std :: iter :: once ( 0 ) ) . collect :: < std :: vec :: Vec < u16 >> ( ) . into_boxed_slice ( ) ) as _ ) ) } } pub const S_OK : :: windows :: ErrorCode = :: windows :: ErrorCode ( 0i32 as _ ) ; # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy , :: std :: cmp :: PartialEq , :: std :: cmp :: Eq , :: std :: default :: Default ) ] pub struct BOOL ( pub i32 ) ; impl BOOL { # [ inline ] pub fn as_bool ( self ) -> bool { ! ( self . 0 == 0 ) } # [ inline ] pub fn ok ( self ) -> :: windows :: Result < ( ) > { if self . as_bool ( ) { Ok ( ( ) ) } else { Err ( :: windows :: ErrorCode :: from_thread ( ) . into ( ) ) } } # [ inline ] pub fn unwrap ( self ) { self . ok ( ) . unwrap ( ) ; } # [ inline ] pub fn expect ( self , msg : & str ) { self . ok ( ) . expect ( msg ) ; } } impl :: std :: fmt :: Debug for BOOL { fn fmt ( & self , fmt : & mut :: std :: fmt :: Formatter < '_ > ) -> :: std :: fmt :: Result { let msg = if self . as_bool ( ) { "true" } else { "false" } ; fmt . write_str ( msg ) } } unsafe impl :: windows :: Abi for BOOL { type Abi = Self ; } impl :: std :: convert :: From < BOOL > for bool { fn from ( value : BOOL ) -> Self { value . as_bool ( ) } } impl :: std :: convert :: From < & BOOL > for bool { fn from ( value : & BOOL ) -> Self { value . as_bool ( ) } } impl :: std :: convert :: From < bool > for BOOL { fn from ( value : bool ) -> Self { if value { BOOL ( 1 ) } else { BOOL ( 0 ) } } } impl :: std :: convert :: From < & bool > for BOOL { fn from ( value : & bool ) -> Self { ( * value ) . into ( ) } } impl :: std :: cmp :: PartialEq < bool > for BOOL { fn eq ( & self , other : & bool ) -> bool { self . as_bool ( ) == * other } } impl :: std :: cmp :: PartialEq < BOOL > for bool { fn eq ( & self , other : & BOOL ) -> bool { * self == other . as_bool ( ) } } impl std :: ops :: Not for BOOL { type Output = Self ; fn not ( self ) -> Self :: Output { if self . as_bool ( ) { BOOL ( 0 ) } else { BOOL ( 1 ) } } } impl < 'a > :: windows :: IntoParam < 'a , BOOL > for bool { fn into_param ( self ) -> :: windows :: Param < 'a , BOOL > { :: windows :: Param :: Owned ( self . into ( ) ) } } } # [ allow ( unused_variables , non_upper_case_globals , non_snake_case , unused_unsafe , non_camel_case_types , dead_code , clippy :: all ) ] pub mod WindowsAndMessaging { # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy ) ] pub struct HHOOK ( pub isize ) ; impl HHOOK { } impl :: std :: default :: Default for HHOOK { fn default ( ) -> Self { Self ( 0 ) } } impl :: std :: fmt :: Debug for HHOOK { fn fmt ( & self , fmt : & mut :: std :: fmt :: Formatter < '_ > ) -> :: std :: fmt :: Result { fmt . debug_struct ( "HHOOK" ) . field ( "Value" , & format_args ! ( "{:?}" , self .0 ) ) . finish ( ) } } impl :: std :: cmp :: PartialEq for HHOOK { fn eq ( & self , other : & Self ) -> bool { self .0 == other .0 } } impl :: std :: cmp :: Eq for HHOOK { } unsafe impl :: windows :: Abi for HHOOK { type Abi = Self ; } # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy ) ] pub struct WPARAM ( pub usize ) ; impl WPARAM { } impl :: std :: default :: Default for WPARAM { fn default ( ) -> Self { Self ( 0 ) } } impl :: std :: fmt :: Debug for WPARAM { fn fmt ( & self , fmt : & mut :: std :: fmt :: Formatter < '_ > ) -> :: std :: fmt :: Result { fmt . debug_struct ( "WPARAM" ) . field ( "Value" , & format_args ! ( "{:?}" , self .0 ) ) . finish ( ) } } impl :: std :: cmp :: PartialEq for WPARAM { fn eq ( & self , other : & Self ) -> bool { self .0 == other .0 } } impl :: std :: cmp :: Eq for WPARAM { } unsafe impl :: windows :: Abi for WPARAM { type Abi = Self ; } # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy ) ] pub struct LPARAM ( pub isize ) ; impl LPARAM { } impl :: std :: default :: Default for LPARAM { fn default ( ) -> Self { Self ( 0 ) } } impl :: std :: fmt :: Debug for LPARAM { fn fmt ( & self , fmt : & mut :: std :: fmt :: Formatter < '_ > ) -> :: std :: fmt :: Result { fmt . debug_struct ( "LPARAM" ) . field ( "Value" , & format_args ! ( "{:?}" , self .0 ) ) . finish ( ) } } impl :: std :: cmp :: PartialEq for LPARAM { fn eq ( & self , other : & Self ) -> bool { self .0 == other .0 } } impl :: std :: cmp :: Eq for LPARAM { } unsafe impl :: windows :: Abi for LPARAM { type Abi = Self ; } pub unsafe fn CallNextHookEx < 'a , T0__ : :: windows :: IntoParam < 'a , HHOOK > , T2__ : :: windows :: IntoParam < 'a , WPARAM > , T3__ : :: windows :: IntoParam < 'a , LPARAM > , > ( hhk : T0__ , ncode : i32 , wparam : T2__ , lparam : T3__ , ) -> super :: SystemServices :: LRESULT { panic ! ( "Unsupported target OS" ) ; } # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy ) ] pub struct HWND ( pub isize ) ; impl HWND { } impl :: std :: default :: Default for HWND { fn default ( ) -> Self { Self ( 0 ) } } impl :: std :: fmt :: Debug for HWND { fn fmt ( & self , fmt : & mut :: std :: fmt :: Formatter < '_ > ) -> :: std :: fmt :: Result { fmt . debug_struct ( "HWND" ) . field ( "Value" , & format_args ! ( "{:?}" , self .0 ) ) . finish ( ) } } impl :: std :: cmp :: PartialEq for HWND { fn eq ( & self , other : & Self ) -> bool { self .0 == other .0 } } impl :: std :: cmp :: Eq for HWND { } unsafe impl :: windows :: Abi for HWND { type Abi = Self ; } # [ derive ( :: std :: cmp :: PartialEq , :: std :: cmp :: Eq , :: std :: marker :: Copy , :: std :: clone :: Clone , :: std :: default :: Default , :: std :: fmt :: Debug ) ] # [ repr ( transparent ) ] pub struct WINDOW_EX_STYLE ( pub u32 ) ; impl WINDOW_EX_STYLE { pub const WS_EX_DLGMODALFRAME : Self = Self ( 1u32 ) ; pub const WS_EX_NOPARENTNOTIFY : Self = Self ( 4u32 ) ; pub const WS_EX_TOPMOST : Self = Self ( 8u32 ) ; pub const WS_EX_ACCEPTFILES : Self = Self ( 16u32 ) ; pub const WS_EX_TRANSPARENT : Self = Self ( 32u32 ) ; pub const WS_EX_MDICHILD : Self = Self ( 64u32 ) ; pub const WS_EX_TOOLWINDOW : Self = Self ( 128u32 ) ; pub const WS_EX_WINDOWEDGE : Self = Self ( 256u32 ) ; pub const WS_EX_CLIENTEDGE : Self = Self ( 512u32 ) ; pub const WS_EX_CONTEXTHELP : Self = Self ( 1024u32 ) ; pub const WS_EX_RIGHT : Self = Self ( 4096u32 ) ; pub const WS_EX_LEFT : Self = Self ( 0u32 ) ; pub const WS_EX_RTLREADING : Self = Self ( 8192u32 ) ; pub const WS_EX_LTRREADING : Self = Self ( 0u32 ) ; pub const WS_EX_LEFTSCROLLBAR : Self = Self ( 16384u32 ) ; pub const WS_EX_RIGHTSCROLLBAR : Self = Self ( 0u32 ) ; pub const WS_EX_CONTROLPARENT : Self = Self ( 65536u32 ) ; pub const WS_EX_STATICEDGE : Self = Self ( 131072u32 ) ; pub const WS_EX_APPWINDOW : Self = Self ( 262144u32 ) ; pub const WS_EX_OVERLAPPEDWINDOW : Self = Self ( 768u32 ) ; pub const WS_EX_PALETTEWINDOW : Self = Self ( 392u32 ) ; pub const WS_EX_LAYERED : Self = Self ( 524288u32 ) ; pub const WS_EX_NOINHERITLAYOUT : Self = Self ( 1048576u32 ) ; pub const WS_EX_NOREDIRECTIONBITMAP : Self = Self ( 2097152u32 ) ; pub const WS_EX_LAYOUTRTL : Self = Self ( 4194304u32 ) ; pub const WS_EX_COMPOSITED : Self = Self ( 33554432u32 ) ; pub const WS_EX_NOACTIVATE : Self = Self ( 134217728u32 ) ; } impl :: std :: convert :: From < u32 > for WINDOW_EX_STYLE { fn from ( value : u32 ) -> Self { Self ( value ) } } unsafe impl :: windows :: Abi for WINDOW_EX_STYLE { type Abi = Self ; } impl :: std :: ops :: BitOr for WINDOW_EX_STYLE { type Output = Self ; fn bitor ( self , rhs : Self ) -> Self { Self ( self . 0 | rhs . 0 ) } } impl :: std :: ops :: BitAnd for WINDOW_EX_STYLE { type Output = Self ; fn bitand ( self , rhs : Self ) -> Self { Self ( self . 0 & rhs . 0 ) } } impl :: std :: ops :: BitOrAssign for WINDOW_EX_STYLE { fn bitor_assign ( & mut self , rhs : Self ) { self . 0 . bitor_assign ( rhs . 0 ) } } impl :: std :: ops :: BitAndAssign for WINDOW_EX_STYLE { fn bitand_assign ( & mut self , rhs : Self ) { self . 0 . bitand_assign ( rhs . 0 ) } } # [ derive ( :: std :: cmp :: PartialEq , :: std :: cmp :: Eq , :: std :: marker :: Copy , :: std :: clone :: Clone , :: std :: default :: Default , :: std :: fmt :: Debug ) ] # [ repr ( transparent ) ] pub struct WINDOW_STYLE ( pub u32 ) ; impl WINDOW_STYLE { pub const WS_OVERLAPPED : Self = Self ( 0u32 ) ; pub const WS_POPUP : Self = Self ( 2147483648u32 ) ; pub const WS_CHILD : Self = Self ( 1073741824u32 ) ; pub const WS_MINIMIZE : Self = Self ( 536870912u32 ) ; pub const WS_MAXIMIZE : Self = Self ( 16777216u32 ) ; pub const WS_HSCROLL : Self = Self ( 1048576u32 ) ; pub const WS_VSCROLL : Self = Self ( 2097152u32 ) ; pub const WS_VISIBLE : Self = Self ( 268435456u32 ) ; pub const WS_DISABLED : Self = Self ( 134217728u32 ) ; pub const WS_CLIPSIBLINGS : Self = Self ( 67108864u32 ) ; pub const WS_CLIPCHILDREN : Self = Self ( 33554432u32 ) ; pub const WS_CAPTION : Self = Self ( 12582912u32 ) ; pub const WS_BORDER : Self = Self ( 8388608u32 ) ; pub const WS_DLGFRAME : Self = Self ( 4194304u32 ) ; pub const WS_SYSMENU : Self = Self ( 524288u32 ) ; pub const WS_THICKFRAME : Self = Self ( 262144u32 ) ; pub const WS_GROUP : Self = Self ( 131072u32 ) ; pub const WS_TABSTOP : Self = Self ( 65536u32 ) ; pub const WS_MINIMIZEBOX : Self = Self ( 131072u32 ) ; pub const WS_MAXIMIZEBOX : Self = Self ( 65536u32 ) ; pub const WS_TILED : Self = Self ( 0u32 ) ; pub const WS_ICONIC : Self = Self ( 536870912u32 ) ; pub const WS_SIZEBOX : Self = Self ( 262144u32 ) ; pub const WS_TILEDWINDOW : Self = Self ( 13565952u32 ) ; pub const WS_OVERLAPPEDWINDOW : Self = Self ( 13565952u32 ) ; pub const WS_POPUPWINDOW : Self = Self ( 2156396544u32 ) ; pub const WS_CHILDWINDOW : Self = Self ( 1073741824u32 ) ; pub const WS_ACTIVECAPTION : Self = Self ( 1u32 ) ; } impl :: std :: convert :: From < u32 > for WINDOW_STYLE { fn from ( value : u32 ) -> Self { Self ( value ) } } unsafe impl :: windows :: Abi for WINDOW_STYLE { type Abi = Self ; } impl :: std :: ops :: BitOr for WINDOW_STYLE { type Output = Self ; fn bitor ( self , rhs : Self ) -> Self { Self ( self . 0 | rhs . 0 ) } } impl :: std :: ops :: BitAnd for WINDOW_STYLE { type Output = Self ; fn bitand ( self , rhs : Self ) -> Self { Self ( self . 0 & rhs . 0 ) } } impl :: std :: ops :: BitOrAssign for WINDOW_STYLE { fn bitor_assign ( & mut self , rhs : Self ) { self . 0 . bitor_assign ( rhs . 0 ) } } impl :: std :: ops :: BitAndAssign for WINDOW_STYLE { fn bitand_assign ( & mut self , rhs : Self ) { self . 0 . bitand_assign ( rhs . 0 ) } } pub unsafe fn CreateWindowExA < 'a , T1__ : :: windows :: IntoParam < 'a , super :: SystemServices :: PSTR > , T2__ : :: windows :: IntoParam < 'a , super :: SystemServices :: PSTR > , T8__ : :: windows :: IntoParam < 'a , HWND > , T9__ : :: windows :: IntoParam < 'a , super :: MenusAndResources :: HMENU > , T10__ : :: windows :: IntoParam < 'a , super :: SystemServices :: HINSTANCE > , > ( dwexstyle : WINDOW_EX_STYLE , lpclassname : T1__ , lpwindowname : T2__ , dwstyle : WINDOW_STYLE , x : i32 , y : i32 , nwidth : i32 , nheight : i32 , hwndparent : T8__ , hmenu : T9__ , hinstance : T10__ , lpparam : * mut :: std :: ffi :: c_void , ) -> HWND { panic ! ( "Unsupported target OS" ) ; } pub unsafe fn DefWindowProcA < 'a , T0__ : :: windows :: IntoParam < 'a , HWND > , T2__ : :: windows :: IntoParam < 'a , WPARAM > , T3__ : :: windows :: IntoParam < 'a , LPARAM > , > ( hwnd : T0__ , msg : u32 , wparam : T2__ , lparam : T3__ , ) -> super :: SystemServices :: LRESULT { panic ! ( "Unsupported target OS" ) ; } pub unsafe fn DestroyWindow < 'a , T0__ : :: windows :: IntoParam < 'a , HWND > , > ( hwnd : T0__ , ) -> super :: SystemServices :: BOOL { panic ! ( "Unsupported target OS" ) ; } # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy ) ] pub struct MSG { pub hwnd : HWND , pub message : u32 , pub wParam : WPARAM , pub lParam : LPARAM , pub time : u32 , pub pt : super :: DisplayDevices :: POINT } impl MSG { } impl :: std :: default :: Default for MSG { fn default ( ) -> Self { Self { hwnd : :: std :: default :: Default :: default ( ) , message : 0 , wParam : :: std :: default :: Default :: default ( ) , lParam : :: std :: default :: Default :: default ( ) , time : 0 , pt : :: std :: default :: Default :: default ( ) } } } impl :: std :: fmt :: Debug for MSG { fn fmt ( & self , fmt : & mut :: std :: fmt :: Formatter < '_ > ) -> :: std :: fmt :: Result { fmt . debug_struct ( "MSG" ) . field ( "hwnd" , & format_args ! ( "{:?}" , self . hwnd ) ) . field ( "message" , & format_args ! ( "{:?}" , self . message ) ) . field ( "wParam" , & format_args ! ( "{:?}" , self . wParam ) ) . field ( "lParam" , & format_args ! ( "{:?}" , self . lParam ) ) . field ( "time" , & format_args ! ( "{:?}" , self . time ) ) . field ( "pt" , & format_args ! ( "{:?}" , self . pt ) ) . finish ( ) } } impl :: std :: cmp :: PartialEq for MSG { fn eq ( & self , other : & Self ) -> bool { self . hwnd == other . hwnd && self . message == other . message && self . wParam == other . wParam && self . lParam == other . lParam && self . time == other . time && self . pt == other . pt } } impl :: std :: cmp :: Eq for MSG { } unsafe impl :: windows :: Abi for MSG { type Abi = Self ; } pub unsafe fn DispatchMessageA < > ( lpmsg : * const MSG , ) -> super :: SystemServices :: LRESULT { panic ! ( "Unsupported target OS" ) ; } pub unsafe fn GetMessageA < 'a , T1__ : :: windows :: IntoParam < 'a , HWND > , > ( lpmsg : * mut MSG , hwnd : T1__ , wmsgfiltermin : u32 , wmsgfiltermax : u32 , ) -> super :: SystemServices :: BOOL { panic ! ( "Unsupported target OS" ) ; } # [ derive ( :: std :: cmp :: PartialEq , :: std :: cmp :: Eq , :: std :: marker :: Copy , :: std :: clone :: Clone , :: std :: default :: Default , :: std :: fmt :: Debug ) ] # [ repr ( transparent ) ] pub struct WINDOW_LONG_PTR_INDEX ( pub i32 ) ; impl WINDOW_LONG_PTR_INDEX { pub const GWL_EXSTYLE : Self = Self ( -20i32 ) ; pub const GWLP_HINSTANCE : Self = Self ( -6i32 ) ; pub const GWLP_HWNDPARENT : Self = Self ( -8i32 ) ; pub const GWLP_ID : Self = Self ( -12i32 ) ; pub const GWL_STYLE : Self = Self ( -16i32 ) ; pub const GWLP_USERDATA : Self = Self ( -21i32 ) ; pub const GWLP_WNDPROC : Self = Self ( -4i32 ) ; pub const GWL_HINSTANCE : Self = Self ( -6i32 ) ; pub const GWL_ID : Self = Self ( -12i32 ) ; pub const GWL_USERDATA : Self = Self ( -21i32 ) ; pub const GWL_WNDPROC : Self = Self ( -4i32 ) ; pub const GWL_HWNDPARENT : Self = Self ( -8i32 ) ; } impl :: std :: convert :: From < i32 > for WINDOW_LONG_PTR_INDEX { fn from ( value : i32 ) -> Self { Self ( value ) } } unsafe impl :: windows :: Abi for WINDOW_LONG_PTR_INDEX { type Abi = Self ; } pub unsafe fn GetWindowLongPtrA < 'a , T0__ : :: windows :: IntoParam < 'a , HWND > , > ( hwnd : T0__ , nindex : WINDOW_LONG_PTR_INDEX , ) -> isize { panic ! ( "Unsupported target OS" ) ; } pub unsafe fn LoadIconA < 'a , T0__ : :: windows :: IntoParam < 'a , super :: SystemServices :: HINSTANCE > , T1__ : :: windows :: IntoParam < 'a , super :: SystemServices :: PSTR > , > ( hinstance : T0__ , lpiconname : T1__ , ) -> super :: MenusAndResources :: HICON { panic ! ( "Unsupported target OS" ) ; } pub unsafe fn PostMessageA < 'a , T0__ : :: windows :: IntoParam < 'a , HWND > , T2__ : :: windows :: IntoParam < 'a , WPARAM > , T3__ : :: windows :: IntoParam < 'a , LPARAM > , > ( hwnd : T0__ , msg : u32 , wparam : T2__ , lparam : T3__ , ) -> super :: SystemServices :: BOOL { panic ! ( "Unsupported target OS" ) ; } pub unsafe fn PostQuitMessage < > ( nexitcode : i32 , ) { panic ! ( "Unsupported target OS" ) ; } # [ derive ( :: std :: cmp :: PartialEq , :: std :: cmp :: Eq , :: std :: marker :: Copy , :: std :: clone :: Clone , :: std :: default :: Default , :: std :: fmt :: Debug ) ] # [ repr ( transparent ) ] pub struct WNDCLASS_STYLES ( pub u32 ) ; impl WNDCLASS_STYLES { pub const CS_VREDRAW : Self = Self ( 1u32 ) ; pub const CS_HREDRAW : Self = Self ( 2u32 ) ; pub const CS_DBLCLKS : Self = Self ( 8u32 ) ; pub const CS_OWNDC : Self = Self ( 32u32 ) ; pub const CS_CLASSDC : Self = Self ( 64u32 ) ; pub const CS_PARENTDC : Self = Self ( 128u32 ) ; pub const CS_NOCLOSE : Self = Self ( 512u32 ) ; pub const CS_SAVEBITS : Self = Self ( 2048u32 ) ; pub const CS_BYTEALIGNCLIENT : Self = Self ( 4096u32 ) ; pub const CS_BYTEALIGNWINDOW : Self = Self ( 8192u32 ) ; pub const CS_GLOBALCLASS : Self = Self ( 16384u32 ) ; pub const CS_IME : Self = Self ( 65536u32 ) ; pub const CS_DROPSHADOW : Self = Self ( 131072u32 ) ; } impl :: std :: convert :: From < u32 > for WNDCLASS_STYLES { fn from ( value : u32 ) -> Self { Self ( value ) } } unsafe impl :: windows :: Abi for WNDCLASS_STYLES { type Abi = Self ; } impl :: std :: ops :: BitOr for WNDCLASS_STYLES { type Output = Self ; fn bitor ( self , rhs : Self ) -> Self { Self ( self . 0 | rhs . 0 ) } } impl :: std :: ops :: BitAnd for WNDCLASS_STYLES { type Output = Self ; fn bitand ( self , rhs : Self ) -> Self { Self ( self . 0 & rhs . 0 ) } } impl :: std :: ops :: BitOrAssign for WNDCLASS_STYLES { fn bitor_assign ( & mut self , rhs : Self ) { self . 0 . bitor_assign ( rhs . 0 ) } } impl :: std :: ops :: BitAndAssign for WNDCLASS_STYLES { fn bitand_assign ( & mut self , rhs : Self ) { self . 0 . bitand_assign ( rhs . 0 ) } } pub type WNDPROC = extern "system" fn ( param0 : HWND , param1 : u32 , param2 : WPARAM , param3 : LPARAM ) -> super :: SystemServices :: LRESULT ; # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy ) ] pub struct WNDCLASSA { pub style : WNDCLASS_STYLES , pub lpfnWndProc : :: std :: option :: Option < WNDPROC > , pub cbClsExtra : i32 , pub cbWndExtra : i32 , pub hInstance : super :: SystemServices :: HINSTANCE , pub hIcon : super :: MenusAndResources :: HICON , pub hCursor : super :: MenusAndResources :: HCURSOR , pub hbrBackground : super :: Gdi :: HBRUSH , pub lpszMenuName : super :: SystemServices :: PSTR , pub lpszClassName : super :: SystemServices :: PSTR } impl WNDCLASSA { } impl :: std :: default :: Default for WNDCLASSA { fn default ( ) -> Self { Self { style : :: std :: default :: Default :: default ( ) , lpfnWndProc : :: std :: default :: Default :: default ( ) , cbClsExtra : 0 , cbWndExtra : 0 , hInstance : :: std :: default :: Default :: default ( ) , hIcon : :: std :: default :: Default :: default ( ) , hCursor : :: std :: default :: Default :: default ( ) , hbrBackground : :: std :: default :: Default :: default ( ) , lpszMenuName : :: std :: default :: Default :: default ( ) , lpszClassName : :: std :: default :: Default :: default ( ) } } } impl :: std :: fmt :: Debug for WNDCLASSA { fn fmt ( & self , fmt : & mut :: std :: fmt :: Formatter < '_ > ) -> :: std :: fmt :: Result { fmt . debug_struct ( "WNDCLASSA" ) . field ( "style" , & format_args ! ( "{:?}" , self . style ) ) . field ( "cbClsExtra" , & format_args ! ( "{:?}" , self . cbClsExtra ) ) . field ( "cbWndExtra" , & format_args ! ( "{:?}" , self . cbWndExtra ) ) . field ( "hInstance" , & format_args ! ( "{:?}" , self . hInstance ) ) . field ( "hIcon" , & format_args ! ( "{:?}" , self . hIcon ) ) . field ( "hCursor" , & format_args ! ( "{:?}" , self . hCursor ) ) . field ( "hbrBackground" , & format_args ! ( "{:?}" , self . hbrBackground ) ) . field ( "lpszMenuName" , & format_args ! ( "{:?}" , self . lpszMenuName ) ) . field ( "lpszClassName" , & format_args ! ( "{:?}" , self . lpszClassName ) ) . finish ( ) } } impl :: std :: cmp :: PartialEq for WNDCLASSA { fn eq ( & self , other : & Self ) -> bool { self . style == other . style && self . lpfnWndProc . map ( | f | f as usize ) == other . lpfnWndProc . map ( | f | f as usize ) && self . cbClsExtra == other . cbClsExtra && self . cbWndExtra == other . cbWndExtra && self . hInstance == other . hInstance && self . hIcon == other . hIcon && self . hCursor == other . hCursor && self . hbrBackground == other . hbrBackground && self . lpszMenuName == other . lpszMenuName && self . lpszClassName == other . lpszClassName } } impl :: std :: cmp :: Eq for WNDCLASSA { } unsafe impl :: windows :: Abi for WNDCLASSA { type Abi = Self ; } pub unsafe fn RegisterClassA < > ( lpwndclass : * const WNDCLASSA , ) -> u16 { panic ! ( "Unsupported target OS" ) ; } pub unsafe fn SetWindowLongPtrA < 'a , T0__ : :: windows :: IntoParam < 'a , HWND > , > ( hwnd : T0__ , nindex : WINDOW_LONG_PTR_INDEX , dwnewlong : isize , ) -> isize { panic ! ( "Unsupported target OS" ) ; } # [ derive ( :: std :: cmp :: PartialEq , :: std :: cmp :: Eq , :: std :: marker :: Copy , :: std :: clone :: Clone , :: std :: default :: Default , :: std :: fmt :: Debug ) ] # [ repr ( transparent ) ] pub struct SetWindowsHookEx_idHook ( pub i32 ) ; impl SetWindowsHookEx_idHook { pub const WH_CALLWNDPROC : Self = Self ( 4i32 ) ; pub const WH_CALLWNDPROCRET : Self = Self ( 12i32 ) ; pub const WH_CBT : Self = Self ( 5i32 ) ; pub const WH_DEBUG : Self = Self ( 9i32 ) ; pub const WH_FOREGROUNDIDLE : Self = Self ( 11i32 ) ; pub const WH_GETMESSAGE : Self = Self ( 3i32 ) ; pub const WH_JOURNALPLAYBACK : Self = Self ( 1i32 ) ; pub const WH_JOURNALRECORD : Self = Self ( 0i32 ) ; pub const WH_KEYBOARD : Self = Self ( 2i32 ) ; pub const WH_KEYBOARD_LL : Self = Self ( 13i32 ) ; pub const WH_MOUSE : Self = Self ( 7i32 ) ; pub const WH_MOUSE_LL : Self = Self ( 14i32 ) ; pub const WH_MSGFILTER : Self = Self ( -1i32 ) ; pub const WH_SHELL : Self = Self ( 10i32 ) ; pub const WH_SYSMSGFILTER : Self = Self ( 6i32 ) ; } impl :: std :: convert :: From < i32 > for SetWindowsHookEx_idHook { fn from ( value : i32 ) -> Self { Self ( value ) } } unsafe impl :: windows :: Abi for SetWindowsHookEx_idHook { type Abi = Self ; } pub type HOOKPROC = extern "system" fn ( code : i32 , wparam : WPARAM , lparam : LPARAM ) -> super :: SystemServices :: LRESULT ; pub unsafe fn SetWindowsHookExA < 'a , T2__ : :: windows :: IntoParam < 'a , super :: SystemServices :: HINSTANCE > , > ( idhook : SetWindowsHookEx_idHook , lpfn : :: std :: option :: Option < HOOKPROC > , hmod : T2__ , dwthreadid : u32 , ) -> HHOOK { panic ! ( "Unsupported target OS" ) ; } pub unsafe fn UnhookWindowsHookEx < 'a , T0__ : :: windows :: IntoParam < 'a , HHOOK > , > ( hhk : T0__ , ) -> super :: SystemServices :: BOOL { panic ! ( "Unsupported target OS" ) ; } # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy ) ] pub struct CREATESTRUCTA { pub lpCreateParams : * mut :: std :: ffi :: c_void , pub hInstance : super :: SystemServices :: HINSTANCE , pub hMenu : super :: MenusAndResources :: HMENU , pub hwndParent : HWND , pub cy : i32 , pub cx : i32 , pub y : i32 , pub x : i32 , pub style : i32 , pub lpszName : super :: SystemServices :: PSTR , pub lpszClass : super :: SystemServices :: PSTR , pub dwExStyle : u32 } impl CREATESTRUCTA { } impl :: std :: default :: Default for CREATESTRUCTA { fn default ( ) -> Self { Self { lpCreateParams : :: std :: ptr :: null_mut ( ) , hInstance : :: std :: default :: Default :: default ( ) , hMenu : :: std :: default :: Default :: default ( ) , hwndParent : :: std :: default :: Default :: default ( ) , cy : 0 , cx : 0 , y : 0 , x : 0 , style : 0 , lpszName : :: std :: default :: Default :: default ( ) , lpszClass : :: std :: default :: Default :: default ( ) , dwExStyle : 0 } } } impl :: std :: fmt :: Debug for CREATESTRUCTA { fn fmt ( & self , fmt : & mut :: std :: fmt :: Formatter < '_ > ) -> :: std :: fmt :: Result { fmt . debug_struct ( "CREATESTRUCTA" ) . field ( "lpCreateParams" , & format_args ! ( "{:?}" , self . lpCreateParams ) ) . field ( "hInstance" , & format_args ! ( "{:?}" , self . hInstance ) ) . field ( "hMenu" , & format_args ! ( "{:?}" , self . hMenu ) ) . field ( "hwndParent" , & format_args ! ( "{:?}" , self . hwndParent ) ) . field ( "cy" , & format_args ! ( "{:?}" , self . cy ) ) . field ( "cx" , & format_args ! ( "{:?}" , self . cx ) ) . field ( "y" , & format_args ! ( "{:?}" , self . y ) ) . field ( "x" , & format_args ! ( "{:?}" , self . x ) ) . field ( "style" , & format_args ! ( "{:?}" , self . style ) ) . field ( "lpszName" , & format_args ! ( "{:?}" , self . lpszName ) ) . field ( "lpszClass" , & format_args ! ( "{:?}" , self . lpszClass ) ) . field ( "dwExStyle" , & format_args ! ( "{:?}" , self . dwExStyle ) ) . finish ( ) } } impl :: std :: cmp :: PartialEq for CREATESTRUCTA { fn eq ( & self , other : & Self ) -> bool { self . lpCreateParams == other . lpCreateParams && self . hInstance == other . hInstance && self . hMenu == other . hMenu && self . hwndParent == other . hwndParent && self . cy == other . cy && self . cx == other . cx && self . y == other . y && self . x == other . x && self . style == other . style && self . lpszName == other . lpszName && self . lpszClass == other . lpszClass && self . dwExStyle == other . dwExStyle } } impl :: std :: cmp :: Eq for CREATESTRUCTA { } unsafe impl :: windows :: Abi for CREATESTRUCTA { type Abi = Self ; } pub const CW_USEDEFAULT : i32 = -2147483648i32 ; # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy ) ] pub struct KBDLLHOOKSTRUCT { pub vkCode : u32 , pub scanCode : u32 , pub flags : u32 , pub time : u32 , pub dwExtraInfo : usize } impl KBDLLHOOKSTRUCT { } impl :: std :: default :: Default for KBDLLHOOKSTRUCT { fn default ( ) -> Self { Self { vkCode : 0 , scanCode : 0 , flags : 0 , time : 0 , dwExtraInfo : 0 } } } impl :: std :: fmt :: Debug for KBDLLHOOKSTRUCT { fn fmt ( & self , fmt : & mut :: std :: fmt :: Formatter < '_ > ) -> :: std :: fmt :: Result { fmt . debug_struct ( "KBDLLHOOKSTRUCT" ) . field ( "vkCode" , & format_args ! ( "{:?}" , self . vkCode ) ) . field ( "scanCode" , & format_args ! ( "{:?}" , self . scanCode ) ) . field ( "flags" , & format_args ! ( "{:?}" , self . flags ) ) . field ( "time" , & format_args ! ( "{:?}" , self . time ) ) . field ( "dwExtraInfo" , & format_args ! ( "{:?}" , self . dwExtraInfo ) ) . finish ( ) } } impl :: std :: cmp :: PartialEq for KBDLLHOOKSTRUCT { fn eq ( & self , other : & Self ) -> bool { self . vkCode == other . vkCode && self . scanCode == other . scanCode && self . flags == other . flags && self . time == other . time && self . dwExtraInfo == other . dwExtraInfo } } impl :: std :: cmp :: Eq for KBDLLHOOKSTRUCT { } unsafe impl :: windows :: Abi for KBDLLHOOKSTRUCT { type Abi = Self ; } pub const VK_CONTROL : u32 = 17u32 ; pub const VK_ESCAPE : u32 = 27u32 ; pub const VK_F12 : u32 = 123u32 ; pub const WM_CLOSE : u32 = 16u32 ; pub const WM_DESTROY : u32 = 2u32 ; pub const WM_NCCREATE : u32 = 129u32 ; pub const WM_QUIT : u32 = 18u32 ; pub const WM_KEYUP : u32 = 257u32 ; pub const WM_SYSKEYUP : u32 = 261u32 ; } } } [INFO] [stdout] | +++++++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused return value of `Box::::from_raw` that must be used [INFO] [stdout] --> /opt/rustwide/target/debug/build/bindings-082b36382e0f0520/out/windows.rs:1:20272 [INFO] [stdout] | [INFO] [stdout] 1 | ... { if ! value . 0 . is_null ( ) { unsafe { :: std :: boxed :: Box :: from_raw ( value . 0 ) ; } } } } } impl < 'a > :: windows :: Into... [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: call `drop(Box::from_raw(ptr))` if you intend to drop the `Box` [INFO] [stdout] help: use `let _ = ...` to ignore the resulting value [INFO] [stdout] | [INFO] [stdout] 1 | # [ allow ( unused_variables , non_upper_case_globals , non_snake_case , unused_unsafe , non_camel_case_types , dead_code , clippy :: all ) ] pub mod Windows { # [ allow ( unused_variables , non_upper_case_globals , non_snake_case , unused_unsafe , non_camel_case_types , dead_code , clippy :: all ) ] pub mod Win32 { # [ allow ( unused_variables , non_upper_case_globals , non_snake_case , unused_unsafe , non_camel_case_types , dead_code , clippy :: all ) ] pub mod CoreAudio { # [ derive ( :: std :: cmp :: PartialEq , :: std :: cmp :: Eq , :: std :: marker :: Copy , :: std :: clone :: Clone , :: std :: default :: Default , :: std :: fmt :: Debug ) ] # [ repr ( transparent ) ] pub struct EDataFlow ( pub i32 ) ; impl EDataFlow { pub const eRender : Self = Self ( 0i32 ) ; pub const eCapture : Self = Self ( 1i32 ) ; pub const eAll : Self = Self ( 2i32 ) ; pub const EDataFlow_enum_count : Self = Self ( 3i32 ) ; } impl :: std :: convert :: From < i32 > for EDataFlow { fn from ( value : i32 ) -> Self { Self ( value ) } } unsafe impl :: windows :: Abi for EDataFlow { type Abi = Self ; } # [ derive ( :: std :: cmp :: PartialEq , :: std :: cmp :: Eq , :: std :: marker :: Copy , :: std :: clone :: Clone , :: std :: default :: Default , :: std :: fmt :: Debug ) ] # [ repr ( transparent ) ] pub struct ERole ( pub i32 ) ; impl ERole { pub const eConsole : Self = Self ( 0i32 ) ; pub const eMultimedia : Self = Self ( 1i32 ) ; pub const eCommunications : Self = Self ( 2i32 ) ; pub const ERole_enum_count : Self = Self ( 3i32 ) ; } impl :: std :: convert :: From < i32 > for ERole { fn from ( value : i32 ) -> Self { Self ( value ) } } unsafe impl :: windows :: Abi for ERole { type Abi = Self ; } # [ repr ( transparent ) ] # [ derive ( :: std :: cmp :: PartialEq , :: std :: cmp :: Eq , :: std :: clone :: Clone , :: std :: fmt :: Debug ) ] pub struct IMMDevice ( :: windows :: IUnknown ) ; impl IMMDevice { } unsafe impl :: windows :: Interface for IMMDevice { type Vtable = IMMDevice_abi ; const IID : :: windows :: Guid = :: windows :: Guid :: from_values ( 3597010495 ,5511 ,20035 , [ 129 ,241 ,185 ,72 ,232 ,7 ,54 ,63 ] , ) ; } impl IMMDevice { pub unsafe fn GetId < > ( & self , ppstrid : * mut super :: SystemServices :: PWSTR , ) -> :: windows :: ErrorCode { ( :: windows :: Interface :: vtable ( self ) .5 ) ( :: windows :: Abi :: abi ( self ) , :: std :: mem :: transmute ( ppstrid ) , ) } pub unsafe fn GetState < > ( & self , pdwstate : * mut u32 , ) -> :: windows :: ErrorCode { ( :: windows :: Interface :: vtable ( self ) .6 ) ( :: windows :: Abi :: abi ( self ) , :: std :: mem :: transmute ( pdwstate ) , ) } } impl :: std :: convert :: From < IMMDevice > for :: windows :: IUnknown { fn from ( value : IMMDevice ) -> Self { unsafe { :: std :: mem :: transmute ( value ) } } } impl :: std :: convert :: From < & IMMDevice > for :: windows :: IUnknown { fn from ( value : & IMMDevice ) -> Self { :: std :: convert :: From :: from ( :: std :: clone :: Clone :: clone ( value ) ) } } impl < 'a > :: windows :: IntoParam < 'a , :: windows :: IUnknown > for IMMDevice { fn into_param ( self ) -> :: windows :: Param < 'a , :: windows :: IUnknown > { :: windows :: Param :: Owned ( :: std :: convert :: Into :: < :: windows :: IUnknown > :: into ( self ) ) } } impl < 'a > :: windows :: IntoParam < 'a , :: windows :: IUnknown > for & 'a IMMDevice { fn into_param ( self ) -> :: windows :: Param < 'a , :: windows :: IUnknown > { :: windows :: Param :: Owned ( :: std :: convert :: Into :: < :: windows :: IUnknown > :: into ( :: std :: clone :: Clone :: clone ( self ) ) ) } } # [ repr ( C ) ] # [ doc ( hidden ) ] pub struct IMMDevice_abi ( pub unsafe extern "system" fn ( this : :: windows :: RawPtr , iid : & :: windows :: Guid , interface : * mut :: windows :: RawPtr ) -> :: windows :: ErrorCode , pub unsafe extern "system" fn ( this : :: windows :: RawPtr ) -> u32 , pub unsafe extern "system" fn ( this : :: windows :: RawPtr ) -> u32 , pub unsafe extern "system" fn ( ) , pub unsafe extern "system" fn ( ) , pub unsafe extern "system" fn ( this : :: windows :: RawPtr , ppstrid : * mut super :: SystemServices :: PWSTR , ) -> :: windows :: ErrorCode , pub unsafe extern "system" fn ( this : :: windows :: RawPtr , pdwstate : * mut u32 , ) -> :: windows :: ErrorCode , ) ; # [ repr ( transparent ) ] # [ derive ( :: std :: cmp :: PartialEq , :: std :: cmp :: Eq , :: std :: clone :: Clone , :: std :: fmt :: Debug ) ] pub struct IMMDeviceCollection ( :: windows :: IUnknown ) ; impl IMMDeviceCollection { } unsafe impl :: windows :: Interface for IMMDeviceCollection { type Vtable = IMMDeviceCollection_abi ; const IID : :: windows :: Guid = :: windows :: Guid :: from_values ( 198681022 ,31258 ,17627 , [ 131 ,151 ,204 ,83 ,146 ,56 ,123 ,94 ] , ) ; } impl IMMDeviceCollection { pub unsafe fn GetCount < > ( & self , pcdevices : * mut u32 , ) -> :: windows :: ErrorCode { ( :: windows :: Interface :: vtable ( self ) .3 ) ( :: windows :: Abi :: abi ( self ) , :: std :: mem :: transmute ( pcdevices ) , ) } pub unsafe fn Item < > ( & self , ndevice : u32 , ppdevice : * mut :: std :: option :: Option < IMMDevice > , ) -> :: windows :: ErrorCode { ( :: windows :: Interface :: vtable ( self ) .4 ) ( :: windows :: Abi :: abi ( self ) , :: std :: mem :: transmute ( ndevice ) , :: std :: mem :: transmute ( ppdevice ) , ) } } impl :: std :: convert :: From < IMMDeviceCollection > for :: windows :: IUnknown { fn from ( value : IMMDeviceCollection ) -> Self { unsafe { :: std :: mem :: transmute ( value ) } } } impl :: std :: convert :: From < & IMMDeviceCollection > for :: windows :: IUnknown { fn from ( value : & IMMDeviceCollection ) -> Self { :: std :: convert :: From :: from ( :: std :: clone :: Clone :: clone ( value ) ) } } impl < 'a > :: windows :: IntoParam < 'a , :: windows :: IUnknown > for IMMDeviceCollection { fn into_param ( self ) -> :: windows :: Param < 'a , :: windows :: IUnknown > { :: windows :: Param :: Owned ( :: std :: convert :: Into :: < :: windows :: IUnknown > :: into ( self ) ) } } impl < 'a > :: windows :: IntoParam < 'a , :: windows :: IUnknown > for & 'a IMMDeviceCollection { fn into_param ( self ) -> :: windows :: Param < 'a , :: windows :: IUnknown > { :: windows :: Param :: Owned ( :: std :: convert :: Into :: < :: windows :: IUnknown > :: into ( :: std :: clone :: Clone :: clone ( self ) ) ) } } # [ repr ( C ) ] # [ doc ( hidden ) ] pub struct IMMDeviceCollection_abi ( pub unsafe extern "system" fn ( this : :: windows :: RawPtr , iid : & :: windows :: Guid , interface : * mut :: windows :: RawPtr ) -> :: windows :: ErrorCode , pub unsafe extern "system" fn ( this : :: windows :: RawPtr ) -> u32 , pub unsafe extern "system" fn ( this : :: windows :: RawPtr ) -> u32 , pub unsafe extern "system" fn ( this : :: windows :: RawPtr , pcdevices : * mut u32 , ) -> :: windows :: ErrorCode , pub unsafe extern "system" fn ( this : :: windows :: RawPtr , ndevice : u32 , ppdevice : * mut :: windows :: RawPtr , ) -> :: windows :: ErrorCode , ) ; # [ repr ( transparent ) ] # [ derive ( :: std :: cmp :: PartialEq , :: std :: cmp :: Eq , :: std :: clone :: Clone , :: std :: fmt :: Debug ) ] pub struct IMMDeviceEnumerator ( :: windows :: IUnknown ) ; impl IMMDeviceEnumerator { } unsafe impl :: windows :: Interface for IMMDeviceEnumerator { type Vtable = IMMDeviceEnumerator_abi ; const IID : :: windows :: Guid = :: windows :: Guid :: from_values ( 2841011410 ,38420 ,20277 , [ 167 ,70 ,222 ,141 ,182 ,54 ,23 ,230 ] , ) ; } impl IMMDeviceEnumerator { pub unsafe fn EnumAudioEndpoints < > ( & self , dataflow : EDataFlow , dwstatemask : u32 , ppdevices : * mut :: std :: option :: Option < IMMDeviceCollection > , ) -> :: windows :: ErrorCode { ( :: windows :: Interface :: vtable ( self ) .3 ) ( :: windows :: Abi :: abi ( self ) , :: std :: mem :: transmute ( dataflow ) , :: std :: mem :: transmute ( dwstatemask ) , :: std :: mem :: transmute ( ppdevices ) , ) } pub unsafe fn GetDefaultAudioEndpoint < > ( & self , dataflow : EDataFlow , role : ERole , ppendpoint : * mut :: std :: option :: Option < IMMDevice > , ) -> :: windows :: ErrorCode { ( :: windows :: Interface :: vtable ( self ) .4 ) ( :: windows :: Abi :: abi ( self ) , :: std :: mem :: transmute ( dataflow ) , :: std :: mem :: transmute ( role ) , :: std :: mem :: transmute ( ppendpoint ) , ) } pub unsafe fn GetDevice < 'a , T0__ : :: windows :: IntoParam < 'a , super :: SystemServices :: PWSTR > , > ( & self , pwstrid : T0__ , ppdevice : * mut :: std :: option :: Option < IMMDevice > , ) -> :: windows :: ErrorCode { ( :: windows :: Interface :: vtable ( self ) .5 ) ( :: windows :: Abi :: abi ( self ) , pwstrid . into_param ( ) . abi ( ) , :: std :: mem :: transmute ( ppdevice ) , ) } } impl :: std :: convert :: From < IMMDeviceEnumerator > for :: windows :: IUnknown { fn from ( value : IMMDeviceEnumerator ) -> Self { unsafe { :: std :: mem :: transmute ( value ) } } } impl :: std :: convert :: From < & IMMDeviceEnumerator > for :: windows :: IUnknown { fn from ( value : & IMMDeviceEnumerator ) -> Self { :: std :: convert :: From :: from ( :: std :: clone :: Clone :: clone ( value ) ) } } impl < 'a > :: windows :: IntoParam < 'a , :: windows :: IUnknown > for IMMDeviceEnumerator { fn into_param ( self ) -> :: windows :: Param < 'a , :: windows :: IUnknown > { :: windows :: Param :: Owned ( :: std :: convert :: Into :: < :: windows :: IUnknown > :: into ( self ) ) } } impl < 'a > :: windows :: IntoParam < 'a , :: windows :: IUnknown > for & 'a IMMDeviceEnumerator { fn into_param ( self ) -> :: windows :: Param < 'a , :: windows :: IUnknown > { :: windows :: Param :: Owned ( :: std :: convert :: Into :: < :: windows :: IUnknown > :: into ( :: std :: clone :: Clone :: clone ( self ) ) ) } } # [ repr ( C ) ] # [ doc ( hidden ) ] pub struct IMMDeviceEnumerator_abi ( pub unsafe extern "system" fn ( this : :: windows :: RawPtr , iid : & :: windows :: Guid , interface : * mut :: windows :: RawPtr ) -> :: windows :: ErrorCode , pub unsafe extern "system" fn ( this : :: windows :: RawPtr ) -> u32 , pub unsafe extern "system" fn ( this : :: windows :: RawPtr ) -> u32 , pub unsafe extern "system" fn ( this : :: windows :: RawPtr , dataflow : EDataFlow , dwstatemask : u32 , ppdevices : * mut :: windows :: RawPtr , ) -> :: windows :: ErrorCode , pub unsafe extern "system" fn ( this : :: windows :: RawPtr , dataflow : EDataFlow , role : ERole , ppendpoint : * mut :: windows :: RawPtr , ) -> :: windows :: ErrorCode , pub unsafe extern "system" fn ( this : :: windows :: RawPtr , pwstrid : super :: SystemServices :: PWSTR , ppdevice : * mut :: windows :: RawPtr , ) -> :: windows :: ErrorCode , pub unsafe extern "system" fn ( ) , pub unsafe extern "system" fn ( ) , ) ; pub const MMDeviceEnumerator : :: windows :: Guid = :: windows :: Guid :: from_values ( 3168666517 ,58671 ,18044 , [ 142 ,61 ,196 ,87 ,146 ,145 ,105 ,46 ] , ) ; pub const DEVICE_STATE_ACTIVE : u32 = 1u32 ; } # [ allow ( unused_variables , non_upper_case_globals , non_snake_case , unused_unsafe , non_camel_case_types , dead_code , clippy :: all ) ] pub mod Debug { pub unsafe fn GetLastError < > ( ) -> u32 { panic ! ( "Unsupported target OS" ) ; } } # [ allow ( unused_variables , non_upper_case_globals , non_snake_case , unused_unsafe , non_camel_case_types , dead_code , clippy :: all ) ] pub mod DisplayDevices { # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy ) ] pub struct POINT { pub x : i32 , pub y : i32 } impl POINT { } impl :: std :: default :: Default for POINT { fn default ( ) -> Self { Self { x : 0 , y : 0 } } } impl :: std :: fmt :: Debug for POINT { fn fmt ( & self , fmt : & mut :: std :: fmt :: Formatter < '_ > ) -> :: std :: fmt :: Result { fmt . debug_struct ( "POINT" ) . field ( "x" , & format_args ! ( "{:?}" , self . x ) ) . field ( "y" , & format_args ! ( "{:?}" , self . y ) ) . finish ( ) } } impl :: std :: cmp :: PartialEq for POINT { fn eq ( & self , other : & Self ) -> bool { self . x == other . x && self . y == other . y } } impl :: std :: cmp :: Eq for POINT { } unsafe impl :: windows :: Abi for POINT { type Abi = Self ; } } # [ allow ( unused_variables , non_upper_case_globals , non_snake_case , unused_unsafe , non_camel_case_types , dead_code , clippy :: all ) ] pub mod Gdi { # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy ) ] pub struct HGDIOBJ ( pub isize ) ; impl HGDIOBJ { } impl :: std :: default :: Default for HGDIOBJ { fn default ( ) -> Self { Self ( 0 ) } } impl :: std :: fmt :: Debug for HGDIOBJ { fn fmt ( & self , fmt : & mut :: std :: fmt :: Formatter < '_ > ) -> :: std :: fmt :: Result { fmt . debug_struct ( "HGDIOBJ" ) . field ( "Value" , & format_args ! ( "{:?}" , self .0 ) ) . finish ( ) } } impl :: std :: cmp :: PartialEq for HGDIOBJ { fn eq ( & self , other : & Self ) -> bool { self .0 == other .0 } } impl :: std :: cmp :: Eq for HGDIOBJ { } unsafe impl :: windows :: Abi for HGDIOBJ { type Abi = Self ; } # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy ) ] pub struct HBRUSH ( pub isize ) ; impl HBRUSH { } impl :: std :: default :: Default for HBRUSH { fn default ( ) -> Self { Self ( 0 ) } } impl :: std :: fmt :: Debug for HBRUSH { fn fmt ( & self , fmt : & mut :: std :: fmt :: Formatter < '_ > ) -> :: std :: fmt :: Result { fmt . debug_struct ( "HBRUSH" ) . field ( "Value" , & format_args ! ( "{:?}" , self .0 ) ) . finish ( ) } } impl :: std :: cmp :: PartialEq for HBRUSH { fn eq ( & self , other : & Self ) -> bool { self .0 == other .0 } } impl :: std :: cmp :: Eq for HBRUSH { } unsafe impl :: windows :: Abi for HBRUSH { type Abi = Self ; } impl < 'a > :: windows :: IntoParam < 'a , HGDIOBJ > for HBRUSH { fn into_param ( self ) -> :: windows :: Param < 'a , HGDIOBJ > { :: windows :: Param :: Owned ( HGDIOBJ ( self . 0 ) ) } } } # [ allow ( unused_variables , non_upper_case_globals , non_snake_case , unused_unsafe , non_camel_case_types , dead_code , clippy :: all ) ] pub mod KeyboardAndMouseInput { pub unsafe fn GetKeyState < > ( nvirtkey : i32 , ) -> i16 { panic ! ( "Unsupported target OS" ) ; } } # [ allow ( unused_variables , non_upper_case_globals , non_snake_case , unused_unsafe , non_camel_case_types , dead_code , clippy :: all ) ] pub mod MenusAndResources { # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy ) ] pub struct HMENU ( pub isize ) ; impl HMENU { } impl :: std :: default :: Default for HMENU { fn default ( ) -> Self { Self ( 0 ) } } impl :: std :: fmt :: Debug for HMENU { fn fmt ( & self , fmt : & mut :: std :: fmt :: Formatter < '_ > ) -> :: std :: fmt :: Result { fmt . debug_struct ( "HMENU" ) . field ( "Value" , & format_args ! ( "{:?}" , self .0 ) ) . finish ( ) } } impl :: std :: cmp :: PartialEq for HMENU { fn eq ( & self , other : & Self ) -> bool { self .0 == other .0 } } impl :: std :: cmp :: Eq for HMENU { } unsafe impl :: windows :: Abi for HMENU { type Abi = Self ; } # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy ) ] pub struct HICON ( pub isize ) ; impl HICON { } impl :: std :: default :: Default for HICON { fn default ( ) -> Self { Self ( 0 ) } } impl :: std :: fmt :: Debug for HICON { fn fmt ( & self , fmt : & mut :: std :: fmt :: Formatter < '_ > ) -> :: std :: fmt :: Result { fmt . debug_struct ( "HICON" ) . field ( "Value" , & format_args ! ( "{:?}" , self .0 ) ) . finish ( ) } } impl :: std :: cmp :: PartialEq for HICON { fn eq ( & self , other : & Self ) -> bool { self .0 == other .0 } } impl :: std :: cmp :: Eq for HICON { } unsafe impl :: windows :: Abi for HICON { type Abi = Self ; } # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy ) ] pub struct HCURSOR ( pub isize ) ; impl HCURSOR { } impl :: std :: default :: Default for HCURSOR { fn default ( ) -> Self { Self ( 0 ) } } impl :: std :: fmt :: Debug for HCURSOR { fn fmt ( & self , fmt : & mut :: std :: fmt :: Formatter < '_ > ) -> :: std :: fmt :: Result { fmt . debug_struct ( "HCURSOR" ) . field ( "Value" , & format_args ! ( "{:?}" , self .0 ) ) . finish ( ) } } impl :: std :: cmp :: PartialEq for HCURSOR { fn eq ( & self , other : & Self ) -> bool { self .0 == other .0 } } impl :: std :: cmp :: Eq for HCURSOR { } unsafe impl :: windows :: Abi for HCURSOR { type Abi = Self ; } impl < 'a > :: windows :: IntoParam < 'a , HICON > for HCURSOR { fn into_param ( self ) -> :: windows :: Param < 'a , HICON > { :: windows :: Param :: Owned ( HICON ( self . 0 ) ) } } } # [ allow ( unused_variables , non_upper_case_globals , non_snake_case , unused_unsafe , non_camel_case_types , dead_code , clippy :: all ) ] pub mod SystemServices { # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy , :: std :: cmp :: Eq , :: std :: fmt :: Debug ) ] pub struct PSTR ( pub * mut u8 ) ; impl :: std :: default :: Default for PSTR { fn default ( ) -> Self { Self ( :: std :: ptr :: null_mut ( ) ) } } impl :: std :: cmp :: PartialEq for PSTR { fn eq ( & self , other : & Self ) -> bool { self . 0 == other . 0 } } unsafe impl :: windows :: Abi for PSTR { type Abi = Self ; fn drop_param ( param : & mut :: windows :: Param < Self > ) { if let :: windows :: Param :: Boxed ( value ) = param { if ! value . 0 . is_null ( ) { unsafe { :: std :: boxed :: Box :: from_raw ( value . 0 ) ; } } } } } impl < 'a > :: windows :: IntoParam < 'a , PSTR > for & 'a str { fn into_param ( self ) -> :: windows :: Param < 'a , PSTR > { :: windows :: Param :: Boxed ( PSTR ( :: std :: boxed :: Box :: < [ u8 ] > :: into_raw ( self . bytes ( ) . chain ( :: std :: iter :: once ( 0 ) ) . collect :: < std :: vec :: Vec < u8 >> ( ) . into_boxed_slice ( ) ) as _ ) ) } } impl < 'a > :: windows :: IntoParam < 'a , PSTR > for String { fn into_param ( self ) -> :: windows :: Param < 'a , PSTR > { :: windows :: Param :: Boxed ( PSTR ( :: std :: boxed :: Box :: < [ u8 ] > :: into_raw ( self . bytes ( ) . chain ( :: std :: iter :: once ( 0 ) ) . collect :: < std :: vec :: Vec < u8 >> ( ) . into_boxed_slice ( ) ) as _ ) ) } } pub unsafe fn GetModuleHandleA < 'a , T0__ : :: windows :: IntoParam < 'a , PSTR > , > ( lpmodulename : T0__ , ) -> isize { panic ! ( "Unsupported target OS" ) ; } # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy ) ] pub struct HINSTANCE ( pub isize ) ; impl HINSTANCE { } impl :: std :: default :: Default for HINSTANCE { fn default ( ) -> Self { Self ( 0 ) } } impl :: std :: fmt :: Debug for HINSTANCE { fn fmt ( & self , fmt : & mut :: std :: fmt :: Formatter < '_ > ) -> :: std :: fmt :: Result { fmt . debug_struct ( "HINSTANCE" ) . field ( "Value" , & format_args ! ( "{:?}" , self .0 ) ) . finish ( ) } } impl :: std :: cmp :: PartialEq for HINSTANCE { fn eq ( & self , other : & Self ) -> bool { self .0 == other .0 } } impl :: std :: cmp :: Eq for HINSTANCE { } unsafe impl :: windows :: Abi for HINSTANCE { type Abi = Self ; } # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy ) ] pub struct LRESULT ( pub i32 ) ; impl LRESULT { } impl :: std :: default :: Default for LRESULT { fn default ( ) -> Self { Self ( 0 ) } } impl :: std :: fmt :: Debug for LRESULT { fn fmt ( & self , fmt : & mut :: std :: fmt :: Formatter < '_ > ) -> :: std :: fmt :: Result { fmt . debug_struct ( "LRESULT" ) . field ( "Value" , & format_args ! ( "{:?}" , self .0 ) ) . finish ( ) } } impl :: std :: cmp :: PartialEq for LRESULT { fn eq ( & self , other : & Self ) -> bool { self .0 == other .0 } } impl :: std :: cmp :: Eq for LRESULT { } unsafe impl :: windows :: Abi for LRESULT { type Abi = Self ; } # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy , :: std :: cmp :: Eq , :: std :: fmt :: Debug ) ] pub struct PWSTR ( pub * mut u16 ) ; impl :: std :: default :: Default for PWSTR { fn default ( ) -> Self { Self ( :: std :: ptr :: null_mut ( ) ) } } impl :: std :: cmp :: PartialEq for PWSTR { fn eq ( & self , other : & Self ) -> bool { self . 0 == other . 0 } } unsafe impl :: windows :: Abi for PWSTR { type Abi = Self ; fn drop_param ( param : & mut :: windows :: Param < Self > ) { if let :: windows :: Param :: Boxed ( value ) = param { if ! value . 0 . is_null ( ) { unsafe { let _ = :: std :: boxed :: Box :: from_raw ( value . 0 ) ; } } } } } impl < 'a > :: windows :: IntoParam < 'a , PWSTR > for & 'a str { fn into_param ( self ) -> :: windows :: Param < 'a , PWSTR > { :: windows :: Param :: Boxed ( PWSTR ( :: std :: boxed :: Box :: < [ u16 ] > :: into_raw ( self . encode_utf16 ( ) . chain ( :: std :: iter :: once ( 0 ) ) . collect :: < std :: vec :: Vec < u16 >> ( ) . into_boxed_slice ( ) ) as _ ) ) } } impl < 'a > :: windows :: IntoParam < 'a , PWSTR > for String { fn into_param ( self ) -> :: windows :: Param < 'a , PWSTR > { :: windows :: Param :: Boxed ( PWSTR ( :: std :: boxed :: Box :: < [ u16 ] > :: into_raw ( self . encode_utf16 ( ) . chain ( :: std :: iter :: once ( 0 ) ) . collect :: < std :: vec :: Vec < u16 >> ( ) . into_boxed_slice ( ) ) as _ ) ) } } pub const S_OK : :: windows :: ErrorCode = :: windows :: ErrorCode ( 0i32 as _ ) ; # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy , :: std :: cmp :: PartialEq , :: std :: cmp :: Eq , :: std :: default :: Default ) ] pub struct BOOL ( pub i32 ) ; impl BOOL { # [ inline ] pub fn as_bool ( self ) -> bool { ! ( self . 0 == 0 ) } # [ inline ] pub fn ok ( self ) -> :: windows :: Result < ( ) > { if self . as_bool ( ) { Ok ( ( ) ) } else { Err ( :: windows :: ErrorCode :: from_thread ( ) . into ( ) ) } } # [ inline ] pub fn unwrap ( self ) { self . ok ( ) . unwrap ( ) ; } # [ inline ] pub fn expect ( self , msg : & str ) { self . ok ( ) . expect ( msg ) ; } } impl :: std :: fmt :: Debug for BOOL { fn fmt ( & self , fmt : & mut :: std :: fmt :: Formatter < '_ > ) -> :: std :: fmt :: Result { let msg = if self . as_bool ( ) { "true" } else { "false" } ; fmt . write_str ( msg ) } } unsafe impl :: windows :: Abi for BOOL { type Abi = Self ; } impl :: std :: convert :: From < BOOL > for bool { fn from ( value : BOOL ) -> Self { value . as_bool ( ) } } impl :: std :: convert :: From < & BOOL > for bool { fn from ( value : & BOOL ) -> Self { value . as_bool ( ) } } impl :: std :: convert :: From < bool > for BOOL { fn from ( value : bool ) -> Self { if value { BOOL ( 1 ) } else { BOOL ( 0 ) } } } impl :: std :: convert :: From < & bool > for BOOL { fn from ( value : & bool ) -> Self { ( * value ) . into ( ) } } impl :: std :: cmp :: PartialEq < bool > for BOOL { fn eq ( & self , other : & bool ) -> bool { self . as_bool ( ) == * other } } impl :: std :: cmp :: PartialEq < BOOL > for bool { fn eq ( & self , other : & BOOL ) -> bool { * self == other . as_bool ( ) } } impl std :: ops :: Not for BOOL { type Output = Self ; fn not ( self ) -> Self :: Output { if self . as_bool ( ) { BOOL ( 0 ) } else { BOOL ( 1 ) } } } impl < 'a > :: windows :: IntoParam < 'a , BOOL > for bool { fn into_param ( self ) -> :: windows :: Param < 'a , BOOL > { :: windows :: Param :: Owned ( self . into ( ) ) } } } # [ allow ( unused_variables , non_upper_case_globals , non_snake_case , unused_unsafe , non_camel_case_types , dead_code , clippy :: all ) ] pub mod WindowsAndMessaging { # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy ) ] pub struct HHOOK ( pub isize ) ; impl HHOOK { } impl :: std :: default :: Default for HHOOK { fn default ( ) -> Self { Self ( 0 ) } } impl :: std :: fmt :: Debug for HHOOK { fn fmt ( & self , fmt : & mut :: std :: fmt :: Formatter < '_ > ) -> :: std :: fmt :: Result { fmt . debug_struct ( "HHOOK" ) . field ( "Value" , & format_args ! ( "{:?}" , self .0 ) ) . finish ( ) } } impl :: std :: cmp :: PartialEq for HHOOK { fn eq ( & self , other : & Self ) -> bool { self .0 == other .0 } } impl :: std :: cmp :: Eq for HHOOK { } unsafe impl :: windows :: Abi for HHOOK { type Abi = Self ; } # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy ) ] pub struct WPARAM ( pub usize ) ; impl WPARAM { } impl :: std :: default :: Default for WPARAM { fn default ( ) -> Self { Self ( 0 ) } } impl :: std :: fmt :: Debug for WPARAM { fn fmt ( & self , fmt : & mut :: std :: fmt :: Formatter < '_ > ) -> :: std :: fmt :: Result { fmt . debug_struct ( "WPARAM" ) . field ( "Value" , & format_args ! ( "{:?}" , self .0 ) ) . finish ( ) } } impl :: std :: cmp :: PartialEq for WPARAM { fn eq ( & self , other : & Self ) -> bool { self .0 == other .0 } } impl :: std :: cmp :: Eq for WPARAM { } unsafe impl :: windows :: Abi for WPARAM { type Abi = Self ; } # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy ) ] pub struct LPARAM ( pub isize ) ; impl LPARAM { } impl :: std :: default :: Default for LPARAM { fn default ( ) -> Self { Self ( 0 ) } } impl :: std :: fmt :: Debug for LPARAM { fn fmt ( & self , fmt : & mut :: std :: fmt :: Formatter < '_ > ) -> :: std :: fmt :: Result { fmt . debug_struct ( "LPARAM" ) . field ( "Value" , & format_args ! ( "{:?}" , self .0 ) ) . finish ( ) } } impl :: std :: cmp :: PartialEq for LPARAM { fn eq ( & self , other : & Self ) -> bool { self .0 == other .0 } } impl :: std :: cmp :: Eq for LPARAM { } unsafe impl :: windows :: Abi for LPARAM { type Abi = Self ; } pub unsafe fn CallNextHookEx < 'a , T0__ : :: windows :: IntoParam < 'a , HHOOK > , T2__ : :: windows :: IntoParam < 'a , WPARAM > , T3__ : :: windows :: IntoParam < 'a , LPARAM > , > ( hhk : T0__ , ncode : i32 , wparam : T2__ , lparam : T3__ , ) -> super :: SystemServices :: LRESULT { panic ! ( "Unsupported target OS" ) ; } # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy ) ] pub struct HWND ( pub isize ) ; impl HWND { } impl :: std :: default :: Default for HWND { fn default ( ) -> Self { Self ( 0 ) } } impl :: std :: fmt :: Debug for HWND { fn fmt ( & self , fmt : & mut :: std :: fmt :: Formatter < '_ > ) -> :: std :: fmt :: Result { fmt . debug_struct ( "HWND" ) . field ( "Value" , & format_args ! ( "{:?}" , self .0 ) ) . finish ( ) } } impl :: std :: cmp :: PartialEq for HWND { fn eq ( & self , other : & Self ) -> bool { self .0 == other .0 } } impl :: std :: cmp :: Eq for HWND { } unsafe impl :: windows :: Abi for HWND { type Abi = Self ; } # [ derive ( :: std :: cmp :: PartialEq , :: std :: cmp :: Eq , :: std :: marker :: Copy , :: std :: clone :: Clone , :: std :: default :: Default , :: std :: fmt :: Debug ) ] # [ repr ( transparent ) ] pub struct WINDOW_EX_STYLE ( pub u32 ) ; impl WINDOW_EX_STYLE { pub const WS_EX_DLGMODALFRAME : Self = Self ( 1u32 ) ; pub const WS_EX_NOPARENTNOTIFY : Self = Self ( 4u32 ) ; pub const WS_EX_TOPMOST : Self = Self ( 8u32 ) ; pub const WS_EX_ACCEPTFILES : Self = Self ( 16u32 ) ; pub const WS_EX_TRANSPARENT : Self = Self ( 32u32 ) ; pub const WS_EX_MDICHILD : Self = Self ( 64u32 ) ; pub const WS_EX_TOOLWINDOW : Self = Self ( 128u32 ) ; pub const WS_EX_WINDOWEDGE : Self = Self ( 256u32 ) ; pub const WS_EX_CLIENTEDGE : Self = Self ( 512u32 ) ; pub const WS_EX_CONTEXTHELP : Self = Self ( 1024u32 ) ; pub const WS_EX_RIGHT : Self = Self ( 4096u32 ) ; pub const WS_EX_LEFT : Self = Self ( 0u32 ) ; pub const WS_EX_RTLREADING : Self = Self ( 8192u32 ) ; pub const WS_EX_LTRREADING : Self = Self ( 0u32 ) ; pub const WS_EX_LEFTSCROLLBAR : Self = Self ( 16384u32 ) ; pub const WS_EX_RIGHTSCROLLBAR : Self = Self ( 0u32 ) ; pub const WS_EX_CONTROLPARENT : Self = Self ( 65536u32 ) ; pub const WS_EX_STATICEDGE : Self = Self ( 131072u32 ) ; pub const WS_EX_APPWINDOW : Self = Self ( 262144u32 ) ; pub const WS_EX_OVERLAPPEDWINDOW : Self = Self ( 768u32 ) ; pub const WS_EX_PALETTEWINDOW : Self = Self ( 392u32 ) ; pub const WS_EX_LAYERED : Self = Self ( 524288u32 ) ; pub const WS_EX_NOINHERITLAYOUT : Self = Self ( 1048576u32 ) ; pub const WS_EX_NOREDIRECTIONBITMAP : Self = Self ( 2097152u32 ) ; pub const WS_EX_LAYOUTRTL : Self = Self ( 4194304u32 ) ; pub const WS_EX_COMPOSITED : Self = Self ( 33554432u32 ) ; pub const WS_EX_NOACTIVATE : Self = Self ( 134217728u32 ) ; } impl :: std :: convert :: From < u32 > for WINDOW_EX_STYLE { fn from ( value : u32 ) -> Self { Self ( value ) } } unsafe impl :: windows :: Abi for WINDOW_EX_STYLE { type Abi = Self ; } impl :: std :: ops :: BitOr for WINDOW_EX_STYLE { type Output = Self ; fn bitor ( self , rhs : Self ) -> Self { Self ( self . 0 | rhs . 0 ) } } impl :: std :: ops :: BitAnd for WINDOW_EX_STYLE { type Output = Self ; fn bitand ( self , rhs : Self ) -> Self { Self ( self . 0 & rhs . 0 ) } } impl :: std :: ops :: BitOrAssign for WINDOW_EX_STYLE { fn bitor_assign ( & mut self , rhs : Self ) { self . 0 . bitor_assign ( rhs . 0 ) } } impl :: std :: ops :: BitAndAssign for WINDOW_EX_STYLE { fn bitand_assign ( & mut self , rhs : Self ) { self . 0 . bitand_assign ( rhs . 0 ) } } # [ derive ( :: std :: cmp :: PartialEq , :: std :: cmp :: Eq , :: std :: marker :: Copy , :: std :: clone :: Clone , :: std :: default :: Default , :: std :: fmt :: Debug ) ] # [ repr ( transparent ) ] pub struct WINDOW_STYLE ( pub u32 ) ; impl WINDOW_STYLE { pub const WS_OVERLAPPED : Self = Self ( 0u32 ) ; pub const WS_POPUP : Self = Self ( 2147483648u32 ) ; pub const WS_CHILD : Self = Self ( 1073741824u32 ) ; pub const WS_MINIMIZE : Self = Self ( 536870912u32 ) ; pub const WS_MAXIMIZE : Self = Self ( 16777216u32 ) ; pub const WS_HSCROLL : Self = Self ( 1048576u32 ) ; pub const WS_VSCROLL : Self = Self ( 2097152u32 ) ; pub const WS_VISIBLE : Self = Self ( 268435456u32 ) ; pub const WS_DISABLED : Self = Self ( 134217728u32 ) ; pub const WS_CLIPSIBLINGS : Self = Self ( 67108864u32 ) ; pub const WS_CLIPCHILDREN : Self = Self ( 33554432u32 ) ; pub const WS_CAPTION : Self = Self ( 12582912u32 ) ; pub const WS_BORDER : Self = Self ( 8388608u32 ) ; pub const WS_DLGFRAME : Self = Self ( 4194304u32 ) ; pub const WS_SYSMENU : Self = Self ( 524288u32 ) ; pub const WS_THICKFRAME : Self = Self ( 262144u32 ) ; pub const WS_GROUP : Self = Self ( 131072u32 ) ; pub const WS_TABSTOP : Self = Self ( 65536u32 ) ; pub const WS_MINIMIZEBOX : Self = Self ( 131072u32 ) ; pub const WS_MAXIMIZEBOX : Self = Self ( 65536u32 ) ; pub const WS_TILED : Self = Self ( 0u32 ) ; pub const WS_ICONIC : Self = Self ( 536870912u32 ) ; pub const WS_SIZEBOX : Self = Self ( 262144u32 ) ; pub const WS_TILEDWINDOW : Self = Self ( 13565952u32 ) ; pub const WS_OVERLAPPEDWINDOW : Self = Self ( 13565952u32 ) ; pub const WS_POPUPWINDOW : Self = Self ( 2156396544u32 ) ; pub const WS_CHILDWINDOW : Self = Self ( 1073741824u32 ) ; pub const WS_ACTIVECAPTION : Self = Self ( 1u32 ) ; } impl :: std :: convert :: From < u32 > for WINDOW_STYLE { fn from ( value : u32 ) -> Self { Self ( value ) } } unsafe impl :: windows :: Abi for WINDOW_STYLE { type Abi = Self ; } impl :: std :: ops :: BitOr for WINDOW_STYLE { type Output = Self ; fn bitor ( self , rhs : Self ) -> Self { Self ( self . 0 | rhs . 0 ) } } impl :: std :: ops :: BitAnd for WINDOW_STYLE { type Output = Self ; fn bitand ( self , rhs : Self ) -> Self { Self ( self . 0 & rhs . 0 ) } } impl :: std :: ops :: BitOrAssign for WINDOW_STYLE { fn bitor_assign ( & mut self , rhs : Self ) { self . 0 . bitor_assign ( rhs . 0 ) } } impl :: std :: ops :: BitAndAssign for WINDOW_STYLE { fn bitand_assign ( & mut self , rhs : Self ) { self . 0 . bitand_assign ( rhs . 0 ) } } pub unsafe fn CreateWindowExA < 'a , T1__ : :: windows :: IntoParam < 'a , super :: SystemServices :: PSTR > , T2__ : :: windows :: IntoParam < 'a , super :: SystemServices :: PSTR > , T8__ : :: windows :: IntoParam < 'a , HWND > , T9__ : :: windows :: IntoParam < 'a , super :: MenusAndResources :: HMENU > , T10__ : :: windows :: IntoParam < 'a , super :: SystemServices :: HINSTANCE > , > ( dwexstyle : WINDOW_EX_STYLE , lpclassname : T1__ , lpwindowname : T2__ , dwstyle : WINDOW_STYLE , x : i32 , y : i32 , nwidth : i32 , nheight : i32 , hwndparent : T8__ , hmenu : T9__ , hinstance : T10__ , lpparam : * mut :: std :: ffi :: c_void , ) -> HWND { panic ! ( "Unsupported target OS" ) ; } pub unsafe fn DefWindowProcA < 'a , T0__ : :: windows :: IntoParam < 'a , HWND > , T2__ : :: windows :: IntoParam < 'a , WPARAM > , T3__ : :: windows :: IntoParam < 'a , LPARAM > , > ( hwnd : T0__ , msg : u32 , wparam : T2__ , lparam : T3__ , ) -> super :: SystemServices :: LRESULT { panic ! ( "Unsupported target OS" ) ; } pub unsafe fn DestroyWindow < 'a , T0__ : :: windows :: IntoParam < 'a , HWND > , > ( hwnd : T0__ , ) -> super :: SystemServices :: BOOL { panic ! ( "Unsupported target OS" ) ; } # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy ) ] pub struct MSG { pub hwnd : HWND , pub message : u32 , pub wParam : WPARAM , pub lParam : LPARAM , pub time : u32 , pub pt : super :: DisplayDevices :: POINT } impl MSG { } impl :: std :: default :: Default for MSG { fn default ( ) -> Self { Self { hwnd : :: std :: default :: Default :: default ( ) , message : 0 , wParam : :: std :: default :: Default :: default ( ) , lParam : :: std :: default :: Default :: default ( ) , time : 0 , pt : :: std :: default :: Default :: default ( ) } } } impl :: std :: fmt :: Debug for MSG { fn fmt ( & self , fmt : & mut :: std :: fmt :: Formatter < '_ > ) -> :: std :: fmt :: Result { fmt . debug_struct ( "MSG" ) . field ( "hwnd" , & format_args ! ( "{:?}" , self . hwnd ) ) . field ( "message" , & format_args ! ( "{:?}" , self . message ) ) . field ( "wParam" , & format_args ! ( "{:?}" , self . wParam ) ) . field ( "lParam" , & format_args ! ( "{:?}" , self . lParam ) ) . field ( "time" , & format_args ! ( "{:?}" , self . time ) ) . field ( "pt" , & format_args ! ( "{:?}" , self . pt ) ) . finish ( ) } } impl :: std :: cmp :: PartialEq for MSG { fn eq ( & self , other : & Self ) -> bool { self . hwnd == other . hwnd && self . message == other . message && self . wParam == other . wParam && self . lParam == other . lParam && self . time == other . time && self . pt == other . pt } } impl :: std :: cmp :: Eq for MSG { } unsafe impl :: windows :: Abi for MSG { type Abi = Self ; } pub unsafe fn DispatchMessageA < > ( lpmsg : * const MSG , ) -> super :: SystemServices :: LRESULT { panic ! ( "Unsupported target OS" ) ; } pub unsafe fn GetMessageA < 'a , T1__ : :: windows :: IntoParam < 'a , HWND > , > ( lpmsg : * mut MSG , hwnd : T1__ , wmsgfiltermin : u32 , wmsgfiltermax : u32 , ) -> super :: SystemServices :: BOOL { panic ! ( "Unsupported target OS" ) ; } # [ derive ( :: std :: cmp :: PartialEq , :: std :: cmp :: Eq , :: std :: marker :: Copy , :: std :: clone :: Clone , :: std :: default :: Default , :: std :: fmt :: Debug ) ] # [ repr ( transparent ) ] pub struct WINDOW_LONG_PTR_INDEX ( pub i32 ) ; impl WINDOW_LONG_PTR_INDEX { pub const GWL_EXSTYLE : Self = Self ( -20i32 ) ; pub const GWLP_HINSTANCE : Self = Self ( -6i32 ) ; pub const GWLP_HWNDPARENT : Self = Self ( -8i32 ) ; pub const GWLP_ID : Self = Self ( -12i32 ) ; pub const GWL_STYLE : Self = Self ( -16i32 ) ; pub const GWLP_USERDATA : Self = Self ( -21i32 ) ; pub const GWLP_WNDPROC : Self = Self ( -4i32 ) ; pub const GWL_HINSTANCE : Self = Self ( -6i32 ) ; pub const GWL_ID : Self = Self ( -12i32 ) ; pub const GWL_USERDATA : Self = Self ( -21i32 ) ; pub const GWL_WNDPROC : Self = Self ( -4i32 ) ; pub const GWL_HWNDPARENT : Self = Self ( -8i32 ) ; } impl :: std :: convert :: From < i32 > for WINDOW_LONG_PTR_INDEX { fn from ( value : i32 ) -> Self { Self ( value ) } } unsafe impl :: windows :: Abi for WINDOW_LONG_PTR_INDEX { type Abi = Self ; } pub unsafe fn GetWindowLongPtrA < 'a , T0__ : :: windows :: IntoParam < 'a , HWND > , > ( hwnd : T0__ , nindex : WINDOW_LONG_PTR_INDEX , ) -> isize { panic ! ( "Unsupported target OS" ) ; } pub unsafe fn LoadIconA < 'a , T0__ : :: windows :: IntoParam < 'a , super :: SystemServices :: HINSTANCE > , T1__ : :: windows :: IntoParam < 'a , super :: SystemServices :: PSTR > , > ( hinstance : T0__ , lpiconname : T1__ , ) -> super :: MenusAndResources :: HICON { panic ! ( "Unsupported target OS" ) ; } pub unsafe fn PostMessageA < 'a , T0__ : :: windows :: IntoParam < 'a , HWND > , T2__ : :: windows :: IntoParam < 'a , WPARAM > , T3__ : :: windows :: IntoParam < 'a , LPARAM > , > ( hwnd : T0__ , msg : u32 , wparam : T2__ , lparam : T3__ , ) -> super :: SystemServices :: BOOL { panic ! ( "Unsupported target OS" ) ; } pub unsafe fn PostQuitMessage < > ( nexitcode : i32 , ) { panic ! ( "Unsupported target OS" ) ; } # [ derive ( :: std :: cmp :: PartialEq , :: std :: cmp :: Eq , :: std :: marker :: Copy , :: std :: clone :: Clone , :: std :: default :: Default , :: std :: fmt :: Debug ) ] # [ repr ( transparent ) ] pub struct WNDCLASS_STYLES ( pub u32 ) ; impl WNDCLASS_STYLES { pub const CS_VREDRAW : Self = Self ( 1u32 ) ; pub const CS_HREDRAW : Self = Self ( 2u32 ) ; pub const CS_DBLCLKS : Self = Self ( 8u32 ) ; pub const CS_OWNDC : Self = Self ( 32u32 ) ; pub const CS_CLASSDC : Self = Self ( 64u32 ) ; pub const CS_PARENTDC : Self = Self ( 128u32 ) ; pub const CS_NOCLOSE : Self = Self ( 512u32 ) ; pub const CS_SAVEBITS : Self = Self ( 2048u32 ) ; pub const CS_BYTEALIGNCLIENT : Self = Self ( 4096u32 ) ; pub const CS_BYTEALIGNWINDOW : Self = Self ( 8192u32 ) ; pub const CS_GLOBALCLASS : Self = Self ( 16384u32 ) ; pub const CS_IME : Self = Self ( 65536u32 ) ; pub const CS_DROPSHADOW : Self = Self ( 131072u32 ) ; } impl :: std :: convert :: From < u32 > for WNDCLASS_STYLES { fn from ( value : u32 ) -> Self { Self ( value ) } } unsafe impl :: windows :: Abi for WNDCLASS_STYLES { type Abi = Self ; } impl :: std :: ops :: BitOr for WNDCLASS_STYLES { type Output = Self ; fn bitor ( self , rhs : Self ) -> Self { Self ( self . 0 | rhs . 0 ) } } impl :: std :: ops :: BitAnd for WNDCLASS_STYLES { type Output = Self ; fn bitand ( self , rhs : Self ) -> Self { Self ( self . 0 & rhs . 0 ) } } impl :: std :: ops :: BitOrAssign for WNDCLASS_STYLES { fn bitor_assign ( & mut self , rhs : Self ) { self . 0 . bitor_assign ( rhs . 0 ) } } impl :: std :: ops :: BitAndAssign for WNDCLASS_STYLES { fn bitand_assign ( & mut self , rhs : Self ) { self . 0 . bitand_assign ( rhs . 0 ) } } pub type WNDPROC = extern "system" fn ( param0 : HWND , param1 : u32 , param2 : WPARAM , param3 : LPARAM ) -> super :: SystemServices :: LRESULT ; # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy ) ] pub struct WNDCLASSA { pub style : WNDCLASS_STYLES , pub lpfnWndProc : :: std :: option :: Option < WNDPROC > , pub cbClsExtra : i32 , pub cbWndExtra : i32 , pub hInstance : super :: SystemServices :: HINSTANCE , pub hIcon : super :: MenusAndResources :: HICON , pub hCursor : super :: MenusAndResources :: HCURSOR , pub hbrBackground : super :: Gdi :: HBRUSH , pub lpszMenuName : super :: SystemServices :: PSTR , pub lpszClassName : super :: SystemServices :: PSTR } impl WNDCLASSA { } impl :: std :: default :: Default for WNDCLASSA { fn default ( ) -> Self { Self { style : :: std :: default :: Default :: default ( ) , lpfnWndProc : :: std :: default :: Default :: default ( ) , cbClsExtra : 0 , cbWndExtra : 0 , hInstance : :: std :: default :: Default :: default ( ) , hIcon : :: std :: default :: Default :: default ( ) , hCursor : :: std :: default :: Default :: default ( ) , hbrBackground : :: std :: default :: Default :: default ( ) , lpszMenuName : :: std :: default :: Default :: default ( ) , lpszClassName : :: std :: default :: Default :: default ( ) } } } impl :: std :: fmt :: Debug for WNDCLASSA { fn fmt ( & self , fmt : & mut :: std :: fmt :: Formatter < '_ > ) -> :: std :: fmt :: Result { fmt . debug_struct ( "WNDCLASSA" ) . field ( "style" , & format_args ! ( "{:?}" , self . style ) ) . field ( "cbClsExtra" , & format_args ! ( "{:?}" , self . cbClsExtra ) ) . field ( "cbWndExtra" , & format_args ! ( "{:?}" , self . cbWndExtra ) ) . field ( "hInstance" , & format_args ! ( "{:?}" , self . hInstance ) ) . field ( "hIcon" , & format_args ! ( "{:?}" , self . hIcon ) ) . field ( "hCursor" , & format_args ! ( "{:?}" , self . hCursor ) ) . field ( "hbrBackground" , & format_args ! ( "{:?}" , self . hbrBackground ) ) . field ( "lpszMenuName" , & format_args ! ( "{:?}" , self . lpszMenuName ) ) . field ( "lpszClassName" , & format_args ! ( "{:?}" , self . lpszClassName ) ) . finish ( ) } } impl :: std :: cmp :: PartialEq for WNDCLASSA { fn eq ( & self , other : & Self ) -> bool { self . style == other . style && self . lpfnWndProc . map ( | f | f as usize ) == other . lpfnWndProc . map ( | f | f as usize ) && self . cbClsExtra == other . cbClsExtra && self . cbWndExtra == other . cbWndExtra && self . hInstance == other . hInstance && self . hIcon == other . hIcon && self . hCursor == other . hCursor && self . hbrBackground == other . hbrBackground && self . lpszMenuName == other . lpszMenuName && self . lpszClassName == other . lpszClassName } } impl :: std :: cmp :: Eq for WNDCLASSA { } unsafe impl :: windows :: Abi for WNDCLASSA { type Abi = Self ; } pub unsafe fn RegisterClassA < > ( lpwndclass : * const WNDCLASSA , ) -> u16 { panic ! ( "Unsupported target OS" ) ; } pub unsafe fn SetWindowLongPtrA < 'a , T0__ : :: windows :: IntoParam < 'a , HWND > , > ( hwnd : T0__ , nindex : WINDOW_LONG_PTR_INDEX , dwnewlong : isize , ) -> isize { panic ! ( "Unsupported target OS" ) ; } # [ derive ( :: std :: cmp :: PartialEq , :: std :: cmp :: Eq , :: std :: marker :: Copy , :: std :: clone :: Clone , :: std :: default :: Default , :: std :: fmt :: Debug ) ] # [ repr ( transparent ) ] pub struct SetWindowsHookEx_idHook ( pub i32 ) ; impl SetWindowsHookEx_idHook { pub const WH_CALLWNDPROC : Self = Self ( 4i32 ) ; pub const WH_CALLWNDPROCRET : Self = Self ( 12i32 ) ; pub const WH_CBT : Self = Self ( 5i32 ) ; pub const WH_DEBUG : Self = Self ( 9i32 ) ; pub const WH_FOREGROUNDIDLE : Self = Self ( 11i32 ) ; pub const WH_GETMESSAGE : Self = Self ( 3i32 ) ; pub const WH_JOURNALPLAYBACK : Self = Self ( 1i32 ) ; pub const WH_JOURNALRECORD : Self = Self ( 0i32 ) ; pub const WH_KEYBOARD : Self = Self ( 2i32 ) ; pub const WH_KEYBOARD_LL : Self = Self ( 13i32 ) ; pub const WH_MOUSE : Self = Self ( 7i32 ) ; pub const WH_MOUSE_LL : Self = Self ( 14i32 ) ; pub const WH_MSGFILTER : Self = Self ( -1i32 ) ; pub const WH_SHELL : Self = Self ( 10i32 ) ; pub const WH_SYSMSGFILTER : Self = Self ( 6i32 ) ; } impl :: std :: convert :: From < i32 > for SetWindowsHookEx_idHook { fn from ( value : i32 ) -> Self { Self ( value ) } } unsafe impl :: windows :: Abi for SetWindowsHookEx_idHook { type Abi = Self ; } pub type HOOKPROC = extern "system" fn ( code : i32 , wparam : WPARAM , lparam : LPARAM ) -> super :: SystemServices :: LRESULT ; pub unsafe fn SetWindowsHookExA < 'a , T2__ : :: windows :: IntoParam < 'a , super :: SystemServices :: HINSTANCE > , > ( idhook : SetWindowsHookEx_idHook , lpfn : :: std :: option :: Option < HOOKPROC > , hmod : T2__ , dwthreadid : u32 , ) -> HHOOK { panic ! ( "Unsupported target OS" ) ; } pub unsafe fn UnhookWindowsHookEx < 'a , T0__ : :: windows :: IntoParam < 'a , HHOOK > , > ( hhk : T0__ , ) -> super :: SystemServices :: BOOL { panic ! ( "Unsupported target OS" ) ; } # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy ) ] pub struct CREATESTRUCTA { pub lpCreateParams : * mut :: std :: ffi :: c_void , pub hInstance : super :: SystemServices :: HINSTANCE , pub hMenu : super :: MenusAndResources :: HMENU , pub hwndParent : HWND , pub cy : i32 , pub cx : i32 , pub y : i32 , pub x : i32 , pub style : i32 , pub lpszName : super :: SystemServices :: PSTR , pub lpszClass : super :: SystemServices :: PSTR , pub dwExStyle : u32 } impl CREATESTRUCTA { } impl :: std :: default :: Default for CREATESTRUCTA { fn default ( ) -> Self { Self { lpCreateParams : :: std :: ptr :: null_mut ( ) , hInstance : :: std :: default :: Default :: default ( ) , hMenu : :: std :: default :: Default :: default ( ) , hwndParent : :: std :: default :: Default :: default ( ) , cy : 0 , cx : 0 , y : 0 , x : 0 , style : 0 , lpszName : :: std :: default :: Default :: default ( ) , lpszClass : :: std :: default :: Default :: default ( ) , dwExStyle : 0 } } } impl :: std :: fmt :: Debug for CREATESTRUCTA { fn fmt ( & self , fmt : & mut :: std :: fmt :: Formatter < '_ > ) -> :: std :: fmt :: Result { fmt . debug_struct ( "CREATESTRUCTA" ) . field ( "lpCreateParams" , & format_args ! ( "{:?}" , self . lpCreateParams ) ) . field ( "hInstance" , & format_args ! ( "{:?}" , self . hInstance ) ) . field ( "hMenu" , & format_args ! ( "{:?}" , self . hMenu ) ) . field ( "hwndParent" , & format_args ! ( "{:?}" , self . hwndParent ) ) . field ( "cy" , & format_args ! ( "{:?}" , self . cy ) ) . field ( "cx" , & format_args ! ( "{:?}" , self . cx ) ) . field ( "y" , & format_args ! ( "{:?}" , self . y ) ) . field ( "x" , & format_args ! ( "{:?}" , self . x ) ) . field ( "style" , & format_args ! ( "{:?}" , self . style ) ) . field ( "lpszName" , & format_args ! ( "{:?}" , self . lpszName ) ) . field ( "lpszClass" , & format_args ! ( "{:?}" , self . lpszClass ) ) . field ( "dwExStyle" , & format_args ! ( "{:?}" , self . dwExStyle ) ) . finish ( ) } } impl :: std :: cmp :: PartialEq for CREATESTRUCTA { fn eq ( & self , other : & Self ) -> bool { self . lpCreateParams == other . lpCreateParams && self . hInstance == other . hInstance && self . hMenu == other . hMenu && self . hwndParent == other . hwndParent && self . cy == other . cy && self . cx == other . cx && self . y == other . y && self . x == other . x && self . style == other . style && self . lpszName == other . lpszName && self . lpszClass == other . lpszClass && self . dwExStyle == other . dwExStyle } } impl :: std :: cmp :: Eq for CREATESTRUCTA { } unsafe impl :: windows :: Abi for CREATESTRUCTA { type Abi = Self ; } pub const CW_USEDEFAULT : i32 = -2147483648i32 ; # [ repr ( C ) ] # [ derive ( :: std :: clone :: Clone , :: std :: marker :: Copy ) ] pub struct KBDLLHOOKSTRUCT { pub vkCode : u32 , pub scanCode : u32 , pub flags : u32 , pub time : u32 , pub dwExtraInfo : usize } impl KBDLLHOOKSTRUCT { } impl :: std :: default :: Default for KBDLLHOOKSTRUCT { fn default ( ) -> Self { Self { vkCode : 0 , scanCode : 0 , flags : 0 , time : 0 , dwExtraInfo : 0 } } } impl :: std :: fmt :: Debug for KBDLLHOOKSTRUCT { fn fmt ( & self , fmt : & mut :: std :: fmt :: Formatter < '_ > ) -> :: std :: fmt :: Result { fmt . debug_struct ( "KBDLLHOOKSTRUCT" ) . field ( "vkCode" , & format_args ! ( "{:?}" , self . vkCode ) ) . field ( "scanCode" , & format_args ! ( "{:?}" , self . scanCode ) ) . field ( "flags" , & format_args ! ( "{:?}" , self . flags ) ) . field ( "time" , & format_args ! ( "{:?}" , self . time ) ) . field ( "dwExtraInfo" , & format_args ! ( "{:?}" , self . dwExtraInfo ) ) . finish ( ) } } impl :: std :: cmp :: PartialEq for KBDLLHOOKSTRUCT { fn eq ( & self , other : & Self ) -> bool { self . vkCode == other . vkCode && self . scanCode == other . scanCode && self . flags == other . flags && self . time == other . time && self . dwExtraInfo == other . dwExtraInfo } } impl :: std :: cmp :: Eq for KBDLLHOOKSTRUCT { } unsafe impl :: windows :: Abi for KBDLLHOOKSTRUCT { type Abi = Self ; } pub const VK_CONTROL : u32 = 17u32 ; pub const VK_ESCAPE : u32 = 27u32 ; pub const VK_F12 : u32 = 123u32 ; pub const WM_CLOSE : u32 = 16u32 ; pub const WM_DESTROY : u32 = 2u32 ; pub const WM_NCCREATE : u32 = 129u32 ; pub const WM_QUIT : u32 = 18u32 ; pub const WM_KEYUP : u32 = 257u32 ; pub const WM_SYSKEYUP : u32 = 261u32 ; } } } [INFO] [stdout] | +++++++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: 2 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Checking rl-audio-device-hotkey v0.1.0 (/opt/rustwide/workdir) [INFO] [stderr] Finished `dev` profile [unoptimized + debuginfo] target(s) in 5.69s [INFO] running `Command { std: "docker" "inspect" "082e163047b465586b36cee4e3591ae726e14f278345636f52618d3f64a599fa", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "082e163047b465586b36cee4e3591ae726e14f278345636f52618d3f64a599fa", kill_on_drop: false }` [INFO] [stdout] 082e163047b465586b36cee4e3591ae726e14f278345636f52618d3f64a599fa