Fixed sorting by Id
Sorting by id incorrectly sorted the music order page by alphabetical order instead of numerical order.
This commit is contained in:
parent
bd7ffd3371
commit
718ccd4774
@ -10,6 +10,7 @@ using System.Drawing;
|
||||
using System.Linq;
|
||||
using System;
|
||||
using TaikoSoundEditor.Collections;
|
||||
using System.Text.RegularExpressions;
|
||||
|
||||
namespace TaikoSoundEditor.Commons.Controls
|
||||
{
|
||||
@ -39,7 +40,7 @@ namespace TaikoSoundEditor.Commons.Controls
|
||||
else if (Config.MusicOrderSort == Config.MusicOrderSortValueId)
|
||||
{
|
||||
SongCards.Add(songCard);
|
||||
SongCards.Sort((c1, c2) => c1.Id.CompareTo(c2.Id));
|
||||
SongCards.Sort((c1, c2) => c1.MusicOrder.UniqueId.CompareTo(c2.MusicOrder.UniqueId));
|
||||
}
|
||||
else if (Config.MusicOrderSort == Config.MusicOrderSortValueGenre)
|
||||
{
|
||||
|
@ -11,7 +11,7 @@ namespace TaikoSoundEditor.Commons.Controls
|
||||
internal WordList WordList { get; }
|
||||
public IMusicOrder MusicOrder { get; }
|
||||
|
||||
public string Id => $"{MusicOrder.UniqueId}.{MusicOrder.Id}";
|
||||
public string Id => $"{MusicOrder.UniqueId}. {MusicOrder.Id}";
|
||||
public string Title => WordList.GetBySong(MusicOrder.Id).JapaneseText;
|
||||
public string Subtitle => WordList.GetBySongSub(MusicOrder.Id).JapaneseText;
|
||||
public string Genre => MusicOrder.Genre.ToString();
|
||||
|
Loading…
Reference in New Issue
Block a user