We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent bae40cf commit 2217ac7Copy full SHA for 2217ac7
UnityHubNative.Net/SubmitableListBox.cs
@@ -45,18 +45,8 @@ protected override void OnKeyDown(KeyEventArgs e)
45
e.Handled = true;
46
return;
47
}
48
- if (_firstTime)
49
- {
50
- _firstTime = false;
51
- var lastSelectedIndex = SelectedIndex;
52
- base.OnKeyDown(e);
53
- if (SelectedIndex == 1)
54
- SelectedIndex = lastSelectedIndex + 1;
55
- else if (SelectedIndex == ItemCount - 1)
56
- SelectedIndex = lastSelectedIndex == 0 ? ItemCount - 1 : lastSelectedIndex - 1;
57
- }
58
- else
59
+ ContainerFromIndex(SelectedIndex)!.Focus();
+ base.OnKeyDown(e);
60
61
62
public SubmitableListBox AddOnSubmit(Action callback)
0 commit comments