title: Extjs window waiting dialog closing problem
body: <p>Dear Friends.i am facing a problem upon closing my window.I calling an ajax call like this</p>
  
  <pre><code>function callPreviewWindow(){   
      $.ajax( {
      type : "GET",
      url : "/ajax/eform/preview.do",
      cache : false,
      dataType : "text/html",
      timeout: 40000,
                beforeSend : function() {
          showWaitingDialog("Please wait...");
      },
  
      error: function (xhr, err)
      {
          resolveAjaxError(xhr, err);
      },
      success : function(data) {  
           showPreviewWindow(data);
  
      }
   });    
  </code></pre>
  
  <p>}</p>
  
  <p>But this ajax call execution taking more time so increased timeout to 40000. and it is working fine and displaying the following window.</p>
  
  <pre><code>function showPreviewWindow(htmlData){
  var previewWindow =  new Ext.Window({
          title: "E-Form View",  
          width:650,
          id:'previewWindow',
          autoHeight: true,
          html: htmlData,
          modal: true,
          y: 150,
          listeners: { 
          beforeclose: function () { 
              searchVisible = false;                      
            } 
          },
        buttons: [
                   { 
                       text: 'Close', handler: function() {
                        previewWindow.close();                                            
                       }
                   }
                  ]
   });
  
  previewWindow.show(this);               
  </code></pre>
  
  <p>}</p>
  
  <p>But the problem is when click on the close Button, I can able to close the window. But the showWaitingDialog ( which i called on before send event in the ajax call function) is not closing.</p>
  
  <p>Please help me to close this also on close button click.</p>
  
  <p>Thanks in advance.
  Sathya</p>