Update further ChangeFocus usages

This commit is contained in:
Salman Ahmed 2022-02-15 02:42:37 +03:00
parent 4bd58cfde1
commit f5d0eb41cb
3 changed files with 4 additions and 3 deletions

View File

@ -183,7 +183,8 @@ namespace osu.Game.Overlays.Login
break; break;
} }
if (form != null) GetContainingInputManager()?.ChangeFocus(form); if (form != null)
ScheduleAfterChildren(() => GetContainingInputManager()?.ChangeFocus(form));
}); });
public override bool AcceptsFocus => true; public override bool AcceptsFocus => true;

View File

@ -78,7 +78,7 @@ namespace osu.Game.Overlays
panel.Bounding = true; panel.Bounding = true;
this.FadeIn(transition_time, Easing.OutQuint); this.FadeIn(transition_time, Easing.OutQuint);
GetContainingInputManager().ChangeFocus(panel); ScheduleAfterChildren(() => GetContainingInputManager().ChangeFocus(panel));
} }
protected override void PopOut() protected override void PopOut()

View File

@ -71,7 +71,7 @@ namespace osu.Game.Screens.Edit.Setup
base.LoadComplete(); base.LoadComplete();
if (string.IsNullOrEmpty(ArtistTextBox.Current.Value)) if (string.IsNullOrEmpty(ArtistTextBox.Current.Value))
GetContainingInputManager().ChangeFocus(ArtistTextBox); ScheduleAfterChildren(() => GetContainingInputManager().ChangeFocus(ArtistTextBox));
ArtistTextBox.Current.BindValueChanged(artist => transferIfRomanised(artist.NewValue, RomanisedArtistTextBox)); ArtistTextBox.Current.BindValueChanged(artist => transferIfRomanised(artist.NewValue, RomanisedArtistTextBox));
TitleTextBox.Current.BindValueChanged(title => transferIfRomanised(title.NewValue, RomanisedTitleTextBox)); TitleTextBox.Current.BindValueChanged(title => transferIfRomanised(title.NewValue, RomanisedTitleTextBox));