* Call the search engine, and get results or the percentage of indexed
* documents.
*/
private void loadSearchResults() {
try {
SearchProgressMonitor pm = SearchProgressMonitor
.getProgressMonitor(getLocale());
if (pm.isDone()) {
this.indexCompletion = 100;
SearchResults results = createHitCollector();
BaseHelpSystem.getSearchManager().search(createSearchQuery(),
results, pm);
hits = results.getSearchHits();
if (hits == null) {
HelpWebappPlugin
.logWarning("No search results returned. Help index is in use."); //$NON-NLS-1$
}
return;
}
// progress
indexCompletion = pm.getPercentage();
if (indexCompletion >= 100) {
// 38573 We do not have results, so index cannot be 100
indexCompletion = 100 - 1;
}
return;