On 26/06/2009, at 12:40 PM, Quincey Morris wrote:
On Jun 25, 2009, at 19:14, Peter Zegelin wrote:
Well I guess the question then becomes 'where is earlier'!
I tried overloading NSViewController::loadView and it also gets
called 'after' the first call to numberOfRowsInTableView.
If I have the 3 methods awakeFromNib, numberOfRowsInTableView and
loadView this is the calling sequence I get:
numberOfRowsInTableView
awakeFromNib
loadView
numberOfRowsInTableView
numberOfRowsInTableView
objectValueForTableColumn <- drawing will start here I guess
Grahams suggestion is a good workaround (thanks!) but I still don't
quite get it.
Your situation requires a little care because you (presumably,
otherwise your question wouldn't make sense) have a NSTableView
subclass,
Go easy on me here - but I just have a regular NSTableView - no
subclass. The NSViewController - which is subclassed -is the
delegate and handles numberOfRowsInTableView/
objectValueForTableColumn. So why didn't my question make sense?
(Alternatively, follow Graham's approach, which in effect makes
initialization unnecessary.)
Yes this works fine.
Peter
_______________________________________________
Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)
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:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com
This email sent to arch...@mail-archive.com