summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorDavid Lönnhager <david.l@mullvad.net>2025-03-04 10:56:03 +0100
committerDavid Lönnhager <david.l@mullvad.net>2025-03-05 23:32:57 +0100
commitd9e4dd0f358a145e2522bcc221f3cba436510252 (patch)
tree9362cb2a272dcfc0890f3feea3331ba17f2747aa
parent3da2c2d4a92391cfa3f12cf0d995d5e5dcf3e5ca (diff)
downloadmullvadvpn-d9e4dd0f358a145e2522bcc221f3cba436510252.tar.xz
mullvadvpn-d9e4dd0f358a145e2522bcc221f3cba436510252.zip
Change from "as _" to "as isize"
-rw-r--r--installer-downloader/src/winapi_impl/delegate.rs2
-rw-r--r--installer-downloader/src/winapi_impl/ui.rs12
2 files changed, 7 insertions, 7 deletions
diff --git a/installer-downloader/src/winapi_impl/delegate.rs b/installer-downloader/src/winapi_impl/delegate.rs
index 08f5292cad..1734642771 100644
--- a/installer-downloader/src/winapi_impl/delegate.rs
+++ b/installer-downloader/src/winapi_impl/delegate.rs
@@ -247,6 +247,6 @@ impl AppDelegateQueue<AppWindow> for Queue {
};
let context_ptr = Box::into_raw(Box::new(context));
// SAFETY: This is safe since `callback` is Send
- unsafe { PostMessageW(hwnd as _, QUEUE_MESSAGE, 0, context_ptr as isize) };
+ unsafe { PostMessageW(hwnd as isize, QUEUE_MESSAGE, 0, context_ptr as isize) };
}
}
diff --git a/installer-downloader/src/winapi_impl/ui.rs b/installer-downloader/src/winapi_impl/ui.rs
index 72ba3d52e8..af5e39bf21 100644
--- a/installer-downloader/src/winapi_impl/ui.rs
+++ b/installer-downloader/src/winapi_impl/ui.rs
@@ -391,8 +391,8 @@ fn handle_banner_label_colors(
if msg == WM_CTLCOLORSTATIC {
// SAFETY: `w` is a valid device context for WM_CTLCOLORSTATIC
unsafe {
- SetTextColor(w as _, rgb([255, 255, 255]));
- SetBkColor(w as _, rgb(BACKGROUND_COLOR));
+ SetTextColor(w as isize, rgb([255, 255, 255]));
+ SetBkColor(w as isize, rgb(BACKGROUND_COLOR));
}
}
None
@@ -415,11 +415,11 @@ fn handle_link_messages(
if msg == WM_CTLCOLORSTATIC && Some(p) == link_hwnd {
// SAFETY: `w` is a valid device context for WM_CTLCOLORSTATIC
unsafe {
- SetBkMode(w as _, TRANSPARENT as _);
- SetTextColor(w as _, rgb(LINK_COLOR));
+ SetBkMode(w as isize, TRANSPARENT as _);
+ SetTextColor(w as isize, rgb(LINK_COLOR));
}
// Out of bounds background
- return Some(COLOR_WINDOW as _);
+ return Some(COLOR_WINDOW as isize);
}
None
@@ -495,7 +495,7 @@ fn create_link_font() -> Result<&'static nwg::Font, nwg::NwgError> {
}
Ok(nwg::Font {
- handle: raw_font as _,
+ handle: raw_font as *mut _,
})
});