Handle server list navigation and focus better

This commit is contained in:
Bronley 2021-07-13 19:05:20 -04:00
parent bd9e01ad71
commit 97ef66ff96
2 changed files with 1 additions and 2 deletions

View File

@ -27,7 +27,6 @@ function onKeyEvent(key as string, press as boolean) as boolean
'user navigating up to the server picker from the input box (it's only focusable if it has items)
else if key = "up" and m.serverUrlContainer.hasFocus() and m.servers.Count() > 0
m.serverPicker.animateToItem = m.serverPicker.content.getChildCount() - 1
m.serverPicker.setFocus(true)
else if key = "OK" and m.serverUrlContainer.hasFocus()
ShowKeyboard()

View File

@ -15,7 +15,7 @@
<!--background for server picker-->
<Rectangle color="0x00000020" width="1620" height="400">
<Spinner id="spinner" translation="[717, 136]" />
<MarkupList id="serverPicker" translation="[50, 20]" itemComponentName="JFServer" itemSpacing="[0, 10]" itemSize="[1520, 100]" numRows="3" vertFocusAnimationStyle="fixedFocus" />
<MarkupList id="serverPicker" translation="[50, 20]" itemComponentName="JFServer" itemSpacing="[0, 10]" itemSize="[1520, 100]" numRows="3" vertFocusAnimationStyle="floatingFocus" />
</Rectangle>
<label text="...or enter server URL manually:" translation="[0, 690]" />