public SearchThread(SearchForm form, IPackage pkg, Predicate<IResourceIndexEntry> match, byte[] pattern, AddCallBack addCB, updateProgressCallback updateProgressCB, stopSearchCallback stopSearchCB, searchCompleteCallback searchCompleteCB) { this.form = form; this.pkg = pkg; this.match = match; this.pattern = (byte[])pattern.Clone(); this.addCB = addCB; this.updateProgressCB = updateProgressCB; this.stopSearchCB = stopSearchCB; this.searchCompleteCB = searchCompleteCB; }
void SearchForm_SearchComplete(object sender, SearchForm.BoolEventArgs e) { searching = false; while (searchThread != null && searchThread.IsAlive) searchThread.Join(100); searchThread = null; this.toolStripProgressBar1.Visible = false; this.toolStripStatusLabel1.Visible = false; tbHex.Enabled = true; btnSearch.Text = "&Search"; }