diff --git a/indra/llui/llfolderview.cpp b/indra/llui/llfolderview.cpp
index 7c1ca017d7e833aae03087cd5a9815eaff01c3d5..c756ff84e10194f30782da0cb8f7c61836a77df5 100644
--- a/indra/llui/llfolderview.cpp
+++ b/indra/llui/llfolderview.cpp
@@ -924,23 +924,27 @@ void LLFolderView::cut()
 {
 	// clear the inventory clipboard
 	LLClipboard::instance().reset();
-	S32 count = mSelectedItems.size();
-	if(getVisible() && getEnabled() && (count > 0))
+	if(getVisible() && getEnabled() && (mSelectedItems.size() > 0))
 	{
+		// Find out which item will be selected once the selection will be cut
 		LLFolderViewItem* item_to_select = getNextUnselectedItem();
+		
+		// Get the selection: removeItem() modified mSelectedItems and makes iterating on it unwise
+		std::set<LLFolderViewItem*> inventory_selected = getSelectionList();
 
-		selected_items_t::iterator item_it;
-		for (item_it = mSelectedItems.begin(); item_it != mSelectedItems.end(); ++item_it)
+		// Move each item to the clipboard and out of their folder
+		for (std::set<LLFolderViewItem*>::iterator item_it = inventory_selected.begin(); item_it != inventory_selected.end(); ++item_it)
 		{
 			LLFolderViewItem* item_to_cut = *item_it;
 			LLFolderViewModelItem* listener = item_to_cut->getViewModelItem();
-			if(listener)
+			if (listener)
 			{
 				listener->cutToClipboard();
 				listener->removeItem();
 			}
 		}
-
+		
+		// Update the selection
 		setSelection(item_to_select, item_to_select ? item_to_select->isOpen() : false, mParentPanel->hasFocus());
 	}
 	mSearchString.clear();
diff --git a/indra/newview/llconversationlog.cpp b/indra/newview/llconversationlog.cpp
index 5f037549abacfb80d68cbf4a4c52766eddf552a8..04abda17992b52f60db434b4f38978402a768d5a 100644
--- a/indra/newview/llconversationlog.cpp
+++ b/indra/newview/llconversationlog.cpp
@@ -532,7 +532,14 @@ void LLConversationLog::onClearLogResponse(const LLSD& notification, const LLSD&
 {
 	if (0 == LLNotificationsUtil::getSelectedOption(notification, response))
 	{
+		deleteTranscripts();
 		mConversations.clear();
 		notifyObservers();
 	}
 }
+
+void LLConversationLog::deleteTranscripts()
+{
+	gDirUtilp->deleteFilesInDir(gDirUtilp->getPerAccountChatLogsDir(), "*." + LL_TRANSCRIPT_FILE_EXTENSION);
+	LLFloaterIMSessionTab::processChatHistoryStyleUpdate(true);
+}
diff --git a/indra/newview/llconversationlog.h b/indra/newview/llconversationlog.h
index d5b6eccb294d4a6cbcf146c829f544581bee2164..5213c9b3ab943907554281d0c913849d9ae99ed9 100644
--- a/indra/newview/llconversationlog.h
+++ b/indra/newview/llconversationlog.h
@@ -140,6 +140,7 @@ class LLConversationLog : public LLSingleton<LLConversationLog>, LLIMSessionObse
 
 	void onClearLog();
 	void onClearLogResponse(const LLSD& notification, const LLSD& response);
+	void deleteTranscripts();
 
 	bool getIsLoggingEnabled() { return mLoggingEnabled; }
 	bool isLogEmpty() { return mConversations.empty(); }
diff --git a/indra/newview/llfloaterimcontainer.cpp b/indra/newview/llfloaterimcontainer.cpp
index 54e50854903f68bf5667244b73d77b844cfe9dc9..5a284cc7b7129d56d81e4fe9f5f1201ea391cfea 100644
--- a/indra/newview/llfloaterimcontainer.cpp
+++ b/indra/newview/llfloaterimcontainer.cpp
@@ -1118,19 +1118,18 @@ void LLFloaterIMContainer::doToSelected(const LLSD& userdata)
 void LLFloaterIMContainer::doToSelectedGroup(const LLSD& userdata)
 {
     std::string action = userdata.asString();
-    LLUUID selected_group = getCurSelectedViewModelItem()->getUUID();
 
     if (action == "group_profile")
     {
-        LLGroupActions::show(selected_group);
+        LLGroupActions::show(mSelectedSession);
     }
     else if (action == "activate_group")
     {
-        LLGroupActions::activate(selected_group);
+        LLGroupActions::activate(mSelectedSession);
     }
     else if (action == "leave_group")
     {
-        LLGroupActions::leave(selected_group);
+        LLGroupActions::leave(mSelectedSession);
     }
 }
 
diff --git a/indra/newview/llfloaterimnearbychat.cpp b/indra/newview/llfloaterimnearbychat.cpp
index a2dd93e10ddba9f918657cd767bd916fa4b6db50..345418bffcac81a35c5a053ed60dd01ccce7fda3 100644
--- a/indra/newview/llfloaterimnearbychat.cpp
+++ b/indra/newview/llfloaterimnearbychat.cpp
@@ -260,6 +260,7 @@ void LLFloaterIMNearbyChat::onOpen(const LLSD& key)
 void LLFloaterIMNearbyChat::onClose(bool app_quitting)
 {
 	// Override LLFloaterIMSessionTab::onClose() so that Nearby Chat is not removed from the conversation floater
+	onClickCloseBtn();
 }
 
 // virtual
diff --git a/indra/newview/llfloaterpreference.cpp b/indra/newview/llfloaterpreference.cpp
index 7742e5b3c3b04803f090255c6578535be065e801..4f86c26a6743cc16eed33a4d39674f99ba791c6e 100755
--- a/indra/newview/llfloaterpreference.cpp
+++ b/indra/newview/llfloaterpreference.cpp
@@ -460,9 +460,6 @@ BOOL LLFloaterPreference::postBuild()
 	// set 'enable' property for 'Clear log...' button
 	changed();
 
-	// set 'enable' property for 'Delete transcripts...' button
-	updateDeleteTranscriptsButton();
-
 	LLLogChat::setSaveHistorySignal(boost::bind(&LLFloaterPreference::onLogChatHistorySaved, this));
 
 	return TRUE;
@@ -1587,13 +1584,8 @@ void LLFloaterPreference::onDeleteTranscriptsResponse(const LLSD& notification,
 {
 	if (0 == LLNotificationsUtil::getSelectedOption(notification, response))
 	{
-		gDirUtilp->deleteFilesInDir(gDirUtilp->getPerAccountChatLogsDir(), "*." + LL_TRANSCRIPT_FILE_EXTENSION);
-
-		std::vector<std::string> list_of_transcriptions_file_names;
-		LLLogChat::getListOfTranscriptFiles(list_of_transcriptions_file_names);
-		getChild<LLButton>("delete_transcripts")->setEnabled(list_of_transcriptions_file_names.size() > 0);
-
-		LLFloaterIMSessionTab::processChatHistoryStyleUpdate(true);
+		LLConversationLog::instance().deleteTranscripts();
+		updateDeleteTranscriptsButton();
 	}
 }
 
@@ -1668,6 +1660,10 @@ void LLFloaterPreference::selectChatPanel()
 void LLFloaterPreference::changed()
 {
 	getChild<LLButton>("clear_log")->setEnabled(LLConversationLog::instance().getConversations().size() > 0);
+
+	// set 'enable' property for 'Delete transcripts...' button
+	updateDeleteTranscriptsButton();
+
 }
 
 //------------------------------Updater---------------------------------------
diff --git a/indra/newview/llimview.cpp b/indra/newview/llimview.cpp
index 5acb0b63740450ee63cd2ce068bcdcc043fb3259..1cceb68e2af553446daf69547fcd86d0a70e0165 100644
--- a/indra/newview/llimview.cpp
+++ b/indra/newview/llimview.cpp
@@ -1591,6 +1591,11 @@ LLUUID LLIMMgr::computeSessionID(
 			session_id = other_participant_id ^ agent_id;
 		}
 	}
+
+	if (gAgent.isInGroup(session_id) && (session_id != other_participant_id))
+	{
+		llwarns << "Group session id different from group id: IM type = " << dialog << ", session id = " << session_id << ", group id = " << other_participant_id << llendl;
+	}
 	return session_id;
 }
 
diff --git a/indra/newview/llinventorybridge.cpp b/indra/newview/llinventorybridge.cpp
index 5bfd63f3dffdac7ab75d73eafbe78fa348a150ec..0ee78d57bd380cf592b9c002872cb506d2d2b36c 100644
--- a/indra/newview/llinventorybridge.cpp
+++ b/indra/newview/llinventorybridge.cpp
@@ -571,7 +571,7 @@ void hide_context_entries(LLMenuGL& menu,
 
 		// descend into split menus:
 		LLMenuItemBranchGL* branchp = dynamic_cast<LLMenuItemBranchGL*>(menu_item);
-		if (NULL != branchp)
+		if ((name == "More") && branchp)
 		{
 			hide_context_entries(*branchp->getBranch(), entries_to_show, disabled_entries);
 		}
diff --git a/indra/newview/llnotificationscripthandler.cpp b/indra/newview/llnotificationscripthandler.cpp
index 19dd6d4ca0940d59585b33e1d584dd644af72d33..08c98e4f282e7c15d062925884f72f25376439e0 100644
--- a/indra/newview/llnotificationscripthandler.cpp
+++ b/indra/newview/llnotificationscripthandler.cpp
@@ -98,7 +98,9 @@ bool LLScriptHandler::processNotification(const LLNotificationPtr& notification)
 		p.on_delete_toast = boost::bind(&LLScriptHandler::onDeleteToast, this, _1);
 		if(gAgent.isDoNotDisturb())
 		{ 
-			p.force_show = notification->getName() == "SystemMessage" || notification->getPriority() >= NOTIFICATION_PRIORITY_HIGH;
+			p.force_show = notification->getName() == "SystemMessage" 
+							||	notification->getName() == "GodMessage" 
+							|| notification->getPriority() >= NOTIFICATION_PRIORITY_HIGH;
 		}
 
 		LLScreenChannel* channel = dynamic_cast<LLScreenChannel*>(mChannel.get());
diff --git a/indra/newview/lltoastnotifypanel.cpp b/indra/newview/lltoastnotifypanel.cpp
index 0aab51453192cdd6a19b736df7170d53a8f0e0dc..bd6c42d4742011335e440706438e531fa63c31df 100644
--- a/indra/newview/lltoastnotifypanel.cpp
+++ b/indra/newview/lltoastnotifypanel.cpp
@@ -223,104 +223,6 @@ void LLToastNotifyPanel::adjustPanelForTipNotice()
 	}
 }
 
