mirror of
https://github.com/junegunn/fzf.git
synced 2026-10-13 00:20:20 +08:00
Trigger focus event after reload (#4931)
- Indexes restart after reload, so same-index item was not seen as new - With --id-nth, compare by key. No event if focused item keeps its key. - Skip focus check while track is blocked - Document that binding reload to focus can loop Close #4930
This commit is contained in:
1 parent
33a3456921
commit
25adb67453
4 files changed
+95
-8
No files matched your search
+4
-1
@@ -1909,7 +1909,10 @@ e.g.
|
||||
\fIfocus\fR
|
||||
.RS
|
||||
Triggered when the focus changes due to a vertical cursor movement or a search
|
||||
result update.
|
||||
result update. After a reload, the focused item is considered new unless
|
||||
\fB\-\-id\-nth\fR is set and the item has the same key as the previously
|
||||
focused item. Because of this, binding \fBreload\fR to this event can cause an
|
||||
infinite loop.
|
||||
|
||||
e.g.
|
||||
\fBfzf \-\-bind 'focus:transform\-preview\-label:echo [ {} ]' \-\-preview 'cat {}'
|
||||
|
||||
Reference in new issue
Block a user