Merge from vscode cfc1ab4c5f816765b91fb7ead3c3427a7c8581a3

This commit is contained in:
ADS Merger
2020-03-11 04:19:23 +00:00
parent 16fab722d5
commit 4c3e48773d
880 changed files with 20441 additions and 11232 deletions

View File

@@ -15,7 +15,7 @@ import * as colors from 'vs/platform/theme/common/colorRegistry';
import * as types from 'vs/base/common/types';
import { Disposable } from 'vs/base/common/lifecycle';
import * as nls from 'vs/nls';
import { IThemeService, ITheme } from 'vs/platform/theme/common/themeService';
import { IThemeService, IColorTheme } from 'vs/platform/theme/common/themeService';
import { IPointDataSet } from 'sql/workbench/contrib/charts/browser/interfaces';
import { IInsightsView, IInsightData } from 'sql/platform/dashboard/browser/insightRegistry';
import { ChartType, LegendPosition } from 'sql/workbench/contrib/charts/common/interfaces';
@@ -61,8 +61,8 @@ export abstract class ChartInsight extends Disposable implements IInsightsView {
}
init() {
this._register(this.themeService.onThemeChange(e => this.updateTheme(e)));
this.updateTheme(this.themeService.getTheme());
this._register(this.themeService.onDidColorThemeChange(e => this.updateTheme(e)));
this.updateTheme(this.themeService.getColorTheme());
// Note: must use a boolean to not render the canvas until all properties such as the labels and chart type are set.
// This is because chart.js doesn't auto-update anything other than dataset when re-rendering so defaults are used
// hence it's easier to not render until ready
@@ -96,7 +96,7 @@ export abstract class ChartInsight extends Disposable implements IInsightsView {
return this._options;
}
protected updateTheme(e: ITheme): void {
protected updateTheme(e: IColorTheme): void {
const foregroundColor = e.getColor(colors.editorForeground);
const foreground = foregroundColor ? foregroundColor.toString() : null;
const backgroundColor = e.getColor(colors.editorBackground);

View File

@@ -10,7 +10,7 @@ import { IChartConfig } from 'sql/workbench/contrib/dashboard/browser/widgets/in
import * as colors from 'vs/platform/theme/common/colorRegistry';
import { editorLineNumbers } from 'vs/editor/common/view/editorColorRegistry';
import { ChangeDetectorRef, Inject, forwardRef } from '@angular/core';
import { IThemeService, ITheme } from 'vs/platform/theme/common/themeService';
import { IThemeService, IColorTheme } from 'vs/platform/theme/common/themeService';
import { IAdsTelemetryService } from 'sql/platform/telemetry/common/telemetry';
import { customMixin } from 'sql/workbench/contrib/charts/browser/interfaces';
import { ChartType } from 'sql/workbench/contrib/charts/common/interfaces';
@@ -127,7 +127,7 @@ export default class BarChart extends ChartInsight {
super.setConfig(config);
}
protected updateTheme(e: ITheme): void {
protected updateTheme(e: IColorTheme): void {
super.updateTheme(e);
const foregroundColor = e.getColor(colors.editorForeground);
const foreground = foregroundColor ? foregroundColor.toString() : null;

View File

@@ -17,7 +17,7 @@ import { IConnectionProfile } from 'sql/platform/connection/common/interfaces';
/* VS imports */
import * as themeColors from 'vs/workbench/common/theme';
import * as colors from 'vs/platform/theme/common/colorRegistry';
import { registerThemingParticipant, ICssStyleCollector, ITheme } from 'vs/platform/theme/common/themeService';
import { registerThemingParticipant, ICssStyleCollector, IColorTheme } from 'vs/platform/theme/common/themeService';
import * as types from 'vs/base/common/types';
import { ScrollableElement } from 'vs/base/browser/ui/scrollbar/scrollableElement';
import { ScrollbarVisibility } from 'vs/base/common/scrollable';
@@ -149,7 +149,7 @@ export class TasksWidget extends DashboardWidget implements IDashboardWidget, On
return tile;
}
private registerThemeing(theme: ITheme, collector: ICssStyleCollector) {
private registerThemeing(theme: IColorTheme, collector: ICssStyleCollector) {
const contrastBorder = theme.getColor(colors.contrastBorder);
const sideBarColor = theme.getColor(themeColors.SIDE_BAR_BACKGROUND);
if (contrastBorder) {

View File

@@ -97,7 +97,7 @@ export class WebviewWidget extends DashboardWidget implements IDashboardWidget,
this._onMessageDisposable.dispose();
}
this._webview = this.webviewService.createWebview(this.id,
this._webview = this.webviewService.createWebviewElement(this.id,
{},
{
allowScripts: true,