User click lost in space for a NSTableView
User click lost in space for a NSTableView
- Subject: User click lost in space for a NSTableView
- From: Stephane Sudre <email@hidden>
- Date: Fri, 19 Nov 2004 17:14:04 +0100
With the following code:
#import "MainController.h"
@implementation MainController
- (int)numberOfRowsInTableView:(NSTableView *)tableView
{
return 3;
}
- (id)tableView:(NSTableView *)tableView
objectValueForTableColumn:(NSTableColumn *)tableColumn row:(int)row
{
return @"toto";
}
- (void)tableViewSelectionDidChange:(NSNotification *)notification
{
NSLog(@"tableViewSelectionDidChange");
}
- (BOOL)selectionShouldChangeInTableView:(NSTableView *)aTableView
{
NSLog(@"selectionShouldChangeInTableView BEFORE");
NSRunAlertPanel(@"title",@"msg %d", @"defaultButton",
@"alternateButton", @"otherButton", 1);
NSLog(@"selectionShouldChangeInTableView AFTER");
return YES;
}
- (BOOL)tableView:(NSTableView *)tableView shouldSelectRow:(int)row
{
NSLog(@"shouldSelectRow");
return YES;
}
@end
when you click on the table view to modify the selection, the alert
appears. and then you have to click in another location in the screen
to receive the tableViewSelectionDidChange notification. I was a post
on this very same topic in the archive and I was wondering if someone
has an idea on why it's happening (I suspect a modal plot over the main
run loop) and how to work around it if possible.
Or should I file a bug report instead?
_______________________________________________
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