iOS: Fix a few instances of UB (#2428)

* Fix iOS 32-bit

* Fix a few invalid message sends on iOS
This commit is contained in:
Mads Marquart 2022-09-01 03:10:00 +02:00 committed by GitHub
parent 66aa6c945d
commit a43a15b4a0
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 9 additions and 8 deletions

View file

@ -262,7 +262,7 @@ unsafe fn get_view_class(root_view_class: &'static Class) -> &'static Class {
let scale_factor: CGFloat = msg_send![object, contentScaleFactor];
PhysicalPosition::from_logical::<(f64, f64), f64>(
(logical_location.x as _, logical_location.y as _),
scale_factor,
scale_factor as f64,
)
};
touch_events.push(EventWrapper::StaticEvent(Event::WindowEvent {