diff options
author | Merov Linden <merov@lindenlab.com> | 2010-12-13 14:36:34 -0800 |
---|---|---|
committer | Merov Linden <merov@lindenlab.com> | 2010-12-13 14:36:34 -0800 |
commit | 8acb521a824f4c1ce84379f225fa84b5cc681f5b (patch) | |
tree | 39adce2dd48ff9aaa3de110df994d31a2fdbe8e5 /indra | |
parent | 1fb47692ffe78a2981d45cd1500306fdc850e6c9 (diff) | |
parent | 18a18f5985c76adaed040b4bdcba15cc251dbeb5 (diff) |
STORM-693 : pull into viewer-development
Diffstat (limited to 'indra')
-rw-r--r-- | indra/newview/llscrollingpanelparam.cpp | 8 | ||||
-rw-r--r-- | indra/newview/lltoolmorph.cpp | 4 | ||||
-rw-r--r-- | indra/newview/lltoolmorph.h | 2 |
3 files changed, 9 insertions, 5 deletions
diff --git a/indra/newview/llscrollingpanelparam.cpp b/indra/newview/llscrollingpanelparam.cpp index 05b273cd29..f8c20dada0 100644 --- a/indra/newview/llscrollingpanelparam.cpp +++ b/indra/newview/llscrollingpanelparam.cpp @@ -165,12 +165,16 @@ void LLScrollingPanelParam::draw() getChildView("max param text")->setVisible( FALSE ); LLPanel::draw(); + // If we're in a focused floater, don't apply the floater's alpha to visual param hint, + // making its behavior similar to texture controls'. + F32 alpha = getTransparencyType() == TT_ACTIVE ? 1.0f : getCurrentTransparency(); + // Draw the hints over the "less" and "more" buttons. gGL.pushUIMatrix(); { const LLRect& r = mHintMin->getRect(); gGL.translateUI((F32)r.mLeft, (F32)r.mBottom, 0.f); - mHintMin->draw(); + mHintMin->draw(alpha); } gGL.popUIMatrix(); @@ -178,7 +182,7 @@ void LLScrollingPanelParam::draw() { const LLRect& r = mHintMax->getRect(); gGL.translateUI((F32)r.mLeft, (F32)r.mBottom, 0.f); - mHintMax->draw(); + mHintMax->draw(alpha); } gGL.popUIMatrix(); diff --git a/indra/newview/lltoolmorph.cpp b/indra/newview/lltoolmorph.cpp index ca80a1db79..964b17d3a6 100644 --- a/indra/newview/lltoolmorph.cpp +++ b/indra/newview/lltoolmorph.cpp @@ -244,13 +244,13 @@ BOOL LLVisualParamHint::render() //----------------------------------------------------------------------------- // draw() //----------------------------------------------------------------------------- -void LLVisualParamHint::draw() +void LLVisualParamHint::draw(F32 alpha) { if (!mIsVisible) return; gGL.getTexUnit(0)->bind(this); - gGL.color4f(1.f, 1.f, 1.f, 1.f); + gGL.color4f(1.f, 1.f, 1.f, alpha); LLGLSUIDefault gls_ui; gGL.begin(LLRender::QUADS); diff --git a/indra/newview/lltoolmorph.h b/indra/newview/lltoolmorph.h index 59201233ae..a6889be151 100644 --- a/indra/newview/lltoolmorph.h +++ b/indra/newview/lltoolmorph.h @@ -68,7 +68,7 @@ public: BOOL render(); void requestUpdate( S32 delay_frames ) {mNeedsUpdate = TRUE; mDelayFrames = delay_frames; } void setUpdateDelayFrames( S32 delay_frames ) { mDelayFrames = delay_frames; } - void draw(); + void draw(F32 alpha); LLViewerVisualParam* getVisualParam() { return mVisualParam; } F32 getVisualParamWeight() { return mVisualParamWeight; } |