mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-02-14 12:08:36 -05:00
Merge from vscode a5cf1da01d5db3d2557132be8d30f89c38019f6c (#8525)
* Merge from vscode a5cf1da01d5db3d2557132be8d30f89c38019f6c * remove files we don't want * fix hygiene * update distro * update distro * fix hygiene * fix strict nulls * distro * distro * fix tests * fix tests * add another edit * fix viewlet icon * fix azure dialog * fix some padding * fix more padding issues
This commit is contained in:
@@ -32,7 +32,7 @@ import { IDiffComputationResult, IEditorWorkerService } from 'vs/editor/common/s
|
||||
import { OverviewRulerZone } from 'vs/editor/common/view/overviewZoneManager';
|
||||
import { LineDecoration } from 'vs/editor/common/viewLayout/lineDecorations';
|
||||
import { RenderLineInput, renderViewLine } from 'vs/editor/common/viewLayout/viewLineRenderer';
|
||||
import { IEditorWhitespace } from 'vs/editor/common/viewLayout/whitespaceComputer';
|
||||
import { IEditorWhitespace } from 'vs/editor/common/viewLayout/linesLayout';
|
||||
import { InlineDecoration, InlineDecorationType, ViewLineRenderingData } from 'vs/editor/common/viewModel/viewModel';
|
||||
import { IContextKeyService } from 'vs/platform/contextkey/common/contextkey';
|
||||
import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation';
|
||||
@@ -1394,12 +1394,16 @@ abstract class ViewZonesComputer {
|
||||
|
||||
private readonly lineChanges: editorCommon.ILineChange[];
|
||||
private readonly originalForeignVZ: IEditorWhitespace[];
|
||||
private readonly originalLineHeight: number;
|
||||
private readonly modifiedForeignVZ: IEditorWhitespace[];
|
||||
private readonly modifiedLineHeight: number;
|
||||
|
||||
constructor(lineChanges: editorCommon.ILineChange[], originalForeignVZ: IEditorWhitespace[], modifiedForeignVZ: IEditorWhitespace[]) {
|
||||
constructor(lineChanges: editorCommon.ILineChange[], originalForeignVZ: IEditorWhitespace[], originalLineHeight: number, modifiedForeignVZ: IEditorWhitespace[], modifiedLineHeight: number) {
|
||||
this.lineChanges = lineChanges;
|
||||
this.originalForeignVZ = originalForeignVZ;
|
||||
this.originalLineHeight = originalLineHeight;
|
||||
this.modifiedForeignVZ = modifiedForeignVZ;
|
||||
this.modifiedLineHeight = modifiedLineHeight;
|
||||
}
|
||||
|
||||
public getViewZones(): IEditorsZones {
|
||||
@@ -1474,7 +1478,7 @@ abstract class ViewZonesComputer {
|
||||
|
||||
stepOriginal.push({
|
||||
afterLineNumber: viewZoneLineNumber,
|
||||
heightInLines: modifiedForeignVZ.current.heightInLines,
|
||||
heightInLines: modifiedForeignVZ.current.height / this.modifiedLineHeight,
|
||||
domNode: null,
|
||||
marginDomNode: marginDomNode
|
||||
});
|
||||
@@ -1491,7 +1495,7 @@ abstract class ViewZonesComputer {
|
||||
}
|
||||
stepModified.push({
|
||||
afterLineNumber: viewZoneLineNumber,
|
||||
heightInLines: originalForeignVZ.current.heightInLines,
|
||||
heightInLines: originalForeignVZ.current.height / this.originalLineHeight,
|
||||
domNode: null
|
||||
});
|
||||
originalForeignVZ.advance();
|
||||
@@ -1750,7 +1754,7 @@ class DiffEditorWidgetSideBySide extends DiffEditorWidgetStyle implements IDiffE
|
||||
}
|
||||
|
||||
protected _getViewZones(lineChanges: editorCommon.ILineChange[], originalForeignVZ: IEditorWhitespace[], modifiedForeignVZ: IEditorWhitespace[], originalEditor: editorBrowser.ICodeEditor, modifiedEditor: editorBrowser.ICodeEditor): IEditorsZones {
|
||||
let c = new SideBySideViewZonesComputer(lineChanges, originalForeignVZ, modifiedForeignVZ);
|
||||
let c = new SideBySideViewZonesComputer(lineChanges, originalForeignVZ, originalEditor.getOption(EditorOption.lineHeight), modifiedForeignVZ, modifiedEditor.getOption(EditorOption.lineHeight));
|
||||
return c.getViewZones();
|
||||
}
|
||||
|
||||
@@ -1877,8 +1881,8 @@ class DiffEditorWidgetSideBySide extends DiffEditorWidgetStyle implements IDiffE
|
||||
|
||||
class SideBySideViewZonesComputer extends ViewZonesComputer {
|
||||
|
||||
constructor(lineChanges: editorCommon.ILineChange[], originalForeignVZ: IEditorWhitespace[], modifiedForeignVZ: IEditorWhitespace[]) {
|
||||
super(lineChanges, originalForeignVZ, modifiedForeignVZ);
|
||||
constructor(lineChanges: editorCommon.ILineChange[], originalForeignVZ: IEditorWhitespace[], originalLineHeight: number, modifiedForeignVZ: IEditorWhitespace[], modifiedLineHeight: number) {
|
||||
super(lineChanges, originalForeignVZ, originalLineHeight, modifiedForeignVZ, modifiedLineHeight);
|
||||
}
|
||||
|
||||
protected _createOriginalMarginDomNodeForModifiedForeignViewZoneInAddedRegion(): HTMLDivElement | null {
|
||||
@@ -2038,7 +2042,7 @@ class InlineViewZonesComputer extends ViewZonesComputer {
|
||||
private readonly renderIndicators: boolean;
|
||||
|
||||
constructor(lineChanges: editorCommon.ILineChange[], originalForeignVZ: IEditorWhitespace[], modifiedForeignVZ: IEditorWhitespace[], originalEditor: editorBrowser.ICodeEditor, modifiedEditor: editorBrowser.ICodeEditor, renderIndicators: boolean) {
|
||||
super(lineChanges, originalForeignVZ, modifiedForeignVZ);
|
||||
super(lineChanges, originalForeignVZ, originalEditor.getOption(EditorOption.lineHeight), modifiedForeignVZ, modifiedEditor.getOption(EditorOption.lineHeight));
|
||||
this.originalModel = originalEditor.getModel()!;
|
||||
this.modifiedEditorOptions = modifiedEditor.getOptions();
|
||||
this.modifiedEditorTabSize = modifiedEditor.getModel()!.getOptions().tabSize;
|
||||
|
||||
Reference in New Issue
Block a user