mirror of
https://github.com/eclipse-sailing-analytics/sailing-analytics.git
synced 2026-10-08 13:20:57 +00:00
Merge branch 'raceboardmodes'
This commit is contained in:
commit
6a807cff29
1 file changed
+14
-9
Executable → Regular
+14
-9
@@ -166,16 +166,21 @@ public abstract class ExpandableSortableColumn<C> extends LeaderboardSortableCol
|
||||
setExpanded(!isExpanded());
|
||||
ensureExpansionDataIsLoaded(new Runnable() {
|
||||
public void run() {
|
||||
int insertIndex = table.getColumnIndex(ExpandableSortableColumn.this);
|
||||
// The check "insertIndex != -1" is necessary, because the child-columns might be deleted asynchronously
|
||||
// while toggling the columns.
|
||||
if (insertIndex != -1) {
|
||||
insertIndex++;
|
||||
for (AbstractSortableColumnWithMinMax<LeaderboardRowDTO, ?> column : getAllVisibleChildren()) {
|
||||
column.updateMinMax();
|
||||
getLeaderboardPanel().insertColumn(insertIndex++, column);
|
||||
// column may have been collapsed meanwhile, so that the columns must not be added to the table right now
|
||||
if (isExpanded()) {
|
||||
int insertIndex = table.getColumnIndex(ExpandableSortableColumn.this);
|
||||
// The check "insertIndex != -1" is necessary, because the child-columns might be deleted
|
||||
// asynchronously while toggling the columns.
|
||||
if (insertIndex != -1) {
|
||||
insertIndex++;
|
||||
for (AbstractSortableColumnWithMinMax<LeaderboardRowDTO, ?> column : getAllVisibleChildren()) {
|
||||
column.updateMinMax();
|
||||
if (table.getColumnIndex(column) < 0) {
|
||||
getLeaderboardPanel().insertColumn(insertIndex++, column);
|
||||
}
|
||||
}
|
||||
getLeaderboardPanel().getLeaderboardTable().redraw();
|
||||
}
|
||||
getLeaderboardPanel().getLeaderboardTable().redraw();
|
||||
}
|
||||
getLeaderboardPanel().setBusyState(oldBusyState);
|
||||
setTogglingInProcess(false);
|
||||
|
||||
Reference in new issue
Block a user