Skip to content
This repository was archived by the owner on Apr 6, 2018. It is now read-only.

Commit 1b88c5a

Browse files
committed
renames command->normal
1 parent 244368a commit 1b88c5a

File tree

3 files changed

+10
-10
lines changed

3 files changed

+10
-10
lines changed

lib/operators/input.coffee

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@ class Change extends Insert
130130
@vimState.activateInsertMode()
131131
@typingCompleted = true
132132
else
133-
@vimState.activateCommandMode()
133+
@vimState.activateNormalMode()
134134

135135
class SubstituteLine extends Change
136136
standalone: true

spec/motions-spec.coffee

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1524,10 +1524,10 @@ describe "Motions", ->
15241524
it "cancels c when no match found", ->
15251525
keydown('c')
15261526
keydown('f')
1527-
commandModeInputKeydown('d')
1527+
normalModeInputKeydown('d')
15281528
expect(editor.getText()).toBe("abcabcabcabc\n")
15291529
expect(editor.getCursorScreenPosition()).toEqual [0, 0]
1530-
expect(vimState.mode).toBe "command"
1530+
expect(vimState.mode).toBe "normal"
15311531

15321532
describe 'the t/T keybindings', ->
15331533
beforeEach ->

spec/operators-spec.coffee

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -728,7 +728,7 @@ describe "Operators", ->
728728

729729
it "undoes correctly with u", ->
730730
keydown('escape')
731-
expect(vimState.mode).toBe "command"
731+
expect(vimState.mode).toBe "normal"
732732
keydown 'u'
733733
expect(editor.getText()).toBe("12345(67)8\nabc(d)e\nA()BCDE")
734734

@@ -752,7 +752,7 @@ describe "Operators", ->
752752
keydown('c')
753753
keydown('%')
754754
expect(editor.getText()).toBe("12345(67)8\nabc(d)e\nABCDE")
755-
expect(vimState.mode).toBe "command"
755+
expect(vimState.mode).toBe "normal"
756756

757757
describe "repetition with .", ->
758758
beforeEach ->
@@ -766,33 +766,33 @@ describe "Operators", ->
766766
editor.setCursorScreenPosition([1, 0])
767767
keydown('.')
768768
expect(editor.getText()).toBe("1x8\nxe\nA()BCDE")
769-
expect(vimState.mode).toBe "command"
769+
expect(vimState.mode).toBe "normal"
770770

771771
it "repeats correctly on the opening bracket", ->
772772
editor.setCursorScreenPosition([1, 3])
773773
keydown('.')
774774
expect(editor.getText()).toBe("1x8\nabcxe\nA()BCDE")
775-
expect(vimState.mode).toBe "command"
775+
expect(vimState.mode).toBe "normal"
776776

777777
it "repeats correctly inside brackets", ->
778778
editor.setCursorScreenPosition([1, 4])
779779
keydown('.')
780780
# this differs from VIM, which deletes the character originally under cursor
781781
expect(editor.getText()).toBe("1x8\nabcxd)e\nA()BCDE")
782-
expect(vimState.mode).toBe "command"
782+
expect(vimState.mode).toBe "normal"
783783

784784
it "repeats correctly on the closing bracket", ->
785785
editor.setCursorScreenPosition([1, 5])
786786
keydown('.')
787787
# this differs from VIM, which deletes the character originally under cursor
788788
expect(editor.getText()).toBe("1x8\nabcx)e\nA()BCDE")
789-
expect(vimState.mode).toBe "command"
789+
expect(vimState.mode).toBe "normal"
790790

791791
it "does nothing when repeated after a bracket", ->
792792
editor.setCursorScreenPosition([2, 3])
793793
keydown('.')
794794
expect(editor.getText()).toBe("1x8\nabc(d)e\nA()BCDE")
795-
expect(vimState.mode).toBe "command"
795+
expect(vimState.mode).toBe "normal"
796796

797797
describe "when followed by a goto line G", ->
798798
beforeEach ->

0 commit comments

Comments
 (0)