mirror of
https://github.com/osukey/osukey.git
synced 2025-06-22 19:57:56 +09:00
Adjust background colours of textbox in chat display
This commit is contained in:
parent
35b9f84c00
commit
b82f92d7b8
@ -30,6 +30,8 @@ namespace osu.Game.Online.Chat
|
|||||||
|
|
||||||
private readonly bool postingTextbox;
|
private readonly bool postingTextbox;
|
||||||
|
|
||||||
|
protected readonly Box Background;
|
||||||
|
|
||||||
private const float textbox_height = 30;
|
private const float textbox_height = 30;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@ -44,7 +46,7 @@ namespace osu.Game.Online.Chat
|
|||||||
|
|
||||||
InternalChildren = new Drawable[]
|
InternalChildren = new Drawable[]
|
||||||
{
|
{
|
||||||
new Box
|
Background = new Box
|
||||||
{
|
{
|
||||||
Colour = Color4.Black,
|
Colour = Color4.Black,
|
||||||
Alpha = 0.8f,
|
Alpha = 0.8f,
|
||||||
@ -54,7 +56,7 @@ namespace osu.Game.Online.Chat
|
|||||||
|
|
||||||
if (postingTextbox)
|
if (postingTextbox)
|
||||||
{
|
{
|
||||||
AddInternal(Textbox = new FocusedTextBox
|
AddInternal(Textbox = new ChatTextBox
|
||||||
{
|
{
|
||||||
RelativeSizeAxes = Axes.X,
|
RelativeSizeAxes = Axes.X,
|
||||||
Height = textbox_height,
|
Height = textbox_height,
|
||||||
@ -110,6 +112,17 @@ namespace osu.Game.Online.Chat
|
|||||||
AddInternal(drawableChannel);
|
AddInternal(drawableChannel);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public class ChatTextBox : FocusedTextBox
|
||||||
|
{
|
||||||
|
protected override void LoadComplete()
|
||||||
|
{
|
||||||
|
base.LoadComplete();
|
||||||
|
|
||||||
|
BackgroundUnfocused = new Color4(10, 10, 10, 10);
|
||||||
|
BackgroundFocused = new Color4(10, 10, 10, 255);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
public class StandAloneDrawableChannel : DrawableChannel
|
public class StandAloneDrawableChannel : DrawableChannel
|
||||||
{
|
{
|
||||||
public Func<Message, ChatLine> CreateChatLineAction;
|
public Func<Message, ChatLine> CreateChatLineAction;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user