summaryrefslogtreecommitdiff
path: root/indra/newview/llviewercontrol.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/llviewercontrol.cpp')
-rw-r--r--indra/newview/llviewercontrol.cpp15
1 files changed, 10 insertions, 5 deletions
diff --git a/indra/newview/llviewercontrol.cpp b/indra/newview/llviewercontrol.cpp
index 2c487665d2..eb8cdd82b3 100644
--- a/indra/newview/llviewercontrol.cpp
+++ b/indra/newview/llviewercontrol.cpp
@@ -63,6 +63,7 @@
#include "llviewerparcelmgr.h"
#include "llparcel.h"
#include "llnotify.h"
+#include "lloverlaybar.h"
#include "llkeyboard.h"
#include "llerrorcontrol.h"
#include "llversionviewer.h"
@@ -269,17 +270,21 @@ static bool handleAudioStreamMusicChanged(const LLSD& newvalue)
if (LLViewerParcelMgr::getInstance()->getAgentParcel()
&& !LLViewerParcelMgr::getInstance()->getAgentParcel()->getMusicURL().empty())
{
- // if stream is already playing, don't call this
- // otherwise music will briefly stop
- if ( !gAudiop->isInternetStreamPlaying() )
+ // if music isn't playing, start it
+ if (gOverlayBar && !gOverlayBar->musicPlaying())
{
- gAudiop->startInternetStream(LLViewerParcelMgr::getInstance()->getAgentParcel()->getMusicURL());
+ LLOverlayBar::toggleMusicPlay(NULL);
}
}
}
else
{
- gAudiop->stopInternetStream();
+ // if music is playing, stop it.
+ if (gOverlayBar && gOverlayBar->musicPlaying())
+ {
+ LLOverlayBar::toggleMusicPlay(NULL);
+ }
+
}
}
return true;