是否有一种简单的方法可以使我的应用程序的 float 工具选项板永久处于事件状态?它们都与打开的文档相关,因此没有理由让它们在任何时间点处于不活动状态。
最佳答案
使用 NSPanel
作为实用程序窗口。
这样,当应用程序不活动时,面板也可以正确隐藏(尽管它是一个标志)。
考虑将其设为“非激活”:
If the receiver is a non-activating panel, then it becomes key only if the hit view returns YES from needsPanelToBecomeKey. This way, a non-activating panel can control whether it takes keyboard focus.
关于objective-c - 使调色板永久激活/聚焦?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/12633455/