mirror of
https://github.com/d47081/qBittorrent.git
synced 2025-01-23 04:54:18 +00:00
Real time sorting of progress column was broken by ealier patch -> Fixed
This commit is contained in:
parent
faaa700270
commit
1910ee20dd
38
src/GUI.cpp
38
src/GUI.cpp
@ -657,20 +657,20 @@ void GUI::sortDownloadList(int index, Qt::SortOrder startSortOrder, bool fromLoa
|
|||||||
sortOrder = Qt::AscendingOrder;
|
sortOrder = Qt::AscendingOrder;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
QString sortOrderLetter;
|
QString sortOrderLetter;
|
||||||
if(sortOrder == Qt::AscendingOrder)
|
if(sortOrder == Qt::AscendingOrder)
|
||||||
sortOrderLetter = "a";
|
sortOrderLetter = "a";
|
||||||
else
|
else
|
||||||
sortOrderLetter = "d";
|
sortOrderLetter = "d";
|
||||||
if(fromLoadColWidth) {
|
if(fromLoadColWidth) {
|
||||||
// XXX: Why is this needed?
|
// XXX: Why is this needed?
|
||||||
if(sortOrder == Qt::DescendingOrder)
|
if(sortOrder == Qt::DescendingOrder)
|
||||||
downloadList->header()->setSortIndicator(index, Qt::AscendingOrder);
|
downloadList->header()->setSortIndicator(index, Qt::AscendingOrder);
|
||||||
else
|
else
|
||||||
downloadList->header()->setSortIndicator(index, Qt::DescendingOrder);
|
downloadList->header()->setSortIndicator(index, Qt::DescendingOrder);
|
||||||
} else {
|
} else {
|
||||||
downloadList->header()->setSortIndicator(index, sortOrder);
|
downloadList->header()->setSortIndicator(index, sortOrder);
|
||||||
}
|
}
|
||||||
switch(index){
|
switch(index){
|
||||||
case SIZE:
|
case SIZE:
|
||||||
case ETA:
|
case ETA:
|
||||||
@ -679,9 +679,13 @@ void GUI::sortDownloadList(int index, Qt::SortOrder startSortOrder, bool fromLoa
|
|||||||
sortDownloadListFloat(index, sortOrder);
|
sortDownloadListFloat(index, sortOrder);
|
||||||
break;
|
break;
|
||||||
case PROGRESS:
|
case PROGRESS:
|
||||||
// Progress sorting must be delayed until files are checked
|
if(fromLoadColWidth){
|
||||||
delayedSorting = true;
|
// Progress sorting must be delayed until files are checked (on startup)
|
||||||
delayedSortingOrder = sortOrder;
|
delayedSorting = true;
|
||||||
|
delayedSortingOrder = sortOrder;
|
||||||
|
}else{
|
||||||
|
sortDownloadListFloat(index, sortOrder);
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
sortDownloadListString(index, sortOrder);
|
sortDownloadListString(index, sortOrder);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user