mirror of
https://github.com/ppy/osu.git
synced 2025-03-15 22:27:46 +08:00
Refactorings
This commit is contained in:
parent
d57508853e
commit
155e9e16a5
@ -23,10 +23,22 @@ namespace osu.Game.Screens.OnlinePlay
|
||||
/// </summary>
|
||||
IBindableList<Room> Rooms { get; }
|
||||
|
||||
/// <summary>
|
||||
/// Adds a <see cref="Room"/> to this <see cref="IRoomManager"/>.
|
||||
/// If already existing, the local room will be updated with the given one.
|
||||
/// </summary>
|
||||
/// <param name="room">The incoming <see cref="Room"/>.</param>
|
||||
void AddOrUpdateRoom(Room room);
|
||||
|
||||
/// <summary>
|
||||
/// Removes a <see cref="Room"/> from this <see cref="IRoomManager"/>.
|
||||
/// </summary>
|
||||
/// <param name="room">The <see cref="Room"/> to remove.</param>
|
||||
void RemoveRoom(Room room);
|
||||
|
||||
/// <summary>
|
||||
/// Removes all <see cref="Room"/>s from this <see cref="IRoomManager"/>.
|
||||
/// </summary>
|
||||
void ClearRooms();
|
||||
|
||||
/// <summary>
|
||||
|
@ -43,7 +43,7 @@ namespace osu.Game.Screens.OnlinePlay.Multiplayer
|
||||
base.OnResuming(last);
|
||||
|
||||
// Upon having left a room, we don't know whether we were the only participant, and whether the room is now closed as a result of leaving it.
|
||||
// To work around this, temporarily clear all rooms until the next listing poll.
|
||||
// To work around this, temporarily remove the room and trigger an immediate listing poll.
|
||||
if (last is MultiplayerMatchSubScreen match)
|
||||
{
|
||||
RoomManager.RemoveRoom(match.Room);
|
||||
|
Loading…
x
Reference in New Issue
Block a user