From cbb559346d225ee42ae818357d9b55a1b95f3cfb Mon Sep 17 00:00:00 2001 From: Ivan Podmazov Date: Wed, 17 Jun 2020 06:17:30 +0300 Subject: [PATCH] fix toggle behaviour (#352) (#386) --- nav.go | 2 -- opts.go | 2 +- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/nav.go b/nav.go index 87f44c0..28eeb68 100644 --- a/nav.go +++ b/nav.go @@ -622,8 +622,6 @@ func (nav *nav) toggle() { } nav.toggleSelection(curr.path) - - nav.down(1) } func (nav *nav) invert() { diff --git a/opts.go b/opts.go index d411190..ae1d051 100644 --- a/opts.go +++ b/opts.go @@ -120,7 +120,7 @@ func init() { gOpts.keys[""] = &callExpr{"top", nil, 1} gOpts.keys["G"] = &callExpr{"bottom", nil, 1} gOpts.keys[""] = &callExpr{"bottom", nil, 1} - gOpts.keys[""] = &callExpr{"toggle", nil, 1} + gOpts.keys[""] = &listExpr{[]expr{&callExpr{"toggle", nil, 1}, &callExpr{"down", nil, 1}}} gOpts.keys["v"] = &callExpr{"invert", nil, 1} gOpts.keys["u"] = &callExpr{"unselect", nil, 1} gOpts.keys["y"] = &callExpr{"copy", nil, 1}