From c163aaa895672596c48a68eb4ba12d9515c010c9 Mon Sep 17 00:00:00 2001 From: Zachary Yedidia Date: Wed, 4 May 2016 07:24:33 -0400 Subject: [PATCH] Small fix to relocation --- cmd/micro/bindings.go | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/cmd/micro/bindings.go b/cmd/micro/bindings.go index 3fc8c3a5..985168d7 100644 --- a/cmd/micro/bindings.go +++ b/cmd/micro/bindings.go @@ -856,23 +856,22 @@ func (v *View) JumpLine() bool { // Prompt for line number linestring, canceled := messenger.Prompt("Jump to line # ") if canceled { - return true + return false } lineint, err := strconv.Atoi(linestring) lineint = lineint - 1 // fix offset if err != nil { messenger.Error(err) // return errors - return true + return false } // Move cursor and view if possible. if lineint < len(v.buf.lines) { v.cursor.x = 0 v.cursor.y = lineint - v.topline = lineint - return false + return true } messenger.Error("Only ", len(v.buf.lines), " lines to jump") - return true + return false } // None is no action