summaryrefslogtreecommitdiff
path: root/indra/newview/llimview.cpp
diff options
context:
space:
mode:
authorRoxie Linden <roxie@lindenlab.com>2010-02-24 17:04:48 -0800
committerRoxie Linden <roxie@lindenlab.com>2010-02-24 17:04:48 -0800
commit6bb43e1369d957a041c796120e87a89ff3fa10ee (patch)
tree678e25f3b62ab90e2940dfcae5feafa1acaa8ffc /indra/newview/llimview.cpp
parentff52ac089f9ed67410f80fe66d0b997f0f2dafcc (diff)
parentfc633fce71c6bdd43ab009558c7556f528335fe0 (diff)
Automated merge up from viewer 2.0 trunk.
Some llvoiceclient changes duplicated changes that had already been made in the voice modularization refactor, so the refactor versions were used.
Diffstat (limited to 'indra/newview/llimview.cpp')
-rw-r--r--indra/newview/llimview.cpp19
1 files changed, 13 insertions, 6 deletions
diff --git a/indra/newview/llimview.cpp b/indra/newview/llimview.cpp
index 15e657c866..d615d01bb1 100644
--- a/indra/newview/llimview.cpp
+++ b/indra/newview/llimview.cpp
@@ -382,10 +382,6 @@ void LLIMModel::LLIMSession::addMessage(const std::string& from, const LLUUID& f
mSpeakers->speakerChatted(from_id);
mSpeakers->setSpeakerTyping(from_id, FALSE);
}
-
- if( mSessionType == P2P_SESSION ||
- mSessionType == ADHOC_SESSION)
- LLRecentPeople::instance().add(from_id);
}
void LLIMModel::LLIMSession::addMessagesFromHistory(const std::list<LLSD>& history)
@@ -684,6 +680,12 @@ bool LLIMModel::addMessage(const LLUUID& session_id, const std::string& from, co
LLIMSession* session = addMessageSilently(session_id, from, from_id, utf8_text, log2file);
if (!session) return false;
+ //good place to add some1 to recent list
+ //other places may be called from message history.
+ if( !from_id.isNull() &&
+ ( session->isP2PSessionType() || session->isAdHocSessionType() ) )
+ LLRecentPeople::instance().add(from_id);
+
// notify listeners
LLSD arg;
arg["session_id"] = session_id;
@@ -1377,7 +1379,7 @@ void LLCallDialogManager::onVoiceChannelChanged(const LLUUID &session_id)
}
sSession = session;
- sSession->mVoiceChannel->setStateChangedCallback(LLCallDialogManager::onVoiceChannelStateChanged);
+ sSession->mVoiceChannel->setStateChangedCallback(boost::bind(LLCallDialogManager::onVoiceChannelStateChanged, _1, _2, _3));
if(sCurrentSessionlName != session->mName)
{
sPreviousSessionlName = sCurrentSessionlName;
@@ -1601,7 +1603,12 @@ void LLOutgoingCallDialog::show(const LLSD& key)
if (!mPayload["disconnected_channel_name"].asString().empty())
{
- childSetTextArg("nearby", "[VOICE_CHANNEL_NAME]", mPayload["disconnected_channel_name"].asString());
+ std::string channel_name = mPayload["disconnected_channel_name"].asString();
+ if (LLIMModel::LLIMSession::AVALINE_SESSION == mPayload["session_type"].asInteger())
+ {
+ channel_name = LLTextUtil::formatPhoneNumber(channel_name);
+ }
+ childSetTextArg("nearby", "[VOICE_CHANNEL_NAME]", channel_name);
childSetTextArg("nearby_P2P", "[VOICE_CHANNEL_NAME]", mPayload["disconnected_channel_name"].asString());
}