summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
authorSeth ProductEngine <slitovchuk@productengine.com>2012-06-08 01:09:00 +0300
committerSeth ProductEngine <slitovchuk@productengine.com>2012-06-08 01:09:00 +0300
commitf7f85dd0dda563a9fb49ed65b193a9ea98da9ba2 (patch)
treeed6b682c24142ce3adc036b023fda7710021585a /indra
parent9b92235291382deac15b860efa281f625d2173dd (diff)
CHUI-122 FIX Add button enabled only for P2P and ad hoc IM sessions.
Diffstat (limited to 'indra')
-rw-r--r--indra/newview/llimfloater.cpp7
-rw-r--r--indra/newview/skins/default/xui/en/floater_im_session.xml1
2 files changed, 7 insertions, 1 deletions
diff --git a/indra/newview/llimfloater.cpp b/indra/newview/llimfloater.cpp
index 6a510c4df1..dcd19b5856 100644
--- a/indra/newview/llimfloater.cpp
+++ b/indra/newview/llimfloater.cpp
@@ -311,7 +311,12 @@ BOOL LLIMFloater::postBuild()
mTypingStart = LLTrans::getString("IM_typing_start_string");
- childSetAction("add_btn", boost::bind(&LLIMFloater::onAddButtonClicked, this));
+ LLButton* add_btn = getChild<LLButton>("add_btn");
+
+ // Allow to add chat participants depending on the session type
+ add_btn->setEnabled(isInviteAllowed());
+ add_btn->setClickedCallback(boost::bind(&LLIMFloater::onAddButtonClicked, this));
+
childSetAction("voice_call_btn", boost::bind(&LLIMFloater::onCallButtonClicked, this));
LLVoiceClient::getInstance()->addObserver(this);
diff --git a/indra/newview/skins/default/xui/en/floater_im_session.xml b/indra/newview/skins/default/xui/en/floater_im_session.xml
index fc5b6b10af..21fc2d25d4 100644
--- a/indra/newview/skins/default/xui/en/floater_im_session.xml
+++ b/indra/newview/skins/default/xui/en/floater_im_session.xml
@@ -59,6 +59,7 @@
top="5"
width="31" />
<button
+ enabled="false"
follows="top|left"
height="25"
image_hover_unselected="Toolbar_Middle_Over"