Index: trunk/phase3/skins/common/wikibits.js |
— | — | @@ -637,13 +637,16 @@ |
638 | 638 | var reverse = (span.getAttribute("sortdir") == 'down'); |
639 | 639 | |
640 | 640 | var newRows = new Array(); |
| 641 | + var staticRows = new Array(); |
641 | 642 | for (var j = rowStart; j < table.rows.length; j++) { |
642 | 643 | var row = table.rows[j]; |
643 | | - var keyText = ts_getInnerText(row.cells[column]); |
644 | | - var oldIndex = (reverse ? -j : j); |
645 | | - var preprocessed = preprocessor( keyText ); |
| 644 | + if((" "+row.className+" ").indexOf(" unsortable ") < 0) { |
| 645 | + var keyText = ts_getInnerText(row.cells[column]); |
| 646 | + var oldIndex = (reverse ? -j : j); |
| 647 | + var preprocessed = preprocessor( keyText ); |
646 | 648 | |
647 | | - newRows[newRows.length] = new Array(row, preprocessed, oldIndex); |
| 649 | + newRows[newRows.length] = new Array(row, preprocessed, oldIndex); |
| 650 | + } else staticRows[staticRows.length] = new Array(row, false, j-rowStart); |
648 | 651 | } |
649 | 652 | |
650 | 653 | newRows.sort(sortfn); |
— | — | @@ -658,6 +661,11 @@ |
659 | 662 | span.setAttribute('sortdir','down'); |
660 | 663 | } |
661 | 664 | |
| 665 | + for(var i in staticRows) { |
| 666 | + var row = staticRows[i]; |
| 667 | + newRows.splice(row[2], 0, row); |
| 668 | + } |
| 669 | + |
662 | 670 | // We appendChild rows that already exist to the tbody, so it moves them rather than creating new ones |
663 | 671 | // don't do sortbottom rows |
664 | 672 | for (var i = 0; i < newRows.length; i++) { |
Index: trunk/phase3/CREDITS |
— | — | @@ -74,6 +74,7 @@ |
75 | 75 | * Olaf Lenz |
76 | 76 | * Paul Copperman |
77 | 77 | * RememberTheDot |
| 78 | +* René Kijewski |
78 | 79 | * ST47 |
79 | 80 | |
80 | 81 | == Translators == |
Index: trunk/phase3/includes/DefaultSettings.php |
— | — | @@ -1444,7 +1444,7 @@ |
1445 | 1445 | * to ensure that client-side caches don't keep obsolete copies of global |
1446 | 1446 | * styles. |
1447 | 1447 | */ |
1448 | | -$wgStyleVersion = '192'; |
| 1448 | +$wgStyleVersion = '193'; |
1449 | 1449 | |
1450 | 1450 | |
1451 | 1451 | # Server-side caching: |
Index: trunk/phase3/RELEASE-NOTES |
— | — | @@ -250,6 +250,8 @@ |
251 | 251 | * Special:Log: Add 'change protection' link for unprotected pages too |
252 | 252 | * Special:Log: Add log type specific CSS classes 'mw-logline-$logtype' to |
253 | 253 | 'li' elements |
| 254 | +* (bug 16754) Making arbitrary rows of sortable tables sticky: |
| 255 | + |- class="unsortable" |
254 | 256 | |
255 | 257 | === Bug fixes in 1.14 === |
256 | 258 | |