summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Dyukov <adyukov@productengine.com>2010-05-28 00:03:08 +0300
committerAndrew Dyukov <adyukov@productengine.com>2010-05-28 00:03:08 +0300
commita1b973fc2a5d28e64dcf010e3652beda78745d35 (patch)
treed06d54f34b0153c57e6e60ec9ff44928b99e74b6
parentb111056501f8b678e27bb0747144e7006d3ab03a (diff)
EXT-7118 FIXED Changed text in group call invite.
- Changed group invite string from "has joined a Voice Chat call with the group [GROUP]" to "just joined '[GROUP]' voice channel." - Added special string for group invite question saying "Would you like to leave [CURRENT_CHAT] and join the call with '[GROUP]'"? - Hooked up this string in code. Reviewed by Vadim Savchuk at https://codereview.productengine.com/secondlife/r/458/ --HG-- branch : product-engine
-rw-r--r--indra/newview/llimview.cpp17
-rw-r--r--indra/newview/skins/default/xui/en/floater_incoming_call.xml10
2 files changed, 24 insertions, 3 deletions
diff --git a/indra/newview/llimview.cpp b/indra/newview/llimview.cpp
index 039df69454..2c1983b6d2 100644
--- a/indra/newview/llimview.cpp
+++ b/indra/newview/llimview.cpp
@@ -1941,15 +1941,24 @@ void LLIncomingCallDialog::onOpen(const LLSD& key)
{
LLCallDialog::onOpen(key);
+ LLStringUtil::format_map_t args;
+ LLGroupData data;
+ // if it's a group call, retrieve group name to use it in question
+ if (gAgent.getGroupData(key["session_id"].asUUID(), data))
+ {
+ args["[GROUP]"] = data.mName;
+ }
// tell the user which voice channel they would be leaving
LLVoiceChannel *voice = LLVoiceChannel::getCurrentVoiceChannel();
if (voice && !voice->getSessionName().empty())
{
- childSetTextArg("question", "[CURRENT_CHAT]", voice->getSessionName());
+ args["[CURRENT_CHAT]"] = voice->getSessionName();
+ childSetText("question", getString(key["question_type"].asString(), args));
}
else
{
- childSetTextArg("question", "[CURRENT_CHAT]", getString("localchat"));
+ args["[CURRENT_CHAT]"] = getString("localchat");
+ childSetText("question", getString(key["question_type"].asString(), args));
}
}
@@ -2480,6 +2489,8 @@ void LLIMMgr::inviteToSession(
}
std::string notify_box_type;
+ // voice invite question is different from default only for group call (EXT-7118)
+ std::string question_type = "VoiceInviteQuestionDefault";
BOOL ad_hoc_invite = FALSE;
if(type == IM_SESSION_P2P_INVITE)
@@ -2491,6 +2502,7 @@ void LLIMMgr::inviteToSession(
{
//only really old school groups have voice invitations
notify_box_type = "VoiceInviteGroup";
+ question_type = "VoiceInviteQuestionGroup";
}
else if ( inv_type == INVITATION_TYPE_VOICE )
{
@@ -2515,6 +2527,7 @@ void LLIMMgr::inviteToSession(
payload["session_handle"] = session_handle;
payload["session_uri"] = session_uri;
payload["notify_box_type"] = notify_box_type;
+ payload["question_type"] = question_type;
LLVoiceChannel* channelp = LLVoiceChannel::getChannelByID(session_id);
if (channelp && channelp->callStarted())
diff --git a/indra/newview/skins/default/xui/en/floater_incoming_call.xml b/indra/newview/skins/default/xui/en/floater_incoming_call.xml
index 1d67123726..24fff6d4ae 100644
--- a/indra/newview/skins/default/xui/en/floater_incoming_call.xml
+++ b/indra/newview/skins/default/xui/en/floater_incoming_call.xml
@@ -32,7 +32,15 @@
</floater.string>
<floater.string
name="VoiceInviteGroup">
- has joined a Voice Chat call with the group [GROUP].
+ just joined '[GROUP]' voice channel.
+ </floater.string>
+ <floater.string
+ name="VoiceInviteQuestionGroup">
+ Would you like to leave [CURRENT_CHAT] and join the call with '[GROUP]'?
+ </floater.string>
+ <floater.string
+ name="VoiceInviteQuestionDefault">
+ Do you want to leave [CURRENT_CHAT] and join this voice chat?
</floater.string>
<avatar_icon
enabled="false"