General refactorings

This commit is contained in:
smoogipoo
2020-09-07 21:08:48 +09:00
parent c1d255a04c
commit 98e9c4dc25
10 changed files with 95 additions and 40 deletions

View File

@ -39,7 +39,7 @@ namespace osu.Game.Screens.Select.Carousel
private BeatmapCollectionManager collectionManager { get; set; }
[Resolved(CanBeNull = true)]
private ManageCollectionDialog manageCollectionDialog { get; set; }
private ManageCollectionsDialog manageCollectionsDialog { get; set; }
private readonly BeatmapSetInfo beatmapSet;
@ -148,9 +148,9 @@ namespace osu.Game.Screens.Select.Carousel
if (dialogOverlay != null)
items.Add(new OsuMenuItem("Delete", MenuItemType.Destructive, () => dialogOverlay.Push(new BeatmapDeleteDialog(beatmapSet))));
var collectionItems = collectionManager.Collections.OrderByDescending(c => c.LastModifyTime).Take(3).Select(createCollectionMenuItem).ToList();
if (manageCollectionDialog != null)
collectionItems.Add(new OsuMenuItem("More...", MenuItemType.Standard, manageCollectionDialog.Show));
var collectionItems = collectionManager.Collections.OrderByDescending(c => c.LastModifyDate).Take(3).Select(createCollectionMenuItem).ToList();
if (manageCollectionsDialog != null)
collectionItems.Add(new OsuMenuItem("More...", MenuItemType.Standard, manageCollectionsDialog.Show));
items.Add(new OsuMenuItem("Add all to...") { Items = collectionItems });