mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-02-05 17:23:51 -05:00
Add dialog close validation (#1704)
This commit is contained in:
@@ -120,11 +120,13 @@ export class DialogModal extends Modal {
|
||||
this.show();
|
||||
}
|
||||
|
||||
public done(): void {
|
||||
public async done(): Promise<void> {
|
||||
if (this._dialog.okButton.enabled) {
|
||||
this._onDone.fire();
|
||||
this.dispose();
|
||||
this.hide();
|
||||
if (await this._dialog.validateClose()) {
|
||||
this._onDone.fire();
|
||||
this.dispose();
|
||||
this.hide();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user