From 23a446bab2b34d0b56e7f55db0d8aa94c374e30b Mon Sep 17 00:00:00 2001 From: Dean Herbert Date: Tue, 20 Nov 2018 15:03:55 +0900 Subject: [PATCH] Add support for all channel types --- osu.Game/Online/Chat/ChannelType.cs | 6 +++++- osu.Game/Overlays/Chat/Tabs/ChannelTabControl.cs | 4 +--- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/osu.Game/Online/Chat/ChannelType.cs b/osu.Game/Online/Chat/ChannelType.cs index 4ac0a99fc6..8439638c46 100644 --- a/osu.Game/Online/Chat/ChannelType.cs +++ b/osu.Game/Online/Chat/ChannelType.cs @@ -5,7 +5,11 @@ namespace osu.Game.Online.Chat { public enum ChannelType { + Public, + Multiplayer, + Spectator, + Temporary, PM, - Public + Group, } } diff --git a/osu.Game/Overlays/Chat/Tabs/ChannelTabControl.cs b/osu.Game/Overlays/Chat/Tabs/ChannelTabControl.cs index 08d4e40a64..ec4c66e36f 100644 --- a/osu.Game/Overlays/Chat/Tabs/ChannelTabControl.cs +++ b/osu.Game/Overlays/Chat/Tabs/ChannelTabControl.cs @@ -56,12 +56,10 @@ protected override TabItem CreateTabItem(Channel value) { switch (value.Type) { - case ChannelType.Public: + default: return new ChannelTabItem(value) { OnRequestClose = tabCloseRequested }; case ChannelType.PM: return new PrivateChannelTabItem(value) { OnRequestClose = tabCloseRequested }; - default: - throw new InvalidOperationException("Only TargetType User and Channel are supported."); } }