mirror of
https://github.com/junegunn/fzf.git
synced 2025-07-31 04:02:01 -07:00
Run preview command when preview window appears after resize (#3113)
# Start fzf in a small screen so that the preview window is hidden fzf --bind 'ctrl-p:toggle-preview' --preview 'stat {}' --preview-window='right,50%,<100(down,50%,hidden)' # Enlarge the screen until the preview window appears. It should not be empty.
This commit is contained in:
@@ -2622,7 +2622,11 @@ func (t *Terminal) Loop() {
|
||||
t.tui.Resume(t.fullscreen, t.sigstop)
|
||||
t.redraw()
|
||||
case reqFullRedraw:
|
||||
wasHidden := t.pwindow == nil
|
||||
t.redraw()
|
||||
if wasHidden && t.pwindow != nil {
|
||||
refreshPreview(t.previewOpts.command)
|
||||
}
|
||||
case reqClose:
|
||||
exit(func() int {
|
||||
if t.output() {
|
||||
|
Reference in New Issue
Block a user