• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Loop through NSTableView to set NSCell state
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Loop through NSTableView to set NSCell state


  • Subject: Re: Loop through NSTableView to set NSCell state
  • From: Andy Lee <email@hidden>
  • Date: Sun, 14 Apr 2002 13:36:19 -0400

At 11:23 AM -0400 4/14/02, Erik J. Barzeski wrote:
On 4/14/02 10:50am, j o a r <email@hidden> wrote:
> Complying with the MVC pattern you should never need to enumerate over
the cells in the table view - the view is just there do display values,
not provide them.

I disagree, and have found times to use -selectedRowEnumerator many times,
if only to figure out _what_ object in the "model" is selected based on the
selected row's index.

You may have missed the original question, which was how to enumerate over all the cells in the table view -- *all* the cells, not just the selected ones, and all the *cells*, not their row numbers (under the mistaken assumption that NSTableView uses one NSCell per displayed cell, the way NSMatrix does).

Onar specifically did not want to select the whole table just to be able to use -selectedRowEnumerator -- which wouldn't have helped anyway, because -selectedRowEnumerator returns row numbers, not instances of NSCell.

--Andy
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.

References: 
 >Re: cocoa-dev digest, Vol 2 #496 - 15 msgs (From: "Erik J. Barzeski" <email@hidden>)

  • Prev by Date: Re: Address Book FrameWork
  • Next by Date: Re: Distorted System Sounds
  • Previous by thread: Re: Loop through NSTableView to set NSCell state
  • Next by thread: Re: Where's classic's system folder ?
  • Index(es):
    • Date
    • Thread