HOTFIX: Fix lineedit focus (#34621)
* Test entered tree fix * Use Opened override * Fix keyboard focus on window open for DialogWindow This affects Phone, Pray, Rename, and multiple other admin verbs. * Clean up
This commit is contained in:
@@ -87,9 +87,6 @@ public sealed partial class DialogWindow : FancyWindow
|
||||
Prompts.AddChild(box);
|
||||
}
|
||||
|
||||
// Grab keyboard focus for the first dialog entry
|
||||
_promptLines[0].Item2.GrabKeyboardFocus();
|
||||
|
||||
OkButton.OnPressed += _ => Confirm();
|
||||
|
||||
CancelButton.OnPressed += _ =>
|
||||
@@ -110,6 +107,14 @@ public sealed partial class DialogWindow : FancyWindow
|
||||
OpenCentered();
|
||||
}
|
||||
|
||||
protected override void Opened()
|
||||
{
|
||||
base.Opened();
|
||||
|
||||
// Grab keyboard focus for the first dialog entry
|
||||
_promptLines[0].Item2.GrabKeyboardFocus();
|
||||
}
|
||||
|
||||
private void Confirm()
|
||||
{
|
||||
var results = new Dictionary<string, string>();
|
||||
|
||||
Reference in New Issue
Block a user