From 67b1db14c964418ce8b1fd760d54761040cc32af Mon Sep 17 00:00:00 2001 From: Scott González Date: Mon, 4 Oct 2010 09:15:40 -0400 Subject: Dialog: Don't change DOM position on open. Fixes #6137 - dialog('open') causes form elements to reset on IE7. --- tests/unit/dialog/dialog_tickets.js | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) (limited to 'tests') diff --git a/tests/unit/dialog/dialog_tickets.js b/tests/unit/dialog/dialog_tickets.js index dfa480fb7..f7b590b53 100644 --- a/tests/unit/dialog/dialog_tickets.js +++ b/tests/unit/dialog/dialog_tickets.js @@ -61,4 +61,21 @@ test("#5531: dialog width should be at least minWidth on creation", function () }); +test("#6137: dialog('open') causes form elements to reset on IE7", function() { + expect(2); + + d1 = $('
' + + 'b
').dialog({autoOpen: false}); + + d1.find('#b')[0].checked = true; + equal($('input:checked').val(), 'b', "checkbox b is checked"); + + d2 = $('
').dialog({autoOpen: false}); + + d1.dialog('open'); + equal($('input:checked').val(), 'b', "checkbox b is checked"); + + d1.add(d2).remove(); +}) + })(jQuery); -- cgit v1.2.3