summaryrefslogtreecommitdiff
path: root/indra/newview/llconversationview.cpp
diff options
context:
space:
mode:
authorMerov Linden <merov@lindenlab.com>2012-11-15 18:07:57 -0800
committerMerov Linden <merov@lindenlab.com>2012-11-15 18:07:57 -0800
commitec5d1e48c4071500400b885e5893373bab0e3d99 (patch)
tree25d879b78fd415ec5271f1948f49718c4cdd072a /indra/newview/llconversationview.cpp
parentbd62d1d33717536e71f5fbb5ab4a477a69494c77 (diff)
CHUI-479 : WIP : Introduce a publicly available LLSpeakingIndicatorManager::updateSpeakingIndicators() method so to reset all indicators when creating new dialogs.
Diffstat (limited to 'indra/newview/llconversationview.cpp')
-rwxr-xr-xindra/newview/llconversationview.cpp25
1 files changed, 12 insertions, 13 deletions
diff --git a/indra/newview/llconversationview.cpp b/indra/newview/llconversationview.cpp
index cc7a76e353..d971c943f0 100755
--- a/indra/newview/llconversationview.cpp
+++ b/indra/newview/llconversationview.cpp
@@ -307,7 +307,9 @@ void LLConversationViewSession::refresh()
mSessionTitle->setText(vmi->getDisplayName());
}
- // Note: for the moment, all that needs to be done is done by LLFolderViewItem::refresh()
+ // Update all speaking indicators
+ llinfos << "Merov debug : LLConversationViewSession::refresh, updateSpeakingIndicators" << llendl;
+ LLSpeakingIndicatorManager::updateSpeakingIndicators();
// Do the regular upstream refresh
LLFolderViewFolder::refresh();
@@ -327,7 +329,6 @@ void LLConversationViewSession::onCurrentVoiceSessionChanged(const LLUUID& sessi
mSpeakingIndicator->setSpeakerId(is_active ? gAgentID : LLUUID::null);
}
- llinfos << "Merov debug : onCurrentVoiceSessionChanged, switchIndicator is_active = " << is_active << llendl;
mSpeakingIndicator->switchIndicator(is_active);
mCallIconLayoutPanel->setVisible(is_active);
}
@@ -456,34 +457,32 @@ void LLConversationViewParticipant::onCurrentVoiceSessionChanged(const LLUUID& s
{
llinfos << "Merov debug : onCurrentVoiceSessionChanged begin, uuid = " << mUUID << ", session_id = " << session_id << llendl;
LLConversationItemParticipant* participant_model = dynamic_cast<LLConversationItemParticipant*>(getViewModelItem());
- //llinfos << "Merov debug : onCurrentVoiceSessionChanged participant_model = " << participant_model << llendl;
if (participant_model)
{
- //llinfos << "Merov debug : onCurrentVoiceSessionChanged enter if 1" << llendl;
LLConversationItemSession* parent_session = participant_model->getParentSession();
- //llinfos << "Merov debug : onCurrentVoiceSessionChanged parent_session = " << parent_session << llendl;
if (parent_session)
{
- //llinfos << "Merov debug : onCurrentVoiceSessionChanged enter if 2" << llendl;
bool is_active = (parent_session->getUUID() == session_id);
- //llinfos << "Merov debug : onCurrentVoiceSessionChanged, is_active = " << is_active << llendl;
mSpeakingIndicator->switchIndicator(is_active);
- //llinfos << "Merov debug : onCurrentVoiceSessionChanged switchIndicator done" << llendl;
}
}
- //llinfos << "Merov debug : onCurrentVoiceSessionChanged end" << llendl;
}
void LLConversationViewParticipant::refresh()
{
// Refresh the participant view from its model data
- LLConversationItemParticipant* vmi = dynamic_cast<LLConversationItemParticipant*>(getViewModelItem());
- vmi->resetRefresh();
+ LLConversationItemParticipant* participant_model = dynamic_cast<LLConversationItemParticipant*>(getViewModelItem());
+ participant_model->resetRefresh();
// *TODO: We should also do something with vmi->isModerator() to echo that state in the UI somewhat
- mSpeakingIndicator->setIsMuted(vmi->isMuted());
- //mSpeakingIndicator->switchIndicator(true);
+ mSpeakingIndicator->setIsMuted(participant_model->isMuted());
+ //LLConversationItemSession* parent_session = participant_model->getParentSession();
+ //if (parent_session)
+ //{
+ // bool is_active = (parent_session->getUUID() == session_id);
+ // mSpeakingIndicator->switchIndicator(is_active);
+ //}
// Do the regular upstream refresh
LLFolderViewItem::refresh();