mirror of
https://github.com/ppy/osu.git
synced 2025-01-15 16:03:01 +08:00
Make current value behaviour between channels and tabs consistent.
- Trim whitespace
This commit is contained in:
parent
4f7ae1ed8b
commit
7ad4c046db
@ -57,6 +57,9 @@ namespace osu.Game.Overlays.Chat
|
|||||||
TabContainer.ChangeChildDepth(selectorTab, float.MaxValue);
|
TabContainer.ChangeChildDepth(selectorTab, float.MaxValue);
|
||||||
|
|
||||||
base.AddTabItem(item, addToDropdown);
|
base.AddTabItem(item, addToDropdown);
|
||||||
|
|
||||||
|
if (SelectedTab == null)
|
||||||
|
SelectTab(item);
|
||||||
}
|
}
|
||||||
|
|
||||||
protected override TabItem<Channel> CreateTabItem(Channel value)
|
protected override TabItem<Channel> CreateTabItem(Channel value)
|
||||||
@ -149,7 +152,7 @@ namespace osu.Game.Overlays.Chat
|
|||||||
protected override bool OnHover(InputState state)
|
protected override bool OnHover(InputState state)
|
||||||
{
|
{
|
||||||
closeButton?.FadeIn(1f, Easing.InBounce);
|
closeButton?.FadeIn(1f, Easing.InBounce);
|
||||||
|
|
||||||
if (!Active)
|
if (!Active)
|
||||||
box.FadeColour(backgroundHover, transition_length, Easing.OutQuint);
|
box.FadeColour(backgroundHover, transition_length, Easing.OutQuint);
|
||||||
return true;
|
return true;
|
||||||
|
@ -398,7 +398,10 @@ namespace osu.Game.Overlays
|
|||||||
if (channel == null) return;
|
if (channel == null) return;
|
||||||
|
|
||||||
if (channel == CurrentChannel)
|
if (channel == CurrentChannel)
|
||||||
|
{
|
||||||
|
currentChannel = null;
|
||||||
currentChannelContainer.Clear(false);
|
currentChannelContainer.Clear(false);
|
||||||
|
}
|
||||||
|
|
||||||
careChannels.Remove(channel);
|
careChannels.Remove(channel);
|
||||||
loadedChannels.Remove(loadedChannels.Find(c => c.Channel == channel));
|
loadedChannels.Remove(loadedChannels.Find(c => c.Channel == channel));
|
||||||
|
Loading…
Reference in New Issue
Block a user