mirror of
https://github.com/ckaczor/vscode-gitlens.git
synced 2026-02-16 10:58:34 -05:00
Updates some @type packages
Fixes typo and utilizes new range method
This commit is contained in:
@@ -398,9 +398,9 @@
|
|||||||
"tmp": "^0.0.31"
|
"tmp": "^0.0.31"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@types/node": "^6.0.51",
|
"@types/node": "^0.0.2",
|
||||||
"@types/mocha": "^2.2.33",
|
"@types/mocha": "^2.2.33",
|
||||||
"@types/tmp": "^0.0.31",
|
"@types/tmp": "^0.0.32",
|
||||||
"mocha": "^3.2.0",
|
"mocha": "^3.2.0",
|
||||||
"tslint": "^4.0.2",
|
"tslint": "^4.0.2",
|
||||||
"typescript": "^2.0.10",
|
"typescript": "^2.0.10",
|
||||||
|
|||||||
@@ -126,7 +126,7 @@ export default class GitCodeLensProvider implements CodeLensProvider {
|
|||||||
if (!this._isValidSymbol(symbol.kind, languageLocation)) return;
|
if (!this._isValidSymbol(symbol.kind, languageLocation)) return;
|
||||||
|
|
||||||
const line = document.lineAt(symbol.location.range.start);
|
const line = document.lineAt(symbol.location.range.start);
|
||||||
// Make sure there is only 1 lense per line
|
// Make sure there is only 1 lens per line
|
||||||
if (lenses.length && lenses[lenses.length - 1].range.start.line === line.lineNumber) return;
|
if (lenses.length && lenses[lenses.length - 1].range.start.line === line.lineNumber) return;
|
||||||
|
|
||||||
let startChar = -1;
|
let startChar = -1;
|
||||||
@@ -149,8 +149,8 @@ export default class GitCodeLensProvider implements CodeLensProvider {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (this._config.codeLens.authors.enabled) {
|
if (this._config.codeLens.authors.enabled) {
|
||||||
|
let multiline = !symbol.location.range.isSingleLine;
|
||||||
// HACK for Omnisharp, since it doesn't return full ranges
|
// HACK for Omnisharp, since it doesn't return full ranges
|
||||||
let multiline = (symbol.location.range.end.line - symbol.location.range.start.line) > 1;
|
|
||||||
if (!multiline && document.languageId === 'csharp') {
|
if (!multiline && document.languageId === 'csharp') {
|
||||||
switch (symbol.kind) {
|
switch (symbol.kind) {
|
||||||
case SymbolKind.File:
|
case SymbolKind.File:
|
||||||
|
|||||||
Reference in New Issue
Block a user