applicationDidFinishLaunching 之前的可可事件
我正在尝试在应用程序启动时加载窗口的大小和其他属性。不幸的是,如果我这样做,
applicationDidFinishLaunching
或者
applicationWillFinishLaunching
...我会出现丑陋的闪烁,显示未修改的窗口并快速切换到修改后的窗口。我知道如何为使用窗口控制器运行的非主窗口执行此操作(通常我在 nib 事件唤醒时执行此操作),但是我将如何在应用程序委托中执行此操作?
谢谢
I'm trying to load a window's size and other properties on application start. Unfortunately, if i do it on
applicationDidFinishLaunching
or
applicationWillFinishLaunching
... i get an ugly flicker, showing the unmodified window and quickly switching to a modified one. I know how to do this for my non-main windows that run with window controllers (usually i do this in awake from nib event), but how would i do it in an application delegate?
Thank you
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您可以告诉窗口在启动时不可见,这意味着您可以创建窗口,调整其框架大小等等,然后然后显示它。
You can tell the window to not be visible at launch, which means you can create your window, mess with its frame size and all that, and then show it.