App.Search.SearchPanel = Ext.extend(App.Search.SearchPanelUi, {
  nSearchPanels: 0,
	resultPagerSize: 15,

	// keep references to the criteria and results handler so that
	// the search function can access them
	searchCriteriaPanel: null,
	searchResultsPanel: null,
		
  initComponent: function() {
    App.Search.SearchPanel.superclass.initComponent.call(this);

    this.constructor.prototype.nSearchPanels++;
    this.searchPanelNo = this.constructor.prototype.nSearchPanels;
    this.title = 'Search ' + this.searchPanelNo;
  },

  // returns the query spec generated by its embedded SearchCriteriaPanel
  getQuerySpec: function() {
    return this.items.getAt(0).getQuerySpec();
  },

	// perform a search
	// used by search button handlers
	search: function(corpus, spec) {
		// reset the queryId before getting a new result
		this.searchResultsPanel.queryId = '0';
			
		var store = this.searchResultsPanel.getStore();

		store.setBaseParam('query', Ext.encode(spec));
		store.setBaseParam('corpus', corpus);
		store.setBaseParam('caseInsensitive', false);
		
		store.load({ params: {
			start: 0,
			limit: this.resultPagerSize
		}});
	}
});
Ext.reg("searchpanel", App.Search.SearchPanel);


@@ -259,18 +259,16 @@
 : null,%0A
-%09%09
 %0A  initC
@@ -286,24 +286,157 @@
 unction() %7B%0A
+    if(this.constructor.prototype.nSearchPanels %3E 0) %7B%0A      Ext.apply(this, Ext.apply(this.initialConfig, %7Bclosable: true%7D));%0A    %7D%0A
     App.Sear

Make Search Panels other than the first one closable