Skip to content

Commit

Permalink
Work for surveyjs/survey-creator#4484 - memory leaks in survey creato…
Browse files Browse the repository at this point in the history
…r - added onDispose callback param
  • Loading branch information
tsv2013 committed Aug 29, 2023
1 parent c3a45fb commit 73ba4ef
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/popup.ts
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,8 @@ export class PopupModel<T = any> extends Base {
onHide = () => { },
onShow = () => { },
cssClass: string = "",
title: string = ""
title: string = "",
private onDispose = () => { }
) {
super();
this.contentComponentName = contentComponentName;
Expand Down Expand Up @@ -111,6 +112,10 @@ export class PopupModel<T = any> extends Base {
this.onFooterActionsCreated.fire(this, options);
return options.actions;
}
public dispose(): void {
super.dispose();
this.onDispose();
}
}

export function createDialogOptions(
Expand Down

0 comments on commit 73ba4ef

Please sign in to comment.