After spent all the afternoon and the night to try understand how it works, I try to ask here to resolve my problem.
I've created a Cocoa App in Xcode. I deleted the default MainMenu.xib file in order to create my own file.
Now I have:
a file named
AppDelegate.swiftwith the following part of code@NSApplicationMain class AppDelegate: NSObject, NSApplicationDelegate {
a file named
Window.swiftwith the following code:class Window: NSWindowController {
A file named
Window.xibthat has no connection (outlet set) since I try to understand how set it so I have deleted all the already created in order to try to recreate it.
The problem is that, even I can link a button (previously inserted with the Interface Builder into the window) in the Window : NSWindowsController class, it return the error
Failed to connect (button) outlet from (NSApplication)
to (NSButton): missing setter or instance variable
I don't understand why since the only connection is the connection now defined and no more possible connection are possible to do (I've tried to link some component around the screen in order to see some anchor zone but no appears).
So, even if there are some questions that analyse this problem given the answer that the user have done something wrong, I try to ask to explain how the connection are performed in order to recreate it and understand where is the problem.
Only for completeness, in the Windows.xib, nether File's Owner, First Responder or Application shows links in the Connections inspector panel.