Test fix
This commit is contained in:
parent
fa77b30a13
commit
3485dc86c7
1 changed files with 13 additions and 8 deletions
|
@ -888,15 +888,20 @@ public class SearchUICore {
|
||||||
}
|
}
|
||||||
double s1 = o1.getSearchDistance(loc, 1);
|
double s1 = o1.getSearchDistance(loc, 1);
|
||||||
double s2 = o2.getSearchDistance(loc, 1);
|
double s2 = o2.getSearchDistance(loc, 1);
|
||||||
if (o1.parentSearchResult != null && o2.parentSearchResult != null) {
|
double ps1 = o1.parentSearchResult == null ? 0 : o1.parentSearchResult.getSearchDistance(loc);
|
||||||
if (o1.parentSearchResult == o2.parentSearchResult) {
|
double ps2 = o2.parentSearchResult == null ? 0 : o2.parentSearchResult.getSearchDistance(loc);
|
||||||
int cmp = collator.compare(localeName1, localeName2);
|
if (ps1 != ps2) {
|
||||||
if (cmp != 0) {
|
return Double.compare(ps1, ps2);
|
||||||
return cmp;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return Double.compare(s1, s2);
|
|
||||||
}
|
}
|
||||||
|
// if (o1.parentSearchResult != null && o2.parentSearchResult != null) {
|
||||||
|
// if (o1.parentSearchResult == o2.parentSearchResult) {
|
||||||
|
// int cmp = collator.compare(localeName1, localeName2);
|
||||||
|
// if (cmp != 0) {
|
||||||
|
// return cmp;
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// return Double.compare(s1, s2);
|
||||||
|
// }
|
||||||
int cmp = collator.compare(localeName1, localeName2);
|
int cmp = collator.compare(localeName1, localeName2);
|
||||||
if (cmp != 0) {
|
if (cmp != 0) {
|
||||||
return cmp;
|
return cmp;
|
||||||
|
|
Loading…
Reference in a new issue