title: Input fields of jquery dialog box freezes
body: <p>I have a dialog box with a button and checkbox on it. On open function of dialog box i have following code:</p>
  
  <pre><code>$('#dialog1').dialog({
      modal: true,
      open: function (event, ui) {
          $('#dialog1').parent('.ui-dialog').css('zIndex', 26)
              .nextAll('.ui-widget-overlay').css('zIndex', 25);
      }
  });
  </code></pre>
  
  <p>Now after I click a button in the dialog, a new dialog opens:</p>
  
  <pre><code>$('#dialog2').dialog({
      modal: true,
      open: function (event, ui) {
          $('#dialog2').parent('.ui-dialog').css('zIndex', 27)
              .nextAll('.ui-widget-overlay').css('zIndex', 25);
      }
  });
  </code></pre>
  
  <p>And after the click on "close" icon of dialog2 following event is triggered:</p>
  
  <pre><code>   $('dialog2').on('dialogclose', function(event) {
                $('#dialog1').close();
                $('div').remove('#dialog2');
           });
  </code></pre>
  
  <p>The problem is after the above event, the input fields of dialog1 freezes and is not clickable. I checked the z-index but found it right. Can somebody help why the input fields are not clikable.</p>