josm
josm copied to clipboard
Add support for alternative tagging of the presets.
Would it be better if we create two separate List for storing PresetLink objects with alternative="true" and the ones that don't have an alternative tag like presets under the "Edit also" section?
The current implementation depends on the order in which preset_link is defined in the XML file. It does not work if the preset_link with the alternative attribute is defined before the non-alternative ones or between them.
@tsmock
It would probably be preferable to have two separate lists. We could sort based off of the alternative tag, but then we start getting into changing the order of the alternatives. This is probably undesirable, if the preset author put the preferred alternative first.
I added lists to store the PresetLink objects. Is there a need to sort the tags in the list?
In a follow up to @tsmock comment: from a functional pov an "alternative preset" is different than a "linked preset". The later offers additional tags that might be added, the former replaces the current tagging with an alternative.
tl;dr the alternative preset links need a separate heading/label that makes the above clear (the "Edit also..." is very confusing here).