mirror of
https://github.com/ppy/osu.git
synced 2024-11-11 11:20:04 +08:00
Set chat text box message length limit based on channel
This commit is contained in:
parent
2af8c7bc24
commit
6453ab6049
@ -156,7 +156,11 @@ namespace osu.Game.Overlays.Chat
|
|||||||
chatTextBox.Current.UnbindFrom(change.OldValue.TextBoxMessage);
|
chatTextBox.Current.UnbindFrom(change.OldValue.TextBoxMessage);
|
||||||
|
|
||||||
if (newChannel != null)
|
if (newChannel != null)
|
||||||
|
{
|
||||||
|
// change length limit first before binding to avoid accidentally truncating pending message from new channel.
|
||||||
|
chatTextBox.LengthLimit = newChannel.MessageLengthLimit;
|
||||||
chatTextBox.Current.BindTo(newChannel.TextBoxMessage);
|
chatTextBox.Current.BindTo(newChannel.TextBoxMessage);
|
||||||
|
}
|
||||||
}, true);
|
}, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user