mirror of
https://github.com/ppy/osu.git
synced 2024-12-15 16:25:32 +08:00
Convert if to switch
This commit is contained in:
parent
96bacaf13f
commit
762b4412e5
@ -247,16 +247,16 @@ namespace osu.Game.Overlays
|
||||
|
||||
textbox.Current.Disabled = chat.ReadOnly;
|
||||
|
||||
if (chat is ChannelChat channelChat)
|
||||
switch (chat)
|
||||
{
|
||||
case ChannelChat channelChat:
|
||||
channelTabs.Current.Value = channelChat;
|
||||
userTabs.DeselectAll();
|
||||
}
|
||||
|
||||
if (chat is UserChat userChat)
|
||||
{
|
||||
break;
|
||||
case UserChat userChat:
|
||||
userTabs.Current.Value = userChat;
|
||||
channelTabs.DeselectAll();
|
||||
break;
|
||||
}
|
||||
|
||||
var loaded = loadedChannels.Find(d => d.Chat == chat);
|
||||
|
Loading…
Reference in New Issue
Block a user