Skip to main content

Search and Top Navigation

#7587 closed bug (worksforme)

Opened July 29, 2011 09:50PM UTC

Closed August 01, 2011 01:57PM UTC

Binding an event in dialog.open function causes endless loop in IE8.0

Reported by: sydneyos Owned by:
Priority: minor Milestone: 1.9.0
Component: ui.dialog Version: 1.8.2
Keywords: Cc:
Blocked by: Blocking:
Description

The following code causes an endless loop such that the dialog in question appears to be repeatedly appended to the end of the page. The vertical scroll gets longer and longer, but if you scroll down fast enough, you can see the dialog flickering. The offending code is in bold. I do not get this in 1.4.2 but I do get it with 1.4.4 and 1.5.1 as well.

$(document).ready(
        function () {
            $("#modal-dialog").dialog({
                autoOpen: false,
                modal: true,
                width: 350,
                height: 235,
                closeOnEscape: false,
                draggable: false,
                resizable: false,
                open: function (event, ui) {
  '''                  $('#refresh').bind("keypress", function (e) {
                        if (e.keyCode == 13 && $(e.target).is(':input')) {
                            $('#btnRefreshLogon').click();
                        }
                    }'''
                    );
                },
                close: function (event, ui) { $('#refresh').unbind('keypress'); }
            });
        }
    );
Attachments (0)
Change History (1)

Changed August 01, 2011 01:57PM UTC by scottgonzalez comment:1

component: ui.coreui.dialog
resolution: → worksforme
status: newclosed