Skip to content

Commit dc0ebb4

Browse files
committed
Interface should start with an additional I. IIndentConverter.
1 parent da4f670 commit dc0ebb4

2 files changed

Lines changed: 7 additions & 7 deletions

File tree

src/vs/editor/common/modes/languageConfigurationRegistry.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ export interface IVirtualModel {
3737
getLineContent(lineNumber: number): string;
3838
}
3939

40-
export interface IndentConverter {
40+
export interface IIndentConverter {
4141
shiftIndent?(indentation: string): string;
4242
unshiftIndent?(indentation: string): string;
4343
normalizeIndentation?(indentation: string): string;
@@ -429,7 +429,7 @@ export class LanguageConfigurationRegistryImpl {
429429
}
430430
}
431431

432-
public getGoodIndentForLine(virtualModel: IVirtualModel, languageId: LanguageId, lineNumber: number, indentConverter: IndentConverter): string {
432+
public getGoodIndentForLine(virtualModel: IVirtualModel, languageId: LanguageId, lineNumber: number, indentConverter: IIndentConverter): string {
433433
let indentRulesSupport = this._getIndentRulesSupport(languageId);
434434
if (!indentRulesSupport) {
435435
return null;
@@ -456,7 +456,7 @@ export class LanguageConfigurationRegistryImpl {
456456
return null;
457457
}
458458

459-
public getIndentForEnter(model: ITokenizedModel, range: Range, indentConverter: IndentConverter): { beforeEnter: string, afterEnter: string } {
459+
public getIndentForEnter(model: ITokenizedModel, range: Range, indentConverter: IIndentConverter): { beforeEnter: string, afterEnter: string } {
460460
model.forceTokenization(range.startLineNumber);
461461
let lineTokens = model.getLineTokens(range.startLineNumber);
462462

@@ -548,7 +548,7 @@ export class LanguageConfigurationRegistryImpl {
548548
* We should always allow intentional indentation. It means, if users change the indentation of `lineNumber` and the content of
549549
* this line doesn't match decreaseIndentPattern, we should not adjust the indentation.
550550
*/
551-
public getIndentActionForType(model: ITokenizedModel, range: Range, ch: string, indentConverter: IndentConverter): string {
551+
public getIndentActionForType(model: ITokenizedModel, range: Range, ch: string, indentConverter: IIndentConverter): string {
552552
let scopedLineTokens = this.getScopedLineTokens(model, range.startLineNumber, range.startColumn);
553553
let indentRulesSupport = this._getIndentRulesSupport(scopedLineTokens.languageId);
554554
if (!indentRulesSupport) {

src/vs/editor/contrib/linesOperations/common/moveLinesCommand.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import * as strings from 'vs/base/common/strings';
88
import { Range } from 'vs/editor/common/core/range';
99
import { Selection } from 'vs/editor/common/core/selection';
1010
import { ICommand, ICursorStateComputerData, IEditOperationBuilder, ITokenizedModel } from 'vs/editor/common/editorCommon';
11-
import { LanguageConfigurationRegistry, IndentConverter } from 'vs/editor/common/modes/languageConfigurationRegistry';
11+
import { LanguageConfigurationRegistry, IIndentConverter } from 'vs/editor/common/modes/languageConfigurationRegistry';
1212
import { ShiftCommand } from 'vs/editor/common/commands/shiftCommand';
1313
import * as IndentUtil from 'vs/editor/contrib/indentation/common/indentUtils';
1414
import { IndentAction } from 'vs/editor/common/modes/languageConfiguration';
@@ -212,7 +212,7 @@ export class MoveLinesCommand implements ICommand {
212212
this._selectionId = builder.trackSelection(s);
213213
}
214214

215-
private buildIndentConverter(tabSize: number): IndentConverter {
215+
private buildIndentConverter(tabSize: number): IIndentConverter {
216216
return {
217217
shiftIndent: (indentation) => {
218218
let desiredIndentCount = ShiftCommand.shiftIndentCount(indentation, indentation.length + 1, tabSize);
@@ -244,7 +244,7 @@ export class MoveLinesCommand implements ICommand {
244244
break;
245245
}
246246
oneLineAbove--;
247-
}
247+
}
248248

249249
if (oneLineAbove < 1 || line > model.getLineCount()) {
250250
return null;

0 commit comments

Comments
 (0)