• 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: Saving field editor changes
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Saving field editor changes


  • Subject: Re: Saving field editor changes
  • From: Quentin Mathé <email@hidden>
  • Date: Mon, 28 Apr 2003 09:23:38 +0200

Le lundi, 28 avr 2003, ` 00:56 Europe/Paris, Pete Yandell a icrit :

Is there any way to get the currently active field editor to submit its changes (to an NSTableView or NSOutlineView) without ending the editing?

For example, I double click a table row to start editing it and type a few characters. Can I programatically convince the field editor to submit this text to the table view, such that its data source's tableView:setObjectValue:forTableColumn:row: method is called, without closing the field editor and changing the first responder?

Implement the delegate method or the notification method :
- (void)controlTextDidChange:(NSNotification *)aNotification

with following code :
[[[outletTableView] datasource] tableView:outletTableView setObjectValue:[[aNotification objectForKey:@"NSFieldEditor] string] forTableColumn:[outletTableView editedColumn] row:[outletTableView editedRow];

I'm not sure it's the solution, but I think it will do the job.

--
Quentin Mathi
email@hidden
_______________________________________________
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: 
 >Saving field editor changes (From: Pete Yandell <email@hidden>)

  • Prev by Date: Re: Protocols on the fly?
  • Next by Date: Custom View
  • Previous by thread: Saving field editor changes
  • Next by thread: Can't Draw To Secondary Monitor
  • Index(es):
    • Date
    • Thread