diff options
| author | Wolfpup Lowenhar <wolfpup67@earthlink.net> | 2010-10-29 09:14:36 -0400 | 
|---|---|---|
| committer | Wolfpup Lowenhar <wolfpup67@earthlink.net> | 2010-10-29 09:14:36 -0400 | 
| commit | be33be7898a70ccff5b3be9a48db4c290c5d8310 (patch) | |
| tree | 2e528f146e0a4dd940cdeaa14b3b15c661e8cc7f /indra | |
| parent | 46940d4a5f9e6b0d19b5e6bacd84c4f7bc89eba3 (diff) | |
| parent | 8209e35643cd21bde2b52bfa26cd77732f4fca9f (diff) | |
STORM-255 : Merge from viewer-development
Diffstat (limited to 'indra')
| -rw-r--r-- | indra/llui/llurlentry.cpp | 3 | ||||
| -rw-r--r-- | indra/newview/llchathistory.cpp | 5 | ||||
| -rw-r--r-- | indra/newview/llnearbychathandler.cpp | 58 | ||||
| -rw-r--r-- | indra/newview/lloutfitslist.cpp | 35 | ||||
| -rw-r--r-- | indra/newview/lloutfitslist.h | 2 | ||||
| -rw-r--r-- | indra/newview/llpanelgrouproles.cpp | 8 | ||||
| -rw-r--r-- | indra/newview/llpaneloutfitsinventory.cpp | 10 | ||||
| -rw-r--r-- | indra/newview/llpaneloutfitsinventory.h | 1 | ||||
| -rw-r--r-- | indra/newview/llscreenchannel.cpp | 8 | ||||
| -rw-r--r-- | indra/newview/lltoast.cpp | 110 | ||||
| -rw-r--r-- | indra/newview/lltoast.h | 35 | ||||
| -rw-r--r-- | indra/newview/llviewermessage.cpp | 15 | ||||
| -rw-r--r-- | indra/newview/skins/default/xui/en/panel_preferences_chat.xml | 34 | ||||
| -rw-r--r-- | indra/newview/skins/default/xui/en/strings.xml | 3 | 
14 files changed, 255 insertions, 72 deletions
| diff --git a/indra/llui/llurlentry.cpp b/indra/llui/llurlentry.cpp index f49dfec82b..84678ef4db 100644 --- a/indra/llui/llurlentry.cpp +++ b/indra/llui/llurlentry.cpp @@ -989,7 +989,8 @@ std::string LLUrlEntryNoLink::getLabel(const std::string &url, const LLUrlLabelC  LLStyle::Params LLUrlEntryNoLink::getStyle() const   {  -	return LLStyle::Params();  +	// Don't render as URL (i.e. no context menu or hand cursor). +	return LLStyle::Params().is_link(false);  } diff --git a/indra/newview/llchathistory.cpp b/indra/newview/llchathistory.cpp index cb5cf4a61d..3dc6e786d3 100644 --- a/indra/newview/llchathistory.cpp +++ b/indra/newview/llchathistory.cpp @@ -790,8 +790,9 @@ void LLChatHistory::appendMessage(const LLChat& chat, const LLSD &args, const LL  				// (don't let object names with hyperlinks override our objectim Url)  				LLStyle::Params link_params(style_params);  				link_params.color.control = "HTMLLinkColor"; +				link_params.is_link = true;  				link_params.link_href = url; -				mEditor->appendText("<nolink>" + chat.mFromName + "</nolink>"  + delimiter, +				mEditor->appendText(chat.mFromName + delimiter,  									false, link_params);  			}  			else if ( chat.mFromName != SYSTEM_FROM && chat.mFromID.notNull() && !message_from_log) @@ -804,7 +805,7 @@ void LLChatHistory::appendMessage(const LLChat& chat, const LLSD &args, const LL  			}  			else  			{ -				mEditor->appendText(chat.mFromName + delimiter, false, style_params); +				mEditor->appendText("<nolink>" + chat.mFromName + "</nolink>" + delimiter, false, style_params);  			}  		}  	} diff --git a/indra/newview/llnearbychathandler.cpp b/indra/newview/llnearbychathandler.cpp index 47d32e57fb..d2ad78f140 100644 --- a/indra/newview/llnearbychathandler.cpp +++ b/indra/newview/llnearbychathandler.cpp @@ -64,6 +64,18 @@ public:  	LLNearbyChatScreenChannel(const LLUUID& id):LLScreenChannelBase(id)   	{  		mStopProcessing = false; + +		LLControlVariable* ctrl = gSavedSettings.getControl("NearbyToastLifeTime").get(); +		if (ctrl) +		{ +			ctrl->getSignal()->connect(boost::bind(&LLNearbyChatScreenChannel::updateToastsLifetime, this)); +		} + +		ctrl = gSavedSettings.getControl("NearbyToastFadingTime").get(); +		if (ctrl) +		{ +			ctrl->getSignal()->connect(boost::bind(&LLNearbyChatScreenChannel::updateToastFadingTime, this)); +		}  	}  	void addNotification	(LLSD& notification); @@ -109,13 +121,26 @@ protected:  		if (!toast) return;  		LL_DEBUGS("NearbyChat") << "Pooling toast" << llendl;  		toast->setVisible(FALSE); -		toast->stopTimer(); +		toast->stopFading();  		toast->setIsHidden(true); + +		// Nearby chat toasts that are hidden, not destroyed. They are collected to the toast pool, so that +		// they can be used next time, this is done for performance. But if the toast lifetime was changed +		// (from preferences floater (STORY-36)) while it was shown (at this moment toast isn't in the pool yet) +		// changes don't take affect. +		// So toast's lifetime should be updated each time it's added to the pool. Otherwise viewer would have +		// to be restarted so that changes take effect. +		toast->setLifetime(gSavedSettings.getS32("NearbyToastLifeTime")); +		toast->setFadingTime(gSavedSettings.getS32("NearbyToastFadingTime"));  		m_toast_pool.push_back(toast->getHandle());  	}  	void	createOverflowToast(S32 bottom, F32 timer); +	void 	updateToastsLifetime(); + +	void	updateToastFadingTime(); +  	create_toast_panel_callback_t m_create_toast_panel_callback_t;  	bool	createPoolToast(); @@ -205,6 +230,27 @@ void LLNearbyChatScreenChannel::onToastFade(LLToast* toast)  	arrangeToasts();  } +void LLNearbyChatScreenChannel::updateToastsLifetime() +{ +	S32 seconds = gSavedSettings.getS32("NearbyToastLifeTime"); +	toast_list_t::iterator it; + +	for(it = m_toast_pool.begin(); it != m_toast_pool.end(); ++it) +	{ +		(*it).get()->setLifetime(seconds); +	} +} + +void LLNearbyChatScreenChannel::updateToastFadingTime() +{ +	S32 seconds = gSavedSettings.getS32("NearbyToastFadingTime"); +	toast_list_t::iterator it; + +	for(it = m_toast_pool.begin(); it != m_toast_pool.end(); ++it) +	{ +		(*it).get()->setFadingTime(seconds); +	} +}  bool	LLNearbyChatScreenChannel::createPoolToast()  { @@ -250,7 +296,7 @@ void LLNearbyChatScreenChannel::addNotification(LLSD& notification)  			{  				panel->addMessage(notification);  				toast->reshapeToPanel(); -				toast->resetTimer(); +				toast->startFading();  				arrangeToasts();  				return; @@ -295,7 +341,7 @@ void LLNearbyChatScreenChannel::addNotification(LLSD& notification)  	panel->init(notification);  	toast->reshapeToPanel(); -	toast->resetTimer(); +	toast->startFading();  	m_active_toasts.push_back(toast->getHandle()); @@ -325,9 +371,9 @@ void LLNearbyChatScreenChannel::arrangeToasts()  int sort_toasts_predicate(LLHandle<LLToast> first, LLHandle<LLToast> second)  { -	F32 v1 = first.get()->getTimer()->getEventTimer().getElapsedTimeF32(); -	F32 v2 = second.get()->getTimer()->getEventTimer().getElapsedTimeF32(); -	return v1 < v2; +	F32 v1 = first.get()->getTimeLeftToLive(); +	F32 v2 = second.get()->getTimeLeftToLive(); +	return v1 > v2;  }  void LLNearbyChatScreenChannel::showToastsBottom() diff --git a/indra/newview/lloutfitslist.cpp b/indra/newview/lloutfitslist.cpp index 70295259b3..6435126fc0 100644 --- a/indra/newview/lloutfitslist.cpp +++ b/indra/newview/lloutfitslist.cpp @@ -115,7 +115,7 @@ public:  		registrar.add("Gear.Wear", boost::bind(&LLOutfitListGearMenu::onWear, this));  		registrar.add("Gear.TakeOff", boost::bind(&LLOutfitListGearMenu::onTakeOff, this));  		registrar.add("Gear.Rename", boost::bind(&LLOutfitListGearMenu::onRename, this)); -		registrar.add("Gear.Delete", boost::bind(&LLOutfitListGearMenu::onDelete, this)); +		registrar.add("Gear.Delete", boost::bind(&LLOutfitsList::removeSelected, mOutfitList));  		registrar.add("Gear.Create", boost::bind(&LLOutfitListGearMenu::onCreate, this, _2));  		registrar.add("Gear.WearAdd", boost::bind(&LLOutfitListGearMenu::onAdd, this)); @@ -197,15 +197,6 @@ private:  		}  	} -	void onDelete() -	{ -		const LLUUID& selected_outfit_id = getSelectedOutfitID(); -		if (selected_outfit_id.notNull()) -		{ -			remove_category(&gInventory, selected_outfit_id); -		} -	} -  	void onCreate(const LLSD& data)  	{  		LLWearableType::EType type = LLWearableType::typeNameToType(data.asString()); @@ -260,6 +251,12 @@ private:  class LLOutfitContextMenu : public LLListContextMenu  { +public: + +	LLOutfitContextMenu(LLOutfitsList* outfit_list) +	:		LLListContextMenu(), +	 		mOutfitList(outfit_list) +	{}  protected:  	/* virtual */ LLContextMenu* createMenu()  	{ @@ -275,7 +272,7 @@ protected:  				boost::bind(&LLAppearanceMgr::takeOffOutfit, &LLAppearanceMgr::instance(), selected_id));  		registrar.add("Outfit.Edit", boost::bind(editOutfit));  		registrar.add("Outfit.Rename", boost::bind(renameOutfit, selected_id)); -		registrar.add("Outfit.Delete", boost::bind(deleteOutfit, selected_id)); +		registrar.add("Outfit.Delete", boost::bind(&LLOutfitsList::removeSelected, mOutfitList));  		enable_registrar.add("Outfit.OnEnable", boost::bind(&LLOutfitContextMenu::onEnable, this, _2));  		enable_registrar.add("Outfit.OnVisible", boost::bind(&LLOutfitContextMenu::onVisible, this, _2)); @@ -338,10 +335,8 @@ protected:  		LLAppearanceMgr::instance().renameOutfit(outfit_cat_id);  	} -	static void deleteOutfit(const LLUUID& outfit_cat_id) -	{ -		remove_category(&gInventory, outfit_cat_id); -	} +private: +	LLOutfitsList*	mOutfitList;  };  ////////////////////////////////////////////////////////////////////////// @@ -358,7 +353,7 @@ LLOutfitsList::LLOutfitsList()  	mCategoriesObserver = new LLInventoryCategoriesObserver();  	mGearMenu = new LLOutfitListGearMenu(this); -	mOutfitMenu = new LLOutfitContextMenu(); +	mOutfitMenu = new LLOutfitContextMenu(this);  }  LLOutfitsList::~LLOutfitsList() @@ -635,6 +630,14 @@ void LLOutfitsList::performAction(std::string action)  void LLOutfitsList::removeSelected()  { +	LLNotificationsUtil::add("DeleteOutfits", LLSD(), LLSD(), boost::bind(&LLOutfitsList::onOutfitsRemovalConfirmation, this, _1, _2)); +} + +void LLOutfitsList::onOutfitsRemovalConfirmation(const LLSD& notification, const LLSD& response) +{ +	S32 option = LLNotificationsUtil::getSelectedOption(notification, response); +	if (option != 0) return; // canceled +  	if (mSelectedOutfitUUID.notNull())  	{  		remove_category(&gInventory, mSelectedOutfitUUID); diff --git a/indra/newview/lloutfitslist.h b/indra/newview/lloutfitslist.h index 5fecbb83e7..a0598737f1 100644 --- a/indra/newview/lloutfitslist.h +++ b/indra/newview/lloutfitslist.h @@ -110,6 +110,8 @@ public:  private: +	void onOutfitsRemovalConfirmation(const LLSD& notification, const LLSD& response); +  	/**  	 * Wrapper for LLCommonUtils::computeDifference. @see LLCommonUtils::computeDifference  	 */ diff --git a/indra/newview/llpanelgrouproles.cpp b/indra/newview/llpanelgrouproles.cpp index 0d1d96eae6..d1362d7922 100644 --- a/indra/newview/llpanelgrouproles.cpp +++ b/indra/newview/llpanelgrouproles.cpp @@ -1576,6 +1576,7 @@ void LLPanelGroupMembersSubTab::update(LLGroupChange gc)  void LLPanelGroupMembersSubTab::addMemberToList(LLUUID id, LLGroupMemberData* data)  { +	if (!data) return;  	LLUIString donated = getString("donation_area");  	donated.setArg("[AREA]", llformat("%d", data->getContribution())); @@ -1616,9 +1617,12 @@ void LLPanelGroupMembersSubTab::onNameCache(const LLUUID& update_id, const LLUUI  	std::string fullname;  	gCacheName->getFullName(id, fullname); -	if (matchesSearchFilter(fullname)) + +	LLGroupMemberData* data; +	// trying to avoid unnecessary hash lookups +	if (matchesSearchFilter(fullname) && ((data = gdatap->mMembers[id]) != NULL))  	{ -		addMemberToList(id, gdatap->mMembers[id]); +		addMemberToList(id, data);  		if(!mMembersList->getEnabled())  		{  			mMembersList->setEnabled(TRUE); diff --git a/indra/newview/llpaneloutfitsinventory.cpp b/indra/newview/llpaneloutfitsinventory.cpp index 4f2cfa2bbc..a90f864ae2 100644 --- a/indra/newview/llpaneloutfitsinventory.cpp +++ b/indra/newview/llpaneloutfitsinventory.cpp @@ -258,17 +258,7 @@ void LLPanelOutfitsInventory::updateListCommands()  void LLPanelOutfitsInventory::onTrashButtonClick()  { -	LLNotificationsUtil::add("DeleteOutfits", LLSD(), LLSD(), boost::bind(&LLPanelOutfitsInventory::onOutfitsRemovalConfirmation, this, _1, _2)); -} - -void LLPanelOutfitsInventory::onOutfitsRemovalConfirmation(const LLSD& notification, const LLSD& response) -{ -	S32 option = LLNotificationsUtil::getSelectedOption(notification, response); -	if (option != 0) return; // canceled -  	mMyOutfitsPanel->removeSelected(); -	updateListCommands(); -	updateVerbs();  }  bool LLPanelOutfitsInventory::isActionEnabled(const LLSD& userdata) diff --git a/indra/newview/llpaneloutfitsinventory.h b/indra/newview/llpaneloutfitsinventory.h index f1ca1dbfeb..a7917b457c 100644 --- a/indra/newview/llpaneloutfitsinventory.h +++ b/indra/newview/llpaneloutfitsinventory.h @@ -89,7 +89,6 @@ protected:  	void onWearButtonClick();  	void showGearMenu();  	void onTrashButtonClick(); -	void onOutfitsRemovalConfirmation(const LLSD& notification, const LLSD& response);  	bool isActionEnabled(const LLSD& userdata);  	void setWearablesLoading(bool val);  	void onWearablesLoaded(); diff --git a/indra/newview/llscreenchannel.cpp b/indra/newview/llscreenchannel.cpp index 18c9ac28c1..61f4897ed0 100644 --- a/indra/newview/llscreenchannel.cpp +++ b/indra/newview/llscreenchannel.cpp @@ -369,7 +369,7 @@ void LLScreenChannel::loadStoredToastsToChannel()  	for(it = mStoredToastList.begin(); it != mStoredToastList.end(); ++it)  	{  		(*it).toast->setIsHidden(false); -		(*it).toast->resetTimer(); +		(*it).toast->startFading();  		mToastList.push_back((*it));  	} @@ -394,7 +394,7 @@ void LLScreenChannel::loadStoredToastByNotificationIDToChannel(LLUUID id)  	}  	toast->setIsHidden(false); -	toast->resetTimer(); +	toast->startFading();  	mToastList.push_back((*it));  	redrawToasts(); @@ -477,7 +477,7 @@ void LLScreenChannel::modifyToastByNotificationID(LLUUID id, LLPanel* panel)  		toast->removeChild(old_panel);  		delete old_panel;  		toast->insertPanel(panel); -		toast->resetTimer(); +		toast->startFading();  		redrawToasts();  	}  } @@ -588,7 +588,7 @@ void LLScreenChannel::showToastsBottom()  		mHiddenToastsNum = 0;  		for(; it != mToastList.rend(); it++)  		{ -			(*it).toast->stopTimer(); +			(*it).toast->stopFading();  			(*it).toast->setVisible(FALSE);  			mHiddenToastsNum++;  		} diff --git a/indra/newview/lltoast.cpp b/indra/newview/lltoast.cpp index c3090cb1fc..8176b8c1f9 100644 --- a/indra/newview/lltoast.cpp +++ b/indra/newview/lltoast.cpp @@ -35,6 +35,13 @@  using namespace LLNotificationsUI; +//-------------------------------------------------------------------------- +LLToastLifeTimer::LLToastLifeTimer(LLToast* toast, F32 period) +	: mToast(toast), +	  LLEventTimer(period) +{ +} +  /*virtual*/  BOOL LLToastLifeTimer::tick()  { @@ -45,6 +52,38 @@ BOOL LLToastLifeTimer::tick()  	return FALSE;  } +void LLToastLifeTimer::stop() +{ +	mEventTimer.stop(); +} + +void LLToastLifeTimer::start() +{ +	mEventTimer.start(); +} + +void LLToastLifeTimer::restart() +{ +	mEventTimer.reset(); +} + +BOOL LLToastLifeTimer::getStarted() +{ +	return mEventTimer.getStarted(); +} + +void LLToastLifeTimer::setPeriod(F32 period) +{ +	mPeriod = period; +} + +F32 LLToastLifeTimer::getRemainingTimeF32() +{ +	F32 et = mEventTimer.getElapsedTimeF32(); +	if (!getStarted() || et > mPeriod) return 0.0f; +	return mPeriod - et; +} +  //--------------------------------------------------------------------------  LLToast::Params::Params()   :	can_fade("can_fade", true), @@ -73,7 +112,8 @@ LLToast::LLToast(const LLToast::Params& p)  	mIsHidden(false),  	mHideBtnPressed(false),  	mIsTip(p.is_tip), -	mWrapperPanel(NULL) +	mWrapperPanel(NULL), +	mIsTransparent(false)  {  	mTimer.reset(new LLToastLifeTimer(this, p.lifetime_secs)); @@ -143,6 +183,7 @@ LLToast::~LLToast()  void LLToast::hide()  {  	setVisible(FALSE); +	setTransparentState(false);  	mTimer->stop();  	mIsHidden = true;  	mOnFadeSignal(this);  @@ -166,6 +207,16 @@ void LLToast::onFocusReceived()  	}  } +void LLToast::setLifetime(S32 seconds) +{ +	mToastLifetime = seconds; +} + +void LLToast::setFadingTime(S32 seconds) +{ +	mToastFadingTime = seconds; +} +  S32 LLToast::getTopPad()  {  	if(mWrapperPanel) @@ -195,13 +246,46 @@ void LLToast::setCanFade(bool can_fade)  //--------------------------------------------------------------------------  void LLToast::expire()  { -	// if toast has fade property - hide it -	if(mCanFade) +	if (mCanFade)  	{ -		hide(); +		if (mIsTransparent) +		{ +			hide(); +		} +		else +		{ +			setTransparentState(true); +			mTimer->restart(); +		}  	}  } +void LLToast::setTransparentState(bool transparent) +{ +	setBackgroundOpaque(!transparent); +	mIsTransparent = transparent; + +	if (transparent) +	{ +		mTimer->setPeriod(mToastFadingTime); +	} +	else +	{ +		mTimer->setPeriod(mToastLifetime); +	} +} + +F32 LLToast::getTimeLeftToLive() +{ +	F32 time_to_live = mTimer->getRemainingTimeF32(); + +	if (!mIsTransparent) +	{ +		time_to_live += mToastFadingTime; +	} + +	return time_to_live; +}  //--------------------------------------------------------------------------  void LLToast::reshapeToPanel() @@ -245,13 +329,6 @@ void LLToast::draw()  			drawChild(mHideBtn);  		}  	} - -	// if timer started and remaining time <= fading time -	if (mTimer->getStarted() && (mToastLifetime -			- mTimer->getEventTimer().getElapsedTimeF32()) <= mToastFadingTime) -	{ -		setBackgroundOpaque(FALSE); -	}  }  //-------------------------------------------------------------------------- @@ -267,6 +344,11 @@ void LLToast::setVisible(BOOL show)  		return;  	} +	if (show && getVisible()) +	{ +		return; +	} +  	if(show)  	{  		setBackgroundOpaque(TRUE); @@ -372,7 +454,8 @@ void LLNotificationsUI::LLToast::stopFading()  {  	if(mCanFade)  	{ -		stopTimer(); +		setTransparentState(false); +		mTimer->stop();  	}  } @@ -380,7 +463,8 @@ void LLNotificationsUI::LLToast::startFading()  {  	if(mCanFade)  	{ -		resetTimer(); +		setTransparentState(false); +		mTimer->start();  	}  } diff --git a/indra/newview/lltoast.h b/indra/newview/lltoast.h index 0a96c092a0..fb534561c9 100644 --- a/indra/newview/lltoast.h +++ b/indra/newview/lltoast.h @@ -49,14 +49,16 @@ class LLToast;  class LLToastLifeTimer: public LLEventTimer  {  public: -	LLToastLifeTimer(LLToast* toast, F32 period) : mToast(toast), LLEventTimer(period){} +	LLToastLifeTimer(LLToast* toast, F32 period);  	/*virtual*/  	BOOL tick(); -	void stop() { mEventTimer.stop(); } -	void start() { mEventTimer.start(); } -	void restart() {mEventTimer.reset(); } -	BOOL getStarted() { return mEventTimer.getStarted(); } +	void stop(); +	void start(); +	void restart(); +	BOOL getStarted(); +	void setPeriod(F32 period); +	F32 getRemainingTimeF32();  	LLTimer&  getEventTimer() { return mEventTimer;}  private : @@ -80,8 +82,14 @@ public:  		Optional<LLUUID>				notif_id,	 //notification ID  										session_id;	 //im session ID  		Optional<LLNotificationPtr>		notification; -		Optional<F32>					lifetime_secs, -										fading_time_secs; // Number of seconds while a toast is fading + +		//NOTE: Life time of a toast (i.e. period of time from the moment toast was shown +		//till the moment when toast was hidden) is the sum of lifetime_secs and fading_time_secs. + +		Optional<F32>					lifetime_secs, // Number of seconds while a toast is non-transparent +										fading_time_secs; // Number of seconds while a toast is transparent + +  		Optional<toast_callback_t>		on_delete_toast,  										on_mouse_enter;  		Optional<bool>					can_fade, @@ -125,10 +133,8 @@ public:  	LLPanel* getPanel() { return mPanel; }  	// enable/disable Toast's Hide button  	void setHideButtonEnabled(bool enabled); -	//  -	void resetTimer() { mTimer->start(); }  	// -	void stopTimer() { mTimer->stop(); } +	F32 getTimeLeftToLive();  	//  	LLToastLifeTimer* getTimer() { return mTimer.get();}  	// @@ -144,6 +150,10 @@ public:  	/*virtual*/ void onFocusReceived(); +	void setLifetime(S32 seconds); + +	void setFadingTime(S32 seconds); +  	/**  	 * Returns padding between floater top and wrapper_panel top.  	 * This padding should be taken into account when positioning or reshaping toasts @@ -196,7 +206,9 @@ private:  	void onToastMouseLeave(); -	void	expire(); +	void expire(); + +	void setTransparentState(bool transparent);  	LLUUID				mNotificationID;  	LLUUID				mSessionID; @@ -222,6 +234,7 @@ private:  	bool		mHideBtnPressed;  	bool		mIsHidden;  // this flag is TRUE when a toast has faded or was hidden with (x) button (EXT-1849)  	bool		mIsTip; +	bool		mIsTransparent;  	commit_signal_t mToastMouseEnterSignal;  	commit_signal_t mToastMouseLeaveSignal; diff --git a/indra/newview/llviewermessage.cpp b/indra/newview/llviewermessage.cpp index 9b1f2e67c6..672213d3e8 100644 --- a/indra/newview/llviewermessage.cpp +++ b/indra/newview/llviewermessage.cpp @@ -1511,7 +1511,12 @@ bool LLOfferInfo::inventory_offer_callback(const LLSD& notification, const LLSD&  		// MUTE falls through to decline  	case IOR_DECLINE:  		{ -			log_message = LLTrans::getString("InvOfferYouDecline") + " " + mDesc + " " + LLTrans::getString("InvOfferFrom") + " " + mFromName +"."; +			{ +				LLStringUtil::format_map_t log_message_args; +				log_message_args["DESC"] = mDesc; +				log_message_args["NAME"] = mFromName; +				log_message = LLTrans::getString("InvOfferDecline", log_message_args); +			}  			chat.mText = log_message;  			if( LLMuteList::getInstance()->isMuted(mFromID ) && ! LLMuteList::getInstance()->isLinden(mFromName) )  // muting for SL-42269  			{ @@ -1710,8 +1715,12 @@ bool LLOfferInfo::inventory_task_offer_callback(const LLSD& notification, const  			msg->addBinaryDataFast(_PREHASH_BinaryBucket, EMPTY_BINARY_BUCKET, EMPTY_BINARY_BUCKET_SIZE);  			// send the message  			msg->sendReliable(mHost); -			 -			log_message = LLTrans::getString("InvOfferYouDecline") + " " + mDesc + " " + LLTrans::getString("InvOfferFrom") + " " + mFromName +"."; +			{ +				LLStringUtil::format_map_t log_message_args; +				log_message_args["DESC"] = mDesc; +				log_message_args["NAME"] = mFromName; +				log_message = LLTrans::getString("InvOfferDecline", log_message_args); +			}  			LLSD args;  			args["MESSAGE"] = log_message;  			LLNotificationsUtil::add("SystemMessage", args); diff --git a/indra/newview/skins/default/xui/en/panel_preferences_chat.xml b/indra/newview/skins/default/xui/en/panel_preferences_chat.xml index e8f36b5298..8a20c3cb16 100644 --- a/indra/newview/skins/default/xui/en/panel_preferences_chat.xml +++ b/indra/newview/skins/default/xui/en/panel_preferences_chat.xml @@ -308,6 +308,38 @@       width="95">          URLs      </text> +    <spinner +     control_name="NearbyToastLifeTime" +     decimal_digits="0" +     follows="left|top" +     height="23" +     increment="1" +     initial_value="23" +     label="Nearby chat toasts life time:" +     label_width="190" +     layout="topleft" +     left="290" +     max_val="60" +     min_val="1" +     name="nearby_toasts_lifetime" +     top_pad="33" +     width="210" /> +    <spinner +     control_name="NearbyToastFadingTime" +     decimal_digits="0" +     follows="left|top" +     height="23" +     increment="1" +     initial_value="3" +     label="Nearby chat toasts fading time:" +     label_width="190" +     layout="topleft" +     left_delta="00" +     max_val="60" +     min_val="0" +     name="nearby_toasts_fadingtime" +     top_pad="15" +     width="210" />      <check_box       control_name="PlayTypingAnim"       height="16" @@ -316,7 +348,7 @@       layout="topleft"       left="30"       name="play_typing_animation" -     top_pad="32" +     top="205"       width="400" />      <check_box       enabled="false" diff --git a/indra/newview/skins/default/xui/en/strings.xml b/indra/newview/skins/default/xui/en/strings.xml index 403d976350..5d3f19edcf 100644 --- a/indra/newview/skins/default/xui/en/strings.xml +++ b/indra/newview/skins/default/xui/en/strings.xml @@ -2242,8 +2242,7 @@ Clears (deletes) the media and all params from the given face.  	<string name="InvOfferOwnedBy">owned by</string>  	<string name="InvOfferOwnedByUnknownUser">owned by an unknown user</string>  	<string name="InvOfferGaveYou">gave you</string> -	<string name="InvOfferYouDecline">You decline</string> -	<string name="InvOfferFrom">from</string> +	<string name="InvOfferDecline">You decline [DESC] from <nolink>[NAME]</nolink>.</string>  	<!-- group money -->  	<string name="GroupMoneyTotal">Total</string> | 
