mirror of
https://github.com/go-sylixos/elvish.git
synced 2024-12-12 17:27:50 +08:00
edit: Only write bufListing when necessary.
This commit is contained in:
parent
097ecfe6f6
commit
b9a2693e57
|
@ -509,7 +509,7 @@ tokens:
|
|||
// Render bufListing under the maximum height constraint
|
||||
nav := es.navigation
|
||||
hist := es.historyListing
|
||||
if hListing > 0 {
|
||||
if hListing > 0 && (comp != nil || nav != nil || hist != nil) {
|
||||
b := newBuffer(width)
|
||||
bufListing = b
|
||||
if comp != nil { // Completion listing
|
||||
|
@ -594,6 +594,9 @@ tokens:
|
|||
}
|
||||
}
|
||||
|
||||
Logger.Printf("bufLine %d, bufMode %d, bufTips %d, bufListing %d",
|
||||
lines(bufLine), lines(bufMode), lines(bufTips), lines(bufListing))
|
||||
|
||||
// Combine buffers (reusing bufLine)
|
||||
buf = bufLine
|
||||
buf.extend(bufMode)
|
||||
|
|
Loading…
Reference in New Issue
Block a user