Re: NSAlert::runModal doesn't work on 10.6
Re: NSAlert::runModal doesn't work on 10.6
- Subject: Re: NSAlert::runModal doesn't work on 10.6
- From: email@hidden
- Date: Wed, 24 Aug 2016 08:31:32 +0900
> On Aug 24, 2016, at 2:56 AM, Andreas Falkenhahn <email@hidden> wrote:
>
> Is that your personal opinion or is this documented anywhere?
There's not anything to the contrary I've seen.
Look no further than LSUIElement.
There is an info plist key that says you have no UI, and guess what it works even if you included one.
There are methods for launching/activating without UI.
App templates have evolved over the years.
There wasn't always a wired up app delegate in the nib by default. It just happens to be a good starting pattern most of the time.
You don't need an app delegate.
You don't need a window.
You are not required to have any of the default menus.
You don't have to provide any icon (the system will provide a default based on the .app bundle UTI).
You only really have to have an Info plist but that can be embedded in the binary, so even the app bundle is not required.
All this adds up to its not required. It's strongly encouraged and supported because it's a great set of design patterns that facilitate good development and consistent experience within the ecosystem.
There are always folks from other language and platform backgrounds who show up wanting to avoid nibs. And they can. But some things are going to be incredibly hard without it.
You do need to hang on to that main runloop created by NSApplicationMain() if you want any AppKit views to work right.
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden