summaryrefslogtreecommitdiff
path: root/indra/llui/lllayoutstack.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/llui/lllayoutstack.cpp')
-rw-r--r--indra/llui/lllayoutstack.cpp14
1 files changed, 9 insertions, 5 deletions
diff --git a/indra/llui/lllayoutstack.cpp b/indra/llui/lllayoutstack.cpp
index 4c730286da..32383b1f1d 100644
--- a/indra/llui/lllayoutstack.cpp
+++ b/indra/llui/lllayoutstack.cpp
@@ -229,7 +229,10 @@ LLLayoutStack::LLLayoutStack(const LLLayoutStack::Params& p)
mOpenTimeConstant(p.open_time_constant),
mCloseTimeConstant(p.close_time_constant),
mResizeBarOverlap(p.resize_bar_overlap)
-{}
+{
+ LLCriticalDamp::setInterpolantConstant(InterpDeltaCloseTime, mCloseTimeConstant);
+ LLCriticalDamp::setInterpolantConstant(InterpDeltaOpenTime, mOpenTimeConstant);
+}
LLLayoutStack::~LLLayoutStack()
{
@@ -478,7 +481,7 @@ void LLLayoutStack::createResizeBar(LLLayoutPanel* panelp)
{
LLResizeBar::Side side = (mOrientation == HORIZONTAL) ? LLResizeBar::RIGHT : LLResizeBar::BOTTOM;
LLRect resize_bar_rect = getRect();
-
+ (void)resize_bar_rect;
LLResizeBar::Params resize_params;
resize_params.name("resize");
resize_params.resizing_view(lp);
@@ -592,7 +595,7 @@ bool LLLayoutStack::animatePanels()
{
if (!mAnimatedThisFrame)
{
- panelp->mVisibleAmt = lerp(panelp->mVisibleAmt, 1.f, LLCriticalDamp::getInterpolant(mOpenTimeConstant));
+ panelp->mVisibleAmt = lerp(panelp->mVisibleAmt, 1.f, LLCriticalDamp::getInterpolant(InterpDeltaOpenTime));
if (panelp->mVisibleAmt > 0.99f)
{
panelp->mVisibleAmt = 1.f;
@@ -617,7 +620,7 @@ bool LLLayoutStack::animatePanels()
{
if (!mAnimatedThisFrame)
{
- panelp->mVisibleAmt = lerp(panelp->mVisibleAmt, 0.f, LLCriticalDamp::getInterpolant(mCloseTimeConstant));
+ panelp->mVisibleAmt = lerp(panelp->mVisibleAmt, 0.f, LLCriticalDamp::getInterpolant(InterpDeltaCloseTime));
if (panelp->mVisibleAmt < 0.001f)
{
panelp->mVisibleAmt = 0.f;
@@ -644,7 +647,7 @@ bool LLLayoutStack::animatePanels()
{
if (!mAnimatedThisFrame)
{
- panelp->mCollapseAmt = lerp(panelp->mCollapseAmt, collapse_state, LLCriticalDamp::getInterpolant(mCloseTimeConstant));
+ panelp->mCollapseAmt = lerp(panelp->mCollapseAmt, collapse_state, LLCriticalDamp::getInterpolant(InterpDeltaCloseTime));
}
if (llabs(panelp->mCollapseAmt - collapse_state) < 0.001f)
@@ -855,3 +858,4 @@ void LLLayoutStack::updateResizeBarLimits()
previous_visible_panelp = visible_panelp;
}
}
+