-//typedef std::set<std::string> button_name_set_t;
-//typedef std::map<std::string, button_name_set_t> disable_button_map_t;
-//
-//disable_button_map_t initUserGiveItemDisableButtonMap()
-//{
-//	// see EXT-5905 for disable rules
-//
-//	disable_button_map_t disable_map;
-//	button_name_set_t buttons;
-//
-//	buttons.insert("Show");
-//	disable_map.insert(std::make_pair("Show", buttons));
-//
-//	buttons.insert("Discard");
-//	disable_map.insert(std::make_pair("Discard", buttons));
-//
-//	buttons.insert("Mute");
-//	disable_map.insert(std::make_pair("Mute", buttons));
-//
-//	return disable_map;
-//}
-//
-//disable_button_map_t initTeleportOfferedDisableButtonMap()
-//{
-//	disable_button_map_t disable_map;
-//	button_name_set_t buttons;
-//
-//	buttons.insert("Teleport");
-//	buttons.insert("Cancel");
-//
-//	disable_map.insert(std::make_pair("Teleport", buttons));
-//	disable_map.insert(std::make_pair("Cancel", buttons));
-//
-//	return disable_map;
-//}
-//
-//disable_button_map_t initFriendshipOfferedDisableButtonMap()
-//{
-//	disable_button_map_t disable_map;
-//	button_name_set_t buttons;
-//
-//	buttons.insert("Accept");
-//	buttons.insert("Decline");
-//
-//	disable_map.insert(std::make_pair("Accept", buttons));
-//	disable_map.insert(std::make_pair("Decline", buttons));
-//
-//	return disable_map;
-//}
-//
-//button_name_set_t getButtonDisableList(const std::string& notification_name, const std::string& button_name)
-//{
-//	static disable_button_map_t user_give_item_disable_map = initUserGiveItemDisableButtonMap();
-//	static disable_button_map_t teleport_offered_disable_map = initTeleportOfferedDisableButtonMap();
-//	static disable_button_map_t friendship_offered_disable_map = initFriendshipOfferedDisableButtonMap();
-//
-//	disable_button_map_t::const_iterator it;
-//	disable_button_map_t::const_iterator it_end;
-//	disable_button_map_t search_map;
-//
-//	if("UserGiveItem" == notification_name)
-//	{
-//		search_map = user_give_item_disable_map;
-//	}
-//	else if("TeleportOffered" == notification_name)
-//	{
-//		search_map = teleport_offered_disable_map;
-//	}
-//	else if("OfferFriendship" == notification_name)
-//	{
-//		search_map = friendship_offered_disable_map;
-//	}
-//
-//	it = search_map.find(button_name);
-//	it_end = search_map.end();
-//
-//	if(it_end != it)
-//	{
-//		return it->second;
-//	}
-//	return button_name_set_t();
-//}
-
-//void LLToastNotifyPanel::disableButtons(const std::string& notification_name, const std::string& selected_button)
-//{
-	//button_name_set_t buttons = getButtonDisableList(notification_name, selected_button);
-
-	//std::vector<index_button_pair_t>::const_iterator it = mButtons.begin();
-	//for ( ; it != mButtons.end(); it++)
-	//{
-	//	LLButton* btn = it->second;
-	//	if(buttons.find(btn->getName()) != buttons.end())
-	//	{
-	//		btn->setEnabled(FALSE);
-	//	}
-	//}
-//}
-
 // static
 void LLToastNotifyPanel::onClickButton(void* data)
 {
@@ -352,7 +254,17 @@ void LLToastNotifyPanel::init( LLRect rect, bool show_images )
     mNumButtons = 0;
     mAddedDefaultBtn = false;
 
-    buildFromFile( "panel_notification.xml");
+	LLRect current_rect = getRect();
+
+	setXMLFilename("");
+	buildFromFile("panel_notification.xml");
+
+	// reshape the panel to its previous size
+	if (current_rect.notEmpty())
+	{
+		reshape(current_rect.getWidth(), current_rect.getHeight());
+	}
+
     if(rect != LLRect::null)
     {
         this->setShape(rect);
@@ -491,37 +403,9 @@ void LLToastNotifyPanel::init( LLRect rect, bool show_images )
         }
     }
 
