summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRichard Nelson <richard@lindenlab.com>2009-08-18 18:46:43 +0000
committerRichard Nelson <richard@lindenlab.com>2009-08-18 18:46:43 +0000
commita7adfe132e241e516c37cb216a89597cedb8ac76 (patch)
treed79c6c55b6802cda8a866cfe25f2ba2b8ae7f29e
parent75834b6490539fff3c1b713b833c7f03ffc3e083 (diff)
DEV-38131 "Drop down boxes with text entry ignore the text in the entry field"
reviewed by James
-rw-r--r--indra/llui/llcombobox.cpp21
1 files changed, 12 insertions, 9 deletions
diff --git a/indra/llui/llcombobox.cpp b/indra/llui/llcombobox.cpp
index 93d2b83c9f..b3c3a2e698 100644
--- a/indra/llui/llcombobox.cpp
+++ b/indra/llui/llcombobox.cpp
@@ -614,17 +614,20 @@ void LLComboBox::showList()
void LLComboBox::hideList()
{
- // assert selection in list
- mList->selectNthItem(mLastSelectedIndex);
+ if (mList->getVisible())
+ {
+ // assert selection in list
+ mList->selectNthItem(mLastSelectedIndex);
- mButton->setToggleState(FALSE);
- mList->setVisible(FALSE);
- mList->mouseOverHighlightNthItem(-1);
+ mButton->setToggleState(FALSE);
+ mList->setVisible(FALSE);
+ mList->mouseOverHighlightNthItem(-1);
- setUseBoundingRect(FALSE);
- if( gFocusMgr.getTopCtrl() == this )
- {
- gFocusMgr.setTopCtrl(NULL);
+ setUseBoundingRect(FALSE);
+ if( gFocusMgr.getTopCtrl() == this )
+ {
+ gFocusMgr.setTopCtrl(NULL);
+ }
}
}