@@ -6,22 +6,22 @@ const targetLineIsEmptyOrWhitespace = (
6
6
) => ! document . lineAt ( line ) . isEmptyOrWhitespace ;
7
7
8
8
enum LineOperation {
9
- Up = 1 ,
10
- Down = 2 ,
9
+ up = 1 ,
10
+ down = 2 ,
11
11
}
12
12
13
13
function getNextLine ( editor : vscode . TextEditor , op : LineOperation ) {
14
14
let document = editor . document ;
15
15
let line = editor . selection . active . line ;
16
16
17
17
switch ( op ) {
18
- case LineOperation . Up :
18
+ case LineOperation . up :
19
19
{
20
20
while ( line > 0 && targetLineIsEmptyOrWhitespace ( -- line , document ) ) { }
21
21
}
22
22
break ;
23
23
24
- case LineOperation . Down :
24
+ case LineOperation . down :
25
25
{
26
26
while (
27
27
line < document . lineCount - 1 &&
@@ -44,7 +44,7 @@ export function activate(context: vscode.ExtensionContext) {
44
44
let paragraphJumpUp = vscode . commands . registerTextEditorCommand (
45
45
"paragraphjump.up" ,
46
46
( editor : vscode . TextEditor ) => {
47
- let targetLine : vscode . TextLine = getNextLine ( editor , LineOperation . Up ) ;
47
+ let targetLine : vscode . TextLine = getNextLine ( editor , LineOperation . up ) ;
48
48
const newPosition = new vscode . Position ( targetLine . lineNumber , 0 ) ;
49
49
moveCursor ( editor , newPosition ) ;
50
50
}
@@ -53,7 +53,7 @@ export function activate(context: vscode.ExtensionContext) {
53
53
let paragraphJumpDown = vscode . commands . registerTextEditorCommand (
54
54
"paragraphjump.down" ,
55
55
( editor : vscode . TextEditor ) => {
56
- let targetLine : vscode . TextLine = getNextLine ( editor , LineOperation . Down ) ;
56
+ let targetLine : vscode . TextLine = getNextLine ( editor , LineOperation . down ) ;
57
57
const newPosition = new vscode . Position ( targetLine . lineNumber , 0 ) ;
58
58
moveCursor ( editor , newPosition ) ;
59
59
}
0 commit comments