mirror of
https://github.com/taigrr/wtf
synced 2025-01-18 04:03:14 -08:00
Rename Prev/Next in MultiSourceWidget
This will open the possibility of a MultiSourceScrollableWidget with no collisions
This commit is contained in:
@@ -4,11 +4,11 @@ import "github.com/gdamore/tcell"
|
||||
|
||||
func (widget *Widget) initializeKeyboardControls() {
|
||||
widget.SetKeyboardChar("/", widget.ShowHelp, "Show/hide this help window")
|
||||
widget.SetKeyboardChar("h", widget.Prev, "Select previous item")
|
||||
widget.SetKeyboardChar("l", widget.Next, "Select next item")
|
||||
widget.SetKeyboardChar("h", widget.PrevSource, "Select previous item")
|
||||
widget.SetKeyboardChar("l", widget.NextSource, "Select next item")
|
||||
widget.SetKeyboardChar("p", widget.Pull, "Pull repo")
|
||||
widget.SetKeyboardChar("c", widget.Checkout, "Checkout branch")
|
||||
|
||||
widget.SetKeyboardKey(tcell.KeyLeft, widget.Prev, "Select previous item")
|
||||
widget.SetKeyboardKey(tcell.KeyRight, widget.Next, "Select next item")
|
||||
widget.SetKeyboardKey(tcell.KeyLeft, widget.PrevSource, "Select previous item")
|
||||
widget.SetKeyboardKey(tcell.KeyRight, widget.NextSource, "Select next item")
|
||||
}
|
||||
|
||||
@@ -6,12 +6,12 @@ import (
|
||||
|
||||
func (widget *Widget) initializeKeyboardControls() {
|
||||
widget.SetKeyboardChar("/", widget.ShowHelp, "Show/hide this help prompt")
|
||||
widget.SetKeyboardChar("h", widget.Prev, "Select previous item")
|
||||
widget.SetKeyboardChar("l", widget.Next, "Select next item")
|
||||
widget.SetKeyboardChar("h", widget.PrevSource, "Select previous item")
|
||||
widget.SetKeyboardChar("l", widget.NextSource, "Select next item")
|
||||
widget.SetKeyboardChar("o", widget.openRepo, "Open item in browser")
|
||||
widget.SetKeyboardChar("r", widget.Refresh, "Refresh widget")
|
||||
|
||||
widget.SetKeyboardKey(tcell.KeyEnter, widget.openRepo, "Open item in browser")
|
||||
widget.SetKeyboardKey(tcell.KeyLeft, widget.Prev, "Select previous item")
|
||||
widget.SetKeyboardKey(tcell.KeyRight, widget.Next, "Select next item")
|
||||
widget.SetKeyboardKey(tcell.KeyLeft, widget.PrevSource, "Select previous item")
|
||||
widget.SetKeyboardKey(tcell.KeyRight, widget.NextSource, "Select next item")
|
||||
}
|
||||
|
||||
@@ -4,11 +4,11 @@ import "github.com/gdamore/tcell"
|
||||
|
||||
func (widget *Widget) initializeKeyboardControls() {
|
||||
widget.SetKeyboardChar("/", widget.ShowHelp, "Show/hide this help prompt")
|
||||
widget.SetKeyboardChar("h", widget.Prev, "Select previous item")
|
||||
widget.SetKeyboardChar("l", widget.Next, "Select next item")
|
||||
widget.SetKeyboardChar("h", widget.PrevSource, "Select previous item")
|
||||
widget.SetKeyboardChar("l", widget.NextSource, "Select next item")
|
||||
widget.SetKeyboardChar("p", widget.Pull, "Pull repo")
|
||||
widget.SetKeyboardChar("c", widget.Checkout, "Checkout branch")
|
||||
|
||||
widget.SetKeyboardKey(tcell.KeyLeft, widget.Prev, "Select previous item")
|
||||
widget.SetKeyboardKey(tcell.KeyRight, widget.Next, "Select next item")
|
||||
widget.SetKeyboardKey(tcell.KeyLeft, widget.PrevSource, "Select previous item")
|
||||
widget.SetKeyboardKey(tcell.KeyRight, widget.NextSource, "Select next item")
|
||||
}
|
||||
|
||||
@@ -7,12 +7,12 @@ import (
|
||||
|
||||
func (widget *Widget) initializeKeyboardControls() {
|
||||
widget.SetKeyboardChar("/", widget.ShowHelp, "Show/hide this help prompt")
|
||||
widget.SetKeyboardChar("h", widget.Prev, "Select previous item")
|
||||
widget.SetKeyboardChar("l", widget.Next, "Select next item")
|
||||
widget.SetKeyboardChar("h", widget.PrevSource, "Select previous item")
|
||||
widget.SetKeyboardChar("l", widget.NextSource, "Select next item")
|
||||
widget.SetKeyboardChar("o", widget.openFile, "Open item")
|
||||
|
||||
widget.SetKeyboardKey(tcell.KeyLeft, widget.Prev, "Select previous item")
|
||||
widget.SetKeyboardKey(tcell.KeyRight, widget.Next, "Select next item")
|
||||
widget.SetKeyboardKey(tcell.KeyLeft, widget.PrevSource, "Select previous item")
|
||||
widget.SetKeyboardKey(tcell.KeyRight, widget.NextSource, "Select next item")
|
||||
}
|
||||
|
||||
func (widget *Widget) openFile() {
|
||||
|
||||
@@ -6,14 +6,14 @@ func (widget *Widget) initializeKeyboardControls() {
|
||||
widget.SetKeyboardChar("/", widget.ShowHelp, "Show/hide this help prompt")
|
||||
widget.SetKeyboardChar("c", widget.Close, "Close item")
|
||||
widget.SetKeyboardChar("d", widget.Delete, "Delete item")
|
||||
widget.SetKeyboardChar("h", widget.Prev, "Select previous project")
|
||||
widget.SetKeyboardChar("h", widget.PrevSource, "Select previous project")
|
||||
widget.SetKeyboardChar("j", widget.Up, "Select previous item")
|
||||
widget.SetKeyboardChar("k", widget.Down, "Select next item")
|
||||
widget.SetKeyboardChar("l", widget.Next, "Select next project")
|
||||
widget.SetKeyboardChar("l", widget.NextSource, "Select next project")
|
||||
widget.SetKeyboardChar("r", widget.Refresh, "Refresh widget")
|
||||
|
||||
widget.SetKeyboardKey(tcell.KeyDown, widget.Down, "Select next item")
|
||||
widget.SetKeyboardKey(tcell.KeyLeft, widget.Prev, "Select previous project")
|
||||
widget.SetKeyboardKey(tcell.KeyRight, widget.Next, "Select next project")
|
||||
widget.SetKeyboardKey(tcell.KeyLeft, widget.PrevSource, "Select previous project")
|
||||
widget.SetKeyboardKey(tcell.KeyRight, widget.NextSource, "Select next project")
|
||||
widget.SetKeyboardKey(tcell.KeyUp, widget.Up, "Select previous item")
|
||||
}
|
||||
|
||||
@@ -7,13 +7,13 @@ import (
|
||||
|
||||
func (widget *Widget) initializeKeyboardControls() {
|
||||
widget.SetKeyboardChar("/", widget.ShowHelp, "Show/hide this help prompt")
|
||||
widget.SetKeyboardChar("h", widget.Prev, "Select previous item")
|
||||
widget.SetKeyboardChar("l", widget.Next, "Select next item")
|
||||
widget.SetKeyboardChar("h", widget.PrevSource, "Select previous item")
|
||||
widget.SetKeyboardChar("l", widget.NextSource, "Select next item")
|
||||
widget.SetKeyboardChar("o", widget.openFile, "Open item")
|
||||
|
||||
widget.SetKeyboardKey(tcell.KeyEnter, widget.openFile, "Open item")
|
||||
widget.SetKeyboardKey(tcell.KeyLeft, widget.Prev, "Select previous item")
|
||||
widget.SetKeyboardKey(tcell.KeyRight, widget.Next, "Select next item")
|
||||
widget.SetKeyboardKey(tcell.KeyLeft, widget.PrevSource, "Select previous item")
|
||||
widget.SetKeyboardKey(tcell.KeyRight, widget.NextSource, "Select next item")
|
||||
}
|
||||
|
||||
func (widget *Widget) openFile() {
|
||||
|
||||
Reference in New Issue
Block a user