Yes not sure what caused it. I have just copied a table and its datasource from another part of my project, which also has a checkbox and it also works fine in my sheet. I'm now gradually changing the datasource to what I want for this table. So far so good.

So problem solved - but I'm not sure what caused the original weirdness.

Peter


On 19/03/2009, at 4:41 PM, Yvonne Du wrote:

Hi, I write a simple project, and put a NSTalbeView in the window, and set the data source to a controller, the implementation of this controller is as following:

@implementation controller

-(int) numberOfRowsInTableView:(NSTableView*)aTableView
{
        return 128;
}

- (id)tableView:(NSTableView *)aTableView objectValueForTableColumn: (NSTableColumn *)aTableColumn row:(NSInteger)rowIndex
{
        return [NSNumber numberWithInt:1];
}
@end

it works fine.
--------------------------------------------------
From: "Peter Zegelin" <[email protected]>
Sent: Thursday, March 19, 2009 1:12 PM
To: "Cocoa Development" <[email protected]>
Subject: Weird NSTableView with checkboxes issue

I have an NSTableView in a sheet window. It has one column and a valid dataSource and delegate. There are 128 rows. If I populate the view with Textcells, sliders or popup button cells the tableview scrolls normally, but if I populate the listbox with checkbox cells the scrolling becomes extremely jerky. In the datasource objectValueForTableColumn method I just do the following:

id)tableView:(NSTableView *)tableView objectValueForTableColumn: (NSTableColumn *)tableColumn row:(int)row{
return [NSNumber numberWithInt:0];
}

my datasource/tableview is copied from another project that does exactly the same thing and it scrolls just fine. The console/ debugger etc. show nothing is amiss.

Any suggestions what may be causing the problem?

Thanks!

Peter
_______________________________________________

Cocoa-dev mailing list ([email protected])

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/yvonnedu_2008%40live.com

This email sent to [email protected]

_______________________________________________

Cocoa-dev mailing list ([email protected])

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [email protected]

Reply via email to