diff options
Diffstat (limited to 'indra/newview')
| -rw-r--r-- | indra/newview/llchiclet.cpp | 19 | ||||
| -rw-r--r-- | indra/newview/llchiclet.h | 2 | ||||
| -rw-r--r-- | indra/newview/llimview.cpp | 24 | 
3 files changed, 36 insertions, 9 deletions
diff --git a/indra/newview/llchiclet.cpp b/indra/newview/llchiclet.cpp index 17ef1f41a4..e6f56d89f7 100644 --- a/indra/newview/llchiclet.cpp +++ b/indra/newview/llchiclet.cpp @@ -477,7 +477,6 @@ void LLIMChiclet::setShowSpeaker(bool show)  	{		  		mShowSpeaker = show;  		toggleSpeakerControl(); -		onChicletSizeChanged();		  	}  } @@ -502,7 +501,6 @@ void LLIMChiclet::setShowCounter(bool show)  	{		  		LLChiclet::setShowCounter(show);  		toggleCounterControl(); -		onChicletSizeChanged();		  	}  } @@ -527,6 +525,8 @@ void LLIMChiclet::setRequiredWidth()  	}   	reshape(required_width, getRect().getHeight()); + +	onChicletSizeChanged();  }  void LLIMChiclet::toggleSpeakerControl() @@ -567,6 +567,7 @@ void LLIMChiclet::setShowNewMessagesIcon(bool show)  	{  		mNewMessagesIcon->setVisible(show);  	} +	setRequiredWidth();  }  bool LLIMChiclet::getShowNewMessagesIcon() @@ -1462,6 +1463,20 @@ void LLChicletPanel::reshape(S32 width, S32 height, BOOL called_from_parent )  } +S32	LLChicletPanel::notifyParent(const LLSD& info) +{ +	if(info.has("notification")) +	{ +		std::string str_notification = info["notification"]; +		if(str_notification == "size_changes") +		{ +			arrange(); +			return 1; +		} +	} +	return LLPanel::notifyParent(info); +} +  void LLChicletPanel::arrange()  {  	if(mChicletList.empty()) diff --git a/indra/newview/llchiclet.h b/indra/newview/llchiclet.h index 2ab6abfb5b..511b85b0b6 100644 --- a/indra/newview/llchiclet.h +++ b/indra/newview/llchiclet.h @@ -1021,6 +1021,8 @@ public:  	S32 getTotalUnreadIMCount(); +	S32	notifyParent(const LLSD& info); +  protected:  	LLChicletPanel(const Params&p);  	friend class LLUICtrlFactory; diff --git a/indra/newview/llimview.cpp b/indra/newview/llimview.cpp index 3549891bc5..d209060b58 100644 --- a/indra/newview/llimview.cpp +++ b/indra/newview/llimview.cpp @@ -243,6 +243,8 @@ void LLIMModel::LLIMSession::onVoiceChannelStateChanged(const LLVoiceChannel::ES  	std::string joined_call = LLTrans::getString("joined_call");  	std::string other_avatar_name = ""; +	std::string message; +  	switch(mSessionType)  	{  	case AVALINE_SESSION: @@ -255,10 +257,13 @@ void LLIMModel::LLIMSession::onVoiceChannelStateChanged(const LLVoiceChannel::ES  			switch(new_state)  			{  			case LLVoiceChannel::STATE_CALL_STARTED : -				LLIMModel::getInstance()->addMessageSilently(mSessionID, other_avatar_name, mOtherParticipantID, started_call); +				message = other_avatar_name + " " + started_call; +				LLIMModel::getInstance()->addMessageSilently(mSessionID, SYSTEM_FROM, LLUUID::null, message); +				  				break;  			case LLVoiceChannel::STATE_CONNECTED : -				LLIMModel::getInstance()->addMessageSilently(mSessionID, you, gAgent.getID(), joined_call); +				message = you + " " + joined_call; +				LLIMModel::getInstance()->addMessageSilently(mSessionID, SYSTEM_FROM, LLUUID::null, message);  			default:  				break;  			} @@ -268,10 +273,12 @@ void LLIMModel::LLIMSession::onVoiceChannelStateChanged(const LLVoiceChannel::ES  			switch(new_state)  			{  			case LLVoiceChannel::STATE_CALL_STARTED : -				LLIMModel::getInstance()->addMessageSilently(mSessionID, you, gAgent.getID(), started_call); +				message = you + " " + started_call; +				LLIMModel::getInstance()->addMessageSilently(mSessionID, SYSTEM_FROM, LLUUID::null, message);  				break;  			case LLVoiceChannel::STATE_CONNECTED : -				LLIMModel::getInstance()->addMessageSilently(mSessionID, other_avatar_name, mOtherParticipantID, joined_call); +				message = other_avatar_name + " " + joined_call; +				LLIMModel::getInstance()->addMessageSilently(mSessionID, SYSTEM_FROM, LLUUID::null, message);  			default:  				break;  			} @@ -295,10 +302,12 @@ void LLIMModel::LLIMSession::onVoiceChannelStateChanged(const LLVoiceChannel::ES  			switch(new_state)  			{  			case LLVoiceChannel::STATE_CALL_STARTED : -				LLIMModel::getInstance()->addMessageSilently(mSessionID, other_avatar_name, mOtherParticipantID, started_call); +				message = other_avatar_name + " " + started_call; +				LLIMModel::getInstance()->addMessageSilently(mSessionID, SYSTEM_FROM, LLUUID::null, message);  				break;  			case LLVoiceChannel::STATE_CONNECTED : -				LLIMModel::getInstance()->addMessageSilently(mSessionID, you, gAgent.getID(), joined_call); +				message = you + " " + joined_call; +				LLIMModel::getInstance()->addMessageSilently(mSessionID, SYSTEM_FROM, LLUUID::null, message);  			default:  				break;  			} @@ -308,7 +317,8 @@ void LLIMModel::LLIMSession::onVoiceChannelStateChanged(const LLVoiceChannel::ES  			switch(new_state)  			{  			case LLVoiceChannel::STATE_CALL_STARTED : -				LLIMModel::getInstance()->addMessageSilently(mSessionID, you, gAgent.getID(), started_call); +				message = you + " " + started_call; +				LLIMModel::getInstance()->addMessageSilently(mSessionID, SYSTEM_FROM, LLUUID::null, message);  				break;  			default:  				break;  | 
