diff options
Diffstat (limited to 'indra/llui')
-rw-r--r-- | indra/llui/llcombobox.cpp | 4 | ||||
-rw-r--r-- | indra/llui/llcombobox.h | 1 |
2 files changed, 5 insertions, 0 deletions
diff --git a/indra/llui/llcombobox.cpp b/indra/llui/llcombobox.cpp index 8b6a73af56..701d1ff706 100644 --- a/indra/llui/llcombobox.cpp +++ b/indra/llui/llcombobox.cpp @@ -231,6 +231,10 @@ void LLComboBox::resetDirty() } } +bool LLComboBox::itemExists(const std::string& name) +{ + return mList->getItemByLabel(name); +} // add item "name" to menu LLScrollListItem* LLComboBox::add(const std::string& name, EAddPosition pos, BOOL enabled) diff --git a/indra/llui/llcombobox.h b/indra/llui/llcombobox.h index 74d64269bd..59beba509c 100644 --- a/indra/llui/llcombobox.h +++ b/indra/llui/llcombobox.h @@ -134,6 +134,7 @@ public: LLScrollListItem* addSeparator(EAddPosition pos = ADD_BOTTOM); BOOL remove( S32 index ); // remove item by index, return TRUE if found and removed void removeall() { clearRows(); } + bool itemExists(const std::string& name); void sortByName(BOOL ascending = TRUE); // Sort the entries in the combobox by name |