mirror of
https://github.com/osukey/osukey.git
synced 2025-08-04 23:24:04 +09:00
Allow footer buttons to be customised
This commit is contained in:
@ -263,9 +263,8 @@ namespace osu.Game.Screens.Select
|
|||||||
|
|
||||||
if (Footer != null)
|
if (Footer != null)
|
||||||
{
|
{
|
||||||
Footer.AddButton(new FooterButtonMods { Current = Mods }, ModSelect);
|
foreach (var (button, overlay) in CreateFooterButtons())
|
||||||
Footer.AddButton(new FooterButtonRandom { Action = triggerRandom });
|
Footer.AddButton(button, overlay);
|
||||||
Footer.AddButton(new FooterButtonOptions(), BeatmapOptions);
|
|
||||||
|
|
||||||
BeatmapOptions.AddButton(@"Manage", @"collections", FontAwesome.Solid.Book, colours.Green, () => manageCollectionsDialog?.Show());
|
BeatmapOptions.AddButton(@"Manage", @"collections", FontAwesome.Solid.Book, colours.Green, () => manageCollectionsDialog?.Show());
|
||||||
BeatmapOptions.AddButton(@"Delete", @"all difficulties", FontAwesome.Solid.Trash, colours.Pink, () => delete(Beatmap.Value.BeatmapSetInfo));
|
BeatmapOptions.AddButton(@"Delete", @"all difficulties", FontAwesome.Solid.Trash, colours.Pink, () => delete(Beatmap.Value.BeatmapSetInfo));
|
||||||
@ -301,6 +300,13 @@ namespace osu.Game.Screens.Select
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
protected virtual IEnumerable<(FooterButton, OverlayContainer)> CreateFooterButtons() => new (FooterButton, OverlayContainer)[]
|
||||||
|
{
|
||||||
|
(new FooterButtonMods { Current = Mods }, ModSelect),
|
||||||
|
(new FooterButtonRandom { Action = triggerRandom }, null),
|
||||||
|
(new FooterButtonOptions(), BeatmapOptions)
|
||||||
|
};
|
||||||
|
|
||||||
protected virtual ModSelectOverlay CreateModSelectOverlay() => new SoloModSelectOverlay();
|
protected virtual ModSelectOverlay CreateModSelectOverlay() => new SoloModSelectOverlay();
|
||||||
|
|
||||||
protected virtual void ApplyFilterToCarousel(FilterCriteria criteria)
|
protected virtual void ApplyFilterToCarousel(FilterCriteria criteria)
|
||||||
|
Reference in New Issue
Block a user