use the last pattern when several available

For some reason, in Spanish but not Catalan, filtering doesn't work with
two-letter tiles. The reason is that e.g. with RR two patterns, R.R and
RR (i.e. two R tiles, or one RR tile), are returned. The first shouldn't
be there since there are no words with RR that are spelled with two R
tiles. Until I can fix this picking the second (last) pattern seems to
work better.
This commit is contained in:
Eric House 2020-12-20 21:19:51 -08:00
parent 15c5f18e7e
commit 9929feecdc

View file

@ -596,7 +596,7 @@ public class DictBrowseDelegate extends DelegateBase
pending = true;
} else if ( 1 == choices.length
|| !XwJNI.dict_hasDuplicates( m_dict ) ) {
pats[ii].tilePat = choices[0];
pats[ii].tilePat = choices[choices.length - 1];
} else {
m_browseState.m_delim = DELIM;
showDialogFragment( DlgID.CHOOSE_TILES, (Object)choices, ii );