It seems that using Xcode’s Interface Builder, when we Ctrl-drag the control to the header file, what we create as outlet is very similar to a webpage’s element’s properties (attributes), and what we create as action is very similar to event handlers. Is that true?
I also wonder why we need to Ctrl-drag the control to the header file, under @interface, instead of just right click on it and choose either “Add outlet” or “Add action”. Why to we have to drag it to an exact place in the header file?
Actually, we don’t need to drag it with Ctrl, this is just for ease of using.We can also link our outlets in code.
And, yes, it is really similar to properties. You even can declare it as properties in your
@interfaceHere’s a good talk on this subject https://groups.google.com/forum/m/?fromgroups#!topic/pdx-cocoaheads-talk/ujqrcCZc-Z8