title: EXT JS close pop up window
body: <p>I have a pop up window without close button, so I have to refresh the page in order to close the pop up window. In this case, I wanna to add an button on the pop up window for closing. </p>
  
  <p>Here is the js code: </p>
  
  <pre><code>function oseGetWIn(id, title, width, height)
  {
      var win = Ext.create('Ext.window.Window', {
          id: id,
          name: id,
          title: title,
          width: width,
          height: height,
          closeAction:'destroy',
          autoScroll:'true',
  
      }); 
      return win; 
  }
  </code></pre>
  
  <p>I tried to add the following, but no effect.</p>
  
  <pre><code>bbar: [
          {
            text: 'Close',
            handler: function () { this.up('.window').close(); }
           }
        ],
  </code></pre>