[enh] use PreserveScrollPosition config value

This commit is contained in:
Adam Tauber 2017-02-11 23:42:07 +01:00
parent ecab5334c7
commit 6326145735

View File

@ -500,7 +500,7 @@ func (a *App) PrintBody(g *gocui.Gui) {
} else {
vrb.Write(req.RawResponseBody)
}
if _, err := vrb.Line(0); err != nil {
if _, err := vrb.Line(0); !a.config.General.PreserveScrollPosition || err != nil {
vrb.SetOrigin(0, 0)
}
return nil