kam_remake icon indicating copy to clipboard operation
kam_remake copied to clipboard

fix compilation with FPC + Lazarus of campaigns sorting algorithm

Open dpronin opened this issue 1 year ago • 5 comments

FPC and Lazarus on Linux do not have List<T>.List[] property, but List<T> fortunately has Sort() method at Linux platform with a comparator to give from a call site

Please, consider these changes to merge them in. The previous business logic of Windows's implementation has been preserved

dpronin avatar Jan 08 '24 02:01 dpronin

I think these changes are easy to verify. We need to get list of current campaigns in the game and see that they are sorted according to the rules. Then we could create a dummy campaign, if it is possible, with the smallest efforts undertaken and name them with TSK, TPR and different other names and see that they are again sorted. Or, if it is possible and there is a list of such campaigns in resources, we might create dummy files and see that their names are sorted according to the rules

dpronin avatar Jan 08 '24 22:01 dpronin

Yes, this or similar test should be done. Could you do such a test please ? I would be able to do it, but some time later.

reyandme avatar Jan 08 '24 22:01 reyandme

Actually, I don't have Windows, neither installed nor an installer to install

dpronin avatar Jan 08 '24 23:01 dpronin

as in the other MR, I could test those changes eventually it seems like a low risk change

sado1 avatar Jan 09 '24 07:01 sado1

as in the other MR, I could test those changes eventually it seems like a low risk change

I would appreciate if you did

dpronin avatar Jan 09 '24 08:01 dpronin