From b5980abf5df2a36c59db35163c129f5b1423c4a2 Mon Sep 17 00:00:00 2001 From: Florrie Date: Wed, 15 Aug 2018 16:38:54 -0300 Subject: Fix tab not working in a particular case The repro: 1. Press tab to select the path element. 2. Press 2 (or 1) to switch to a different grouplike listing. 3. Press 1 (or 2) to switch back. Note that the root.select()'ed element is the grouplike listing's form, i.e. the list of tracks/groups, not the path element. 4. Press tab. Note that the root.select()'ed element does not change. This fixes the issue by setting curIndex to 0, which is the index of the grouplike listing's form. This makes the tab key behave correctly and select the path element in step 4. --- ui.js | 1 + 1 file changed, 1 insertion(+) (limited to 'ui.js') diff --git a/ui.js b/ui.js index befa764..ac7154d 100644 --- a/ui.js +++ b/ui.js @@ -733,6 +733,7 @@ class GrouplikeListingElement extends Form { } selected() { + this.curIndex = 0 this.root.select(this.form) } -- cgit 1.3.0-6-gf8a5