Browse Source

updated to have lastChat var and new keybinding for CTRL+z

pull/36/head
David Haukeness 5 years ago
parent
commit
5e6e97d7f6
No known key found for this signature in database
GPG Key ID: A7F1091956853EF9
  1. 8
      main.go

8
main.go

@ -22,6 +22,7 @@ var ( @@ -22,6 +22,7 @@ var (
channels []keybase.Channel
stream = false
lastMessage keybase.ChatAPI
lastChat = ""
g *gocui.Gui
)
@ -124,6 +125,13 @@ func initKeybindings() error { @@ -124,6 +125,13 @@ func initKeybindings() error {
}); err != nil {
return err
}
if err := g.SetKeybinding("", gocui.KeyCtrlZ, gocui.ModNone,
func(g *gocui.Gui, v *gocui.View) error {
cmdJoin([]string{"/join", lastChat})
return nil
}); err != nil {
return err
}
if err := g.SetKeybinding("Edit", gocui.KeyCtrlC, gocui.ModNone,
func(g *gocui.Gui, v *gocui.View) error {
popupView("Chat")

Loading…
Cancel
Save