Commit 1df8a69f authored by Prakhar Agarwal's avatar Prakhar Agarwal 🎯
Browse files

Fixed dialog not removing from DOM

parent 28a1bc84
......@@ -36,7 +36,7 @@
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title" id="dialog-title"></h5>
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
<button type="button" class="close" onClick="cancel()" aria-label="Close">
<span aria-hidden="true">&times;</span>
</button>
</div>
......
......@@ -613,7 +613,6 @@ function cancel() {
var i, attrs, gfxstub;
//window.close(true);
if(pdgui.is_webapp()){
remove_dialog(pd_object_callback)
$("#dialog-modal").modal("hide");
}
......@@ -804,6 +803,12 @@ function add_events(name) {
});
}
pdgui.dialog_bindings(name);
if (pdgui.is_webapp) {
$("#dialog-modal").on("hidden.bs.modal", function (e) {
remove_dialog(pd_object_callback)
$("#dialog-modal").off("hidden.bs.modal")
})
}
}
</script>
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment