Supplemental:  the table only renders once. However many objects are in the 
_rules array are presented when any column header is activated. Then the table 
freezes up.  Additionally items can be added to the array; nothing more happens 
with the table view.


Erik Stainsby
[email protected]
-------------------------------------
Consistently place constants on the LHS of an expression: you cannot 
accidentally assign when you meant to compare.




On 2012-02-29, at 12:25 AM, Graham Cox wrote:

> 
> On 29/02/2012, at 5:47 PM, Jens Alfke wrote:
> 
>> 
>> On Feb 28, 2012, at 8:39 PM, Erik Stainsby wrote:
>> 
>>>     [_rules addObject: rule];
>>>     [table reloadData];
>>>     [table setNeedsDisplay:YES];
>> 
>> IIRC you need to call -noteNumberOfRowsChanged instead, if you've change the 
>> number of rows. -reloadData is just for reloading the existing rows.
> 
> 
> That's news to me - I've always just called -reloadData. I believe it queries 
> the rowCount, and then marks as needing redisplay those rows that are 
> visible. This might be less optimal that reloading only the changed rows, but 
> as far as I know, this has always worked fine for me.
> 
> Erik's code looks OK, but we don't know that the outlet <table> is actually 
> pointing to anything, or that it's pointing to the correct thing. That's what 
> I'd check first - set a breakpoint in appendRule: and have a look at it.
> 
> --Graham
> 
> 


_______________________________________________

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:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [email protected]

Reply via email to