summaryrefslogtreecommitdiff
path: root/Scripts/Terminal/InputArea.cs
blob: 04c0887ece370880e0465ac4e31239f82adb929c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
using Godot;

namespace Texty.Scripts.Terminal;

public partial class InputArea : HBoxContainer
{
    protected Label PromptLabel => GetNodeOrNull<Label>($"%{nameof(PromptLabel)}");
    protected LineEdit TextInput => GetNodeOrNull<LineEdit>($"%{nameof(TextInput)}");

    public new bool HasFocus => TextInput?.HasFocus() ?? false;

    public virtual void OnTextEntered(string text)
    {
    }
}