summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--doc/contributions.txt2
-rwxr-xr-xindra/newview/llfloaterworldmap.cpp19
2 files changed, 15 insertions, 6 deletions
diff --git a/doc/contributions.txt b/doc/contributions.txt
index daaffe2dee..96630b1995 100644
--- a/doc/contributions.txt
+++ b/doc/contributions.txt
@@ -158,6 +158,7 @@ Ann Congrejo
CT-193
Ansariel Hiller
STORM-1101
+ VWR-25480
Ardy Lay
STORM-859
VWR-19499
@@ -442,6 +443,7 @@ Jonathan Yap
STORM-1095
STORM-1236
STORM-1259
+ VWR-25480
Kage Pixel
VWR-11
Ken March
diff --git a/indra/newview/llfloaterworldmap.cpp b/indra/newview/llfloaterworldmap.cpp
index f8a4ce7ad0..b3910982d1 100755
--- a/indra/newview/llfloaterworldmap.cpp
+++ b/indra/newview/llfloaterworldmap.cpp
@@ -1527,17 +1527,24 @@ void LLFloaterWorldMap::updateSims(bool found_null_sim)
mCompletingRegionName = "";
}
- // if match found, highlight it and go
- if (!match.isUndefined())
+ if (num_results > 0)
{
- list->selectByValue(match);
+ // if match found, highlight it and go
+ if (!match.isUndefined())
+ {
+ list->selectByValue(match);
+ }
+ // else select first found item
+ else
+ {
+ list->selectFirstItem();
+ }
getChild<LLUICtrl>("search_results")->setFocus(TRUE);
onCommitSearchResult();
}
-
- // if we found nothing, say "none"
- if (num_results == 0)
+ else
{
+ // if we found nothing, say "none"
list->setCommentText(LLTrans::getString("worldmap_results_none_found"));
list->operateOnAll(LLCtrlListInterface::OP_DESELECT);
}