diff --git a/library/modules/platform/uikit.sx b/library/modules/platform/uikit.sx index b4e8364..6cd0506 100644 --- a/library/modules/platform/uikit.sx +++ b/library/modules/platform/uikit.sx @@ -266,9 +266,7 @@ uikit_refresh_safe_insets :: (plat: *UIKitPlatform) { inline if OS != .ios { return; } if plat.gl_view == null { return; } - sel_safe := sel_registerName("safeAreaInsets".ptr); - msg_insets : (*void, *void) -> UIEdgeInsets = xx objc_msgSend; - i := msg_insets(plat.gl_view, sel_safe); + i := #objc_call(UIEdgeInsets)(plat.gl_view, "safeAreaInsets"); plat.safe_top = xx i.top; plat.safe_left = xx i.left; plat.safe_bottom = xx i.bottom; @@ -545,7 +543,6 @@ uikit_scene_will_connect_ios :: (delegate: *void, scene: *void) { sel_add_to_runloop := sel_registerName("addToRunLoop:forMode:".ptr); sel_current_runloop := sel_registerName("currentRunLoop".ptr); sel_tick := sel_registerName("sxTick:".ptr); - sel_safe_insets := sel_registerName("safeAreaInsets".ptr); msg_o : (*void, *void) -> *void = xx objc_msgSend; msg_v : (*void, *void) -> void = xx objc_msgSend;