• 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
NSTableView / NSArrayController drag and drop
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSTableView / NSArrayController drag and drop


  • Subject: NSTableView / NSArrayController drag and drop
  • From: Pierre Bernard <email@hidden>
  • Date: Tue, 16 May 2006 08:19:53 +0200

Hi!

I am trying to implement drag and drop from a NSTableView that is set up using an NSArrayController.

I have downloaded Mmalcolm Crawford's Bookmarks sample code from homepage.mac.com/mmalc/CocoaExamples/controllers.html
In my application I have tried to replicate the same set-up as in the sample code:


- Subclass of NSArrayController
- The array controller is data source and delegate to the table view
- The data source has an outlet pointing to the table view.

I skipped a few methods as I only need to drag from the table view (to the Finder). It should not accept drops.

However when I run my application I am reminded to implement the table data source methods:

- (int) numberOfRowsInTableView: (NSTableView *) tableView
- (id) tableView: (NSTableView *) tableView
objectValueForTableColumn: (NSTableColumn *) tableColumn
row: (int) row

How come this is not needed in the sample code?


Best Pierre Bernard


--- Pierre Bernard http://www.bernard-web.com/pierre http://www.houdah.com






--- Pierre Bernard http://www.bernard-web.com/pierre http://www.houdah.com



_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: NSTableView / NSArrayController drag and drop
      • From: "Pierce T. Wetter III" <email@hidden>
  • Prev by Date: Fwd: NSSlider and NSSliderCell classes
  • Next by Date: Re: Need help with document, window controllers and bindings.
  • Previous by thread: Re: Need help with document, window controllers and bindings.
  • Next by thread: Re: NSTableView / NSArrayController drag and drop
  • Index(es):
    • Date
    • Thread