rename scrollup/down to scroll-up/down

cc #764
This commit is contained in:
Gokcehan committed 2022-03-30 12:58:38 +03:00
1 parent afa90fe647
commit 4db1a63b75
7 files changed
+26 -26

No files matched your search

+2 -2
View File
@@ -17,11 +17,11 @@ var (
"up",
"half-up",
"page-up",
"scrollup",
"scroll-up",
"down",
"half-down",
"page-down",
"scrolldown",
"scroll-down",
"updir",
"open",
"quit",
+5 -5
View File
@@ -20,11 +20,11 @@ The following commands are provided by lf:
up (default 'k' and '<up>')
half-up (default '<c-u>')
page-up (default '<c-b>' and '<pgup>')
scrollup (default '<c-y>')
scroll-up (default '<c-y>')
down (default 'j' and '<down>')
half-down (default '<c-d>')
page-down (default '<c-f>' and '<pgdn>')
scrolldown (default '<c-e>')
scroll-down (default '<c-e>')
updir (default 'h' and '<left>')
open (default 'l' and '<right>')
top (default 'gg' and '<home>')
@@ -264,13 +264,13 @@ Quit lf and return to the shell.
up (default 'k' and '<up>')
half-up (default '<c-u>')
page-up (default '<c-b>' and '<pgup>')
scrollup (default '<c-y>')
scroll-up (default '<c-y>')
down (default 'j' and '<down>')
half-down (default '<c-d>')
page-down (default '<c-f>' and '<pgdn>')
scrolldown (default '<c-e>')
scroll-down (default '<c-e>')
Move the current file selection upwards/downwards by one/half a page/full page.
Move/scroll the current file selection upwards/downwards by one/half a page/full page.
updir (default 'h' and '<left>')
+6 -6
View File
@@ -25,11 +25,11 @@ The following commands are provided by lf:
up (default 'k' and '<up>')
half-up (default '<c-u>')
page-up (default '<c-b>' and '<pgup>')
scrollup (default '<c-y>')
scroll-up (default '<c-y>')
down (default 'j' and '<down>')
half-down (default '<c-d>')
page-down (default '<c-f>' and '<pgdn>')
scrolldown (default '<c-e>')
scroll-down (default '<c-e>')
updir (default 'h' and '<left>')
open (default 'l' and '<right>')
top (default 'gg' and '<home>')
@@ -273,14 +273,14 @@ Quit lf and return to the shell.
up (default 'k' and '<up>')
half-up (default '<c-u>')
page-up (default '<c-b>' and '<pgup>')
scrollup (default '<c-y>')
scroll-up (default '<c-y>')
down (default 'j' and '<down>')
half-down (default '<c-d>')
page-down (default '<c-f>' and '<pgdn>')
scrolldown (default '<c-e>')
scroll-down (default '<c-e>')
Move the current file selection upwards/downwards by one/half a page/full
page.
Move/scroll the current file selection upwards/downwards by one/half a
page/full page.
updir (default 'h' and '<left>')
+4 -4
View File
@@ -816,11 +816,11 @@ func (e *callExpr) eval(app *app, args []string) {
app.ui.loadFile(app.nav, true)
app.ui.loadFileInfo(app.nav)
}
case "scrollup":
case "scroll-up":
if !app.nav.init {
return
}
if app.nav.scrollup(e.count) {
if app.nav.scrollUp(e.count) {
app.ui.loadFile(app.nav, true)
app.ui.loadFileInfo(app.nav)
}
@@ -848,11 +848,11 @@ func (e *callExpr) eval(app *app, args []string) {
app.ui.loadFile(app.nav, true)
app.ui.loadFileInfo(app.nav)
}
case "scrolldown":
case "scroll-down":
if !app.nav.init {
return
}
if app.nav.scrolldown(e.count) {
if app.nav.scrollDown(e.count) {
app.ui.loadFile(app.nav, true)
app.ui.loadFileInfo(app.nav)
}
+5 -5
View File
@@ -35,11 +35,11 @@ The following commands are provided by lf:
up (default 'k' and '<up>')
half-up (default '<c-u>')
page-up (default '<c-b>' and '<pgup>')
scrollup (default '<c-y>')
scroll-up (default '<c-y>')
down (default 'j' and '<down>')
half-down (default '<c-d>')
page-down (default '<c-f>' and '<pgdn>')
scrolldown (default '<c-e>')
scroll-down (default '<c-e>')
updir (default 'h' and '<left>')
open (default 'l' and '<right>')
top (default 'gg' and '<home>')
@@ -304,14 +304,14 @@ Quit lf and return to the shell.
up (default 'k' and '<up>')
half-up (default '<c-u>')
page-up (default '<c-b>' and '<pgup>')
scrollup (default '<c-y>')
scroll-up (default '<c-y>')
down (default 'j' and '<down>')
half-down (default '<c-d>')
page-down (default '<c-f>' and '<pgdn>')
scrolldown (default '<c-e>')
scroll-down (default '<c-e>')
.EE
.PP
Move the current file selection upwards/downwards by one/half a page/full page.
Move/scroll the current file selection upwards/downwards by one/half a page/full page.
.PP
.EX
updir (default 'h' and '<left>')
+2 -2
View File
@@ -828,7 +828,7 @@ func (nav *nav) down(dist int) bool {
return old != dir.ind
}
func (nav *nav) scrollup(dist int) bool {
func (nav *nav) scrollUp(dist int) bool {
dir := nav.currDir()
// when reached top do nothing
@@ -857,7 +857,7 @@ func (nav *nav) scrollup(dist int) bool {
return old != dir.ind
}
func (nav *nav) scrolldown(dist int) bool {
func (nav *nav) scrollDown(dist int) bool {
dir := nav.currDir()
maxind := len(dir.files) - 1
+2 -2
View File
@@ -130,13 +130,13 @@ func init() {
gOpts.keys["<c-u>"] = &callExpr{"half-up", nil, 1}
gOpts.keys["<c-b>"] = &callExpr{"page-up", nil, 1}
gOpts.keys["<pgup>"] = &callExpr{"page-up", nil, 1}
gOpts.keys["<c-y>"] = &callExpr{"scrollup", nil, 1}
gOpts.keys["<c-y>"] = &callExpr{"scroll-up", nil, 1}
gOpts.keys["j"] = &callExpr{"down", nil, 1}
gOpts.keys["<down>"] = &callExpr{"down", nil, 1}
gOpts.keys["<c-d>"] = &callExpr{"half-down", nil, 1}
gOpts.keys["<c-f>"] = &callExpr{"page-down", nil, 1}
gOpts.keys["<pgdn>"] = &callExpr{"page-down", nil, 1}
gOpts.keys["<c-e>"] = &callExpr{"scrolldown", nil, 1}
gOpts.keys["<c-e>"] = &callExpr{"scroll-down", nil, 1}
gOpts.keys["h"] = &callExpr{"updir", nil, 1}
gOpts.keys["<left>"] = &callExpr{"updir", nil, 1}
gOpts.keys["l"] = &callExpr{"open", nil, 1}