From 3d09c6517af1f54591f4ecc753a2f884f7cb0f12 Mon Sep 17 00:00:00 2001 From: Patrick Walton Date: Wed, 3 Feb 2016 14:15:18 -0800 Subject: [PATCH] Add a binding to -[NSView superview]. --- src/appkit.rs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/appkit.rs b/src/appkit.rs index b3f8efb..83f6644 100644 --- a/src/appkit.rs +++ b/src/appkit.rs @@ -1242,6 +1242,7 @@ pub trait NSView { unsafe fn setWantsBestResolutionOpenGLSurface_(self, flag: BOOL); unsafe fn convertPoint_fromView_(self, point: NSPoint, view: id) -> NSPoint; unsafe fn addSubview_(self, view: id); + unsafe fn superview(self) -> id; } impl NSView for id { @@ -1277,6 +1278,9 @@ impl NSView for id { msg_send![self, addSubview:view] } + unsafe fn superview(self) -> id { + msg_send![self, superview] + } } pub trait NSOpenGLView {