• 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: Multiple NSTableView question
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Multiple NSTableView question


  • Subject: Re: Multiple NSTableView question
  • From: "Sven A. Schmidt" <email@hidden>
  • Date: Thu, 21 Jun 2001 09:43:57 +0200

On Donnerstag, Juni 21, 2001, at 12:53 Uhr, Jason Brown wrote:

I keep reading that by evaluating the theTableView argument used in

- (int)numberOfRowsInTableView:(NSTable *)theTableView

and

- (id)tableView:(NSTableView *)theTableView
objectValueForTableColumn:(NSTableColumn *)theColumn
row:(int)rowIndex


you can distinguish which table view is invoking these methods, when using more than one table view.

My question is this: Evaluate it against what?

In your controller object you probably keep outlets to the table views you use. By testing

if ( [ myFirstView isEqualTo: theTableView ] ) { ... }

you can figure out where the message comes from. You can find "isEqualTo" and the like in the NSComparisonMethods protocal description in Foundation. There are useful string comparisons in there, too.

Sven


References: 
 >Multiple NSTableView question (From: Jason Brown <email@hidden>)

  • Prev by Date: Re: Sending messages to nil -- anyway to detect this?
  • Next by Date: Re: WWDC Dev Tools / Software update
  • Previous by thread: Re: Multiple NSTableView question
  • Next by thread: Re: Multiple NSTableView question
  • Index(es):
    • Date
    • Thread