mirror of
https://github.com/ppy/osu.git
synced 2025-01-26 20:23:00 +08:00
Change LoginPanel
to use LocalUser.Status
for the dropdown
This commit is contained in:
parent
b86c883a5d
commit
e3989c854d
@ -139,7 +139,7 @@ namespace osu.Game.Overlays.Login
|
||||
},
|
||||
};
|
||||
|
||||
panel.Status.BindValueChanged(_ => updateDropdownCurrent(), true);
|
||||
api.LocalUser.Value.Status.BindValueChanged(e => updateDropdownCurrent(e.NewValue), true);
|
||||
|
||||
dropdown.Current.BindValueChanged(action =>
|
||||
{
|
||||
@ -172,9 +172,9 @@ namespace osu.Game.Overlays.Login
|
||||
ScheduleAfterChildren(() => GetContainingInputManager()?.ChangeFocus(form));
|
||||
});
|
||||
|
||||
private void updateDropdownCurrent()
|
||||
private void updateDropdownCurrent(UserStatus? status)
|
||||
{
|
||||
switch (panel.Status.Value)
|
||||
switch (status)
|
||||
{
|
||||
case UserStatus.Online:
|
||||
dropdown.Current.Value = UserAction.Online;
|
||||
|
Loading…
Reference in New Issue
Block a user