aboutsummaryrefslogtreecommitdiff
path: root/src/page_artists.go
diff options
context:
space:
mode:
Diffstat (limited to 'src/page_artists.go')
-rw-r--r--src/page_artists.go5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/page_artists.go b/src/page_artists.go
index 4175f3c..f67697c 100644
--- a/src/page_artists.go
+++ b/src/page_artists.go
@@ -34,20 +34,20 @@ func (a *app) artistsPage() tview.Primitive {
34 34
35 a.loadAlbumInPanel(sel.id) 35 a.loadAlbumInPanel(sel.id)
36 a.tv.SetFocus(a.songsList) 36 a.tv.SetFocus(a.songsList)
37 a.updateFooter()
38 }) 37 })
39 a.artistsTree.SetBorderAttributes(tcell.AttrDim).SetBorder(true) 38 a.artistsTree.SetBorderAttributes(tcell.AttrDim).SetBorder(true)
39 a.artistsTree.SetFocusFunc(func() { a.updateFooter() })
40 40
41 // Songs list for the selected album 41 // Songs list for the selected album
42 a.songsList = tview.NewList() 42 a.songsList = tview.NewList()
43 a.songsList.ShowSecondaryText(false).SetHighlightFullLine(true) 43 a.songsList.ShowSecondaryText(false).SetHighlightFullLine(true)
44 a.songsList.SetBorderAttributes(tcell.AttrDim).SetBorder(true) 44 a.songsList.SetBorderAttributes(tcell.AttrDim).SetBorder(true)
45 a.songsList.SetFocusFunc(func() { a.updateFooter() })
45 46
46 // Change the left-right keys to switch between the panels 47 // Change the left-right keys to switch between the panels
47 a.artistsTree.SetInputCapture(func(event *tcell.EventKey) *tcell.EventKey { 48 a.artistsTree.SetInputCapture(func(event *tcell.EventKey) *tcell.EventKey {
48 if event.Key() == tcell.KeyLeft || event.Key() == tcell.KeyRight { 49 if event.Key() == tcell.KeyLeft || event.Key() == tcell.KeyRight {
49 a.tv.SetFocus(a.songsList) 50 a.tv.SetFocus(a.songsList)
50 a.updateFooter()
51 return nil 51 return nil
52 } 52 }
53 return event 53 return event
@@ -56,7 +56,6 @@ func (a *app) artistsPage() tview.Primitive {
56 a.songsList.SetInputCapture(func(event *tcell.EventKey) *tcell.EventKey { 56 a.songsList.SetInputCapture(func(event *tcell.EventKey) *tcell.EventKey {
57 if event.Key() == tcell.KeyLeft || event.Key() == tcell.KeyRight { 57 if event.Key() == tcell.KeyLeft || event.Key() == tcell.KeyRight {
58 a.tv.SetFocus(a.artistsTree) 58 a.tv.SetFocus(a.artistsTree)
59 a.updateFooter()
60 return nil 59 return nil
61 } 60 }
62 return event 61 return event