Jump to content

sortSecondary problem (for the developers, mainly)


squeegee

Recommended Posts

Posted

When you are sorting on a column and two or more values are the same, the function sortSecondary is used. Unfortunately, this function appears to return different values every time it runs, because the "sorted" list will change order on every GUI update for those rows for which the sorted column values are equal. Now, if there are only 2 or 3 rows where this occurs, it's only mildly annoying. But if you're running lots of torrents, and there are lots of rows for which the sorted column values are equal, especially when you can't see all the rows, it then becomes majorly annoying.

For myself, I just used this simple fix (which only works if you leave the name of the torrent in the first column):

In stable.js:

change two instances of this.secIndex to 0

so that it always does a secondary sort on the first column (name of torrent, if you don't drag it to a different column)

dxSTable.prototype.sortSecondary=function(x,y){var m=this.getValue(x.e,this.secIndex);var n=this.getValue(y.e,this.secIndex);

to

dxSTable.prototype.sortSecondary=function(x,y){var m=this.getValue(x.e,0);var n=this.getValue(y.e,0);

Posted

Heh, I actually bugged Directrix about this a long time ago, but was too lazy to try and figure out a fix for it myself. I haven't tested your change, but if it works... good job! ;D

Posted

webui.zip has always been separate, and it'll most likely remain as such. If Directrix updates anything and releases it to the public, he'll announce it on #utorrent-webui and/or the forums. Until then, patience is key :)

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...