-    // adjust panel's height to the text size
-    mInfoPanel->setFollowsAll();
     snapToMessageHeight(mTextBox, MAX_LENGTH);
 }
 
-
-
-//void LLToastNotifyPanel::onToastPanelButtonClicked(const LLUUID& notification_id, const std::string btn_name)
-//{
-//	if(mNotification->getID() == notification_id)
-//	{
-//		disableButtons(mNotification->getName(), btn_name);
-//	}
-//}
-
-//void LLToastNotifyPanel::disableRespondedOptions(const LLNotificationPtr& notification)
-//{
-//	LLSD response = notification->getResponse();
-//	for (LLSD::map_const_iterator response_it = response.beginMap(); 
-//		response_it != response.endMap(); ++response_it)
-//	{
-//		if (response_it->second.isBoolean() && response_it->second.asBoolean())
-//		{
-//			// that after multiple responses there can be many pressed buttons
-//			// need to process them all
-//			disableButtons(notification->getName(), response_it->first);
-//		}
-//	}
-//}
-
-
 //////////////////////////////////////////////////////////////////////////
 
 LLIMToastNotifyPanel::LLIMToastNotifyPanel(LLNotificationPtr& pNotification, const LLUUID& session_id, const LLRect& rect /* = LLRect::null */,
@@ -538,13 +422,12 @@ LLIMToastNotifyPanel::~LLIMToastNotifyPanel()
 
 void LLIMToastNotifyPanel::reshape(S32 width, S32 height, BOOL called_from_parent /* = TRUE */)
 {
+	LLToastPanel::reshape(width, height, called_from_parent);
 	snapToMessageHeight(mTextBox, MAX_LENGTH);
 }
 
 void LLIMToastNotifyPanel::compactButtons()
 {
-	mTextBox->setFollowsAll();
-
 	//we can't set follows in xml since it broke toasts behavior
 	setFollows(FOLLOWS_LEFT|FOLLOWS_RIGHT|FOLLOWS_TOP);
 
@@ -590,6 +473,5 @@ void LLIMToastNotifyPanel::init( LLRect rect, bool show_images )
 	compactButtons();
 }
 
-
 // EOF
 
diff --git a/indra/newview/lltoastpanel.cpp b/indra/newview/lltoastpanel.cpp
index 54d3912136bf2661edc5090cbbfee6758017fc03..187aee207c411c1ce4045d16bdcfab3af33cd258 100644
--- a/indra/newview/lltoastpanel.cpp
+++ b/indra/newview/lltoastpanel.cpp
@@ -81,9 +81,7 @@ void LLToastPanel::snapToMessageHeight(LLTextBase* message, S32 maxLineCount)
 		S32 newTextHeight = llmin(requiredTextHeight, maxTextHeight);
 
 		heightDelta = newTextHeight - oldTextHeight;
-		S32 new_panel_height = llmin(
-				llmax(getRect().getHeight() + heightDelta, MIN_PANEL_HEIGHT),
-				maxTextHeight);
+		S32 new_panel_height = llmax(getRect().getHeight() + heightDelta, MIN_PANEL_HEIGHT);
 
 		//reshape the panel with new height
 		if (new_panel_height != getRect().getHeight())
diff --git a/indra/newview/llviewermessage.cpp b/indra/newview/llviewermessage.cpp
index 359819ec493b04e587b91537583350082a4a7dde..6bbfd307947a44cb3e38dd9553dfe8d83a5bbca2 100755
--- a/indra/newview/llviewermessage.cpp
+++ b/indra/newview/llviewermessage.cpp
@@ -2371,7 +2371,7 @@ void process_improved_im(LLMessageSystem *msg, void **user_data)
 	LLNotification::Params params;
 
 	switch(dialog)
-	{
+	{ 
 	case IM_CONSOLE_AND_CHAT_HISTORY:
 		args["MESSAGE"] = message;
 		payload["from_id"] = from_id;
@@ -2391,7 +2391,10 @@ void process_improved_im(LLMessageSystem *msg, void **user_data)
 			// do nothing -- don't distract newbies in
 			// Prelude with global IMs
 		}
-		else if (offline == IM_ONLINE && is_do_not_disturb && from_id.notNull())
+		else if (offline == IM_ONLINE 
+					&& is_do_not_disturb
+					&& from_id.notNull() //not a system message
+					&& to_id.notNull()) //not global message
 		{
 			// return a standard "do not disturb" message, but only do it to online IM 
 			// (i.e. not other auto responses and not store-and-forward IM)
diff --git a/indra/newview/skins/default/xui/en/panel_notification.xml b/indra/newview/skins/default/xui/en/panel_notification.xml
index 94c468e1bb0d06e189cc7d6cfeeee4ae94a13f8d..421ecf10a17f916833f40826400a5c0ea14deb36 100644
--- a/indra/newview/skins/default/xui/en/panel_notification.xml
+++ b/indra/newview/skins/default/xui/en/panel_notification.xml
@@ -22,7 +22,7 @@
     background_visible="true"
   bg_alpha_color="ToastBackground"
   bg_opaque_color="ToastBackground"
-    follows="left|right|top"
+    follows="all"
     height="100"
     label="info_panel"
     layout="topleft"