Re: Two view controllers in one set of files (Noob
On Mar 25, 2009, at 8:26 PM, Peter N Lewis wrote:
At 12:57 -0400 25/3/09, I. Savant wrote:
You can certainly have more than one class declared and implemented
in the same .h/.m files. You can also have multiple controllers
the same XIB. Wherever your classes are declared/implemented, they
show up as "available" in Interface Builder as individual classes, so
when you instantiate them, they appear as if they were
declared/implemented in different files. IB does not care.
This is not strictly true - the interface for the class must be in
a .h file.
Interface Builder does not appear to search implementation (.m, .mm,
As I phrased it, it is most definitely true. You missed the part
where I said, "... in the same .h/.m files". I'm not speaking of
putting everything in a .m (or .mm) file. This raises more issues than
it solves, IB's ability to analyze things being one.
But I'm a bit uncertain when you would have two tightly coupled
controllers that could not simply be a single controller, so perhaps
the OP would like to post the reason why he wants them together (the
reason why you are asking a question is often helpful in determining
the best answer which is not always the answer to the question
Cocoa-dev mailing list (Cocoa-dev@xxxxxxxxxxxxxxx)
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 maillists@xxxxxxxxx