NSView - 获取超级视图层次结构
有没有一种简单的方法可以将 NSView 层次结构(nsview 的超级视图的超级视图的超级视图)返回到主窗口或中间的一个点?
谢谢
Is there a simple way to walk back up the NSView hierarchy (superview of superview of superview of nsview) to the main window or a point in between?
Thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
对于该术语的任何定义,视图不一定与“主窗口”有任何关系,但您可以简单地通过 询问它。
A view won't necessarily have anything to do with “the main window”, for any definition of that term, but you can get the window that a view is in by simply asking it.