From ac9312d6f7aee8db09e4128d569ab8864b6ebe5a Mon Sep 17 00:00:00 2001 From: Jon Atkins Date: Sat, 18 May 2013 18:02:13 +0100 Subject: [PATCH] destroy and remove dialogs after they're closed - otherwise they remain in the DOM, hidden but there fix #288 --- code/dialog.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/code/dialog.js b/code/dialog.js index 58e8e443..81c196d5 100644 --- a/code/dialog.js +++ b/code/dialog.js @@ -167,6 +167,9 @@ window.dialog = function(options) { window.DIALOG_COUNT--; console.log('window.dialog: ' + $(this).data('id') + ' (' + $(this).dialog('option', 'title') + ') closed. ' + window.DIALOG_COUNT + ' remain.'); + + // remove from DOM and destroy + $(this).dialog('destroy').remove(); }, focus: function() { if($(this).data('focusCallback')) {