diff --git a/cocoa/src/appkit.rs b/cocoa/src/appkit.rs index c159b1a..bb5f40d 100644 --- a/cocoa/src/appkit.rs +++ b/cocoa/src/appkit.rs @@ -1673,6 +1673,7 @@ pub trait NSView: Sized { unsafe fn widthAnchor(self) -> id; unsafe fn heightAnchor(self) -> id; + unsafe fn convertRectToBacking(self, rect: NSRect) -> NSRect; } impl NSView for id { @@ -1743,6 +1744,10 @@ impl NSView for id { unsafe fn heightAnchor(self) -> id { msg_send![self, heightAnchor] } + + unsafe fn convertRectToBacking(self, rect: NSRect) -> NSRect { + msg_send![self, convertRectToBacking:rect] + } } pub type NSAutoresizingMaskOptions = u64;