import com.hughes.android.dictionary.DictionaryInfo.IndexInfo;
import com.hughes.android.dictionary.engine.RowBase.RowKey;
import com.hughes.util.CachingList;
-import com.hughes.util.CollectionUtil;
import com.hughes.util.TransformingList;
import com.hughes.util.raf.RAFList;
import com.hughes.util.raf.RAFSerializable;
if (!indexEntry.normalizedToken.startsWith(normalizedPrefix)) {
break;
}
- rowCount += indexEntry.numRows;
+ rowCount += indexEntry.numRows + indexEntry.htmlEntries.size();
if (rowCount > maxRows) {
System.out.println("Giving up, too many words with prefix: " + normalizedPrefix);
break;
final int exactMatchIndex = findInsertionPointIndex(searchText, interrupted);
if (exactMatchIndex != -1) {
final IndexEntry exactMatch = sortedIndexEntries.get(exactMatchIndex);
- if (pattern.matcher(exactMatch.token).matches()) {
+ if (pattern.matcher(exactMatch.token).find()) {
matches.get(RowMatchType.TITLE_MATCH).add(rows.get(exactMatch.startRow));
}
}
-
final String searchToken = bestPrefix;
final int insertionPointIndex = findInsertionPointIndex(searchToken, interrupted);