1
0
Fork 0

Fix Clippy lints in macOS backend

This commit is contained in:
Robbert van der Helm 2023-01-01 22:38:57 +01:00
parent 39e97ab2be
commit 8e3e078220
2 changed files with 2 additions and 5 deletions

View file

@ -234,7 +234,7 @@ extern "C" fn view_did_change_backing_properties(this: &Object, _: Sel, _: id) {
let ns_window: *mut Object = msg_send![this, window]; let ns_window: *mut Object = msg_send![this, window];
let scale_factor: f64 = let scale_factor: f64 =
if ns_window.is_null() { 1.0 } else { NSWindow::backingScaleFactor(ns_window) as f64 }; if ns_window.is_null() { 1.0 } else { NSWindow::backingScaleFactor(ns_window) };
let state: &mut WindowState = WindowState::from_field(this); let state: &mut WindowState = WindowState::from_field(this);

View file

@ -229,10 +229,7 @@ impl Window {
let rect = NSRect::new( let rect = NSRect::new(
NSPoint::new(0.0, 0.0), NSPoint::new(0.0, 0.0),
NSSize::new( NSSize::new(window_info.logical_size().width, window_info.logical_size().height),
window_info.logical_size().width as f64,
window_info.logical_size().height as f64,
),
); );
let ns_window = unsafe { let ns_window = unsafe {