No need to query row position of the cursor if mouse is disabled

This commit is contained in:
Junegunn Choi 2017-01-10 22:55:55 +09:00
parent ae274158de
commit 0c127cfdc1
No known key found for this signature in database
GPG Key ID: 254BC280FEF9C627

View File

@ -185,7 +185,9 @@ func (r *LightRenderer) Init() {
r.csi(fmt.Sprintf("%dA", r.MaxY()-1))
r.csi("G")
// r.csi("s")
r.yoffset, _ = r.findOffset()
if r.mouse {
r.yoffset, _ = r.findOffset()
}
}
func (r *LightRenderer) move(y int, x int) {