« get me outta code hell

Don't select 'up' button by default - mtui - Music Text User Interface - user-friendly command line music player
about summary refs log tree commit diff
path: root/ui.js
diff options
context:
space:
mode:
authorFlorrie <towerofnix@gmail.com>2018-05-31 23:08:55 -0300
committerFlorrie <towerofnix@gmail.com>2018-05-31 23:08:55 -0300
commit24466e09fabecb9cc47ed248bb976d32c70ab3e4 (patch)
tree293943917107d86baa48976e6bc4a2c14a18d01e /ui.js
parent1542bb95af86bfd3aeda7919f7abde6a699e5198 (diff)
Don't select 'up' button by default
Diffstat (limited to 'ui.js')
-rw-r--r--ui.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/ui.js b/ui.js
index 5a6a6c9..7a3a333 100644
--- a/ui.js
+++ b/ui.js
@@ -275,7 +275,7 @@ class GrouplikeListingElement extends ListScrollForm {
 
     if (wasSelected) {
       if (resetIndex) {
-        this.curIndex = 0
+        this.curIndex = Math.min(this.inputs.length, 1)
         this.scrollItems = 0
         this.updateSelectedElement()
       } else {