Handle against playlists which disallow selection

`SelectedItem.Disabled` is also not checked against in the select-via-click flow inside `DrawableRoomPlaylistItem` (only `AllowSelection` is checked).
This commit is contained in:
Salman Ahmed
2022-05-05 05:42:49 +03:00
parent 464b3af5f3
commit f28978b856
2 changed files with 10 additions and 1 deletions

View File

@ -56,6 +56,9 @@ namespace osu.Game.Tests.Visual.Multiplayer
AddStep("click", () => InputManager.Click(MouseButton.Left));
AddAssert("no item selected", () => playlist.SelectedItem.Value == null);
AddStep("press down", () => InputManager.Key(Key.Down));
AddAssert("no item selected", () => playlist.SelectedItem.Value == null);
}
[Test]
@ -73,6 +76,9 @@ namespace osu.Game.Tests.Visual.Multiplayer
AddStep("click", () => InputManager.Click(MouseButton.Left));
AddAssert("no item selected", () => playlist.SelectedItem.Value == null);
AddStep("press down", () => InputManager.Key(Key.Down));
AddAssert("no item selected", () => playlist.SelectedItem.Value == null);
}
[Test]
@ -91,6 +97,9 @@ namespace osu.Game.Tests.Visual.Multiplayer
AddStep("click", () => InputManager.Click(MouseButton.Left));
AddAssert("no item selected", () => playlist.SelectedItem.Value == null);
AddStep("press down", () => InputManager.Key(Key.Down));
AddAssert("no item selected", () => playlist.SelectedItem.Value == null);
}
[Test]