mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-02-10 10:12:34 -05:00
Merge VS Code 1.31.1 (#4283)
This commit is contained in:
@@ -10,8 +10,8 @@ export const IIssueService = createDecorator<IIssueService>('issueService');
|
||||
// Since data sent through the service is serialized to JSON, functions will be lost, so Color objects
|
||||
// should not be sent as their 'toString' method will be stripped. Instead convert to strings before sending.
|
||||
export interface WindowStyles {
|
||||
backgroundColor: string;
|
||||
color: string;
|
||||
backgroundColor?: string;
|
||||
color?: string;
|
||||
}
|
||||
export interface WindowData {
|
||||
styles: WindowStyles;
|
||||
@@ -26,19 +26,19 @@ export const enum IssueType {
|
||||
}
|
||||
|
||||
export interface IssueReporterStyles extends WindowStyles {
|
||||
textLinkColor: string;
|
||||
textLinkActiveForeground: string;
|
||||
inputBackground: string;
|
||||
inputForeground: string;
|
||||
inputBorder: string;
|
||||
inputErrorBorder: string;
|
||||
inputActiveBorder: string;
|
||||
buttonBackground: string;
|
||||
buttonForeground: string;
|
||||
buttonHoverBackground: string;
|
||||
sliderBackgroundColor: string;
|
||||
sliderHoverColor: string;
|
||||
sliderActiveColor: string;
|
||||
textLinkColor?: string;
|
||||
textLinkActiveForeground?: string;
|
||||
inputBackground?: string;
|
||||
inputForeground?: string;
|
||||
inputBorder?: string;
|
||||
inputErrorBorder?: string;
|
||||
inputActiveBorder?: string;
|
||||
buttonBackground?: string;
|
||||
buttonForeground?: string;
|
||||
buttonHoverBackground?: string;
|
||||
sliderBackgroundColor?: string;
|
||||
sliderHoverColor?: string;
|
||||
sliderActiveColor?: string;
|
||||
}
|
||||
|
||||
export interface IssueReporterExtensionData {
|
||||
@@ -75,9 +75,9 @@ export interface IssueReporterFeatures {
|
||||
}
|
||||
|
||||
export interface ProcessExplorerStyles extends WindowStyles {
|
||||
hoverBackground: string;
|
||||
hoverForeground: string;
|
||||
highlightForeground: string;
|
||||
hoverBackground?: string;
|
||||
hoverForeground?: string;
|
||||
highlightForeground?: string;
|
||||
}
|
||||
|
||||
export interface ProcessExplorerData extends WindowData {
|
||||
@@ -87,6 +87,6 @@ export interface ProcessExplorerData extends WindowData {
|
||||
|
||||
export interface IIssueService {
|
||||
_serviceBrand: any;
|
||||
openReporter(data: IssueReporterData): Thenable<void>;
|
||||
openProcessExplorer(data: ProcessExplorerData): Thenable<void>;
|
||||
openReporter(data: IssueReporterData): Promise<void>;
|
||||
openProcessExplorer(data: ProcessExplorerData): Promise<void>;
|
||||
}
|
||||
|
||||
@@ -28,11 +28,11 @@ export class IssueService implements IIssueService {
|
||||
constructor(
|
||||
private machineId: string,
|
||||
private userEnv: IProcessEnvironment,
|
||||
@IEnvironmentService private environmentService: IEnvironmentService,
|
||||
@ILaunchService private launchService: ILaunchService,
|
||||
@ILogService private logService: ILogService,
|
||||
@IDiagnosticsService private diagnosticsService: IDiagnosticsService,
|
||||
@IWindowsService private windowsService: IWindowsService
|
||||
@IEnvironmentService private readonly environmentService: IEnvironmentService,
|
||||
@ILaunchService private readonly launchService: ILaunchService,
|
||||
@ILogService private readonly logService: ILogService,
|
||||
@IDiagnosticsService private readonly diagnosticsService: IDiagnosticsService,
|
||||
@IWindowsService private readonly windowsService: IWindowsService
|
||||
) {
|
||||
this.registerListeners();
|
||||
}
|
||||
@@ -118,6 +118,7 @@ export class IssueService implements IIssueService {
|
||||
const position = this.getWindowPosition(this._issueParentWindow, 700, 800);
|
||||
|
||||
this._issueWindow = new BrowserWindow({
|
||||
fullscreen: false,
|
||||
width: position.width,
|
||||
height: position.height,
|
||||
minWidth: 300,
|
||||
@@ -163,6 +164,7 @@ export class IssueService implements IIssueService {
|
||||
this._processExplorerWindow = new BrowserWindow({
|
||||
skipTaskbar: true,
|
||||
resizable: true,
|
||||
fullscreen: false,
|
||||
width: position.width,
|
||||
height: position.height,
|
||||
minWidth: 300,
|
||||
@@ -187,7 +189,7 @@ export class IssueService implements IIssueService {
|
||||
const environment = parseArgs(process.argv);
|
||||
const config = objects.assign(environment, windowConfiguration);
|
||||
for (let key in config) {
|
||||
if (config[key] === void 0 || config[key] === null || config[key] === '') {
|
||||
if (config[key] === undefined || config[key] === null || config[key] === '') {
|
||||
delete config[key]; // only send over properties that have a true value
|
||||
}
|
||||
}
|
||||
@@ -321,11 +323,11 @@ export class IssueService implements IIssueService {
|
||||
const environment = parseArgs(process.argv);
|
||||
const config = objects.assign(environment, windowConfiguration);
|
||||
for (let key in config) {
|
||||
if (config[key] === void 0 || config[key] === null || config[key] === '') {
|
||||
if (config[key] === undefined || config[key] === null || config[key] === '') {
|
||||
delete config[key]; // only send over properties that have a true value
|
||||
}
|
||||
}
|
||||
|
||||
return `${require.toUrl('vs/code/electron-browser/issue/issueReporter.html')}?config=${encodeURIComponent(JSON.stringify(config))}`;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -15,7 +15,7 @@ export class IssueChannel implements IServerChannel {
|
||||
throw new Error(`Event not found: ${event}`);
|
||||
}
|
||||
|
||||
call(_, command: string, arg?: any): Thenable<any> {
|
||||
call(_, command: string, arg?: any): Promise<any> {
|
||||
switch (command) {
|
||||
case 'openIssueReporter':
|
||||
return this.service.openReporter(arg);
|
||||
@@ -33,11 +33,11 @@ export class IssueChannelClient implements IIssueService {
|
||||
|
||||
constructor(private channel: IChannel) { }
|
||||
|
||||
openReporter(data: IssueReporterData): Thenable<void> {
|
||||
openReporter(data: IssueReporterData): Promise<void> {
|
||||
return this.channel.call('openIssueReporter', data);
|
||||
}
|
||||
|
||||
openProcessExplorer(data: ProcessExplorerData): Thenable<void> {
|
||||
openProcessExplorer(data: ProcessExplorerData): Promise<void> {
|
||||
return this.channel.call('openProcessExplorer', data);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user