public override VimPoint Move(Interfaces.IVimHost host) { int dst_line = this.Repeat - 1; if (dst_line != host.CurrentPosition.X) { host.GotoLine(dst_line); } host.ScrollLineCenter(); return host.CurrentPosition; }
public override VimPoint Move(Interfaces.IVimHost host) { if (host.IsCurrentPositionAtStartOfDocument()) { return host.CurrentPosition; } VimPoint start_pos = host.CurrentPosition; VimPoint pos = null; for (int i = 0; i < this.Repeat; i++) { if (!host.FindLeftBrace(start_pos, out pos)) { return host.CurrentPosition; } start_pos = pos; } host.GotoLine(pos.X); host.MoveCursor(pos); return host.CurrentPosition; }