feat(main): suffix text channel topic to TextView title (#27)

This commit is contained in:
rigormorrtiss 2021-08-16 22:48:45 +04:00 • committed by GitHub
parent d0fb493eb9
commit 7b0a824f5b

View file

@ -210,7 +210,12 @@ func onGuildsTreeViewSelected(n *tview.TreeNode) {
currentChannel = r
app.SetFocus(messageInputField)
messagesTextView.Clear()
messagesTextView.SetTitle(r.Name)
title := "#" + r.Name
if r.Topic != "" {
title += " - " + r.Topic
}
messagesTextView.SetTitle(title)
for _, t := range currentGuild.Threads {
if t.ParentID == currentChannel.ID {