mirror of
https://github.com/cappuccino/cappuccino.git
synced 2026-10-24 00:58:53 +00:00
detect sort descriptors when table column is added
This commit is contained in:
1 parent
50d36e76ac
commit
ed98a44116
1 file changed
+11
@@ -870,6 +870,17 @@ CPTableViewFirstColumnOnlyAutoresizingStyle = 5;
|
||||
else
|
||||
_dirtyTableColumnRangeIndex = MIN(NUMBER_OF_COLUMNS() - 1, _dirtyTableColumnRangeIndex);
|
||||
|
||||
if ([[self sortDescriptors] count] > 0)
|
||||
{
|
||||
var mainSortDescriptor = [[self sortDescriptors] objectAtIndex:0];
|
||||
|
||||
if (aTableColumn === [self _tableColumnForSortDescriptor:mainSortDescriptor])
|
||||
{
|
||||
var image = [mainSortDescriptor ascending] ? [self _tableHeaderSortImage] : [self _tableHeaderReverseSortImage];
|
||||
[self setIndicatorImage:image inTableColumn:aTableColumn];
|
||||
}
|
||||
}
|
||||
|
||||
[self tile];
|
||||
[self setNeedsLayout];
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user