mirror of
https://github.com/ppy/osu.git
synced 2025-01-27 11:12:59 +08:00
Fix lint errors
This commit is contained in:
parent
a575566638
commit
e4cccb5e31
@ -19,7 +19,7 @@ namespace osu.Game.Tests.Visual.Ranking
|
|||||||
public partial class TestSceneCollectionButton : OsuManualInputManagerTestScene
|
public partial class TestSceneCollectionButton : OsuManualInputManagerTestScene
|
||||||
{
|
{
|
||||||
private CollectionButton collectionButton;
|
private CollectionButton collectionButton;
|
||||||
private BeatmapInfo beatmapInfo = new BeatmapInfo { OnlineID = 88 };
|
private readonly BeatmapInfo beatmapInfo = new BeatmapInfo { OnlineID = 88 };
|
||||||
|
|
||||||
[SetUpSteps]
|
[SetUpSteps]
|
||||||
public void SetUpSteps()
|
public void SetUpSteps()
|
||||||
|
@ -24,7 +24,6 @@ namespace osu.Game.Tests.Visual.Ranking
|
|||||||
|
|
||||||
private DummyAPIAccess dummyAPI => (DummyAPIAccess)API;
|
private DummyAPIAccess dummyAPI => (DummyAPIAccess)API;
|
||||||
|
|
||||||
|
|
||||||
[SetUpSteps]
|
[SetUpSteps]
|
||||||
public void SetUpSteps()
|
public void SetUpSteps()
|
||||||
{
|
{
|
||||||
|
@ -17,15 +17,16 @@ namespace osu.Game.Screens.Ranking
|
|||||||
{
|
{
|
||||||
public partial class CollectionPopover : OsuPopover
|
public partial class CollectionPopover : OsuPopover
|
||||||
{
|
{
|
||||||
private OsuMenu menu;
|
|
||||||
private readonly BeatmapInfo beatmapInfo;
|
private readonly BeatmapInfo beatmapInfo;
|
||||||
|
|
||||||
[Resolved]
|
[Resolved]
|
||||||
private RealmAccess realm { get; set; } = null!;
|
private RealmAccess realm { get; set; } = null!;
|
||||||
[Resolved]
|
|
||||||
private ManageCollectionsDialog? manageCollectionsDialog { get; set; }
|
|
||||||
|
|
||||||
public CollectionPopover(BeatmapInfo beatmapInfo) : base(false)
|
[Resolved]
|
||||||
|
private ManageCollectionsDialog manageCollectionsDialog { get; set; }
|
||||||
|
|
||||||
|
public CollectionPopover(BeatmapInfo beatmapInfo)
|
||||||
|
: base(false)
|
||||||
{
|
{
|
||||||
this.beatmapInfo = beatmapInfo;
|
this.beatmapInfo = beatmapInfo;
|
||||||
}
|
}
|
||||||
@ -38,7 +39,7 @@ namespace osu.Game.Screens.Ranking
|
|||||||
|
|
||||||
Children = new[]
|
Children = new[]
|
||||||
{
|
{
|
||||||
menu = new OsuMenu(Direction.Vertical, true)
|
new OsuMenu(Direction.Vertical, true)
|
||||||
{
|
{
|
||||||
Items = items,
|
Items = items,
|
||||||
},
|
},
|
||||||
@ -56,9 +57,9 @@ namespace osu.Game.Screens.Ranking
|
|||||||
get
|
get
|
||||||
{
|
{
|
||||||
var collectionItems = realm.Realm.All<BeatmapCollection>()
|
var collectionItems = realm.Realm.All<BeatmapCollection>()
|
||||||
.OrderBy(c => c.Name)
|
.OrderBy(c => c.Name)
|
||||||
.AsEnumerable()
|
.AsEnumerable()
|
||||||
.Select(c => new CollectionToggleMenuItem(c.ToLive(realm), beatmapInfo)).Cast<OsuMenuItem>().ToList();
|
.Select(c => new CollectionToggleMenuItem(c.ToLive(realm), beatmapInfo)).Cast<OsuMenuItem>().ToList();
|
||||||
|
|
||||||
if (manageCollectionsDialog != null)
|
if (manageCollectionsDialog != null)
|
||||||
collectionItems.Add(new OsuMenuItem("Manage...", MenuItemType.Standard, manageCollectionsDialog.Show));
|
collectionItems.Add(new OsuMenuItem("Manage...", MenuItemType.Standard, manageCollectionsDialog.Show));
|
||||||
|
@ -79,8 +79,7 @@ namespace osu.Game.Screens.Ranking
|
|||||||
|
|
||||||
private void getBeatmapSet()
|
private void getBeatmapSet()
|
||||||
{
|
{
|
||||||
GetBeatmapSetRequest beatmapSetRequest;
|
GetBeatmapSetRequest beatmapSetRequest = new GetBeatmapSetRequest(BeatmapSetInfo.OnlineID);
|
||||||
beatmapSetRequest = new GetBeatmapSetRequest(BeatmapSetInfo.OnlineID);
|
|
||||||
|
|
||||||
loading.Show();
|
loading.Show();
|
||||||
beatmapSetRequest.Success += beatmapSet =>
|
beatmapSetRequest.Success += beatmapSet =>
|
||||||
@ -103,7 +102,6 @@ namespace osu.Game.Screens.Ranking
|
|||||||
|
|
||||||
private void toggleFavouriteStatus()
|
private void toggleFavouriteStatus()
|
||||||
{
|
{
|
||||||
|
|
||||||
Enabled.Value = false;
|
Enabled.Value = false;
|
||||||
loading.Show();
|
loading.Show();
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user