diff --git a/src/macos/view.rs b/src/macos/view.rs index 1e95ff0..52c9311 100644 --- a/src/macos/view.rs +++ b/src/macos/view.rs @@ -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 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); diff --git a/src/macos/window.rs b/src/macos/window.rs index bf442da..fd67de7 100644 --- a/src/macos/window.rs +++ b/src/macos/window.rs @@ -229,10 +229,7 @@ impl Window { let rect = NSRect::new( NSPoint::new(0.0, 0.0), - NSSize::new( - window_info.logical_size().width as f64, - window_info.logical_size().height as f64, - ), + NSSize::new(window_info.logical_size().width, window_info.logical_size().height), ); let ns_window = unsafe {