mirror of
https://github.com/ppy/osu.git
synced 2025-01-29 01:22:54 +08:00
Merge pull request #4081 from peppy/fix-room-inspector-cover
Fix room inspector cover not resetting when no room selected
This commit is contained in:
commit
b58a61b277
@ -93,10 +93,14 @@ namespace osu.Game.Screens.Multi.Lounge.Components
|
||||
Host.BindValueChanged(v =>
|
||||
{
|
||||
hostText.Clear();
|
||||
flagContainer.Clear();
|
||||
|
||||
if (v != null)
|
||||
{
|
||||
hostText.AddText("hosted by ");
|
||||
hostText.AddLink(v.Username, null, LinkAction.OpenUserProfile, v.Id.ToString(), "Open profile", s => s.Font = "Exo2.0-BoldItalic");
|
||||
|
||||
flagContainer.Child = new DrawableFlag(v.Country) { RelativeSizeAxes = Axes.Both };
|
||||
}
|
||||
});
|
||||
|
||||
ParticipantCount.BindValueChanged(v => summary.Text = $"{v:#,0}{" participant".Pluralize(v == 1)}");
|
||||
|
@ -53,10 +53,8 @@ namespace osu.Game.Screens.Multi
|
||||
Duration.UnbindFrom(room.Duration);
|
||||
}
|
||||
|
||||
room = value;
|
||||
room = value ?? new Room();
|
||||
|
||||
if (room != null)
|
||||
{
|
||||
RoomID.BindTo(room.RoomID);
|
||||
Name.BindTo(room.Name);
|
||||
Host.BindTo(room.Host);
|
||||
@ -71,7 +69,6 @@ namespace osu.Game.Screens.Multi
|
||||
Duration.BindTo(room.Duration);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void updatePlaylist()
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user