summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--indra/newview/llbottomtray.cpp1
-rw-r--r--indra/newview/llspeakbutton.cpp9
-rw-r--r--indra/newview/llspeakbutton.h1
3 files changed, 10 insertions, 1 deletions
diff --git a/indra/newview/llbottomtray.cpp b/indra/newview/llbottomtray.cpp
index a17ba79078..e5cc2fce88 100644
--- a/indra/newview/llbottomtray.cpp
+++ b/indra/newview/llbottomtray.cpp
@@ -50,7 +50,6 @@ LLBottomTray::LLBottomTray(const LLSD&)
mSpeakBtn(NULL),
mNearbyChatBar(NULL),
mToolbarStack(NULL)
-
{
mFactoryMap["chat_bar"] = LLCallbackMap(LLBottomTray::createNearbyChatBar, NULL);
diff --git a/indra/newview/llspeakbutton.cpp b/indra/newview/llspeakbutton.cpp
index cd765b0338..312d7050b9 100644
--- a/indra/newview/llspeakbutton.cpp
+++ b/indra/newview/llspeakbutton.cpp
@@ -62,6 +62,15 @@ LLSpeakButton::Params::Params()
// See widgets/talk_button.xml
}
+void LLSpeakButton::draw()
+{
+ // gVoiceClient is the authoritative global source of info regarding our open-mic state, we merely reflect that state.
+ bool openmic = gVoiceClient->getUserPTTState();
+ mSpeakBtn->setToggleState(openmic);
+ llinfos << "mic state " << int(openmic) << llendl;
+ LLUICtrl::draw();
+}
+
LLSpeakButton::LLSpeakButton(const Params& p)
: LLUICtrl(p)
, mPrivateCallPanel(NULL)
diff --git a/indra/newview/llspeakbutton.h b/indra/newview/llspeakbutton.h
index f59ded2133..48a4d5880b 100644
--- a/indra/newview/llspeakbutton.h
+++ b/indra/newview/llspeakbutton.h
@@ -61,6 +61,7 @@ public:
};
/*virtual*/ ~LLSpeakButton();
+ /*virtual*/ void draw();
void setSpeakBtnToggleState(bool state);