Move search to background thread

Once the first result is found and used, remaining search time is done
on a background thread. The search order has also been changed to
optimize search result time. Once all the searches are complete, the
status bar will show the number of search results.