summaryrefslogtreecommitdiff
path: root/indra/llui/llmultislider.cpp
diff options
context:
space:
mode:
authorandreykproductengine <andreykproductengine@lindenlab.com>2018-12-07 17:10:05 +0200
committerandreykproductengine <andreykproductengine@lindenlab.com>2018-12-07 17:10:05 +0200
commit6762c4515a9b0f98164d6efd191abec5ca4dd211 (patch)
tree8f6f88ec54a3e09babb65c263dff1b53e2960051 /indra/llui/llmultislider.cpp
parentd4fe87cca49162c978b4eacde880431977624874 (diff)
SL-1894 When crossing regions altitude slider could misbehave
Diffstat (limited to 'indra/llui/llmultislider.cpp')
-rw-r--r--indra/llui/llmultislider.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/indra/llui/llmultislider.cpp b/indra/llui/llmultislider.cpp
index 9a7b6f9f6b..ed93b3d44c 100644
--- a/indra/llui/llmultislider.cpp
+++ b/indra/llui/llmultislider.cpp
@@ -354,17 +354,17 @@ const std::string& LLMultiSlider::addSlider(F32 val)
return mCurSlider;
}
-void LLMultiSlider::addSlider(F32 val, const std::string& name)
+bool LLMultiSlider::addSlider(F32 val, const std::string& name)
{
F32 initVal = val;
if(mValue.size() >= mMaxNumSliders) {
- return;
+ return false;
}
bool foundOne = findUnusedValue(initVal);
if(!foundOne) {
- return;
+ return false;
}
// add a new thumb rect
@@ -383,6 +383,8 @@ void LLMultiSlider::addSlider(F32 val, const std::string& name)
// move the slider
setSliderValue(mCurSlider, initVal, TRUE);
+
+ return true;
}
bool LLMultiSlider::findUnusedValue(F32& initVal)