mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-01-22 01:25:38 -05:00
Add telemetry for ModelView wizards (#12596)
* Add telemetry for ModelView wizards * Remove unnecessary params * Fix compile error
This commit is contained in:
@@ -203,7 +203,7 @@ export class NewDashboardTabDialog extends Modal {
|
||||
}
|
||||
|
||||
public close() {
|
||||
this.hide();
|
||||
this.hide('close');
|
||||
}
|
||||
|
||||
private addNewTabs() {
|
||||
@@ -214,7 +214,7 @@ export class NewDashboardTabDialog extends Modal {
|
||||
}
|
||||
|
||||
public cancel() {
|
||||
this.hide();
|
||||
this.hide('cancel');
|
||||
}
|
||||
|
||||
public open(dashboardTabs: Array<IDashboardTab>, openedTabs: Array<IDashboardTab>) {
|
||||
|
||||
@@ -27,7 +27,7 @@ export class CustomDialogService {
|
||||
}
|
||||
|
||||
public showWizard(wizard: Wizard, options?: IModalOptions): void {
|
||||
let wizardModal = this._instantiationService.createInstance(WizardModal, wizard, 'WizardPage', options || DefaultWizardOptions);
|
||||
let wizardModal = this._instantiationService.createInstance(WizardModal, wizard, options || DefaultWizardOptions);
|
||||
this._wizardModals.set(wizard, wizardModal);
|
||||
wizardModal.render();
|
||||
wizardModal.open();
|
||||
|
||||
@@ -132,7 +132,7 @@ export class DialogModal extends Modal {
|
||||
if (await this._dialog.validateClose()) {
|
||||
this._onDone.fire();
|
||||
this.dispose();
|
||||
this.hide();
|
||||
this.hide('close');
|
||||
}
|
||||
clearTimeout(buttonSpinnerHandler);
|
||||
this._doneButton.element.classList.remove('validating');
|
||||
@@ -143,15 +143,7 @@ export class DialogModal extends Modal {
|
||||
public cancel(): void {
|
||||
this._onCancel.fire();
|
||||
this.dispose();
|
||||
this.hide();
|
||||
}
|
||||
|
||||
protected hide(): void {
|
||||
super.hide();
|
||||
}
|
||||
|
||||
protected show(): void {
|
||||
super.show();
|
||||
this.hide('cancel');
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -46,7 +46,6 @@ export class WizardModal extends Modal {
|
||||
|
||||
constructor(
|
||||
private _wizard: Wizard,
|
||||
name: string,
|
||||
options: IModalOptions,
|
||||
@ILayoutService layoutService: ILayoutService,
|
||||
@IThemeService themeService: IThemeService,
|
||||
@@ -57,7 +56,7 @@ export class WizardModal extends Modal {
|
||||
@ILogService logService: ILogService,
|
||||
@ITextResourcePropertiesService textResourcePropertiesService: ITextResourcePropertiesService
|
||||
) {
|
||||
super(_wizard.title, name, telemetryService, layoutService, clipboardService, themeService, logService, textResourcePropertiesService, contextKeyService, options);
|
||||
super(_wizard.title, _wizard.name, telemetryService, layoutService, clipboardService, themeService, logService, textResourcePropertiesService, contextKeyService, options);
|
||||
this._useDefaultMessageBoxLocation = false;
|
||||
}
|
||||
|
||||
@@ -264,14 +263,14 @@ export class WizardModal extends Modal {
|
||||
}
|
||||
this._onDone.fire();
|
||||
this.dispose();
|
||||
this.hide();
|
||||
this.hide('done');
|
||||
}
|
||||
}
|
||||
|
||||
public cancel(): void {
|
||||
this._onCancel.fire();
|
||||
this.dispose();
|
||||
this.hide();
|
||||
this.hide('cancel');
|
||||
}
|
||||
|
||||
private async validateNavigation(newPage: number): Promise<boolean> {
|
||||
@@ -288,14 +287,6 @@ export class WizardModal extends Modal {
|
||||
return navigationValid;
|
||||
}
|
||||
|
||||
protected hide(): void {
|
||||
super.hide();
|
||||
}
|
||||
|
||||
protected show(): void {
|
||||
super.show();
|
||||
}
|
||||
|
||||
/**
|
||||
* Overridable to change behavior of escape key
|
||||
*/
|
||||
|
||||
@@ -200,6 +200,7 @@ export class Wizard {
|
||||
public width: DialogWidth | undefined;
|
||||
|
||||
constructor(public title: string,
|
||||
public readonly name: string,
|
||||
public doneButton: DialogButton,
|
||||
public cancelButton: DialogButton,
|
||||
public nextButton: DialogButton,
|
||||
|
||||
@@ -107,7 +107,7 @@ export class ProfilerFilterDialog extends Modal {
|
||||
this._loadFilterButton = this.addFooterButton(LoadFilterText, () => this.loadSavedFilter(), 'left');
|
||||
this._applyButton = this.addFooterButton(ApplyText, () => this.filterSession());
|
||||
this._okButton = this.addFooterButton(OkText, () => this.handleOkButtonClick());
|
||||
this._cancelButton = this.addFooterButton(CancelText, () => this.hide());
|
||||
this._cancelButton = this.addFooterButton(CancelText, () => this.hide('cancel'));
|
||||
this._register(attachButtonStyler(this._okButton, this._themeService));
|
||||
this._register(attachButtonStyler(this._cancelButton, this._themeService));
|
||||
this._register(attachButtonStyler(this._applyButton, this._themeService));
|
||||
@@ -139,7 +139,7 @@ export class ProfilerFilterDialog extends Modal {
|
||||
|
||||
/* espace key */
|
||||
protected onClose() {
|
||||
this.hide();
|
||||
this.hide('close');
|
||||
}
|
||||
|
||||
/* enter key */
|
||||
@@ -149,7 +149,7 @@ export class ProfilerFilterDialog extends Modal {
|
||||
|
||||
private handleOkButtonClick(): void {
|
||||
this.filterSession();
|
||||
this.hide();
|
||||
this.hide('ok');
|
||||
}
|
||||
|
||||
private handleClearButtonClick() {
|
||||
|
||||
Reference in New Issue
Block a user