Re: CD: Creating a managed object
Re: CD: Creating a managed object
- Subject: Re: CD: Creating a managed object
- From: "I. Savant" <email@hidden>
- Date: Tue, 29 May 2007 07:18:54 -0400
On May 28, 2007, at 11:42 PM, Ian Joyner wrote:
OK, even if this is not quite right, it's only a small routine to
refactor, so I think this is pretty clean (the only thing I'm
uneasy about is manipulating a model object in a view, but perhaps
that is alright.
I think you need to go back to the fundamentals in the
documentation and put in some serious review/research time before
continuing any further. There's simply no good reason for your approach.
You should consider data source and delegate style methods (like
NSTableView). Study NSTableView's design and do it that way.
Something like -myView:didClickAtPoint: ... if that's sent to a
delegate (your controller) the delegate can respond by creating a new
model object and any housekeeping.
Any time you have a view directly interacting with a model or vice-
versa, your design is incorrect.
--
I.S.
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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