Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Line Numbers in Tables




On 31/08/2007, at 12:31 PM, Gordon Apple wrote:

I implemented your approach for now and it works. However, isn't there
any better way to bind the column directly to the enclosing TableView?
Using your approach, I'm going through my document object just to make the
connection. What happens if I want a second instance of the (nib) view for
the same document? Will the column references automatically get updated to
the active window?


Also, this is sort of a self-synchronizing approach to the enumeration,
which is probably ok, assuming the table iterates all the rows each time.

Please read and take note of all earlier responses to your question.

The approach you're following is not a good one and if it isn't already broken, it could get broken in future.

The best solution has been given to you and should be simple to implement: use a datasource for that particular column. Apparently NSTableView works fine with both bindings and a datasource at the same time (although I've never tried it).

- Chris

Attachment: smime.p7s
Description: S/MIME cryptographic signature

_______________________________________________

Cocoa-dev mailing list (email@hidden)

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/email@hidden

This email sent to email@hidden

References: 
 >Re: Line Numbers in Tables (From: Gordon Apple <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.