Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Add the + command.

  • Loading branch information...
commit 453bbe7f151ccd10c8fc236004bc702ef79d66b5 1 parent f1ee6eb
@georgebrock georgebrock authored
Showing with 8 additions and 2 deletions.
  1. +3 −2 js/normal_mode/motions.js
  2. +5 −0 tests/acceptance/motions.js
View
5 js/normal_mode/motions.js
@@ -269,8 +269,7 @@
}
}),
- //RETURN
- '\u000D': new C({
+ '+': new C({
callback: function (vim, count) {
vim.moveCursorRelative(count, '^');
},
@@ -284,4 +283,6 @@
}
})
};
+
+ Vimulator.NormalMode.Motions[U.Keys.RETURN] = Vimulator.NormalMode.Motions['+'];
}());
View
5 tests/acceptance/motions.js
@@ -303,4 +303,9 @@ describe("The return motion", function () {
pressKeys("2" + RETURN);
expect(cursorPosition()).toEqual({row: 2, col: 2});
});
+
+ it("is the same as +", function () {
+ pressKeys("2l+");
+ expect(cursorPosition()).toEqual({row: 1, col: 0});
+ });
});

0 comments on commit 453bbe7

Please sign in to comment.
Something went wrong with that request. Please try again.