mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-01-17 17:22:42 -05:00
Clean up dialog event hide reasons (#14566)
* Clean up dialog event hide reasons * Remove done
This commit is contained in:
@@ -4,7 +4,7 @@
|
||||
*--------------------------------------------------------------------------------------------*/
|
||||
|
||||
import 'vs/css!./media/dialogModal';
|
||||
import { Modal, IModalOptions } from 'sql/workbench/browser/modal/modal';
|
||||
import { Modal, IModalOptions, HideReason } from 'sql/workbench/browser/modal/modal';
|
||||
import { Wizard, DialogButton, WizardPage } from 'sql/workbench/services/dialog/common/dialogTypes';
|
||||
import { DialogPane } from 'sql/workbench/services/dialog/browser/dialogPane';
|
||||
import { bootstrapAngular } from 'sql/workbench/services/bootstrap/browser/bootstrapService';
|
||||
@@ -274,15 +274,18 @@ export class WizardModal extends Modal {
|
||||
}
|
||||
this._onDone.fire();
|
||||
this.dispose();
|
||||
this.hide('done');
|
||||
this.hide('ok');
|
||||
}
|
||||
}
|
||||
|
||||
public cancel(): void {
|
||||
public close(): void {
|
||||
this.cancel('close');
|
||||
}
|
||||
public cancel(hideReason: HideReason = 'cancel'): void {
|
||||
const currentPage = this._wizard.pages[this._wizard.currentPage];
|
||||
this._onCancel.fire();
|
||||
this.dispose();
|
||||
this.hide('cancel', currentPage.pageName ?? this._wizard.currentPage.toString());
|
||||
this.hide(hideReason, currentPage.pageName ?? this._wizard.currentPage.toString());
|
||||
}
|
||||
|
||||
private async validateNavigation(newPage: number): Promise<boolean> {
|
||||
|
||||
Reference in New Issue
Block a user