diff --git a/Cargo.toml b/Cargo.toml index e79a7c8..03ed795 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -17,7 +17,7 @@ once_cell = "1" thiserror = "1" [target."cfg(target_os = \"windows\")".dependencies.windows-sys] -version = "0.45" +version = "0.48" features = [ "Win32_UI_WindowsAndMessaging", "Win32_Foundation", diff --git a/src/platform_impl/windows/icon.rs b/src/platform_impl/windows/icon.rs index 153eb63..4a3c9fd 100644 --- a/src/platform_impl/windows/icon.rs +++ b/src/platform_impl/windows/icon.rs @@ -91,7 +91,7 @@ impl WinIcon { bitmap_info.bmiHeader.biHeight = rc.bottom; bitmap_info.bmiHeader.biPlanes = 1; bitmap_info.bmiHeader.biBitCount = 32; - bitmap_info.bmiHeader.biCompression = BI_RGB; + bitmap_info.bmiHeader.biCompression = BI_RGB as _; let h_dc_bitmap = GetDC(0); diff --git a/src/platform_impl/windows/util.rs b/src/platform_impl/windows/util.rs index 709fe12..77df4d7 100644 --- a/src/platform_impl/windows/util.rs +++ b/src/platform_impl/windows/util.rs @@ -54,7 +54,7 @@ impl DerefMut for Accel { // taken from winit's code base // https://github.com/rust-windowing/winit/blob/ee88e38f13fbc86a7aafae1d17ad3cd4a1e761df/src/platform_impl/windows/util.rs#L138 -pub fn get_instance_handle() -> windows_sys::Win32::Foundation::HINSTANCE { +pub fn get_instance_handle() -> windows_sys::Win32::Foundation::HMODULE { // Gets the instance handle by taking the address of the // pseudo-variable created by the microsoft linker: // https://devblogs.microsoft.com/oldnewthing/20041025-00/?p=37483