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

Re: Enter in NSTableView


  • Subject: Re: Enter in NSTableView
  • From: Brian Webster <email@hidden>
  • Date: Sun, 23 Nov 2003 10:55:23 -0600

Stolen shamelessly from the OmniGroup's OmniAppKit framework:

http://cocoa.mamasam.com/COCOADEV/2003/01/2/54902.php

On Nov 23, 2003, at 5:09 AM, Ivan Myrvold wrote:

I have customized NSTableView, where I have an NSComboBoxCell in the
first column. The NSTableView is in a sheet. Here is how I set it up:

- (void)windowDidLoad {
NSComboBoxCell *comboCell;
NSTableColumn *combocolumn = [[ofsbliste tableColumns]
objectAtIndex:0];

comboCell = [[NSComboBoxCell alloc] init];
[combocolumn setDataCell:comboCell];
[comboCell setControlSize:NSSmallControlSize];
[comboCell setFont:[NSFont systemFontOfSize:[NSFont
smallSystemFontSize]]];
[comboCell setEditable:YES];
[comboCell setCompletes:YES];
[comboCell setAction:@selector(selectedItem:)];
[comboCell setTarget:self];

combocolumn = [[oikkefsbliste tableColumns] objectAtIndex:0];
[combocolumn setDataCell:comboCell];
[comboCell release];
.....
I am happy how this works, but for one small detail. When I hit enter,
I would like to have the action for the OK button activated. How it
works now is that the next row in the NSTableView is selected, and I
would like to have that changed. Any tips for how I could implement
that?

Ivan
_______________________________________________
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.


--
Brian Webster
email@hidden
http://homepage.mac.com/bwebster
_______________________________________________
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: 
 >Enter in NSTableView (From: Ivan Myrvold <email@hidden>)

  • Prev by Date: Re: OT: Meaning of .m extension
  • Next by Date: Re: OT: Meaning of .m extension
  • Previous by thread: Enter in NSTableView
  • Next by thread: info/inspector icon
  • Index(es):
    • Date
    • Thread