diff options
| author | Mnikolenko ProductEngine <mnikolenko@productengine.com> | 2014-11-05 12:36:56 +0200 | 
|---|---|---|
| committer | Mnikolenko ProductEngine <mnikolenko@productengine.com> | 2014-11-05 12:36:56 +0200 | 
| commit | ae04cb854948ae3ef5c84ac11c2d7a4e04b28a9b (patch) | |
| tree | 3098fba0c95bdec1c29d7087c2601fcf0b2d778d | |
| parent | 799d13269a5cdf29a5d68c15ceac42f0407b5833 (diff) | |
MAINT-4621 FIXED start new session with the caller (if it doesn't exist) and only then show autoreject message
| -rwxr-xr-x | indra/newview/llimview.cpp | 18 | 
1 files changed, 18 insertions, 0 deletions
diff --git a/indra/newview/llimview.cpp b/indra/newview/llimview.cpp index 8d8239611c..5d3a11e245 100755 --- a/indra/newview/llimview.cpp +++ b/indra/newview/llimview.cpp @@ -3061,6 +3061,24 @@ void LLIMMgr::inviteToSession(  		{  			if (gAgent.isDoNotDisturb() && !isRejectGroupCall && !isRejectNonFriendCall)  			{ +				if (!hasSession(session_id) && (type == IM_SESSION_P2P_INVITE)) +				{ +					std::string fixed_session_name = caller_name; +					if(!session_name.empty() && session_name.size()>1) +					{ +						fixed_session_name = session_name; +					} +					else +					{ +						LLAvatarName av_name; +						if (LLAvatarNameCache::get(caller_id, &av_name)) +						{ +							fixed_session_name = av_name.getDisplayName(); +						} +					} +					LLIMModel::getInstance()->newSession(session_id, fixed_session_name, IM_NOTHING_SPECIAL, caller_id, false, false); +				} +  				LLSD args;  				addSystemMessage(session_id, "you_auto_rejected_call", args);  				send_do_not_disturb_message(gMessageSystem, caller_id, session_id);  | 
