Fix 'postion' typos (#76187)

Fix 'postion' typos
This commit is contained in:
Sandeep Somavarapu 2019-06-30 20:24:12 +02:00 committed by GitHub
commit 1af379c856
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
8 changed files with 16 additions and 16 deletions

View file

@ -36,7 +36,7 @@ export class Position {
}
/**
* Create a new postion from this position.
* Create a new position from this position.
*
* @param newLineNumber new line number
* @param newColumn new column

View file

@ -611,25 +611,25 @@ export class PieceTreeBase {
let resultLen = 0;
const searcher = new Searcher(searchData.wordSeparators, searchData.regex);
let startPostion = this.nodeAt2(searchRange.startLineNumber, searchRange.startColumn);
if (startPostion === null) {
let startPosition = this.nodeAt2(searchRange.startLineNumber, searchRange.startColumn);
if (startPosition === null) {
return [];
}
let endPosition = this.nodeAt2(searchRange.endLineNumber, searchRange.endColumn);
if (endPosition === null) {
return [];
}
let start = this.positionInBuffer(startPostion.node, startPostion.remainder);
let start = this.positionInBuffer(startPosition.node, startPosition.remainder);
let end = this.positionInBuffer(endPosition.node, endPosition.remainder);
if (startPostion.node === endPosition.node) {
this.findMatchesInNode(startPostion.node, searcher, searchRange.startLineNumber, searchRange.startColumn, start, end, searchData, captureMatches, limitResultCount, resultLen, result);
if (startPosition.node === endPosition.node) {
this.findMatchesInNode(startPosition.node, searcher, searchRange.startLineNumber, searchRange.startColumn, start, end, searchData, captureMatches, limitResultCount, resultLen, result);
return result;
}
let startLineNumber = searchRange.startLineNumber;
let currentNode = startPostion.node;
let currentNode = startPosition.node;
while (currentNode !== endPosition.node) {
let lineBreakCnt = this.getLineFeedCnt(currentNode.piece.bufferIndex, start, currentNode.piece.end);
@ -663,9 +663,9 @@ export class PieceTreeBase {
}
startLineNumber++;
startPostion = this.nodeAt2(startLineNumber, 1);
currentNode = startPostion.node;
start = this.positionInBuffer(startPostion.node, startPostion.remainder);
startPosition = this.nodeAt2(startLineNumber, 1);
currentNode = startPosition.node;
start = this.positionInBuffer(startPosition.node, startPosition.remainder);
}
if (startLineNumber === searchRange.endLineNumber) {

View file

@ -25,7 +25,7 @@ export interface ITextResourceConfigurationService {
* Value can be of native type or an object keyed off the section name.
*
* @param resource - Resource for which the configuration has to be fetched.
* @param postion - Position in the resource for which configuration has to be fetched.
* @param position - Position in the resource for which configuration has to be fetched.
* @param section - Section of the configuraion.
*
*/

View file

@ -91,7 +91,7 @@ export class DragAndDropCommand implements editorCommon.ICommand {
this.selection.endColumn
);
} else {
// The target position is before the selection's end postion. Since the selection doesn't contain the target position, the selection is one-line and target position is before this selection.
// The target position is before the selection's end position. Since the selection doesn't contain the target position, the selection is one-line and target position is before this selection.
this.targetSelection = new Selection(
this.targetPosition.lineNumber - this.selection.endLineNumber + this.selection.startLineNumber,
this.targetPosition.column,

2
src/vs/monaco.d.ts vendored
View file

@ -453,7 +453,7 @@ declare namespace monaco {
readonly column: number;
constructor(lineNumber: number, column: number);
/**
* Create a new postion from this position.
* Create a new position from this position.
*
* @param newLineNumber new line number
* @param newColumn new column

2
src/vs/vscode.d.ts vendored
View file

@ -3826,7 +3826,7 @@ declare module 'vscode' {
/**
* Provide selection ranges for the given positions.
*
* Selection ranges should be computed individually and independend for each postion. The editor will merge
* Selection ranges should be computed individually and independend for each position. The editor will merge
* and deduplicate ranges but providers must return hierarchies of selection ranges so that a range
* is [contained](#Range.contains) by its parent.
*

View file

@ -53,7 +53,7 @@ declare module 'vscode' {
*/
provideCallHierarchyItem(
document: TextDocument,
postion: Position,
position: Position,
token: CancellationToken
): ProviderResult<CallHierarchyItem>;

View file

@ -30,7 +30,7 @@ export interface CallHierarchyProvider {
provideCallHierarchyItem(
document: ITextModel,
postion: IPosition,
position: IPosition,
token: CancellationToken
): ProviderResult<CallHierarchyItem>;