mirror of
https://github.com/ppy/osu.git
synced 2025-02-06 23:12:54 +08:00
Fix null inspections on GameplayChatDisplay
This commit is contained in:
parent
09fc30e377
commit
47d81e7dee
@ -19,6 +19,8 @@ namespace osu.Game.Screens.OnlinePlay.Multiplayer
|
|||||||
[Resolved(CanBeNull = true)]
|
[Resolved(CanBeNull = true)]
|
||||||
private ILocalUserPlayInfo? localUserInfo { get; set; }
|
private ILocalUserPlayInfo? localUserInfo { get; set; }
|
||||||
|
|
||||||
|
protected new ChatTextBox TextBox => base.TextBox!;
|
||||||
|
|
||||||
private readonly IBindable<LocalUserPlayingState> localUserPlaying = new Bindable<LocalUserPlayingState>();
|
private readonly IBindable<LocalUserPlayingState> localUserPlaying = new Bindable<LocalUserPlayingState>();
|
||||||
|
|
||||||
public override bool PropagatePositionalInputSubTree => localUserPlaying.Value != LocalUserPlayingState.Playing;
|
public override bool PropagatePositionalInputSubTree => localUserPlaying.Value != LocalUserPlayingState.Playing;
|
||||||
@ -58,7 +60,7 @@ namespace osu.Game.Screens.OnlinePlay.Multiplayer
|
|||||||
|
|
||||||
localUserPlaying.BindValueChanged(playing =>
|
localUserPlaying.BindValueChanged(playing =>
|
||||||
{
|
{
|
||||||
// for now let's never hold focus. this avoid misdirected gameplay keys entering chat.
|
// for now let's never hold focus. this avoids misdirected gameplay keys entering chat.
|
||||||
// note that this is done within this callback as it triggers an un-focus as well.
|
// note that this is done within this callback as it triggers an un-focus as well.
|
||||||
TextBox.HoldFocus = false;
|
TextBox.HoldFocus = false;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user