Page MenuHomeWildfire Games

Sorting arrows shows wrong direction
ClosedPublic

Authored by ffffffff on Aug 14 2017, 12:29 AM.

Details

Summary

in lobby, replaymenu, load games:

ascending arrow peak shall shows to the top, cause small values are first bigger are least
descendin arrow peak shall shows to the bottom, cause small values are least bigger are first

f. e. name sort a is low z is high: ascending sort -> arrow peak shows up cause little is top big is bottom right?

also for numbers. ascending sort f.e. rate: 1200 is little 1400 is high so arrow peak shows top cause arrow peak shows where small is

so we need to change direction

Test Plan

test

Diff Detail

Repository
rP 0 A.D. Public Repository
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

ffffffff created this revision.Aug 14 2017, 12:29 AM
ffffffff retitled this revision from Sorting arrows wrong direction (lobby, replaymenu, load games) to Sorting arrows shows wrong direction.
ffffffff edited the summary of this revision. (Show Details)
vladislavbelov requested changes to this revision.Aug 14 2017, 8:24 AM
vladislavbelov added a subscriber: vladislavbelov.

Good point. But as you noticed, you need change many line of code to change the same style. I suggest to add a style and called it ModernSortedList, or something like that.

This revision now requires changes to proceed.Aug 14 2017, 8:24 AM
ffffffff updated this revision to Diff 3128.Aug 14 2017, 8:37 PM
ffffffff edited edge metadata.
vladislavbelov accepted this revision.Aug 14 2017, 8:59 PM

I've tested it, it works on Windows 8.1. The new style allows to not repeat unnecessary styles.

This revision is now accepted and ready to land.Aug 14 2017, 8:59 PM
elexis accepted this revision.Aug 20 2017, 2:20 PM

Actually I couldn't figure out whether the arrows should point from A to Z or from Z to A. I found examples for both on a web image search.

Currently, the arrows in the playername column of the lobby point from A to Z.
The arrows in the rating column point from small numbers to great numbers.

If the arrows should point in the direction of increments, then it would have to be A > Z for ascending order.
If the arrows are seen as a comparison operation, then it should be A < Z for ascending order.

In fact I've even seen both a small arrow and an actual arrow pointing in the opposite direction on the same tab:

But considering that the windows and nautilus file manager use the proposed sorting, I accept this.

Patch complete, we only have these three sorted lists. (Because the mod selection one still isnt sorted).

binaries/data/mods/mod/gui/common/modern/styles.xml
72 ↗(On Diff #3128)

No spaces around the equal character.

binaries/data/mods/public/gui/savedgames/load.xml
29 ↗(On Diff #3128)

In we don't use alphabetical sorting but some kind of priority based sorting:
name, type, style, size usually come first.

This revision was automatically updated to reflect the committed changes.