mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-01-15 01:25:36 -05:00
Merge from vscode e3c4990c67c40213af168300d1cfeb71d680f877 (#16569)
This commit is contained in:
@@ -25,7 +25,6 @@ import { ISerializationService } from 'sql/platform/serialization/common/seriali
|
||||
import { IFileBrowserService } from 'sql/workbench/services/fileBrowser/common/interfaces';
|
||||
import { IExtHostContext } from 'vs/workbench/api/common/extHost.protocol';
|
||||
import { extHostNamedCustomer } from 'vs/workbench/api/common/extHostCustomers';
|
||||
import { assign } from 'vs/base/common/objects';
|
||||
import { serializableToMap } from 'sql/base/common/map';
|
||||
import { IAssessmentService } from 'sql/workbench/services/assessment/common/interfaces';
|
||||
import { IDataGridProviderService } from 'sql/workbench/services/dataGridProvider/common/dataGridProviderService';
|
||||
@@ -570,7 +569,7 @@ export class MainThreadDataProtocol extends Disposable implements MainThreadData
|
||||
}
|
||||
|
||||
public $onObjectExplorerNodeExpanded(providerId: string, expandResponse: azdata.ObjectExplorerExpandInfo): void {
|
||||
let expandInfo: NodeExpandInfoWithProviderId = assign({ providerId: providerId }, expandResponse);
|
||||
let expandInfo: NodeExpandInfoWithProviderId = Object.assign({ providerId: providerId }, expandResponse);
|
||||
this._objectExplorerService.onNodeExpanded(expandInfo);
|
||||
}
|
||||
|
||||
|
||||
@@ -16,7 +16,6 @@ import { ModelViewInput, ModelViewInputModel, ModeViewSaveHandler } from 'sql/wo
|
||||
|
||||
import * as vscode from 'vscode';
|
||||
import * as azdata from 'azdata';
|
||||
import { assign } from 'vs/base/common/objects';
|
||||
import { TelemetryView, TelemetryAction } from 'sql/platform/telemetry/common/telemetryKeys';
|
||||
import { IAdsTelemetryService } from 'sql/platform/telemetry/common/telemetry';
|
||||
import { IEditorInput, IEditorPane } from 'vs/workbench/common/editor';
|
||||
@@ -92,7 +91,7 @@ export class MainThreadModelViewDialog extends Disposable implements MainThreadM
|
||||
|
||||
public $openDialog(handle: number, dialogName?: string): Thenable<void> {
|
||||
let dialog = this.getDialog(handle);
|
||||
const options = assign({}, DefaultDialogOptions);
|
||||
const options = Object.assign({}, DefaultDialogOptions);
|
||||
options.width = dialog.width;
|
||||
options.dialogStyle = dialog.dialogStyle;
|
||||
options.dialogPosition = dialog.dialogPosition;
|
||||
@@ -247,7 +246,7 @@ export class MainThreadModelViewDialog extends Disposable implements MainThreadM
|
||||
|
||||
public $openWizard(handle: number, source?: string): Thenable<void> {
|
||||
let wizard = this.getWizard(handle);
|
||||
const options = assign({}, DefaultWizardOptions);
|
||||
const options = Object.assign({}, DefaultWizardOptions);
|
||||
options.width = wizard.width;
|
||||
this._dialogService.showWizard(wizard, options, source);
|
||||
return Promise.resolve();
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
|
||||
import { IMainContext } from 'vs/workbench/api/common/extHost.protocol';
|
||||
import { Emitter } from 'vs/base/common/event';
|
||||
import { deepClone, assign } from 'vs/base/common/objects';
|
||||
import { deepClone } from 'vs/base/common/objects';
|
||||
import { URI } from 'vs/base/common/uri';
|
||||
import * as nls from 'vs/nls';
|
||||
|
||||
@@ -323,17 +323,17 @@ class ComponentBuilderImpl<T extends azdata.Component, TPropertyBag extends azda
|
||||
|
||||
withProperties<U>(properties: U): azdata.ComponentBuilder<T, TPropertyBag> {
|
||||
// Keep any properties that may have been set during initial object construction
|
||||
this._component.properties = assign({}, this._component.properties, properties);
|
||||
this._component.properties = Object.assign({}, this._component.properties, properties);
|
||||
return this;
|
||||
}
|
||||
|
||||
withProps(properties: TPropertyBag): azdata.ComponentBuilder<T, TPropertyBag> {
|
||||
this._component.properties = assign({}, this._component.properties, properties);
|
||||
this._component.properties = Object.assign({}, this._component.properties, properties);
|
||||
return this;
|
||||
}
|
||||
|
||||
withValidation(validation: (component: T) => boolean | Thenable<boolean>): azdata.ComponentBuilder<T, TPropertyBag> {
|
||||
this._component.customValidations.push(validation);
|
||||
this._component.customValidations.push(validation as (component: ThisType<ComponentWrapper>) => boolean | Thenable<boolean>); // Use specific type to avoid type assertion error
|
||||
return this;
|
||||
}
|
||||
|
||||
@@ -406,7 +406,7 @@ class FormContainerBuilder extends GenericContainerBuilder<azdata.FormContainer,
|
||||
});
|
||||
}
|
||||
|
||||
return new InternalItemConfig(componentWrapper, assign({}, itemLayout || {}, {
|
||||
return new InternalItemConfig(componentWrapper, Object.assign({}, itemLayout || {}, {
|
||||
title: formComponent.title,
|
||||
actions: actions,
|
||||
isFormComponent: true,
|
||||
@@ -794,7 +794,7 @@ class ComponentWrapper implements azdata.Component {
|
||||
}
|
||||
|
||||
public updateProperties(properties: { [key: string]: any }): Thenable<void> {
|
||||
this.properties = assign(this.properties, properties);
|
||||
this.properties = Object.assign(this.properties, properties);
|
||||
return this.notifyPropertyChanged();
|
||||
}
|
||||
|
||||
@@ -803,7 +803,7 @@ class ComponentWrapper implements azdata.Component {
|
||||
}
|
||||
|
||||
public updateCssStyles(cssStyles: { [key: string]: string }): Thenable<void> {
|
||||
this.properties.CSSStyles = assign(this.properties.CSSStyles || {}, cssStyles);
|
||||
this.properties.CSSStyles = Object.assign(this.properties.CSSStyles || {}, cssStyles);
|
||||
return this.notifyPropertyChanged();
|
||||
}
|
||||
|
||||
@@ -1648,7 +1648,7 @@ class DeclarativeTableWrapper extends ComponentWrapper implements azdata.Declara
|
||||
// and so map them into their IDs instead. We don't want to update the actual
|
||||
// data property though since the caller would still expect that to contain
|
||||
// the Component objects they created
|
||||
const properties = assign({}, this.properties);
|
||||
const properties = Object.assign({}, this.properties);
|
||||
const componentsToAdd: ComponentWrapper[] = [];
|
||||
if (properties.data?.length > 0) {
|
||||
|
||||
|
||||
@@ -26,7 +26,7 @@ class ModelViewPanelImpl implements azdata.window.ModelViewPanel {
|
||||
public handle: number;
|
||||
protected _modelViewId: string;
|
||||
protected _valid: boolean = true;
|
||||
protected _onValidityChanged: vscode.Event<boolean>;
|
||||
protected _onValidityChanged: Event<boolean>;
|
||||
|
||||
constructor(private _viewType: string,
|
||||
protected _extHostModelViewDialog: ExtHostModelViewDialog,
|
||||
|
||||
@@ -14,7 +14,6 @@ import * as azdata from 'azdata';
|
||||
import * as vsTreeExt from 'vs/workbench/api/common/extHostTreeViews';
|
||||
import { Emitter } from 'vs/base/common/event';
|
||||
import { IExtensionDescription } from 'vs/platform/extensions/common/extensions';
|
||||
import { assign } from 'vs/base/common/objects';
|
||||
import { ILogService } from 'vs/platform/log/common/log';
|
||||
import { TreeDataTransferDTO } from 'vs/workbench/api/common/shared/treeDataTransfer';
|
||||
|
||||
@@ -166,7 +165,7 @@ export class ExtHostTreeView<T> extends vsTreeExt.ExtHostTreeView<T> {
|
||||
protected override createTreeNode(element: T, extensionTreeItem: azdata.TreeComponentItem, parent?: vsTreeExt.TreeNode | vsTreeExt.Root): vsTreeExt.TreeNode {
|
||||
let node = super.createTreeNode(element, extensionTreeItem, parent);
|
||||
if (node.item) {
|
||||
node.item = assign(node.item, { checked: extensionTreeItem.checked, enabled: extensionTreeItem.enabled });
|
||||
node.item = Object.assign(node.item, { checked: extensionTreeItem.checked, enabled: extensionTreeItem.enabled });
|
||||
}
|
||||
return node;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user