summaryrefslogtreecommitdiff
path: root/indra/newview/llspeakbutton.cpp
diff options
context:
space:
mode:
authorMike Antipov <mantipov@productengine.com>2009-11-20 14:39:27 +0200
committerMike Antipov <mantipov@productengine.com>2009-11-20 14:39:27 +0200
commit91fdbd92c8e93e1676ba501bbc91ee56d38255c3 (patch)
tree3ae910c9c5401dfb9f65cb6e354221e375506fc3 /indra/newview/llspeakbutton.cpp
parent8dd743e783464f59b1d80763d8e2e8c52e048cb1 (diff)
Fixed normal bug EXT-2616 ("Speak" button isn't narrowed and has title when width of window is 800px)
- updated resize behavior to shrink Snapshot button: only speaker is shown in this case. - updated LLSpeakButton to hide/show its labels - updated talk_button widget (talk_button.xml) to have correct follows attributes - also fixed bug with calculating necessary updates for children while extending bottom tray --HG-- branch : product-engine
Diffstat (limited to 'indra/newview/llspeakbutton.cpp')
-rw-r--r--indra/newview/llspeakbutton.cpp21
1 files changed, 21 insertions, 0 deletions
diff --git a/indra/newview/llspeakbutton.cpp b/indra/newview/llspeakbutton.cpp
index 51d53b2674..54f776ca6a 100644
--- a/indra/newview/llspeakbutton.cpp
+++ b/indra/newview/llspeakbutton.cpp
@@ -143,6 +143,27 @@ void LLSpeakButton::setShowToolTip(const std::string& msg)
mShowBtn->setToolTip(msg);
}
+void LLSpeakButton::setLabelVisible(bool visible)
+{
+ static std::string label_selected = mSpeakBtn->getLabelSelected();
+ static std::string label_unselected = mSpeakBtn->getLabelUnselected();
+
+ if (visible)
+ {
+ mSpeakBtn->setLabelSelected(label_selected);
+ mSpeakBtn->setLabelUnselected(label_unselected);
+ }
+ else
+ {
+ static LLStringExplicit empty_string("");
+ mSpeakBtn->setLabelSelected(empty_string);
+ mSpeakBtn->setLabelUnselected(empty_string);
+ }
+}
+
+//////////////////////////////////////////////////////////////////////////
+/// PROTECTED SECTION
+//////////////////////////////////////////////////////////////////////////
void LLSpeakButton::onMouseDown_SpeakBtn()
{
bool down = true;