summaryrefslogtreecommitdiff
path: root/indra/newview/llpanelvolumepulldown.cpp
diff options
context:
space:
mode:
authorAndrey Kleshchev <andreykproductengine@lindenlab.com>2020-05-18 23:29:31 +0300
committerAndrey Kleshchev <andreykproductengine@lindenlab.com>2020-05-18 23:29:31 +0300
commitd23e6491691be7f1937b78910e7c20b7741a890c (patch)
tree103292a54ca089d9a0ad9a653ffc53ddee1407f4 /indra/newview/llpanelvolumepulldown.cpp
parent53da10525ed0e7b2dc78d40ad20313d98310d1cf (diff)
parented3d9abdd01304b5a9708880d9b150fb6568256b (diff)
Merged master into DRTVWR-508
Diffstat (limited to 'indra/newview/llpanelvolumepulldown.cpp')
-rw-r--r--indra/newview/llpanelvolumepulldown.cpp58
1 files changed, 1 insertions, 57 deletions
diff --git a/indra/newview/llpanelvolumepulldown.cpp b/indra/newview/llpanelvolumepulldown.cpp
index f063d84272..6f11e76a72 100644
--- a/indra/newview/llpanelvolumepulldown.cpp
+++ b/indra/newview/llpanelvolumepulldown.cpp
@@ -41,9 +41,6 @@
#include "llfloaterpreference.h"
#include "llsliderctrl.h"
-/* static */ const F32 LLPanelVolumePulldown::sAutoCloseFadeStartTimeSec = 2.0f;
-/* static */ const F32 LLPanelVolumePulldown::sAutoCloseTotalTimeSec = 3.0f;
-
///----------------------------------------------------------------------------
/// Class LLPanelVolumePulldown
///----------------------------------------------------------------------------
@@ -51,8 +48,6 @@
// Default constructor
LLPanelVolumePulldown::LLPanelVolumePulldown()
{
- mHoverTimer.stop();
-
mCommitCallbackRegistrar.add("Vol.setControlFalse", boost::bind(&LLPanelVolumePulldown::setControlFalse, this, _2));
mCommitCallbackRegistrar.add("Vol.SetSounds", boost::bind(&LLPanelVolumePulldown::onClickSetSounds, this));
mCommitCallbackRegistrar.add("Vol.updateMediaAutoPlayCheckbox", boost::bind(&LLPanelVolumePulldown::updateMediaAutoPlayCheckbox, this, _1));
@@ -62,41 +57,7 @@ LLPanelVolumePulldown::LLPanelVolumePulldown()
BOOL LLPanelVolumePulldown::postBuild()
{
- return LLPanel::postBuild();
-}
-
-/*virtual*/
-void LLPanelVolumePulldown::onMouseEnter(S32 x, S32 y, MASK mask)
-{
- mHoverTimer.stop();
- LLPanel::onMouseEnter(x,y,mask);
-}
-
-/*virtual*/
-void LLPanelVolumePulldown::onTopLost()
-{
- setVisible(FALSE);
-}
-
-/*virtual*/
-void LLPanelVolumePulldown::onMouseLeave(S32 x, S32 y, MASK mask)
-{
- mHoverTimer.start();
- LLPanel::onMouseLeave(x,y,mask);
-}
-
-/*virtual*/
-void LLPanelVolumePulldown::onVisibilityChange ( BOOL new_visibility )
-{
- if (new_visibility)
- {
- mHoverTimer.start(); // timer will be stopped when mouse hovers over panel
- }
- else
- {
- mHoverTimer.stop();
-
- }
+ return LLPanelPulldown::postBuild();
}
void LLPanelVolumePulldown::onAdvancedButtonClick(const LLSD& user_data)
@@ -150,20 +111,3 @@ void LLPanelVolumePulldown::onClickSetSounds()
// or if sound effects are disabled.
getChild<LLCheckBoxCtrl>("gesture_audio_play_btn")->setEnabled(!gSavedSettings.getBOOL("MuteSounds"));
}
-
-//virtual
-void LLPanelVolumePulldown::draw()
-{
- F32 alpha = mHoverTimer.getStarted()
- ? clamp_rescale(mHoverTimer.getElapsedTimeF32(), sAutoCloseFadeStartTimeSec, sAutoCloseTotalTimeSec, 1.f, 0.f)
- : 1.0f;
- LLViewDrawContext context(alpha);
-
- LLPanel::draw();
-
- if (alpha == 0.f)
- {
- setVisible(FALSE);
- }
-}
-