mirror of
https://github.com/ppy/osu.git
synced 2025-02-21 00:12:59 +08:00
Add visual states for ChannelSelectorTabItem
This commit is contained in:
parent
1fa70167c2
commit
d81ff9cbc2
@ -211,6 +211,7 @@ namespace osu.Game.Overlays.Chat
|
||||
set
|
||||
{
|
||||
activeBindable.Value = !activeBindable.Value;
|
||||
selectorUpdateState();
|
||||
base.Active = false;
|
||||
}
|
||||
}
|
||||
@ -235,6 +236,26 @@ namespace osu.Game.Overlays.Chat
|
||||
backgroundInactive = colour.Gray2;
|
||||
backgroundActive = colour.Gray3;
|
||||
}
|
||||
|
||||
protected override void LoadComplete()
|
||||
{
|
||||
base.LoadComplete();
|
||||
|
||||
selectorUpdateState();
|
||||
}
|
||||
|
||||
protected override void OnHoverLost(InputState state)
|
||||
{
|
||||
selectorUpdateState();
|
||||
}
|
||||
|
||||
private void selectorUpdateState()
|
||||
{
|
||||
if (activeBindable.Value)
|
||||
fadeActive();
|
||||
else
|
||||
fadeInactive();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user