From a6b6ca9a24cbc1bfe0b3e45602e1eda1e1e9c8f9 Mon Sep 17 00:00:00 2001
From: richard <none@none>
Date: Mon, 2 Nov 2009 14:58:39 -0800
Subject: made floater close/minimize buttons "chrome" so they don't take
 keyboard focus removed LLHudView::colorFromType which was unused

reviewed by James
---
 indra/llui/llfloater.cpp       |  1 +
 indra/newview/llhudview.cpp    | 14 --------------
 indra/newview/llhudview.h      |  2 --
 indra/newview/llviewermenu.cpp |  1 -
 4 files changed, 1 insertion(+), 17 deletions(-)

(limited to 'indra')

diff --git a/indra/llui/llfloater.cpp b/indra/llui/llfloater.cpp
index 8c72b079ee..26a8b6c48f 100644
--- a/indra/llui/llfloater.cpp
+++ b/indra/llui/llfloater.cpp
@@ -1839,6 +1839,7 @@ void LLFloater::buildButtons()
 		p.follows.flags(FOLLOWS_TOP|FOLLOWS_RIGHT);
 		p.tool_tip(sButtonToolTips[i]);
 		p.scale_image(true);
+		p.chrome(true);
 
 		LLButton* buttonp = LLUICtrlFactory::create<LLButton>(p);
 		addChild(buttonp);
diff --git a/indra/newview/llhudview.cpp b/indra/newview/llhudview.cpp
index 027cd2ab07..261d9f1df7 100644
--- a/indra/newview/llhudview.cpp
+++ b/indra/newview/llhudview.cpp
@@ -71,20 +71,6 @@ void LLHUDView::draw()
 	LLView::draw();
 }
 
-
-// public
-const LLColor4& LLHUDView::colorFromType(S32 type)
-{
-	switch (type)
-	{
-	case 0:
-		return LLColor4::green;
-	default:
-		return LLColor4::black;
-	}
-}
-
-
 /*virtual*/
 BOOL LLHUDView::handleMouseDown(S32 x, S32 y, MASK mask)
 {
diff --git a/indra/newview/llhudview.h b/indra/newview/llhudview.h
index 05ff9c8596..0946e2c5c8 100644
--- a/indra/newview/llhudview.h
+++ b/indra/newview/llhudview.h
@@ -47,8 +47,6 @@ public:
 
 	virtual void draw();
 
-	const LLColor4& colorFromType(S32 type);
-
 protected:
 	/*virtual*/ BOOL handleMouseDown(S32 x, S32 y, MASK mask);
 };
diff --git a/indra/newview/llviewermenu.cpp b/indra/newview/llviewermenu.cpp
index 864cf9d57b..c801ffc01e 100644
--- a/indra/newview/llviewermenu.cpp
+++ b/indra/newview/llviewermenu.cpp
@@ -145,7 +145,6 @@
 #include "llmenucommands.h"
 #include "llmenugl.h"
 #include "llmimetypes.h"
-#include "llmorphview.h"
 #include "llmoveview.h"
 #include "llmutelist.h"
 #include "llnotify.h"
-- 
cgit v1.2.3


From a100a6e07f8b6ea16313e25e3249736228d9b03c Mon Sep 17 00:00:00 2001
From: "Nyx (Neal Orman)" <nyx@lindenlab.com>
Date: Mon, 2 Nov 2009 19:05:20 -0500
Subject: EXT-1947 EXT-1945 EXT-1919 EXT-2088 appearance edit dummy param +
 animation fix

Several fixes here:
1) minor rename in argument of setIsDummy
2) corrected parameter set_by_user to calls of setVisualParamWeight where we
   shouldn't be animating
3) ensured finally that mIsDummy is set properly for all wearable parameters
4) ensured that mIsDUmmy is set properly for non-wearable based parameters on
   your own avatar

Code reviewed by Bigpapi
---
 indra/llcharacter/llvisualparam.h       |  2 +-
 indra/newview/lldriverparam.cpp         |  1 -
 indra/newview/llscrollingpanelparam.cpp |  8 ++++----
 indra/newview/llvoavatarself.cpp        |  5 ++++-
 indra/newview/llwearable.cpp            | 19 ++++++-------------
 5 files changed, 15 insertions(+), 20 deletions(-)

(limited to 'indra')

diff --git a/indra/llcharacter/llvisualparam.h b/indra/llcharacter/llvisualparam.h
index affc49debf..eec56d7844 100644
--- a/indra/llcharacter/llvisualparam.h
+++ b/indra/llcharacter/llvisualparam.h
@@ -151,7 +151,7 @@ public:
 	virtual void			setAnimating(BOOL is_animating) { mIsAnimating = is_animating && !mIsDummy; }
 	BOOL					getAnimating() const { return mIsAnimating; }
 
-	void					setIsDummy(BOOL is_self) { mIsDummy = is_self; }
+	void					setIsDummy(BOOL is_dummy) { mIsDummy = is_dummy; }
 
 protected:
 	F32					mCurWeight;			// current weight
diff --git a/indra/newview/lldriverparam.cpp b/indra/newview/lldriverparam.cpp
index 527656ab6b..45f4b4fbd0 100644
--- a/indra/newview/lldriverparam.cpp
+++ b/indra/newview/lldriverparam.cpp
@@ -224,7 +224,6 @@ void LLDriverParam::setAvatar(LLVOAvatar *avatarp)
 		}
 	}
 	*new_param = *this;
-	new_param->setIsDummy(FALSE);
 	return new_param;
 }
 
diff --git a/indra/newview/llscrollingpanelparam.cpp b/indra/newview/llscrollingpanelparam.cpp
index 0a520ff65f..1fbaeb94f5 100644
--- a/indra/newview/llscrollingpanelparam.cpp
+++ b/indra/newview/llscrollingpanelparam.cpp
@@ -209,7 +209,7 @@ void LLScrollingPanelParam::onSliderMoved(LLUICtrl* ctrl, void* userdata)
 	F32 new_weight = self->percentToWeight( (F32)slider->getValue().asReal() );
 	if (current_weight != new_weight )
 	{
-		self->mWearable->setVisualParamWeight( param->getID(), new_weight, TRUE );
+		self->mWearable->setVisualParamWeight( param->getID(), new_weight, FALSE );
 		gAgent.getAvatarObject()->updateVisualParams();
 	}
 }
@@ -298,7 +298,7 @@ void LLScrollingPanelParam::onHintHeldDown( LLVisualParamHint* hint )
 			if (slider->getMinValue() < new_percent
 				&& new_percent < slider->getMaxValue())
 			{
-				mWearable->setVisualParamWeight( hint->getVisualParam()->getID(), new_weight, TRUE);
+				mWearable->setVisualParamWeight( hint->getVisualParam()->getID(), new_weight, FALSE);
 				gAgent.getAvatarObject()->updateVisualParams();
 
 				slider->setValue( weightToPercent( new_weight ) );
@@ -330,7 +330,7 @@ void LLScrollingPanelParam::onHintMinMouseUp( void* userdata )
 			if (slider->getMinValue() < new_percent
 				&& new_percent < slider->getMaxValue())
 			{
-				self->mWearable->setVisualParamWeight(hint->getVisualParam()->getID(), new_weight, TRUE);
+				self->mWearable->setVisualParamWeight(hint->getVisualParam()->getID(), new_weight, FALSE);
 				slider->setValue( self->weightToPercent( new_weight ) );
 			}
 		}
@@ -364,7 +364,7 @@ void LLScrollingPanelParam::onHintMaxMouseUp( void* userdata )
 				if (slider->getMinValue() < new_percent
 					&& new_percent < slider->getMaxValue())
 				{
-					self->mWearable->setVisualParamWeight(hint->getVisualParam()->getID(), new_weight, TRUE);
+					self->mWearable->setVisualParamWeight(hint->getVisualParam()->getID(), new_weight, FALSE);
 					slider->setValue( self->weightToPercent( new_weight ) );
 				}
 			}
diff --git a/indra/newview/llvoavatarself.cpp b/indra/newview/llvoavatarself.cpp
index 758db538a2..34e6b0f89e 100644
--- a/indra/newview/llvoavatarself.cpp
+++ b/indra/newview/llvoavatarself.cpp
@@ -205,7 +205,10 @@ void LLVOAvatarSelf::markDead()
 		 param;
 		 param = (LLViewerVisualParam*) getNextVisualParam())
 	{
-		param->setIsDummy(TRUE);
+		if (param->getWearableType() != WT_INVALID)
+		{
+			param->setIsDummy(TRUE);
+		}
 	}
 
 	return success;
diff --git a/indra/newview/llwearable.cpp b/indra/newview/llwearable.cpp
index 4cd29bb838..c32fc2bae1 100644
--- a/indra/newview/llwearable.cpp
+++ b/indra/newview/llwearable.cpp
@@ -60,7 +60,7 @@ static std::string asset_id_to_filename(const LLUUID &asset_id);
 
 LLWearable::LLWearable(const LLTransactionID& transaction_id) :
 	mDefinitionVersion(LLWearable::sCurrentDefinitionVersion),
-	mType(WT_SHAPE)
+	mType(WT_INVALID)
 {
 	mTransactionID = transaction_id;
 	mAssetID = mTransactionID.makeAssetID(gAgent.getSecureSessionID());
@@ -68,7 +68,7 @@ LLWearable::LLWearable(const LLTransactionID& transaction_id) :
 
 LLWearable::LLWearable(const LLAssetID& asset_id) :
 	mDefinitionVersion( LLWearable::sCurrentDefinitionVersion ),
-	mType(WT_SHAPE)
+	mType(WT_INVALID)
 {
 	mAssetID = asset_id;
 	mTransactionID.setNull();
@@ -181,13 +181,7 @@ void LLWearable::createVisualParams()
 	{
 		if (param->getWearableType() == mType)
 		{
-			if (mVisualParamIndexMap[param->getID()])
-			{
-				delete mVisualParamIndexMap[param->getID()];
-			}
-			LLViewerVisualParam *new_param = param->cloneParam(this);
-			new_param->setIsDummy(FALSE);
-			mVisualParamIndexMap[param->getID()] = new_param;
+			addVisualParam(param->cloneParam(this));
 		}
 	}
 
@@ -750,7 +744,8 @@ void LLWearable::copyDataFrom(const LLWearable* src)
 	mDescription = src->mDescription;
 	mPermissions = src->mPermissions;
 	mSaleInfo = src->mSaleInfo;
-	mType = src->mType;
+
+	setType(src->mType);
 
 	mSavedVisualParamMap.clear();
 	// Deep copy of mVisualParamMap (copies only those params that are current, filling in defaults where needed)
@@ -763,9 +758,6 @@ void LLWearable::copyDataFrom(const LLWearable* src)
 			S32 id = param->getID();
 			F32 weight = src->getVisualParamWeight(id);
 			mSavedVisualParamMap[id] = weight;
-			
-			// Clones a visual param from src and adds it to this wearable. Value of param is taken from current value of source param, not saved.
-			addVisualParam(param->cloneParam(this));
 		}
 	}
 
@@ -860,6 +852,7 @@ void LLWearable::addVisualParam(LLVisualParam *param)
 	{
 		delete mVisualParamIndexMap[param->getID()];
 	}
+	param->setIsDummy(FALSE);
 	mVisualParamIndexMap[param->getID()] = param;
 }
 
-- 
cgit v1.2.3


From 995c18b1c7eb8fd23c0a35d5f504c03b7f2b144f Mon Sep 17 00:00:00 2001
From: richard <none@none>
Date: Mon, 2 Nov 2009 19:28:24 -0800
Subject: removed picture_style from LLButton::Params and allow empty labels

---
 indra/llui/llbutton.cpp                            | 32 +++-------------------
 indra/llui/llbutton.h                              |  5 +---
 indra/llui/llfloater.cpp                           |  1 -
 indra/llui/llflyoutbutton.cpp                      |  1 +
 indra/llui/llmenugl.cpp                            |  2 --
 indra/llui/llscrollbar.cpp                         |  2 ++
 indra/llui/lltabcontainer.cpp                      |  4 ++-
 indra/newview/llchiclet.cpp                        |  3 --
 indra/newview/lldebugmessagebox.cpp                |  1 +
 indra/newview/llfavoritesbar.cpp                   |  1 +
 .../default/xui/en/floater_animation_preview.xml   |  2 --
 .../skins/default/xui/en/floater_avatar_picker.xml |  2 --
 .../skins/default/xui/en/floater_camera.xml        |  7 -----
 .../skins/default/xui/en/floater_color_picker.xml  |  1 -
 .../skins/default/xui/en/floater_gesture.xml       |  3 --
 .../skins/default/xui/en/floater_lagmeter.xml      |  3 --
 .../skins/default/xui/en/floater_media_browser.xml |  2 --
 .../skins/default/xui/en/floater_moveview.xml      |  6 ----
 .../skins/default/xui/en/floater_report_abuse.xml  |  1 -
 .../skins/default/xui/en/floater_test_button.xml   |  2 --
 .../skins/default/xui/en/floater_texture_ctrl.xml  |  1 -
 .../newview/skins/default/xui/en/floater_tools.xml | 27 ------------------
 .../skins/default/xui/en/inspect_avatar.xml        |  4 ---
 .../newview/skins/default/xui/en/inspect_group.xml |  1 -
 .../skins/default/xui/en/inspect_object.xml        |  2 --
 .../default/xui/en/panel_avatar_list_item.xml      |  2 --
 .../skins/default/xui/en/panel_bottomtray.xml      |  1 -
 .../skins/default/xui/en/panel_edit_pick.xml       |  1 -
 .../skins/default/xui/en/panel_edit_wearable.xml   |  1 -
 .../default/xui/en/panel_group_info_sidetray.xml   |  2 --
 .../skins/default/xui/en/panel_group_list_item.xml |  2 --
 .../skins/default/xui/en/panel_landmarks.xml       |  3 --
 .../skins/default/xui/en/panel_navigation_bar.xml  |  4 ---
 .../default/xui/en/panel_notifications_channel.xml |  1 -
 .../newview/skins/default/xui/en/panel_people.xml  | 11 --------
 .../skins/default/xui/en/panel_pick_info.xml       |  1 -
 .../skins/default/xui/en/panel_pick_list_item.xml  |  1 -
 indra/newview/skins/default/xui/en/panel_picks.xml |  3 --
 .../newview/skins/default/xui/en/panel_places.xml  |  1 -
 .../default/xui/en/panel_preferences_alerts.xml    |  2 --
 .../default/xui/en/panel_preferences_sound.xml     |  7 -----
 .../default/xui/en/panel_prim_media_controls.xml   | 18 ------------
 .../skins/default/xui/en/panel_profile_view.xml    |  1 -
 .../skins/default/xui/en/panel_progress.xml        |  1 -
 .../skins/default/xui/en/panel_scrolling_param.xml |  2 --
 .../default/xui/en/panel_teleport_history.xml      |  1 -
 .../default/xui/en/panel_teleport_history_item.xml |  2 --
 .../skins/default/xui/en/widgets/combo_box.xml     |  2 --
 .../default/xui/en/widgets/location_input.xml      |  2 --
 .../skins/default/xui/en/widgets/search_editor.xml |  4 +--
 .../skins/default/xui/es/floater_script_debug.xml  |  2 +-
 .../skins/default/xui/it/floater_script_debug.xml  |  2 +-
 .../skins/default/xui/nl/floater_script_debug.xml  |  2 +-
 .../skins/default/xui/pt/floater_script_debug.xml  |  2 +-
 54 files changed, 19 insertions(+), 181 deletions(-)

(limited to 'indra')

diff --git a/indra/llui/llbutton.cpp b/indra/llui/llbutton.cpp
index a7946cacf5..8daceb9485 100644
--- a/indra/llui/llbutton.cpp
+++ b/indra/llui/llbutton.cpp
@@ -95,8 +95,7 @@ LLButton::Params::Params()
 	is_toggle("is_toggle", false),
 	scale_image("scale_image", true),
 	hover_glow_amount("hover_glow_amount"),
-	commit_on_return("commit_on_return", true),
-	picture_style("picture_style", false)
+	commit_on_return("commit_on_return", true)
 {
 	addSynonym(is_toggle, "toggle");
 	held_down_delay.seconds = 0.5f;
@@ -153,17 +152,9 @@ LLButton::LLButton(const LLButton::Params& p)
 	static LLUICachedControl<S32> llbutton_orig_h_pad ("UIButtonOrigHPad", 0);
 	static Params default_params(LLUICtrlFactory::getDefaultParams<LLButton>());
 
-	//if we aren't a picture_style button set label as name if not provided
-	if (!p.picture_style.isProvided() || !p.picture_style)
+	if (!p.label_selected.isProvided())
 	{
-		if (!p.label.isProvided()) 
-		{
-			mUnselectedLabel = p.name();
-		}
-		if (!p.label_selected.isProvided())	
-		{
-			mSelectedLabel = mUnselectedLabel.getString();
-		}
+		mSelectedLabel = mUnselectedLabel;
 	}
 
 	// Hack to make sure there is space for at least one character
@@ -1099,19 +1090,4 @@ void LLButton::resetMouseDownTimer()
 {
 	mMouseDownTimer.stop();
 	mMouseDownTimer.reset();
-}
-
-
-// *TODO: Remove this function after the initial XUI XML re-export pass.
-// static
-void LLButton::setupParamsForExport(Params& p, LLView* parent)
-{
-	std::string label = p.label;
-	if (label.empty())
-	{
-		//if our label is empty this is a picture style button
-		p.picture_style = true;
-	}
-
-	LLUICtrl::setupParamsForExport(p, parent);
-}
+}
\ No newline at end of file
diff --git a/indra/llui/llbutton.h b/indra/llui/llbutton.h
index 85580a98bf..08f289092f 100644
--- a/indra/llui/llbutton.h
+++ b/indra/llui/llbutton.h
@@ -115,8 +115,7 @@ public:
 		// misc
 		Optional<bool>			is_toggle,
 								scale_image,
-								commit_on_return,
-								picture_style;      //if true, don't display label
+								commit_on_return;
 		
 		Optional<F32>				hover_glow_amount;
 		Optional<TimeIntervalParam>	held_down_delay;
@@ -247,8 +246,6 @@ protected:
 
 	LLFrameTimer	mMouseDownTimer;
 
-	// If the label is empty, set the picture_style attribute
-	static void setupParamsForExport(Params& p, LLView* parent);
 private:
 	void			drawBorder(LLUIImage* imagep, const LLColor4& color, S32 size);
 	void			resetMouseDownTimer();
diff --git a/indra/llui/llfloater.cpp b/indra/llui/llfloater.cpp
index 26a8b6c48f..90ba2dc41f 100644
--- a/indra/llui/llfloater.cpp
+++ b/indra/llui/llfloater.cpp
@@ -1826,7 +1826,6 @@ void LLFloater::buildButtons()
 		LLButton::Params p;
 		p.name(sButtonNames[i]);
 		p.rect(btn_rect);
-		p.label("");
 		p.image_unselected.name(sButtonActiveImageNames[i]);
 		// Selected, no matter if hovered or not, is "pressed"
 		p.image_selected.name(sButtonPressedImageNames[i]);
diff --git a/indra/llui/llflyoutbutton.cpp b/indra/llui/llflyoutbutton.cpp
index 3483bac782..abb0b869eb 100644
--- a/indra/llui/llflyoutbutton.cpp
+++ b/indra/llui/llflyoutbutton.cpp
@@ -48,6 +48,7 @@ LLFlyoutButton::LLFlyoutButton(const Params& p)
 	// Text label button
 	LLButton::Params bp(p.action_button);
 	bp.name(p.label);
+	bp.label(p.label);
 	bp.rect.left(0).bottom(0).width(getRect().getWidth() - FLYOUT_BUTTON_ARROW_WIDTH).height(getRect().getHeight());
 	bp.click_callback.function(boost::bind(&LLFlyoutButton::onActionButtonClick, this, _2));
 	bp.follows.flags(FOLLOWS_ALL);
diff --git a/indra/llui/llmenugl.cpp b/indra/llui/llmenugl.cpp
index 91e7e46195..7847cc1790 100644
--- a/indra/llui/llmenugl.cpp
+++ b/indra/llui/llmenugl.cpp
@@ -1555,8 +1555,6 @@ LLMenuScrollItem::LLMenuScrollItem(const Params& p)
 	}
 
 	LLButton::Params bparams;
-	bparams.label("");
-	bparams.label_selected("");
 	bparams.mouse_opaque(true);
 	bparams.scale_image(false);
 	bparams.click_callback(p.scroll_callback);
diff --git a/indra/llui/llscrollbar.cpp b/indra/llui/llscrollbar.cpp
index dfd315d451..b450ecbbf9 100644
--- a/indra/llui/llscrollbar.cpp
+++ b/indra/llui/llscrollbar.cpp
@@ -115,6 +115,7 @@ LLScrollbar::LLScrollbar(const Params & p)
 
 	LLButton::Params up_btn(mOrientation == VERTICAL ? p.up_button : p.left_button);
 	up_btn.name(std::string("Line Up"));
+	up_btn.label(std::string("Line Up"));
 	up_btn.rect(line_up_rect);
 	up_btn.click_callback.function(boost::bind(&LLScrollbar::onLineUpBtnPressed, this, _2));
 	up_btn.mouse_held_callback.function(boost::bind(&LLScrollbar::onLineUpBtnPressed, this, _2));
@@ -125,6 +126,7 @@ LLScrollbar::LLScrollbar(const Params & p)
 
 	LLButton::Params down_btn(mOrientation == VERTICAL ? p.down_button : p.right_button);
 	down_btn.name(std::string("Line Down"));
+	down_btn.label(std::string("Line Down"));
 	down_btn.rect(line_down_rect);
 	down_btn.follows.flags(FOLLOWS_RIGHT|FOLLOWS_BOTTOM);
 	down_btn.click_callback.function(boost::bind(&LLScrollbar::onLineDownBtnPressed, this, _2));
diff --git a/indra/llui/lltabcontainer.cpp b/indra/llui/lltabcontainer.cpp
index cde4c75518..6ca9c4ceda 100644
--- a/indra/llui/lltabcontainer.cpp
+++ b/indra/llui/lltabcontainer.cpp
@@ -927,7 +927,7 @@ void LLTabContainer::addTabPanel(const TabPanelParams& panel)
 		textbox = LLUICtrlFactory::create<LLTextBox> (params);
 		
 		LLButton::Params p;
-		p.name("");
+		p.name("placeholder");
 		btn = LLUICtrlFactory::create<LLButton>(p);
 	}
 	else
@@ -1645,6 +1645,7 @@ void LLTabContainer::initButtons()
 
 		LLButton::Params prev_btn_params;
 		prev_btn_params.name(std::string("Up Arrow"));
+		prev_btn_params.label(std::string("Up Arrow"));
 		prev_btn_params.rect(up_arrow_btn_rect);
 		prev_btn_params.follows.flags(FOLLOWS_TOP | FOLLOWS_LEFT);
 		prev_btn_params.image_unselected.name("scrollbutton_up_out_blue.tga");
@@ -1654,6 +1655,7 @@ void LLTabContainer::initButtons()
 
 		LLButton::Params next_btn_params;
 		next_btn_params.name(std::string("Down Arrow"));
+		next_btn_params.label(std::string("Down Arrow"));
 		next_btn_params.rect(down_arrow_btn_rect);
 		next_btn_params.follows.flags(FOLLOWS_BOTTOM | FOLLOWS_LEFT);
 		next_btn_params.image_unselected.name("scrollbutton_down_out_blue.tga");
diff --git a/indra/newview/llchiclet.cpp b/indra/newview/llchiclet.cpp
index bad61101c1..7214ac2886 100644
--- a/indra/newview/llchiclet.cpp
+++ b/indra/newview/llchiclet.cpp
@@ -1264,17 +1264,14 @@ LLTalkButton::Params::Params()
 	speak_button.font(LLFontGL::getFontSansSerifSmall());
 	speak_button.tab_stop(false);
 	speak_button.is_toggle(true);
-	speak_button.picture_style(true);
 	// Use default button art. JC
 	//speak_button.image_selected(LLUI::getUIImage("SegmentedBtn_Left_Selected"));
 	//speak_button.image_unselected(LLUI::getUIImage("SegmentedBtn_Left_Off"));
 
 	show_button.name("right");
-	show_button.label(LLStringUtil::null);
 	show_button.rect(LLRect(0, 0, 20, 0));
 	show_button.tab_stop(false);
 	show_button.is_toggle(true);
-	show_button.picture_style(true);
 	show_button.image_selected(LLUI::getUIImage("ComboButton_Selected"));
 	show_button.image_unselected(LLUI::getUIImage("ComboButton_Off"));
 
diff --git a/indra/newview/lldebugmessagebox.cpp b/indra/newview/lldebugmessagebox.cpp
index 29e375c9fa..7814e94dfd 100644
--- a/indra/newview/lldebugmessagebox.cpp
+++ b/indra/newview/lldebugmessagebox.cpp
@@ -124,6 +124,7 @@ LLDebugVarMessageBox::LLDebugVarMessageBox(const std::string& title, EDebugVarTy
 
 	LLButton::Params p;
 	p.name(std::string("Animate"));
+	p.label(std::string("Animate"));
 	p.rect(LLRect(20, 45, 180, 25));
 	p.click_callback.function(boost::bind(&LLDebugVarMessageBox::onAnimateClicked, this, _2));
 	mAnimateButton = LLUICtrlFactory::create<LLButton>(p);
diff --git a/indra/newview/llfavoritesbar.cpp b/indra/newview/llfavoritesbar.cpp
index a6afbc05be..04860b061c 100644
--- a/indra/newview/llfavoritesbar.cpp
+++ b/indra/newview/llfavoritesbar.cpp
@@ -750,6 +750,7 @@ void LLFavoritesBarCtrl::updateButtons(U32 bar_width)
 			bparams.tab_stop(false);
 			bparams.font(mFont);
 			bparams.name(">>");
+			bparams.label(">>");
 			bparams.tool_tip(mChevronButtonToolTip);
 			bparams.click_callback.function(boost::bind(&LLFavoritesBarCtrl::showDropDownMenu, this));
 
diff --git a/indra/newview/skins/default/xui/en/floater_animation_preview.xml b/indra/newview/skins/default/xui/en/floater_animation_preview.xml
index ab3d5722f0..ebce758d3d 100644
--- a/indra/newview/skins/default/xui/en/floater_animation_preview.xml
+++ b/indra/newview/skins/default/xui/en/floater_animation_preview.xml
@@ -455,7 +455,6 @@ Maximum animation length is [MAX_LENGTH] seconds.
      layout="topleft"
      left="10"
      name="play_btn"
-     picture_style="true"
      tool_tip="Play/pause your animation"
      top_pad="0"
      width="28" />
@@ -467,7 +466,6 @@ Maximum animation length is [MAX_LENGTH] seconds.
      layout="topleft"
      left_pad="4"
      name="stop_btn"
-     picture_style="true"
      tool_tip="Stop animation playback"
      top_delta="0"
      width="28" />
diff --git a/indra/newview/skins/default/xui/en/floater_avatar_picker.xml b/indra/newview/skins/default/xui/en/floater_avatar_picker.xml
index 3f4f8b197f..8cfe5288fd 100644
--- a/indra/newview/skins/default/xui/en/floater_avatar_picker.xml
+++ b/indra/newview/skins/default/xui/en/floater_avatar_picker.xml
@@ -116,7 +116,6 @@
              height="20"
              width="20"
              name="RefreshFriends"
-             picture_style="true"
              image_overlay="Refresh_Off">
              <button.commit_callback 
               function="Refresh.FriendList"/>
@@ -188,7 +187,6 @@
              height="28"
              width="28"
              name="Refresh"
-             picture_style="true"
              image_overlay="Refresh_Off" />
             <scroll_list
              follows="all"
diff --git a/indra/newview/skins/default/xui/en/floater_camera.xml b/indra/newview/skins/default/xui/en/floater_camera.xml
index 1b69418013..a569b62e96 100644
--- a/indra/newview/skins/default/xui/en/floater_camera.xml
+++ b/indra/newview/skins/default/xui/en/floater_camera.xml
@@ -42,7 +42,6 @@
          layout="topleft"
          left="45"
          name="cam_track_stick"
-         picture_style="true"
          quadrant="left"
          scale_image="false"
          sound_flags="3"
@@ -59,7 +58,6 @@
          left="7"
          minus_image="ScrollThumb_Vert"
          name="zoom"
-         picture_style="true"
          plus_image="ScrollThumb_Vert"
          quadrant="left"
          scale_image="false"
@@ -75,7 +73,6 @@
          layout="topleft"
          left="45"
          name="cam_rotate_stick"
-         picture_style="true"
          quadrant="left"
          scale_image="false"
          sound_flags="3"
@@ -98,7 +95,6 @@
              layout="topleft"
              left="5"
              name="rear_view"
-             picture_style="true"
              tool_tip="Rear View"
              top="2"
              width="30">
@@ -113,7 +109,6 @@
              layout="topleft"
              left_pad="5"
              name="group_view"
-             picture_style="true"
              tool_tip="Group View"
              top="2"
              width="30">
@@ -128,7 +123,6 @@
              layout="topleft"
              left="5"
              name="front_view"
-             picture_style="true"
              tool_tip="Front View"
              top_pad="5"
              width="30">
@@ -143,7 +137,6 @@
              layout="topleft"
              left_pad="5"
              name="mouselook_view"
-             picture_style="true"
              tool_tip="Mouselook View"
              top_pad="-30"
              width="30">
diff --git a/indra/newview/skins/default/xui/en/floater_color_picker.xml b/indra/newview/skins/default/xui/en/floater_color_picker.xml
index 686b8dc40f..7c6376d84a 100644
--- a/indra/newview/skins/default/xui/en/floater_color_picker.xml
+++ b/indra/newview/skins/default/xui/en/floater_color_picker.xml
@@ -180,7 +180,6 @@
      layout="topleft"
      left_pad="30"
      name="color_pipette"
-     picture_style="true"
      width="32" />
     <button
      follows="right|bottom"
diff --git a/indra/newview/skins/default/xui/en/floater_gesture.xml b/indra/newview/skins/default/xui/en/floater_gesture.xml
index 128d518e12..90b3339225 100644
--- a/indra/newview/skins/default/xui/en/floater_gesture.xml
+++ b/indra/newview/skins/default/xui/en/floater_gesture.xml
@@ -68,7 +68,6 @@
                layout="topleft"
                left="10"
                name="recent_viewsort_btn"
-               picture_style="true"
                top="5"
                width="18" />
               <button
@@ -81,7 +80,6 @@
                  layout="topleft"
                  left_pad="5"
                  name="new_gesture_btn"
-                 picture_style="true"
                  tool_tip="Make new gesture"
                  top_delta="0"
                  width="18" />
@@ -95,7 +93,6 @@
                  layout="topleft"
                  left_pad="230"
                  name="del_btn"
-                 picture_style="true"
                  tool_tip="Delete this gesture"
                  top_delta="0"
                  width="18" />
diff --git a/indra/newview/skins/default/xui/en/floater_lagmeter.xml b/indra/newview/skins/default/xui/en/floater_lagmeter.xml
index d98fdc5118..1ee6fd57e7 100644
--- a/indra/newview/skins/default/xui/en/floater_lagmeter.xml
+++ b/indra/newview/skins/default/xui/en/floater_lagmeter.xml
@@ -184,7 +184,6 @@
      layout="topleft"
      left="8"
      name="client_lagmeter"
-     picture_style="true"
      tab_stop="false"
      tool_tip="Client lag status"
      top="24"
@@ -233,7 +232,6 @@
      layout="topleft"
      left="8"
      name="network_lagmeter"
-     picture_style="true"
      tab_stop="false"
      tool_tip="Network lag status"
      top="64"
@@ -282,7 +280,6 @@
      layout="topleft"
      left="8"
      name="server_lagmeter"
-     picture_style="true"
      tab_stop="false"
      tool_tip="Server lag status"
      top="104"
diff --git a/indra/newview/skins/default/xui/en/floater_media_browser.xml b/indra/newview/skins/default/xui/en/floater_media_browser.xml
index b11892be74..bc590dc612 100644
--- a/indra/newview/skins/default/xui/en/floater_media_browser.xml
+++ b/indra/newview/skins/default/xui/en/floater_media_browser.xml
@@ -127,7 +127,6 @@
              layout="topleft"
              left_delta="55"
              name="play"
-             picture_style="true"
              top_delta="0"
              width="55" />
             <button
@@ -138,7 +137,6 @@
              layout="topleft"
              left_delta="0"
              name="pause"
-             picture_style="true"
              top_delta="0"
              width="55" />
             <button
diff --git a/indra/newview/skins/default/xui/en/floater_moveview.xml b/indra/newview/skins/default/xui/en/floater_moveview.xml
index 02cbef5987..5a8ffcebea 100644
--- a/indra/newview/skins/default/xui/en/floater_moveview.xml
+++ b/indra/newview/skins/default/xui/en/floater_moveview.xml
@@ -56,7 +56,6 @@
          layout="topleft"
          left="17"
          name="turn left btn"
-         picture_style="true"
          scale_image="false"
          tool_tip="Turn left (press Left Arrow or A)"
          top="45"
@@ -70,7 +69,6 @@
          layout="topleft"
          left_pad="34"
          name="turn right btn"
-         picture_style="true"
          scale_image="false"
          tool_tip="Turn right (press Right Arrow or D)"
          top_delta="0"
@@ -84,7 +82,6 @@
          layout="topleft"
          left="10"
          name="move up btn"
-         picture_style="true"
          scale_image="false"
          tool_tip="Fly up, press &quot;E&quot;"
          top="14"
@@ -98,7 +95,6 @@
          layout="topleft"
          left_pad="45"
          name="move down btn"
-         picture_style="true"
          scale_image="false"
          tool_tip="Fly down, press &quot;C&quot;"
          top_delta="0"
@@ -112,7 +108,6 @@
          layout="topleft"
          left="46"
          name="forward btn"
-         picture_style="true"
          quadrant="up"
          scale_image="false"
          tool_tip="Walk forward (press up arrow or W)"
@@ -127,7 +122,6 @@
          layout="topleft"
          left_delta="0"
          name="backward btn"
-         picture_style="true"
          quadrant="down"
          scale_image="false"
          tool_tip="Walk backward (press down arrow or S)"
diff --git a/indra/newview/skins/default/xui/en/floater_report_abuse.xml b/indra/newview/skins/default/xui/en/floater_report_abuse.xml
index 88f09b521c..0b61dcef58 100644
--- a/indra/newview/skins/default/xui/en/floater_report_abuse.xml
+++ b/indra/newview/skins/default/xui/en/floater_report_abuse.xml
@@ -126,7 +126,6 @@
      layout="topleft"
      left_delta="0"
      name="pick_btn"
-     picture_style="true"
      image_overlay="Inv_Object"
      tool_tip="Object Picker - Identify an object as the subject of this report"
      top_pad="0"
diff --git a/indra/newview/skins/default/xui/en/floater_test_button.xml b/indra/newview/skins/default/xui/en/floater_test_button.xml
index 89a1ddda99..2bd0d1a0fa 100644
--- a/indra/newview/skins/default/xui/en/floater_test_button.xml
+++ b/indra/newview/skins/default/xui/en/floater_test_button.xml
@@ -96,7 +96,6 @@
      layout="topleft"
      left="200"
      name="image_button"
-     picture_style="true"
      top="20"
      width="16" />
     <button
@@ -107,7 +106,6 @@
      layout="topleft"
      left_delta="0"
      name="image_color_button"
-     picture_style="true"
      top_pad="10"
      width="16" />
 </floater>
diff --git a/indra/newview/skins/default/xui/en/floater_texture_ctrl.xml b/indra/newview/skins/default/xui/en/floater_texture_ctrl.xml
index 0a1f6e0e29..7b0baa5de2 100644
--- a/indra/newview/skins/default/xui/en/floater_texture_ctrl.xml
+++ b/indra/newview/skins/default/xui/en/floater_texture_ctrl.xml
@@ -125,7 +125,6 @@
      layout="topleft"
      left="139"
      name="Pipette"
-     picture_style="true"
      top="250"
      width="32" />
     <button
diff --git a/indra/newview/skins/default/xui/en/floater_tools.xml b/indra/newview/skins/default/xui/en/floater_tools.xml
index ca12538302..0202e8b582 100644
--- a/indra/newview/skins/default/xui/en/floater_tools.xml
+++ b/indra/newview/skins/default/xui/en/floater_tools.xml
@@ -75,7 +75,6 @@
      layout="topleft"
      left="10"
      name="button focus"
-     picture_style="true"
      tool_tip="Focus"
      width="20">
 	  <button.commit_callback
@@ -92,7 +91,6 @@
      layout="topleft"
      left_pad="20"
      name="button move"
-     picture_style="true"
      tool_tip="Move"
      width="20">
 	  <button.commit_callback
@@ -109,7 +107,6 @@
      layout="topleft"
      left_pad="20"
      name="button edit"
-     picture_style="true"
      tool_tip="Edit"
      width="20">
 	  <button.commit_callback
@@ -126,7 +123,6 @@
      layout="topleft"
      left_pad="20"
      name="button create"
-     picture_style="true"
      tool_tip="Create"
      width="20">
 	  <button.commit_callback
@@ -143,7 +139,6 @@
      layout="topleft"
      left_pad="20"
      name="button land"
-     picture_style="true"
      tool_tip="Land"
      width="20">
 	  <button.commit_callback
@@ -320,8 +315,6 @@
      image_disabled="ForwardArrow_Disabled"
      image_selected="ForwardArrow_Press"
      image_unselected="ForwardArrow_Off"
-     picture_style="true"
-     label_selected="Options"
      layout="topleft"
      name="Options..."
      tool_tip="Grid options"
@@ -342,7 +335,6 @@
      layout="topleft"
      left="4"
      name="ToolCube"
-     picture_style="true"
      tool_tip="Cube"
      top="51"
      width="20" />
@@ -356,7 +348,6 @@
      layout="topleft"
      left_delta="26"
      name="ToolPrism"
-     picture_style="true"
      tool_tip="Prism"
      top_delta="0"
      width="20" />
@@ -370,7 +361,6 @@
      layout="topleft"
      left_delta="26"
      name="ToolPyramid"
-     picture_style="true"
      tool_tip="Pyramid"
      top_delta="0"
      width="20" />
@@ -384,7 +374,6 @@
      layout="topleft"
      left_delta="26"
      name="ToolTetrahedron"
-     picture_style="true"
      tool_tip="Tetrahedron"
      top_delta="0"
      width="20" />
@@ -398,7 +387,6 @@
      layout="topleft"
      left_delta="26"
      name="ToolCylinder"
-     picture_style="true"
      tool_tip="Cylinder"
      top_delta="0"
      width="20" />
@@ -412,7 +400,6 @@
      layout="topleft"
      left_delta="26"
      name="ToolHemiCylinder"
-     picture_style="true"
      tool_tip="Hemicylinder"
      top_delta="0"
      width="20" />
@@ -426,7 +413,6 @@
      layout="topleft"
      left_delta="26"
      name="ToolCone"
-     picture_style="true"
      tool_tip="Cone"
      top_delta="0"
      width="20" />
@@ -440,7 +426,6 @@
      layout="topleft"
      left_delta="26"
      name="ToolHemiCone"
-     picture_style="true"
      tool_tip="Hemicone"
      top_delta="0"
      width="20" />
@@ -454,7 +439,6 @@
      layout="topleft"
      left_delta="26"
      name="ToolSphere"
-     picture_style="true"
      tool_tip="Sphere"
      top_delta="0"
      width="20" />
@@ -468,7 +452,6 @@
      layout="topleft"
      left_delta="26"
      name="ToolHemiSphere"
-     picture_style="true"
      tool_tip="Hemisphere"
      top_delta="0"
      width="20" />
@@ -482,7 +465,6 @@
      layout="topleft"
      left="4"
      name="ToolTorus"
-     picture_style="true"
      tool_tip="Torus"
      top="77"
      width="20" />
@@ -496,7 +478,6 @@
      layout="topleft"
      left_delta="26"
      name="ToolTube"
-     picture_style="true"
      tool_tip="Tube"
      top_delta="0"
      width="20" />
@@ -510,7 +491,6 @@
      layout="topleft"
      left_delta="26"
      name="ToolRing"
-     picture_style="true"
      tool_tip="Ring"
      top_delta="0"
      width="20" />
@@ -524,7 +504,6 @@
      layout="topleft"
      left_delta="26"
      name="ToolTree"
-     picture_style="true"
      tool_tip="Tree"
      top_delta="0"
      width="20" />
@@ -538,7 +517,6 @@
      layout="topleft"
      left_delta="26"
      name="ToolGrass"
-     picture_style="true"
      tool_tip="Grass"
      top_delta="0"
      width="20" />
@@ -927,7 +905,6 @@
 			 left_pad="0"
 			 top_delta="0"
 			 name="button set group"
-			 picture_style="true"
 			 tab_stop="false"
 			 tool_tip="Choose a group to share this object's permissions"
 			 width="10" />
@@ -2700,7 +2677,6 @@
 			 layout="topleft"
 			 left_pad="0"
 			 name="add_media"
-			 picture_style="true"
 			 tab_stop="false"
 			 top_delta="0"
 			 tool_tip="Add Media"
@@ -2716,7 +2692,6 @@
 			 layout="topleft"
 			 left_pad="5"
 			 name="delete_media"
-			 picture_style="true"
 			 tool_tip="Delete this media texture"
 			 top_delta="0"
 			 width="18">
@@ -2733,7 +2708,6 @@
 			 layout="topleft"
 			 left_pad="10"
 			 name="edit_media"
-			 picture_style="true"
 			 top_delta="0"
 			 width="18">
 				<button.commit_callback
@@ -2871,7 +2845,6 @@
         <!--TODO: HOOK UP TO HELP VIEWER-->
        <!-- <button
          image_overlay="Arrow_Right_Off"
-         picture_style="true"
          left_pad="5"
          name="button show owners help"
          tool_tip="See an explanation of colors"
diff --git a/indra/newview/skins/default/xui/en/inspect_avatar.xml b/indra/newview/skins/default/xui/en/inspect_avatar.xml
index 6b13e2f1c7..920b2d4fbf 100644
--- a/indra/newview/skins/default/xui/en/inspect_avatar.xml
+++ b/indra/newview/skins/default/xui/en/inspect_avatar.xml
@@ -102,7 +102,6 @@
      left_pad="0"
      top_delta="4"
      name="mute_btn"
-     picture_style="true"
      width="16" />
     <avatar_icon
      follows="all"
@@ -122,7 +121,6 @@
      image_unselected="ForwardArrow_Off"
      layout="topleft"
      name="view_profile_btn"
-     picture_style="true"
      right="-8"
      top="35"
      left_delta="110"
@@ -144,7 +142,6 @@
      image_unselected="OptionsMenu_Off"
      menu_filename="menu_inspect_avatar_gear.xml"
      name="gear_btn"
-     picture_style="true"
      right="-10"
      top="249"
      width="18" />
@@ -157,7 +154,6 @@
      image_unselected="OptionsMenu_Off"
      menu_filename="menu_inspect_self_gear.xml"
      name="gear_self_btn"
-     picture_style="true"
      right="-10"
      top="249"
      width="18" />
diff --git a/indra/newview/skins/default/xui/en/inspect_group.xml b/indra/newview/skins/default/xui/en/inspect_group.xml
index db12daa6e0..bc9c9244d7 100644
--- a/indra/newview/skins/default/xui/en/inspect_group.xml
+++ b/indra/newview/skins/default/xui/en/inspect_group.xml
@@ -80,7 +80,6 @@ L$123 to join
      image_selected="ForwardArrow_Press"
      image_unselected="ForwardArrow_Off"
      name="view_profile_btn"
-     picture_style="true"
      right="-8"
      top="35"
      left_delta="110"
diff --git a/indra/newview/skins/default/xui/en/inspect_object.xml b/indra/newview/skins/default/xui/en/inspect_object.xml
index fe492e0ae8..8bd4bb76c6 100644
--- a/indra/newview/skins/default/xui/en/inspect_object.xml
+++ b/indra/newview/skins/default/xui/en/inspect_object.xml
@@ -168,7 +168,6 @@ This is a really long description for an object being as how it is at least 80 c
      image_unselected="OptionsMenu_Off"
      menu_filename="menu_inspect_object_gear.xml"
      name="gear_btn"
-     picture_style="true"
      right="-10"
      top_delta="5"
      width="18" />
@@ -180,7 +179,6 @@ This is a really long description for an object being as how it is at least 80 c
      image_unselected="ForwardArrow_Off"
      layout="topleft"
      name="more_info_btn"
-     picture_style="true"
      right="-5"
      top="20"
      left_delta="110"
diff --git a/indra/newview/skins/default/xui/en/panel_avatar_list_item.xml b/indra/newview/skins/default/xui/en/panel_avatar_list_item.xml
index 18761c3bb9..0c42686531 100644
--- a/indra/newview/skins/default/xui/en/panel_avatar_list_item.xml
+++ b/indra/newview/skins/default/xui/en/panel_avatar_list_item.xml
@@ -76,7 +76,6 @@
      left_pad="3"
      right="-31"
      name="info_btn"
-     picture_style="true"
      top_delta="-2"
      width="16" />
     <button
@@ -87,7 +86,6 @@
      left_pad="5"
      right="-3"
      name="profile_btn"
-     picture_style="true"
      top_delta="-2"
      width="20" />
 </panel>
diff --git a/indra/newview/skins/default/xui/en/panel_bottomtray.xml b/indra/newview/skins/default/xui/en/panel_bottomtray.xml
index 73a1bae1c6..e08a282d57 100644
--- a/indra/newview/skins/default/xui/en/panel_bottomtray.xml
+++ b/indra/newview/skins/default/xui/en/panel_bottomtray.xml
@@ -281,7 +281,6 @@
                follows="right"
                flash_color="EmphasisColor"
                name="Unread"
-               picture_style="true"
                image_overlay="Widget_UpArrow" />
                <unread_notifications
                width="34"
diff --git a/indra/newview/skins/default/xui/en/panel_edit_pick.xml b/indra/newview/skins/default/xui/en/panel_edit_pick.xml
index bac6f6e4d1..282b3f3e55 100644
--- a/indra/newview/skins/default/xui/en/panel_edit_pick.xml
+++ b/indra/newview/skins/default/xui/en/panel_edit_pick.xml
@@ -17,7 +17,6 @@
      image_overlay="BackArrow_Off"
      layout="topleft"
      name="back_btn"
-     picture_style="true"
      left="10"
      tab_stop="false"
      top="2"
diff --git a/indra/newview/skins/default/xui/en/panel_edit_wearable.xml b/indra/newview/skins/default/xui/en/panel_edit_wearable.xml
index 77b887de9b..f76a56bda4 100644
--- a/indra/newview/skins/default/xui/en/panel_edit_wearable.xml
+++ b/indra/newview/skins/default/xui/en/panel_edit_wearable.xml
@@ -137,7 +137,6 @@ left="0"
      image_overlay="BackArrow_Off"
      layout="topleft"
      name="back_btn"
-     picture_style="true"
      left="10"
      top="7" />
 	<text
diff --git a/indra/newview/skins/default/xui/en/panel_group_info_sidetray.xml b/indra/newview/skins/default/xui/en/panel_group_info_sidetray.xml
index d8d47c4008..f3304bf4e5 100644
--- a/indra/newview/skins/default/xui/en/panel_group_info_sidetray.xml
+++ b/indra/newview/skins/default/xui/en/panel_group_info_sidetray.xml
@@ -32,7 +32,6 @@ background_visible="true"
      image_overlay="BackArrow_Off"
      layout="topleft"
      name="back"
-     picture_style="true"
      left="10"
      tab_stop="false"
      top="2"
@@ -194,7 +193,6 @@ background_visible="true"
      image_overlay="Refresh_Off"
      layout="topleft"
      name="btn_refresh"
-     picture_style="true"
      left="5"
      width="20" />
      <button
diff --git a/indra/newview/skins/default/xui/en/panel_group_list_item.xml b/indra/newview/skins/default/xui/en/panel_group_list_item.xml
index ffa485051c..5f6b911620 100644
--- a/indra/newview/skins/default/xui/en/panel_group_list_item.xml
+++ b/indra/newview/skins/default/xui/en/panel_group_list_item.xml
@@ -54,7 +54,6 @@
      left_pad="3"
      right="-31"
      name="info_btn"
-     picture_style="true"
      top_delta="-2"
      width="16" />
    <!--*TODO: Should only appear on rollover-->
@@ -66,7 +65,6 @@
      left_pad="5"
      right="-3"
      name="profile_btn"
-     picture_style="true"
      top_delta="-2"
      width="20" />
 </panel>
diff --git a/indra/newview/skins/default/xui/en/panel_landmarks.xml b/indra/newview/skins/default/xui/en/panel_landmarks.xml
index 5293043ba7..a2ddc7a43b 100644
--- a/indra/newview/skins/default/xui/en/panel_landmarks.xml
+++ b/indra/newview/skins/default/xui/en/panel_landmarks.xml
@@ -103,7 +103,6 @@
          layout="topleft"
          left="10"
          name="options_gear_btn"
-         picture_style="true"
          top="6"
          width="18" />
         <button
@@ -115,7 +114,6 @@
          layout="topleft"
          left_pad="5"
          name="add_btn"
-         picture_style="true"
          tool_tip="Add new landmark"
          width="18" />
         <dnd_button
@@ -126,7 +124,6 @@
          layout="topleft"
          right="-5"
          name="trash_btn"
-         picture_style="true"
          tool_tip="Remove selected landmark"
          top="6"
          width="18" />
diff --git a/indra/newview/skins/default/xui/en/panel_navigation_bar.xml b/indra/newview/skins/default/xui/en/panel_navigation_bar.xml
index 4175d21639..ddfa6e72a3 100644
--- a/indra/newview/skins/default/xui/en/panel_navigation_bar.xml
+++ b/indra/newview/skins/default/xui/en/panel_navigation_bar.xml
@@ -51,7 +51,6 @@
 	     layout="topleft"
 	     left="10"
 	     name="back_btn"
-	     picture_style="true"
 	     tool_tip="Go back to previous location"
 	     top="3"
 	     width="31" />
@@ -69,7 +68,6 @@
 	     layout="topleft"
 	     left_pad="0"
 	     name="forward_btn"
-	     picture_style="true"
 	     tool_tip="Go forward one location"
 	     top_delta="0"
 	     width="31" />
@@ -86,7 +84,6 @@
 	     layout="topleft"
 	     left_pad="7"
 	     name="home_btn"
-	     picture_style="true"
 	     tool_tip="Teleport to my home location"
 	     top_delta="0"
 	     width="32" />
@@ -127,7 +124,6 @@
 	<!--      left_pad="5" -->
 	<!--      mouse_opaque="false" -->
 	<!--      name="search_bg" -->
-	<!--      picture_style="true" -->
 	<!--      top_delta="0" -->
 	<!--      width="168" /> -->
 
diff --git a/indra/newview/skins/default/xui/en/panel_notifications_channel.xml b/indra/newview/skins/default/xui/en/panel_notifications_channel.xml
index c67ae41677..7b6c0f33da 100644
--- a/indra/newview/skins/default/xui/en/panel_notifications_channel.xml
+++ b/indra/newview/skins/default/xui/en/panel_notifications_channel.xml
@@ -71,7 +71,6 @@
      layout="topleft"
      left_delta="0"
      name="header"
-     picture_style="true"
      top_delta="-20"
      width="100" />
 </panel>
diff --git a/indra/newview/skins/default/xui/en/panel_people.xml b/indra/newview/skins/default/xui/en/panel_people.xml
index e234a7b358..c8194a286b 100644
--- a/indra/newview/skins/default/xui/en/panel_people.xml
+++ b/indra/newview/skins/default/xui/en/panel_people.xml
@@ -95,7 +95,6 @@ background_visible="true"
              layout="topleft"
              left="10"
              name="nearby_view_sort_btn"
-             picture_style="true"
              top="5"
              width="18" />
              <button
@@ -107,7 +106,6 @@ background_visible="true"
                  layout="topleft"
                  left_pad="5"
                  name="add_friend_btn"
-                 picture_style="true"
                  top_delta="0"
                  tool_tip="Add selected resident to your friends List"
                  width="18" />
@@ -183,7 +181,6 @@ background_visible="true"
                layout="topleft"
                left="10"
                name="friends_viewsort_btn"
-               picture_style="true"
                top="5"
                width="18" />
                 <button
@@ -195,7 +192,6 @@ background_visible="true"
                  layout="topleft"
                  left_pad="5"
                  name="add_btn"
-                 picture_style="true"
                  tool_tip="Offer friendship to a resident"
                  top_delta="0"
                  width="18" />
@@ -209,7 +205,6 @@ background_visible="true"
                  left_pad="10"
                  right="-10"
                  name="del_btn"
-                 picture_style="true"
                  tool_tip="Remove selected person from your Friends list"
                  top_delta="0"
                  width="18" />
@@ -252,7 +247,6 @@ background_visible="true"
                layout="topleft"
                left="10"
                name="groups_viewsort_btn"
-               picture_style="true"
                top="7"
                width="18" />
                 <button
@@ -264,7 +258,6 @@ background_visible="true"
                  layout="topleft"
                  left_pad="5"
                  name="plus_btn"
-                 picture_style="true"
                  tool_tip="Join group/Create new group"
                  top_delta="0"
                  width="18" />
@@ -277,7 +270,6 @@ background_visible="true"
                  layout="topleft"
                  left_pad="24"
                  name="activate_btn"
-                 picture_style="true"
                  tool_tip="Activate selected group"
                  top_delta="5"
                  width="10" />
@@ -290,7 +282,6 @@ background_visible="true"
                 left_pad="10"
                  right="-10"
                  name="minus_btn"
-                 picture_style="true"
                  tool_tip="Leave selected group"
                  top_delta="-5"
                  width="18" />
@@ -336,7 +327,6 @@ background_visible="true"
                layout="topleft"
                left="10"
                name="recent_viewsort_btn"
-               picture_style="true"
                top="7"
                width="18" />
               <button
@@ -348,7 +338,6 @@ background_visible="true"
                  layout="topleft"
                  left_pad="5"
                  name="add_friend_btn"
-                 picture_style="true"
                  top_delta="0"
                  tool_tip="Add selected resident to your friends List"
                  width="18" />
diff --git a/indra/newview/skins/default/xui/en/panel_pick_info.xml b/indra/newview/skins/default/xui/en/panel_pick_info.xml
index a67ae59b4a..42a1363b1b 100644
--- a/indra/newview/skins/default/xui/en/panel_pick_info.xml
+++ b/indra/newview/skins/default/xui/en/panel_pick_info.xml
@@ -15,7 +15,6 @@
      image_overlay="BackArrow_Off"
      layout="topleft"
      name="back_btn"
-     picture_style="true"
      left="10"
      tab_stop="false"
      top="2"
diff --git a/indra/newview/skins/default/xui/en/panel_pick_list_item.xml b/indra/newview/skins/default/xui/en/panel_pick_list_item.xml
index 38ea6b6196..7ff227ecb6 100644
--- a/indra/newview/skins/default/xui/en/panel_pick_list_item.xml
+++ b/indra/newview/skins/default/xui/en/panel_pick_list_item.xml
@@ -75,7 +75,6 @@
      image_unselected="BuyArrow_Press"
      layout="topleft"
      name="info_chevron"
-     picture_style="true"
      right="-7"
      tab_stop="false"
      top="27"
diff --git a/indra/newview/skins/default/xui/en/panel_picks.xml b/indra/newview/skins/default/xui/en/panel_picks.xml
index cbe1f11e3d..ae61852f68 100644
--- a/indra/newview/skins/default/xui/en/panel_picks.xml
+++ b/indra/newview/skins/default/xui/en/panel_picks.xml
@@ -41,7 +41,6 @@
              layout="topleft"
              left="0"
              name="gear_menu_btn"
-             picture_style="true"
              top="5"
              width="18" />
             <button
@@ -53,7 +52,6 @@
              layout="topleft"
              left_pad="15"
              name="new_btn"
-             picture_style="true"
              tool_tip="Create new pick at current location"
              top="5"
              width="18" />
@@ -65,7 +63,6 @@
              image_unselected="TrashItem_Off"
              layout="topleft"
              name="trash_btn"
-             picture_style="true"
              right="-10"
              top="5"
              width="18" />
diff --git a/indra/newview/skins/default/xui/en/panel_places.xml b/indra/newview/skins/default/xui/en/panel_places.xml
index 5aa53ab46b..5887d05d7c 100644
--- a/indra/newview/skins/default/xui/en/panel_places.xml
+++ b/indra/newview/skins/default/xui/en/panel_places.xml
@@ -106,7 +106,6 @@ background_visible="true"
          image_disabled="ForwardArrow_Disabled"
          image_selected="ForwardArrow_Press"
          image_unselected="ForwardArrow_Off"
-         picture_style="true"
          layout="topleft"
          name="overflow_btn"
          right="-10"
diff --git a/indra/newview/skins/default/xui/en/panel_preferences_alerts.xml b/indra/newview/skins/default/xui/en/panel_preferences_alerts.xml
index 159323538c..a94df4150d 100644
--- a/indra/newview/skins/default/xui/en/panel_preferences_alerts.xml
+++ b/indra/newview/skins/default/xui/en/panel_preferences_alerts.xml
@@ -73,7 +73,6 @@
      layout="topleft"
      left_delta="137"
      name="enable_this_popup"
-     picture_style="true"
      top_pad="10"
      width="43">
         <button.commit_callback
@@ -92,7 +91,6 @@
      layout="topleft"
      left_pad="50"
      name="disable_this_popup"
-     picture_style="true"
      top_delta="0"
      width="43">
         <button.commit_callback
diff --git a/indra/newview/skins/default/xui/en/panel_preferences_sound.xml b/indra/newview/skins/default/xui/en/panel_preferences_sound.xml
index 832c9775ce..705c7ee0af 100644
--- a/indra/newview/skins/default/xui/en/panel_preferences_sound.xml
+++ b/indra/newview/skins/default/xui/en/panel_preferences_sound.xml
@@ -40,7 +40,6 @@
      layout="topleft"
      left_pad="16"
      name="mute_audio"
-     picture_style="true"
      tab_stop="false"
      top_delta="-2"
      width="22" />
@@ -86,7 +85,6 @@
      layout="topleft"
      left_pad="16"
      name="mute_wind"
-     picture_style="true"
      tab_stop="false"
      top_delta="-2"
      width="22" />
@@ -122,7 +120,6 @@
      layout="topleft"
      left_pad="16"
      name="mute_ui"
-     picture_style="true"
      tab_stop="false"
      top_delta="-2"
      width="22" />
@@ -158,7 +155,6 @@
      layout="topleft"
      left_pad="16"
      name="mute_media"
-     picture_style="true"
      tab_stop="false"
      top_delta="-2"
      width="22" />
@@ -194,7 +190,6 @@
      layout="topleft"
      left_pad="16"
      name="mute_sfx"
-     picture_style="true"
      tab_stop="false"
      top_delta="-2"
      width="22" />
@@ -230,7 +225,6 @@
      layout="topleft"
      left_pad="16"
      name="mute_music"
-     picture_style="true"
      tab_stop="false"
      top_delta="-2"
      width="22" />
@@ -278,7 +272,6 @@
      layout="topleft"
      left_pad="16"
      name="mute_voice"
-     picture_style="true"
      tab_stop="false"
      top_delta="-2"
      width="22" />
diff --git a/indra/newview/skins/default/xui/en/panel_prim_media_controls.xml b/indra/newview/skins/default/xui/en/panel_prim_media_controls.xml
index b21fbc1795..7b34e2931e 100644
--- a/indra/newview/skins/default/xui/en/panel_prim_media_controls.xml
+++ b/indra/newview/skins/default/xui/en/panel_prim_media_controls.xml
@@ -82,7 +82,6 @@
 		  image_unselected="media_btn_back.png"
 		  layout="topleft"
 		  tool_tip="Step back"
-		  picture_style="true"
 		  width="22"
 		  top_delta="4">
 		<button.commit_callback
@@ -103,7 +102,6 @@
 		  image_unselected="media_btn_forward.png"
 		  layout="topleft"
 		  tool_tip="Step forward"
-		  picture_style="true"
 		  top_delta="0"
 		  min_width="17"
 		  width="17">
@@ -141,7 +139,6 @@
 		  image_unselected="media_btn_home.png"
 		  layout="topleft"
 		  tool_tip="Home page"
-		  picture_style="true"
 		  min_width="22"
 		  width="22">
 		<button.commit_callback
@@ -162,7 +159,6 @@
 		  image_unselected="button_anim_stop.tga"
 		  layout="topleft"
 		  tool_tip="Stop media"
-		  picture_style="true"
 		  min_width="22"
 		  width="22">
 		<button.commit_callback
@@ -199,7 +195,6 @@
 		  image_unselected="media_btn_reload.png"
 		  layout="topleft"
 		  tool_tip="Reload"
-		  picture_style="true"
 		  min_width="22"
 		  width="22">
 		<button.commit_callback
@@ -219,7 +214,6 @@
 		  image_selected="media_btn_stoploading.png"
 		  image_unselected="media_btn_stoploading.png"
 		  layout="topleft"
-		  picture_style="true"
 		  tool_tip = "Stop loading"
 		  min_width="22"
 		  width="22">
@@ -241,7 +235,6 @@
 		  image_unselected="button_anim_play.tga"
 		  layout="topleft"
 		  tool_tip = "Play media"
-		  picture_style="true"
 		  min_width="22"
 		  width="22">
 		<button.commit_callback
@@ -262,7 +255,6 @@
 		  image_unselected="button_anim_pause.tga"
 		  layout="topleft"
 		  tool_tip = "Pause media"
-		  picture_style="true">
 		<button.commit_callback
 			function="MediaCtrl.Pause" />
 	  </button>
@@ -367,7 +359,6 @@ function="MediaCtrl.CommitURL" />
 		  is_toggle="true"
 		  layout="topleft"
 		  scale_image="false" 
-		  picture_style="true"
 		  tool_tip="Mute This Media"
 		  top_delta="22"
 		  min_width="24"
@@ -391,7 +382,6 @@ function="MediaCtrl.CommitURL" />
 		  image_unselected="media_btn_scrollup.png"
 		  layout="topleft"
 		  tool_tip="Volume up"
-		  picture_style="true"
 		  scale_image="true"
 		  min_width="20"
 		  width="20" >
@@ -414,7 +404,6 @@ function="MediaCtrl.CommitURL" />
 		  image_unselected="media_btn_scrolldown.png"
 		  layout="topleft"
 		  tool_tip="Volume down"
-		  picture_style="true"
 		  scale_image="true"
 		  min_width="20"
 		  width="20">
@@ -446,7 +435,6 @@ function="MediaCtrl.CommitURL" />
 		  image_unselected="media_btn_scrollup.png"
 		  layout="topleft"
 		  tool_tip="Scroll up"
-		  picture_style="true"
 		  scale_image="false"
 		  left="12"
 		  top_delta="4"
@@ -460,7 +448,6 @@ function="MediaCtrl.CommitURL" />
 		  layout="topleft"
 		  left="3"
 		  tool_tip="Scroll left"
-		  picture_style="true"
 		  scale_image="false"
 		  top="12"
 		  min_width="8"
@@ -473,7 +460,6 @@ function="MediaCtrl.CommitURL" />
 		  layout="topleft"
 		  left_pad="9"
 		  tool_tip="Scroll right"
-		  picture_style="true"
 		  scale_image="false"
 		  top_delta="0"
 		  min_width="8"
@@ -486,7 +472,6 @@ function="MediaCtrl.CommitURL" />
 		  layout="topleft"
 		  left="12"
 		  tool_tip="Scroll down"
-		  picture_style="true"
 		  scale_image="false"
 		  top="20"
 		  min_width="8"
@@ -506,7 +491,6 @@ function="MediaCtrl.CommitURL" />
 		  image_unselected="media_btn_optimalzoom.png"
 		  layout="topleft"
 		  tool_tip="Zoom"
-		  picture_style="true"
 		  min_width="22"
 		  width="22">
 		<button.commit_callback
@@ -542,7 +526,6 @@ function="MediaCtrl.CommitURL" />
 		  image_unselected="media_btn_newwindow.png"
 		  layout="topleft"
 		  tool_tip = "Open URL in browser"
-		  picture_style="true"
 		  top_delta="-3"
 		  min_width="24"
 		  width="24" >
@@ -579,7 +562,6 @@ function="MediaCtrl.CommitURL" />
 		  image_unselected="media_btn_done.png"
 		  layout="topleft"
 		  tool_tip ="Close media control"
-		  picture_style="true"
 		  top_delta="-4"
 		  width="21" >
 		<button.commit_callback
diff --git a/indra/newview/skins/default/xui/en/panel_profile_view.xml b/indra/newview/skins/default/xui/en/panel_profile_view.xml
index 195b731531..70e6a08e96 100644
--- a/indra/newview/skins/default/xui/en/panel_profile_view.xml
+++ b/indra/newview/skins/default/xui/en/panel_profile_view.xml
@@ -21,7 +21,6 @@
      image_overlay="BackArrow_Off"
      layout="topleft"
      name="back"
-     picture_style="true"
      left="10"
      tab_stop="false"
      top="2"
diff --git a/indra/newview/skins/default/xui/en/panel_progress.xml b/indra/newview/skins/default/xui/en/panel_progress.xml
index a312e4cf13..18c2228906 100644
--- a/indra/newview/skins/default/xui/en/panel_progress.xml
+++ b/indra/newview/skins/default/xui/en/panel_progress.xml
@@ -129,7 +129,6 @@
      layout="topleft"
      left="-106"
      name="cancel_btn"
-     picture_style="true"
      top="700"
      width="90" />
 </panel>
diff --git a/indra/newview/skins/default/xui/en/panel_scrolling_param.xml b/indra/newview/skins/default/xui/en/panel_scrolling_param.xml
index 21ecd01839..44afadf65a 100644
--- a/indra/newview/skins/default/xui/en/panel_scrolling_param.xml
+++ b/indra/newview/skins/default/xui/en/panel_scrolling_param.xml
@@ -56,7 +56,6 @@
      layout="topleft"
      left="2"
      name="less"
-     picture_style="true"
      tab_stop="false"
      top="0"
      width="132" />
@@ -70,7 +69,6 @@
      layout="topleft"
      left_pad="2"
      name="more"
-     picture_style="true"
      tab_stop="false"
      top_delta="0"
      width="132" />
diff --git a/indra/newview/skins/default/xui/en/panel_teleport_history.xml b/indra/newview/skins/default/xui/en/panel_teleport_history.xml
index 4169c6245b..bbfffe7bab 100644
--- a/indra/newview/skins/default/xui/en/panel_teleport_history.xml
+++ b/indra/newview/skins/default/xui/en/panel_teleport_history.xml
@@ -176,7 +176,6 @@
          layout="topleft"
          left="10"
          name="gear_btn"
-         picture_style="true"
          top="5"
          width="18" />
     </panel>
diff --git a/indra/newview/skins/default/xui/en/panel_teleport_history_item.xml b/indra/newview/skins/default/xui/en/panel_teleport_history_item.xml
index 73a7d95ff4..289daee7c2 100644
--- a/indra/newview/skins/default/xui/en/panel_teleport_history_item.xml
+++ b/indra/newview/skins/default/xui/en/panel_teleport_history_item.xml
@@ -56,7 +56,6 @@
      left_pad="3"
      right="-31"
      name="info_btn"
-     picture_style="true"
      top_delta="-2"
      width="16" />
     <button
@@ -67,7 +66,6 @@
      left_pad="5"
      right="-3"
      name="profile_btn"
-     picture_style="true"
      top_delta="-2"
      width="20" />
 </panel>
diff --git a/indra/newview/skins/default/xui/en/widgets/combo_box.xml b/indra/newview/skins/default/xui/en/widgets/combo_box.xml
index 9ed3749308..fa3cb9275e 100644
--- a/indra/newview/skins/default/xui/en/widgets/combo_box.xml
+++ b/indra/newview/skins/default/xui/en/widgets/combo_box.xml
@@ -4,7 +4,6 @@
            max_chars="20"
            follows="right|top">
   <combo_box.combo_button name="Combobox Button"
-                          label=""
                           hover_glow_amount="0.15"
                           font="SansSerifSmall"
                           scale_image="false"
@@ -12,7 +11,6 @@
                           image_selected="ComboButton_Selected"
                           image_disabled="ComboButton_Disabled" />
   <combo_box.drop_down_button name="Drop Down Button"
-                              label=""
                               hover_glow_amount="0.15"
                               font="SansSerifSmall"
                               scale_image="true"
diff --git a/indra/newview/skins/default/xui/en/widgets/location_input.xml b/indra/newview/skins/default/xui/en/widgets/location_input.xml
index f2e48c517d..d88bcfab1d 100644
--- a/indra/newview/skins/default/xui/en/widgets/location_input.xml
+++ b/indra/newview/skins/default/xui/en/widgets/location_input.xml
@@ -20,7 +20,6 @@
                 allow_new_values="true"
                 >
   <info_button name="Place Information"
-                          label=""
                           width="16"
                           height="16"
                           follows="left|top"
@@ -30,7 +29,6 @@
                           image_disabled_selected="Info_Off"
                           image_disabled="Info_Off" />
   <add_landmark_button name="Add Landmark"
-                          label=""
                           hover_glow_amount="0.15"
                           image_hover_selected="Favorite_Star_Over"
                           image_hover_unselected="Favorite_Star_Over"
diff --git a/indra/newview/skins/default/xui/en/widgets/search_editor.xml b/indra/newview/skins/default/xui/en/widgets/search_editor.xml
index f482ff3b89..9a79243b03 100644
--- a/indra/newview/skins/default/xui/en/widgets/search_editor.xml
+++ b/indra/newview/skins/default/xui/en/widgets/search_editor.xml
@@ -7,14 +7,14 @@
   background_image="TextField_Search_Off"
   background_image_disabled="TextField_Search_Disabled"
   background_image_focused="TextField_Search_Active" >
-  <search_button label=""
+  <search_button 
     top_pad="4"
     left_pad="4" 
     width="13"
     height="13" 
 	  image_unselected="Search"
 	  image_selected="Search" />
-  <clear_button label=""
+  <clear_button 
    image_unselected="Icon_Close_Foreground"
    image_selected="Icon_Close_Press" />
 </search_editor>
diff --git a/indra/newview/skins/default/xui/es/floater_script_debug.xml b/indra/newview/skins/default/xui/es/floater_script_debug.xml
index e33ffb7d96..e9b66c74d2 100644
--- a/indra/newview/skins/default/xui/es/floater_script_debug.xml
+++ b/indra/newview/skins/default/xui/es/floater_script_debug.xml
@@ -1,6 +1,6 @@
 <?xml version="1.0" encoding="utf-8" standalone="yes"?>
 <multi_floater name="script debug floater" title="Alerta/Error de los scripts">
 	<tab_container name="Preview Tabs">
-		<floater label="Script" name="all_scripts" title="[Todos los scripts]"/>
+		<floater label="Script" name="all_scripts" title="[All scripts]"/>
 	</tab_container>
 </multi_floater>
diff --git a/indra/newview/skins/default/xui/it/floater_script_debug.xml b/indra/newview/skins/default/xui/it/floater_script_debug.xml
index 39736dde67..66e0af264f 100644
--- a/indra/newview/skins/default/xui/it/floater_script_debug.xml
+++ b/indra/newview/skins/default/xui/it/floater_script_debug.xml
@@ -1,6 +1,6 @@
 <?xml version="1.0" encoding="utf-8" standalone="yes"?>
 <multi_floater name="script debug floater" title="Avvisi/Errori Script">
 	<tab_container name="Preview Tabs">
-		<floater label="Script" name="all_scripts" title="[Tutti gli script]"/>
+		<floater label="Script" name="all_scripts" title="[All scripts]"/>
 	</tab_container>
 </multi_floater>
diff --git a/indra/newview/skins/default/xui/nl/floater_script_debug.xml b/indra/newview/skins/default/xui/nl/floater_script_debug.xml
index 306ad5d1a3..df9531473e 100644
--- a/indra/newview/skins/default/xui/nl/floater_script_debug.xml
+++ b/indra/newview/skins/default/xui/nl/floater_script_debug.xml
@@ -1,6 +1,6 @@
 <?xml version="1.0" encoding="utf-8" standalone="yes"?>
 <multi_floater name="script debug floater" title="Script waarschuwing/fout">
 	<tab_container name="Preview Tabs">
-		<floater label="Script" name="all_scripts" title="[Alle scripts]"/>
+		<floater label="Script" name="all_scripts" title="[All scripts]"/>
 	</tab_container>
 </multi_floater>
diff --git a/indra/newview/skins/default/xui/pt/floater_script_debug.xml b/indra/newview/skins/default/xui/pt/floater_script_debug.xml
index 48c73b93a3..d7a9bc6f87 100644
--- a/indra/newview/skins/default/xui/pt/floater_script_debug.xml
+++ b/indra/newview/skins/default/xui/pt/floater_script_debug.xml
@@ -1,6 +1,6 @@
 <?xml version="1.0" encoding="utf-8" standalone="yes"?>
 <multi_floater name="script debug floater" title="Aviso de script/erro">
 	<tab_container name="Preview Tabs">
-		<floater label="Script" name="all_scripts" title="[Todos os scripts]"/>
+		<floater label="Script" name="all_scripts" title="[All scripts]"/>
 	</tab_container>
 </multi_floater>
-- 
cgit v1.2.3


From 9d8bd3625a01e38fb6b1af6153a43408933495df Mon Sep 17 00:00:00 2001
From: "Nyx (Neal Orman)" <nyx@lindenlab.com>
Date: Tue, 3 Nov 2009 14:41:53 -0500
Subject: DEV-1186 possibly typo in avatar_lad.xml

bumped wearable definition number and fixed minor typo in avatar_lad.xml - fix submitted by external contributor.
Verified the change is correct and gave credit - change is de minimis, but we haven't caught this/noticed on our
own for a while.

Code reviewed by Bigpapi
---
 indra/newview/character/avatar_lad.xml | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

(limited to 'indra')

diff --git a/indra/newview/character/avatar_lad.xml b/indra/newview/character/avatar_lad.xml
index c43ba27984..10c197d09e 100644
--- a/indra/newview/character/avatar_lad.xml
+++ b/indra/newview/character/avatar_lad.xml
@@ -1,6 +1,6 @@
 <?xml version="1.0" encoding="US-ASCII" standalone="yes"?>
 <linden_avatar
- version="1.0" wearable_definition_version="23"> 
+ version="1.0" wearable_definition_version="24"> 
   <!-- The wearable_definition_version is checked during asset upload. -->
   <!-- If you increment it, check indra/lib/python/indra/assetutil.py.  -->
   <skeleton
@@ -8985,7 +8985,7 @@ render_pass="bump">
          id="1017" />
 
         <driven
-         id="1033" />
+         id="1035" />
 
         <driven
          id="914"
-- 
cgit v1.2.3


From 90d92647f417601814c3e7fffac357435f485c79 Mon Sep 17 00:00:00 2001
From: "Nyx (Neal Orman)" <nyx@lindenlab.com>
Date: Tue, 3 Nov 2009 15:17:27 -0500
Subject: EXT-2141 baked texture not keyed on version #

We actually already have this, stored in our baked texture dictionary.
Generated new UUIDs for the baked texture hashes -
this will ensure that new baked textures will be generated when users switch
to viewer-2, and should clear up the invisibility issues people see from old
1.22 bakes being used as alpha-enabled.

Code reviewed by Bigpapi
---
 indra/newview/llvoavatardefines.cpp | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

(limited to 'indra')

diff --git a/indra/newview/llvoavatardefines.cpp b/indra/newview/llvoavatardefines.cpp
index 5624f19c8d..49c4a1a6c8 100644
--- a/indra/newview/llvoavatardefines.cpp
+++ b/indra/newview/llvoavatardefines.cpp
@@ -84,34 +84,34 @@ LLVOAvatarDictionary::BakedTextures::BakedTextures()
 {
 	// Baked textures
 	addEntry(BAKED_HEAD,       new BakedEntry(TEX_HEAD_BAKED,  
-											  "head", "18ded8d6-bcfc-e415-8539-944c0f5ea7a6", 
+											  "head", "a4b9dc38-e13b-4df9-b284-751efb0566ff", 
 											  3, TEX_HEAD_BODYPAINT, TEX_HEAD_TATTOO, TEX_HEAD_ALPHA,
 											  5, WT_SHAPE, WT_SKIN, WT_HAIR, WT_TATTOO, WT_ALPHA));
 
 	addEntry(BAKED_UPPER,      new BakedEntry(TEX_UPPER_BAKED, 
-											  "upper_body", "338c29e3-3024-4dbb-998d-7c04cf4fa88f", 
+											  "upper_body", "5943ff64-d26c-4a90-a8c0-d61f56bd98d4", 
 											  7, TEX_UPPER_SHIRT,TEX_UPPER_BODYPAINT, TEX_UPPER_JACKET,
 											  TEX_UPPER_GLOVES, TEX_UPPER_UNDERSHIRT, TEX_UPPER_TATTOO, TEX_UPPER_ALPHA,
 											  8, WT_SHAPE, WT_SKIN,	WT_SHIRT, WT_JACKET, WT_GLOVES, WT_UNDERSHIRT, WT_TATTOO, WT_ALPHA));											  
 
 	addEntry(BAKED_LOWER,      new BakedEntry(TEX_LOWER_BAKED, 
-											  "lower_body", "91b4a2c7-1b1a-ba16-9a16-1f8f8dcc1c3f",
+											  "lower_body", "2944ee70-90a7-425d-a5fb-d749c782ed7d",
 											  8, TEX_LOWER_PANTS,TEX_LOWER_BODYPAINT,TEX_LOWER_SHOES, TEX_LOWER_SOCKS,
 											  TEX_LOWER_JACKET, TEX_LOWER_UNDERPANTS, TEX_LOWER_TATTOO, TEX_LOWER_ALPHA,
 											  9, WT_SHAPE, WT_SKIN,	WT_PANTS, WT_SHOES,	 WT_SOCKS,  WT_JACKET, WT_UNDERPANTS, WT_TATTOO, WT_ALPHA));
 
 	addEntry(BAKED_EYES,       new BakedEntry(TEX_EYES_BAKED,  
-											  "eyes", "b2cf28af-b840-1071-3c6a-78085d8128b5",
+											  "eyes", "27b1bc0f-979f-4b13-95fe-b981c2ba9788",
 											  2, TEX_EYES_IRIS, TEX_EYES_ALPHA,
 											  2, WT_EYES, WT_ALPHA));
 
 	addEntry(BAKED_SKIRT,      new BakedEntry(TEX_SKIRT_BAKED,
-											  "skirt", "ea800387-ea1a-14e0-56cb-24f2022f969a", 
+											  "skirt", "03e7e8cb-1368-483b-b6f3-74850838ba63", 
 											  1, TEX_SKIRT,
 											  1, WT_SKIRT));
 
 	addEntry(BAKED_HAIR,       new BakedEntry(TEX_HAIR_BAKED,
-											  "hair", "0af1ef7c-ad24-11dd-8790-001f5bf833e8", 
+											  "hair", "a60e85a9-74e8-48d8-8a2d-8129f28d9b61", 
 											  2, TEX_HAIR, TEX_HAIR_ALPHA,
 											  2, WT_HAIR, WT_ALPHA));
 }
-- 
cgit v1.2.3


From 5202334de82a8dbf8f2616fd323291826c17077b Mon Sep 17 00:00:00 2001
From: Mike Antipov <mantipov@productengine.com>
Date: Wed, 4 Nov 2009 12:02:04 +0200
Subject: Fixed Windows build, broken in changeset 698ac0866792 - Made member
 Speaker Listeners as LLpointers in LLParticipantList

--HG--
branch : product-engine
---
 indra/newview/llparticipantlist.cpp | 13 +++++++------
 indra/newview/llparticipantlist.h   |  6 +++---
 2 files changed, 10 insertions(+), 9 deletions(-)

(limited to 'indra')

diff --git a/indra/newview/llparticipantlist.cpp b/indra/newview/llparticipantlist.cpp
index 9450bee315..edff706fee 100644
--- a/indra/newview/llparticipantlist.cpp
+++ b/indra/newview/llparticipantlist.cpp
@@ -45,14 +45,15 @@
 LLParticipantList::LLParticipantList(LLSpeakerMgr* data_source, LLAvatarList* avatar_list):
 	mSpeakerMgr(data_source),
 	mAvatarList(avatar_list),
-	mSpeakerAddListener(*this),
-	mSpeakerRemoveListener(*this),
-	mSpeakerClearListener(*this),
 	mSortOrder(E_SORT_BY_NAME)
 {
-	mSpeakerMgr->addListener(&mSpeakerAddListener, "add");
-	mSpeakerMgr->addListener(&mSpeakerRemoveListener, "remove");
-	mSpeakerMgr->addListener(&mSpeakerClearListener, "clear");
+	mSpeakerAddListener = new SpeakerAddListener(*this);
+	mSpeakerRemoveListener = new SpeakerRemoveListener(*this);
+	mSpeakerClearListener = new SpeakerClearListener(*this);
+
+	mSpeakerMgr->addListener(mSpeakerAddListener, "add");
+	mSpeakerMgr->addListener(mSpeakerRemoveListener, "remove");
+	mSpeakerMgr->addListener(mSpeakerClearListener, "clear");
 
 	mAvatarList->setNoItemsCommentText(LLTrans::getString("LoadingData"));
 	mAvatarList->setDoubleClickCallback(boost::bind(&LLParticipantList::onAvatarListDoubleClicked, this, mAvatarList));
diff --git a/indra/newview/llparticipantlist.h b/indra/newview/llparticipantlist.h
index 04d9e29256..8c209c0b20 100644
--- a/indra/newview/llparticipantlist.h
+++ b/indra/newview/llparticipantlist.h
@@ -103,9 +103,9 @@ class LLParticipantList
 		LLSpeakerMgr*		mSpeakerMgr;
 		LLAvatarList*		mAvatarList;
 
-		SpeakerAddListener		mSpeakerAddListener;
-		SpeakerRemoveListener	mSpeakerRemoveListener;
-		SpeakerClearListener	mSpeakerClearListener;
+		LLPointer<SpeakerAddListener>		mSpeakerAddListener;
+		LLPointer<SpeakerRemoveListener>	mSpeakerRemoveListener;
+		LLPointer<SpeakerClearListener>		mSpeakerClearListener;
 
 		EParticipantSortOrder	mSortOrder;
 };
-- 
cgit v1.2.3


From 459e7e268462e93d7e3ec680f4ecf8c120b19a05 Mon Sep 17 00:00:00 2001
From: Eugene Kondrashev <ekondrashev@productengine.com>
Date: Wed, 4 Nov 2009 12:54:44 +0200
Subject: Implemented normal subtask EXT-1516 - Implement chiclet for ad-hoc
 chat.

--HG--
branch : product-engine
---
 indra/newview/llchiclet.cpp | 3 +++
 indra/newview/llchiclet.h   | 2 ++
 2 files changed, 5 insertions(+)

(limited to 'indra')

diff --git a/indra/newview/llchiclet.cpp b/indra/newview/llchiclet.cpp
index 1049348684..8a4650763f 100644
--- a/indra/newview/llchiclet.cpp
+++ b/indra/newview/llchiclet.cpp
@@ -455,6 +455,7 @@ LLAdHocChiclet::Params::Params()
 , unread_notifications("unread_notifications")
 , speaker("speaker")
 , show_speaker("show_speaker")
+, avatar_icon_color("avatar_icon_color", LLColor4::green)
 {
 	// *TODO Vadim: Get rid of hardcoded values.
 	rect(LLRect(0, 25, 45, 0));
@@ -492,6 +493,8 @@ LLAdHocChiclet::LLAdHocChiclet(const Params& p)
 {
 	LLChicletAvatarIconCtrl::Params avatar_params = p.avatar_icon;
 	mChicletIconCtrl = LLUICtrlFactory::create<LLChicletAvatarIconCtrl>(avatar_params);
+	//Make the avatar modified
+	mChicletIconCtrl->setColor(p.avatar_icon_color);
 	addChild(mChicletIconCtrl);
 
 	LLChicletNotificationCounterCtrl::Params unread_params = p.unread_notifications;
diff --git a/indra/newview/llchiclet.h b/indra/newview/llchiclet.h
index 6eefd9829f..f82259c73e 100644
--- a/indra/newview/llchiclet.h
+++ b/indra/newview/llchiclet.h
@@ -457,6 +457,8 @@ public:
 
 		Optional<bool>	show_speaker;
 
+		Optional<LLColor4>	avatar_icon_color;
+
 		Params();
 	};
 
-- 
cgit v1.2.3


From 7ad64438430de9a26d2c7c790eb196db4817f259 Mon Sep 17 00:00:00 2001
From: Eugene Mutavchi <emutavchi@productengine.com>
Date: Wed, 4 Nov 2009 13:45:27 +0200
Subject: Implemented normal sub-task EXT-2145 (Incorrect names of Call button
 on IM Control Panels)

--HG--
branch : product-engine
---
 indra/newview/skins/default/xui/en/panel_adhoc_control_panel.xml | 4 ++--
 indra/newview/skins/default/xui/en/panel_group_control_panel.xml | 4 ++--
 indra/newview/skins/default/xui/en/panel_im_control_panel.xml    | 2 +-
 3 files changed, 5 insertions(+), 5 deletions(-)

(limited to 'indra')

diff --git a/indra/newview/skins/default/xui/en/panel_adhoc_control_panel.xml b/indra/newview/skins/default/xui/en/panel_adhoc_control_panel.xml
index 87c4e2787f..0c1e777fa1 100644
--- a/indra/newview/skins/default/xui/en/panel_adhoc_control_panel.xml
+++ b/indra/newview/skins/default/xui/en/panel_adhoc_control_panel.xml
@@ -19,13 +19,13 @@
      width="180" />
     <button
      name="call_btn"
-     label="Call"
+     label="Call Group"
      left_delta="27"
      width="125"
      height="20" />
     <button
      name="end_call_btn"
-     label="End Call"
+     label="Leave Call"
      width="125"
      height="20" 
      visible="false"/>
diff --git a/indra/newview/skins/default/xui/en/panel_group_control_panel.xml b/indra/newview/skins/default/xui/en/panel_group_control_panel.xml
index 3358015335..560d353d00 100644
--- a/indra/newview/skins/default/xui/en/panel_group_control_panel.xml
+++ b/indra/newview/skins/default/xui/en/panel_group_control_panel.xml
@@ -25,12 +25,12 @@
      height="20" />
     <button
      name="call_btn"
-     label="Call"
+     label="Call Group"
      width="125"
      height="20" />
     <button
      name="end_call_btn"
-     label="End Call"
+     label="Leave Call"
      width="125"
      height="20" 
      visible="false"/>
diff --git a/indra/newview/skins/default/xui/en/panel_im_control_panel.xml b/indra/newview/skins/default/xui/en/panel_im_control_panel.xml
index 0dd3878426..7308ca3c29 100644
--- a/indra/newview/skins/default/xui/en/panel_im_control_panel.xml
+++ b/indra/newview/skins/default/xui/en/panel_im_control_panel.xml
@@ -31,7 +31,7 @@
     <button
      follows="left|bottom"
      height="20"
-     label="End Call"
+     label="Leave Call"
      name="end_call_btn"
      visible="false"
      width="125" />
-- 
cgit v1.2.3


From 8bd0c9058d3d24218cf59dd01f152b41240853a4 Mon Sep 17 00:00:00 2001
From: Yuri Chebotarev <ychebotarev@productengine.com>
Date: Wed, 4 Nov 2009 14:25:41 +0200
Subject: fix for some group_info bugs. EXT-1091 "Refresh" button is overlapped
 by "Cancel" button in "Group Profile" panel

--HG--
branch : product-engine
---
 .../default/xui/en/panel_group_info_sidetray.xml     | 20 ++++++++++++--------
 1 file changed, 12 insertions(+), 8 deletions(-)

(limited to 'indra')

diff --git a/indra/newview/skins/default/xui/en/panel_group_info_sidetray.xml b/indra/newview/skins/default/xui/en/panel_group_info_sidetray.xml
index 132c031942..7e24ad2c94 100644
--- a/indra/newview/skins/default/xui/en/panel_group_info_sidetray.xml
+++ b/indra/newview/skins/default/xui/en/panel_group_info_sidetray.xml
@@ -128,15 +128,16 @@ background_visible="true"
              <accordion_tab
                  can_resize="false"
                  layout="topleft"
-                 name="tab_general"
+                 name="group_general_tab"
                  title="General">
         <panel
         border="false"
+         class="panel_group_general" 
          filename="panel_group_general.xml"
          layout="topleft"
          left="0"
          help_topic="group_general_tab"
-         name="general_tab"
+         name="group_general_tab_panel"
          top="0"
          width="333" />
          </accordion_tab>
@@ -144,15 +145,16 @@ background_visible="true"
                  can_resize="false"
                  expanded="false"
                  layout="topleft"
-                 name="tab_roles"
+                 name="group_roles_tab"
                  title="Roles">
         <panel
         border="false"
+         class="panel_group_roles"
          filename="panel_group_roles.xml"
          layout="topleft"
          left="0"
          help_topic="group_roles_tab"
-         name="roles_tab"
+         name="group_roles_tab_panel"
          top="0"
          width="333" />
          </accordion_tab>
@@ -160,14 +162,15 @@ background_visible="true"
                  can_resize="false"
                  expanded="false"
                  layout="topleft"
-                 name="tab_notices"
+                 name="group_notices_tab"
                  title="Notices">
         <panel
+         class="panel_group_notices"
          filename="panel_group_notices.xml"
          layout="topleft"
          left="0"
          help_topic="group_notices_tab"
-         name="notices_tab"
+         name="group_notices_tab_panel"
          top="0"
          width="333" />
          </accordion_tab>
@@ -175,15 +178,16 @@ background_visible="true"
                  can_resize="false"
                  expanded="false"
                  layout="topleft"
-                 name="tab_notices"
+                 name="group_land_tab"
                  title="Land/Assets">
         <panel
         border="false"
+         class="panel_group_land_money"
          filename="panel_group_land_money.xml"
          layout="topleft"
          left="0"
          help_topic="group_land_money_tab"
-         name="land_money_tab"
+         name="group_land_tab_panel"
          top="0"
          width="333" />
          </accordion_tab>
-- 
cgit v1.2.3


From 2715e94a5ae969956f493609561f0cc144ec2c37 Mon Sep 17 00:00:00 2001
From: Sergei Litovchuk <slitovchuk@productengine.com>
Date: Wed, 4 Nov 2009 14:33:00 +0200
Subject: Implemented major task EXT-2054 "Hook up parcel permission icons to
 parcel profile": - Added icon representation of parcel permissions to Place
 Profile panel.

--HG--
branch : product-engine
---
 indra/newview/llpanellandmarkinfo.cpp              |  14 ---
 indra/newview/llpanelplaceinfo.cpp                 |  14 +++
 indra/newview/llpanelplaceprofile.cpp              |  86 ++++++++-------
 indra/newview/llpanelplaceprofile.h                |  13 ++-
 .../skins/default/xui/en/panel_place_profile.xml   | 116 ++-------------------
 5 files changed, 84 insertions(+), 159 deletions(-)

(limited to 'indra')

diff --git a/indra/newview/llpanellandmarkinfo.cpp b/indra/newview/llpanellandmarkinfo.cpp
index 1152ca6873..fd6a41c505 100644
--- a/indra/newview/llpanellandmarkinfo.cpp
+++ b/indra/newview/llpanellandmarkinfo.cpp
@@ -139,20 +139,6 @@ void LLPanelLandmarkInfo::processParcelInfo(const LLParcelData& parcel_data)
 {
 	LLPanelPlaceInfo::processParcelInfo(parcel_data);
 
-	// HACK: Flag 0x2 == adult region,
-	// Flag 0x1 == mature region, otherwise assume PG
-	std::string rating = LLViewerRegion::accessToString(SIM_ACCESS_PG);
-	if (parcel_data.flags & 0x2)
-	{
-		rating = LLViewerRegion::accessToString(SIM_ACCESS_ADULT);
-	}
-	else if (parcel_data.flags & 0x1)
-	{
-		rating = LLViewerRegion::accessToString(SIM_ACCESS_MATURE);
-	}
-
-	mMaturityRatingText->setValue(rating);
-
 	S32 region_x;
 	S32 region_y;
 	S32 region_z;
diff --git a/indra/newview/llpanelplaceinfo.cpp b/indra/newview/llpanelplaceinfo.cpp
index 2c5f4b5afa..e6d10be858 100644
--- a/indra/newview/llpanelplaceinfo.cpp
+++ b/indra/newview/llpanelplaceinfo.cpp
@@ -209,6 +209,20 @@ void LLPanelPlaceInfo::processParcelInfo(const LLParcelData& parcel_data)
 		mDescEditor->setText(parcel_data.desc);
 	}
 
+	// HACK: Flag 0x2 == adult region,
+	// Flag 0x1 == mature region, otherwise assume PG
+	std::string rating = LLViewerRegion::accessToString(SIM_ACCESS_PG);
+	if (parcel_data.flags & 0x2)
+	{
+		rating = LLViewerRegion::accessToString(SIM_ACCESS_ADULT);
+	}
+	else if (parcel_data.flags & 0x1)
+	{
+		rating = LLViewerRegion::accessToString(SIM_ACCESS_MATURE);
+	}
+
+	mMaturityRatingText->setValue(rating);
+
 	S32 region_x;
 	S32 region_y;
 	S32 region_z;
diff --git a/indra/newview/llpanelplaceprofile.cpp b/indra/newview/llpanelplaceprofile.cpp
index 9ba72fe6cf..814139607c 100644
--- a/indra/newview/llpanelplaceprofile.cpp
+++ b/indra/newview/llpanelplaceprofile.cpp
@@ -84,16 +84,24 @@ BOOL LLPanelPlaceProfile::postBuild()
 	mParcelOwner = getChild<LLTextBox>("owner_value");
 	mLastVisited = getChild<LLTextBox>("last_visited_value");
 
-	mRatingText = getChild<LLTextBox>("rating_value");
+	mParcelRatingIcon = getChild<LLIconCtrl>("rating_icon");
+	mParcelRatingText = getChild<LLTextBox>("rating_value");
+	mVoiceIcon = getChild<LLIconCtrl>("voice_icon");
 	mVoiceText = getChild<LLTextBox>("voice_value");
+	mFlyIcon = getChild<LLIconCtrl>("fly_icon");
 	mFlyText = getChild<LLTextBox>("fly_value");
+	mPushIcon = getChild<LLIconCtrl>("push_icon");
 	mPushText = getChild<LLTextBox>("push_value");
+	mBuildIcon = getChild<LLIconCtrl>("build_icon");
 	mBuildText = getChild<LLTextBox>("build_value");
+	mScriptsIcon = getChild<LLIconCtrl>("scripts_icon");
 	mScriptsText = getChild<LLTextBox>("scripts_value");
+	mDamageIcon = getChild<LLIconCtrl>("damage_icon");
 	mDamageText = getChild<LLTextBox>("damage_value");
 
 	mRegionNameText = getChild<LLTextBox>("region_name");
 	mRegionTypeText = getChild<LLTextBox>("region_type");
+	mRegionRatingIcon = getChild<LLIconCtrl>("region_rating_icon");
 	mRegionRatingText = getChild<LLTextBox>("region_rating");
 	mRegionOwnerText = getChild<LLTextBox>("region_owner");
 	mRegionGroupText = getChild<LLTextBox>("region_group");
@@ -128,16 +136,24 @@ void LLPanelPlaceProfile::resetLocation()
 	mParcelOwner->setValue(not_available);
 	mLastVisited->setValue(not_available);
 
-	mRatingText->setText(not_available);
+	mParcelRatingIcon->setValue(not_available);
+	mParcelRatingText->setText(not_available);
+	mVoiceIcon->setValue(not_available);
 	mVoiceText->setText(not_available);
+	mFlyIcon->setValue(not_available);
 	mFlyText->setText(not_available);
+	mPushIcon->setValue(not_available);
 	mPushText->setText(not_available);
+	mBuildIcon->setValue(not_available);
 	mBuildText->setText(not_available);
-	mParcelScriptsText->setText(not_available);
+	mScriptsIcon->setValue(not_available);
+	mScriptsText->setText(not_available);
+	mDamageIcon->setValue(not_available);
 	mDamageText->setText(not_available);
 
 	mRegionNameText->setValue(not_available);
 	mRegionTypeText->setValue(not_available);
+	mRegionRatingIcon->setValue(not_available);
 	mRegionRatingText->setValue(not_available);
 	mRegionOwnerText->setValue(not_available);
 	mRegionGroupText->setValue(not_available);
@@ -191,33 +207,6 @@ void LLPanelPlaceProfile::setInfoType(INFO_TYPE type)
 	LLPanelPlaceInfo::setInfoType(type);
 }
 
-// virtual
-void LLPanelPlaceProfile::processParcelInfo(const LLParcelData& parcel_data)
-{
-	LLPanelPlaceInfo::processParcelInfo(parcel_data);
-
-	// HACK: Flag 0x2 == adult region,
-	// Flag 0x1 == mature region, otherwise assume PG
-	std::string rating = LLViewerRegion::accessToString(SIM_ACCESS_PG);
-	if (parcel_data.flags & 0x2)
-	{
-		rating = LLViewerRegion::accessToString(SIM_ACCESS_ADULT);
-	}
-	else if (parcel_data.flags & 0x1)
-	{
-		rating = LLViewerRegion::accessToString(SIM_ACCESS_MATURE);
-	}
-
-	mMaturityRatingText->setValue(rating);
-	mRatingText->setValue(rating);
-
-	//update for_sale banner, here we should use DFQ_FOR_SALE instead of PF_FOR_SALE
-	//because we deal with remote parcel response format
-	bool is_for_sale = (parcel_data.flags & DFQ_FOR_SALE) &&
-					 mInfoType == AGENT ? TRUE : FALSE;
-	mForSalePanel->setVisible(is_for_sale);
-}
-
 void LLPanelPlaceProfile::displaySelectedParcelInfo(LLParcel* parcel,
 													LLViewerRegion* region,
 													const LLVector3d& pos_global,
@@ -238,19 +227,34 @@ void LLPanelPlaceProfile::displaySelectedParcelInfo(LLParcel* parcel,
 
 	// HACK: Converting sim access flags to the format
 	// returned by remote parcel response.
-	switch(region->getSimAccess())
+	U8 sim_access = region->getSimAccess();
+	switch(sim_access)
 	{
 	case SIM_ACCESS_MATURE:
 		parcel_data.flags = 0x1;
+
+		mParcelRatingIcon->setValue("parcel_drk_M");
+		mRegionRatingIcon->setValue("parcel_drk_M");
 		break;
 
 	case SIM_ACCESS_ADULT:
 		parcel_data.flags = 0x2;
+
+		mParcelRatingIcon->setValue("parcel_drk_R");
+		mRegionRatingIcon->setValue("parcel_drk_R");
 		break;
 
 	default:
 		parcel_data.flags = 0;
+
+		mParcelRatingIcon->setValue("parcel_drk_PG");
+		mRegionRatingIcon->setValue("parcel_drk_PG");
 	}
+
+	std::string rating = LLViewerRegion::accessToString(sim_access);
+	mParcelRatingText->setText(rating);
+	mRegionRatingText->setText(rating);
+
 	parcel_data.desc = parcel->getDesc();
 	parcel_data.name = parcel->getName();
 	parcel_data.sim_name = region->getName();
@@ -268,37 +272,45 @@ void LLPanelPlaceProfile::displaySelectedParcelInfo(LLParcel* parcel,
 	// Processing parcel characteristics
 	if (parcel->getParcelFlagAllowVoice())
 	{
+		mVoiceIcon->setValue("parcel_drk_Voice");
 		mVoiceText->setText(on);
 	}
 	else
 	{
+		mVoiceIcon->setValue("parcel_drk_VoiceNo");
 		mVoiceText->setText(off);
 	}
 
 	if (!region->getBlockFly() && parcel->getAllowFly())
 	{
+		mFlyIcon->setValue("parcel_drk_Fly");
 		mFlyText->setText(on);
 	}
 	else
 	{
+		mFlyIcon->setValue("parcel_drk_FlyNo");
 		mFlyText->setText(off);
 	}
 
 	if (region->getRestrictPushObject() || parcel->getRestrictPushObject())
 	{
+		mPushIcon->setValue("parcel_drk_PushNo");
 		mPushText->setText(off);
 	}
 	else
 	{
+		mPushIcon->setValue("parcel_drk_Push");
 		mPushText->setText(on);
 	}
 
 	if (parcel->getAllowModify())
 	{
+		mBuildIcon->setValue("parcel_drk_Build");
 		mBuildText->setText(on);
 	}
 	else
 	{
+		mBuildIcon->setValue("parcel_drk_BuildNo");
 		mBuildText->setText(off);
 	}
 
@@ -306,25 +318,28 @@ void LLPanelPlaceProfile::displaySelectedParcelInfo(LLParcel* parcel,
 	   (region->getRegionFlags() & REGION_FLAGS_ESTATE_SKIP_SCRIPTS) ||
 	   !parcel->getAllowOtherScripts())
 	{
+		mScriptsIcon->setValue("parcel_drk_ScriptsNo");
 		mScriptsText->setText(off);
 	}
 	else
 	{
+		mScriptsIcon->setValue("parcel_drk_Scripts");
 		mScriptsText->setText(on);
 	}
 
 	if (region->getAllowDamage() || parcel->getAllowDamage())
 	{
+		mDamageIcon->setValue("parcel_drk_Damage");
 		mDamageText->setText(on);
 	}
 	else
 	{
+		mDamageIcon->setValue("parcel_drk_DamageNo");
 		mDamageText->setText(off);
 	}
 
 	mRegionNameText->setText(region->getName());
 	mRegionTypeText->setText(region->getSimProductName());
-	mRegionRatingText->setText(region->getSimAccessString());
 
 	// Determine parcel owner
 	if (parcel->isPublic())
@@ -383,9 +398,6 @@ void LLPanelPlaceProfile::displaySelectedParcelInfo(LLParcel* parcel,
 													 &dwell);
 	if (for_sale)
 	{
-		// Adding "For Sale" flag in remote parcel response format.
-		parcel_data.flags |= DFQ_FOR_SALE;
-
 		const LLUUID& auth_buyer_id = parcel->getAuthorizedBuyerID();
 		if(auth_buyer_id.notNull())
 		{
@@ -403,6 +415,8 @@ void LLPanelPlaceProfile::displaySelectedParcelInfo(LLParcel* parcel,
 			mSaleToText->setText(getString("anyone"));
 		}
 
+		mForSalePanel->setVisible(for_sale);
+
 		const U8* sign = (U8*)getString("price_text").c_str();
 		const U8* sqm = (U8*)getString("area_text").c_str();
 
@@ -455,7 +469,7 @@ void LLPanelPlaceProfile::displaySelectedParcelInfo(LLParcel* parcel,
 
 	mSelectedParcelID = parcel->getLocalID();
 	mLastSelectedRegionID = region->getRegionID();
-	processParcelInfo(parcel_data);
+	LLPanelPlaceInfo::processParcelInfo(parcel_data);
 
 	mYouAreHerePanel->setVisible(is_current_parcel);
 	getChild<LLAccordionCtrlTab>("sales_tab")->setVisible(for_sale);
diff --git a/indra/newview/llpanelplaceprofile.h b/indra/newview/llpanelplaceprofile.h
index d8e4bcb6bd..db54ff8af9 100644
--- a/indra/newview/llpanelplaceprofile.h
+++ b/indra/newview/llpanelplaceprofile.h
@@ -35,6 +35,7 @@
 
 #include "llpanelplaceinfo.h"
 
+class LLIconCtrl;
 class LLTextEditor;
 
 class LLPanelPlaceProfile : public LLPanelPlaceInfo
@@ -49,8 +50,6 @@ public:
 
 	/*virtual*/ void setInfoType(INFO_TYPE type);
 
-	/*virtual*/ void processParcelInfo(const LLParcelData& parcel_data);
-
 	// Displays information about the currently selected parcel
 	// without sending a request to the server.
 	// If is_current_parcel true shows "You Are Here" banner.
@@ -81,16 +80,24 @@ private:
 	LLTextBox*			mParcelOwner;
 	LLTextBox*			mLastVisited;
 
-	LLTextBox*			mRatingText;
+	LLIconCtrl*			mParcelRatingIcon;
+	LLTextBox*			mParcelRatingText;
+	LLIconCtrl*			mVoiceIcon;
 	LLTextBox*			mVoiceText;
+	LLIconCtrl*			mFlyIcon;
 	LLTextBox*			mFlyText;
+	LLIconCtrl*			mPushIcon;
 	LLTextBox*			mPushText;
+	LLIconCtrl*			mBuildIcon;
 	LLTextBox*			mBuildText;
+	LLIconCtrl*			mScriptsIcon;
 	LLTextBox*			mScriptsText;
+	LLIconCtrl*			mDamageIcon;
 	LLTextBox*			mDamageText;
 
 	LLTextBox*			mRegionNameText;
 	LLTextBox*			mRegionTypeText;
+	LLIconCtrl*			mRegionRatingIcon;
 	LLTextBox*			mRegionRatingText;
 	LLTextBox*			mRegionOwnerText;
 	LLTextBox*			mRegionGroupText;
diff --git a/indra/newview/skins/default/xui/en/panel_place_profile.xml b/indra/newview/skins/default/xui/en/panel_place_profile.xml
index 7e073f064d..4dc65fa736 100644
--- a/indra/newview/skins/default/xui/en/panel_place_profile.xml
+++ b/indra/newview/skins/default/xui/en/panel_place_profile.xml
@@ -289,33 +289,14 @@
                          left="0"
                          top="0"
                          width="275">
-                            <icon
-                             follows="top|left"
-                             height="16"
-                             image_name="parcel_drk_M"
-                             layout="topleft"
-                             left="20"
-                             name="icon_M"
-                             top="0"
-                             width="18" />
-                            <icon
-                             follows="top|left"
-                             height="16"
-                             image_name="parcel_drk_R"
-                             layout="topleft"
-                             left="20"
-                             name="icon_R"
-                             top="0"
-                             width="18" />
                             <icon
                              follows="top|left"
                              height="16"
                              image_name="parcel_drk_PG"
                              layout="topleft"
                              left="20"
-                             name="icon_PG"
+                             name="rating_icon"
                              top="0"
-                             visible="false"
                              width="18" />
                             <text
                              follows="left|top"
@@ -332,7 +313,7 @@
                              left_pad="0"
                              name="rating_value"
                              top_delta="0"
-                             value="Mature"
+                             value="unknown"
                              width="120" />
                             <icon
                              follows="top|left"
@@ -340,19 +321,9 @@
                              image_name="parcel_drk_Voice"
                              layout="topleft"
                              left="20"
-                             name="icon_Voice"
+                             name="voice_icon"
                              top_pad="5"
                              width="22" />
-                            <icon
-                             follows="top|left"
-                             height="18"
-                             image_name="parcel_drk_VoiceNo"
-                             layout="topleft"
-                             left="20"
-                             name="icon_VoiceNo"
-                             top_delta="0"
-                             visible="false"
-                             width="22" />
                             <text
                              follows="left|top"
                              height="18"
@@ -377,19 +348,9 @@
                              image_name="parcel_drk_Fly"
                              layout="topleft"
                              left="20"
-                             name="icon_Fly"
+                             name="fly_icon"
                              top_pad="3"
                              width="22" />
-                            <icon
-                             follows="top|left"
-                             height="18"
-                             image_name="parcel_drk_FlyNo"
-                             layout="topleft"
-                             left="20"
-                             name="icon_FlyNo"
-                             top_delta="0"
-                             visible="false"
-                             width="22" />
                             <text
                              follows="left|top"
                              height="16"
@@ -413,18 +374,8 @@
                              image_name="parcel_drk_Push"
                              layout="topleft"
                              left="20"
-                             name="icon_Push"
+                             name="push_icon"
                              top_pad="3"
-                             visible="false"
-                             width="22" />
-                            <icon
-                             follows="top|left"
-                             height="18"
-                             image_name="parcel_drk_PushNo"
-                             layout="topleft"
-                             left="20"
-                             name="icon_PushNo"
-                             top_delta="0"
                              width="22" />
                             <text
                              follows="left|top"
@@ -449,18 +400,9 @@
                              image_name="parcel_drk_Build"
                              layout="topleft"
                              left="20"
-                             name="icon_Build"
+                             name="build_icon"
                              top_pad="3"
                              width="22" />
-                            <icon
-                             follows="top|left"
-                             height="18"
-                             image_name="parcel_drk_BuildNo"
-                             layout="topleft"
-                             left="20"
-                             name="icon_BuildNo"
-                             top_delta="0"
-                             visible="false" />
                             <text
                              follows="left|top"
                              height="14"
@@ -484,18 +426,9 @@
                              image_name="parcel_drk_Scripts"
                              layout="topleft"
                              left="20"
-                             name="icon_Scripts"
+                             name="scripts_icon"
                              top_pad="3"
                              width="22" />
-                            <icon
-                             follows="top|left"
-                             height="18"
-                             image_name="parcel_drk_ScriptsNo"
-                             layout="topleft"
-                             left="20"
-                             name="icon_ScriptsNo"
-                             top_delta="0"
-                             visible="false" />
                             <text
                              follows="left|top"
                              height="14"
@@ -519,18 +452,9 @@
                              image_name="parcel_drk_Damage"
                              layout="topleft"
                              left="20"
-                             name="icon_Damage"
+                             name="damage_icon"
                              top_pad="7"
-                             visible="false"
                              width="22" />
-                            <icon
-                             follows="top|left"
-                             height="18"
-                             image_name="parcel_drk_DamageNo"
-                             layout="topleft"
-                             left="20"
-                             name="icon_DamageNo"
-                             top_delta="0" />
                             <text
                              follows="left|top"
                              height="14"
@@ -622,33 +546,13 @@
                          top_pad="7"
                          value="Rating:"
                          width="80" />
-                        <icon
-                         follows="top|left"
-                         height="16"
-                         image_name="parcel_drk_M"
-                         layout="topleft"
-                         left_pad="0"
-                         name="icon_M"
-                         width="18" />
-                        <icon
-                         follows="top|left"
-                         height="16"
-                         image_name="parcel_drk_R"
-                         layout="topleft"
-                         left_delta="0"
-                         name="icon_R"
-                         top_delta="0"
-                         visible="false"
-                         width="18" />
                         <icon
                          follows="top|left"
                          height="16"
                          image_name="parcel_drk_PG"
                          layout="topleft"
-                         left_delta="0"
-                         name="icon_PG"
-                         top_delta="0"
-                         visible="false"
+                         left_pad="0"
+                         name="region_rating_icon"
                          width="18" />
                         <text
                          follows="left|top|right"
-- 
cgit v1.2.3


From 380bb0ce09913ae05000c86fb0a0ed410ead1089 Mon Sep 17 00:00:00 2001
From: Sergei Litovchuk <slitovchuk@productengine.com>
Date: Wed, 4 Nov 2009 15:24:11 +0200
Subject: No ticket. Removed extra includes. Fixed copyright years.

--HG--
branch : product-engine
---
 indra/newview/llpanellandmarkinfo.cpp    | 5 +----
 indra/newview/llpanellandmarkinfo.h      | 2 +-
 indra/newview/llpanellandmarks.cpp       | 2 +-
 indra/newview/llpanellandmarks.h         | 2 +-
 indra/newview/llpanelpicks.cpp           | 2 +-
 indra/newview/llpanelpicks.h             | 2 +-
 indra/newview/llpanelplaceinfo.cpp       | 7 +------
 indra/newview/llpanelplaceinfo.h         | 2 +-
 indra/newview/llpanelplaceprofile.cpp    | 4 +---
 indra/newview/llpanelplaceprofile.h      | 2 +-
 indra/newview/llpanelplaces.cpp          | 2 +-
 indra/newview/llpanelplaces.h            | 2 +-
 indra/newview/llpanelplacestab.cpp       | 2 +-
 indra/newview/llpanelplacestab.h         | 2 +-
 indra/newview/llpanelteleporthistory.cpp | 2 +-
 indra/newview/llpanelteleporthistory.h   | 2 +-
 16 files changed, 16 insertions(+), 26 deletions(-)

(limited to 'indra')

diff --git a/indra/newview/llpanellandmarkinfo.cpp b/indra/newview/llpanellandmarkinfo.cpp
index fd6a41c505..fe01fc6307 100644
--- a/indra/newview/llpanellandmarkinfo.cpp
+++ b/indra/newview/llpanellandmarkinfo.cpp
@@ -4,7 +4,7 @@
  *
  * $LicenseInfo:firstyear=2009&license=viewergpl$
  *
- * Copyright (c) 2004-2009, Linden Research, Inc.
+ * Copyright (c) 2009, Linden Research, Inc.
  *
  * Second Life Viewer Source Code
  * The source code in this file ("Source Code") is provided by Linden Lab
@@ -34,8 +34,6 @@
 
 #include "llpanellandmarkinfo.h"
 
-#include "llinventory.h"
-
 #include "llcombobox.h"
 #include "lllineeditor.h"
 #include "lltextbox.h"
@@ -44,7 +42,6 @@
 
 #include "llagent.h"
 #include "llagentui.h"
-#include "llinventorymodel.h"
 #include "lllandmarkactions.h"
 #include "llviewerinventory.h"
 #include "llviewerparcelmgr.h"
diff --git a/indra/newview/llpanellandmarkinfo.h b/indra/newview/llpanellandmarkinfo.h
index 03377986b3..73e0ddb9cc 100644
--- a/indra/newview/llpanellandmarkinfo.h
+++ b/indra/newview/llpanellandmarkinfo.h
@@ -4,7 +4,7 @@
  *
  * $LicenseInfo:firstyear=2009&license=viewergpl$
  *
- * Copyright (c) 2004-2009, Linden Research, Inc.
+ * Copyright (c) 2009, Linden Research, Inc.
  *
  * Second Life Viewer Source Code
  * The source code in this file ("Source Code") is provided by Linden Lab
diff --git a/indra/newview/llpanellandmarks.cpp b/indra/newview/llpanellandmarks.cpp
index 5f717b51cc..34c146826f 100644
--- a/indra/newview/llpanellandmarks.cpp
+++ b/indra/newview/llpanellandmarks.cpp
@@ -4,7 +4,7 @@
  *
  * $LicenseInfo:firstyear=2009&license=viewergpl$
  *
- * Copyright (c) 2001-2009, Linden Research, Inc.
+ * Copyright (c) 2009, Linden Research, Inc.
  *
  * Second Life Viewer Source Code
  * The source code in this file ("Source Code") is provided by Linden Lab
diff --git a/indra/newview/llpanellandmarks.h b/indra/newview/llpanellandmarks.h
index 0e7abb4865..d54761ed59 100644
--- a/indra/newview/llpanellandmarks.h
+++ b/indra/newview/llpanellandmarks.h
@@ -5,7 +5,7 @@
  *
  * $LicenseInfo:firstyear=2009&license=viewergpl$
  *
- * Copyright (c) 2001-2009, Linden Research, Inc.
+ * Copyright (c) 2009, Linden Research, Inc.
  *
  * Second Life Viewer Source Code
  * The source code in this file ("Source Code") is provided by Linden Lab
diff --git a/indra/newview/llpanelpicks.cpp b/indra/newview/llpanelpicks.cpp
index 6181531f82..2bf04f9681 100644
--- a/indra/newview/llpanelpicks.cpp
+++ b/indra/newview/llpanelpicks.cpp
@@ -4,7 +4,7 @@
  *
  * $LicenseInfo:firstyear=2009&license=viewergpl$
  * 
- * Copyright (c) 2004-2009, Linden Research, Inc.
+ * Copyright (c) 2009, Linden Research, Inc.
  * 
  * Second Life Viewer Source Code
  * The source code in this file ("Source Code") is provided by Linden Lab
diff --git a/indra/newview/llpanelpicks.h b/indra/newview/llpanelpicks.h
index 06a0f0a0fd..5a2754ad10 100644
--- a/indra/newview/llpanelpicks.h
+++ b/indra/newview/llpanelpicks.h
@@ -4,7 +4,7 @@
  *
  * $LicenseInfo:firstyear=2009&license=viewergpl$
  * 
- * Copyright (c) 2004-2009, Linden Research, Inc.
+ * Copyright (c) 2009, Linden Research, Inc.
  * 
  * Second Life Viewer Source Code
  * The source code in this file ("Source Code") is provided by Linden Lab
diff --git a/indra/newview/llpanelplaceinfo.cpp b/indra/newview/llpanelplaceinfo.cpp
index e6d10be858..c600651015 100644
--- a/indra/newview/llpanelplaceinfo.cpp
+++ b/indra/newview/llpanelplaceinfo.cpp
@@ -4,7 +4,7 @@
  *
  * $LicenseInfo:firstyear=2009&license=viewergpl$
  * 
- * Copyright (c) 2004-2009, Linden Research, Inc.
+ * Copyright (c) 2009, Linden Research, Inc.
  * 
  * Second Life Viewer Source Code
  * The source code in this file ("Source Code") is provided by Linden Lab
@@ -38,8 +38,6 @@
 #include "llsdutil.h"
 #include "llsecondlifeurls.h"
 
-#include "llinventory.h"
-
 #include "llsdutil_math.h"
 
 #include "llscrollcontainer.h"
@@ -48,15 +46,12 @@
 #include "llagent.h"
 #include "llavatarpropertiesprocessor.h"
 #include "llexpandabletextbox.h"
-#include "llfloaterworldmap.h"
-#include "llinventorymodel.h"
 #include "llpanelpick.h"
 #include "lltexturectrl.h"
 #include "llviewerinventory.h"
 #include "llviewerparcelmgr.h"
 #include "llviewerregion.h"
 #include "llviewertexteditor.h"
-#include "llworldmap.h"
 
 LLPanelPlaceInfo::LLPanelPlaceInfo()
 :	LLPanel(),
diff --git a/indra/newview/llpanelplaceinfo.h b/indra/newview/llpanelplaceinfo.h
index c9e1347542..ec30397cff 100644
--- a/indra/newview/llpanelplaceinfo.h
+++ b/indra/newview/llpanelplaceinfo.h
@@ -4,7 +4,7 @@
  *
  * $LicenseInfo:firstyear=2009&license=viewergpl$
  * 
- * Copyright (c) 2004-2009, Linden Research, Inc.
+ * Copyright (c) 2009, Linden Research, Inc.
  * 
  * Second Life Viewer Source Code
  * The source code in this file ("Source Code") is provided by Linden Lab
diff --git a/indra/newview/llpanelplaceprofile.cpp b/indra/newview/llpanelplaceprofile.cpp
index 814139607c..b2a9f6f251 100644
--- a/indra/newview/llpanelplaceprofile.cpp
+++ b/indra/newview/llpanelplaceprofile.cpp
@@ -4,7 +4,7 @@
  *
  * $LicenseInfo:firstyear=2009&license=viewergpl$
  *
- * Copyright (c) 2004-2009, Linden Research, Inc.
+ * Copyright (c) 2009, Linden Research, Inc.
  *
  * Second Life Viewer Source Code
  * The source code in this file ("Source Code") is provided by Linden Lab
@@ -36,8 +36,6 @@
 
 #include "llparcel.h"
 
-#include "llqueryflags.h"
-
 #include "lliconctrl.h"
 #include "lllineeditor.h"
 #include "lltextbox.h"
diff --git a/indra/newview/llpanelplaceprofile.h b/indra/newview/llpanelplaceprofile.h
index db54ff8af9..b3ef4acf51 100644
--- a/indra/newview/llpanelplaceprofile.h
+++ b/indra/newview/llpanelplaceprofile.h
@@ -4,7 +4,7 @@
  *
  * $LicenseInfo:firstyear=2009&license=viewergpl$
  *
- * Copyright (c) 2004-2009, Linden Research, Inc.
+ * Copyright (c) 2009, Linden Research, Inc.
  *
  * Second Life Viewer Source Code
  * The source code in this file ("Source Code") is provided by Linden Lab
diff --git a/indra/newview/llpanelplaces.cpp b/indra/newview/llpanelplaces.cpp
index 42e4a6e40b..6f15e53299 100644
--- a/indra/newview/llpanelplaces.cpp
+++ b/indra/newview/llpanelplaces.cpp
@@ -4,7 +4,7 @@
  *
  * $LicenseInfo:firstyear=2009&license=viewergpl$
  *
- * Copyright (c) 2004-2009, Linden Research, Inc.
+ * Copyright (c) 2009, Linden Research, Inc.
  *
  * Second Life Viewer Source Code
  * The source code in this file ("Source Code") is provided by Linden Lab
diff --git a/indra/newview/llpanelplaces.h b/indra/newview/llpanelplaces.h
index 39eb5261db..8faed613f4 100644
--- a/indra/newview/llpanelplaces.h
+++ b/indra/newview/llpanelplaces.h
@@ -4,7 +4,7 @@
  *
  * $LicenseInfo:firstyear=2009&license=viewergpl$
  * 
- * Copyright (c) 2004-2009, Linden Research, Inc.
+ * Copyright (c) 2009, Linden Research, Inc.
  * 
  * Second Life Viewer Source Code
  * The source code in this file ("Source Code") is provided by Linden Lab
diff --git a/indra/newview/llpanelplacestab.cpp b/indra/newview/llpanelplacestab.cpp
index 7c0a7b0cc4..f5e7ff3c40 100644
--- a/indra/newview/llpanelplacestab.cpp
+++ b/indra/newview/llpanelplacestab.cpp
@@ -4,7 +4,7 @@
  *
  * $LicenseInfo:firstyear=2009&license=viewergpl$
  * 
- * Copyright (c) 2004-2009, Linden Research, Inc.
+ * Copyright (c) 2009, Linden Research, Inc.
  * 
  * Second Life Viewer Source Code
  * The source code in this file ("Source Code") is provided by Linden Lab
diff --git a/indra/newview/llpanelplacestab.h b/indra/newview/llpanelplacestab.h
index 1c70869414..3f56dcb283 100644
--- a/indra/newview/llpanelplacestab.h
+++ b/indra/newview/llpanelplacestab.h
@@ -4,7 +4,7 @@
  *
  * $LicenseInfo:firstyear=2009&license=viewergpl$
  * 
- * Copyright (c) 2004-2009, Linden Research, Inc.
+ * Copyright (c) 2009, Linden Research, Inc.
  * 
  * Second Life Viewer Source Code
  * The source code in this file ("Source Code") is provided by Linden Lab
diff --git a/indra/newview/llpanelteleporthistory.cpp b/indra/newview/llpanelteleporthistory.cpp
index 7dd9df674c..437af1c4e7 100644
--- a/indra/newview/llpanelteleporthistory.cpp
+++ b/indra/newview/llpanelteleporthistory.cpp
@@ -4,7 +4,7 @@
  *
  * $LicenseInfo:firstyear=2009&license=viewergpl$
  * 
- * Copyright (c) 2001-2009, Linden Research, Inc.
+ * Copyright (c) 2009, Linden Research, Inc.
  * 
  * Second Life Viewer Source Code
  * The source code in this file ("Source Code") is provided by Linden Lab
diff --git a/indra/newview/llpanelteleporthistory.h b/indra/newview/llpanelteleporthistory.h
index 7c1b403432..b34d9e876c 100644
--- a/indra/newview/llpanelteleporthistory.h
+++ b/indra/newview/llpanelteleporthistory.h
@@ -5,7 +5,7 @@
  *
  * $LicenseInfo:firstyear=2009&license=viewergpl$
  * 
- * Copyright (c) 2001-2009, Linden Research, Inc.
+ * Copyright (c) 2009, Linden Research, Inc.
  * 
  * Second Life Viewer Source Code
  * The source code in this file ("Source Code") is provided by Linden Lab
-- 
cgit v1.2.3


From 14af8485fd3759cda8b5471b0f6171b832d3e1b4 Mon Sep 17 00:00:00 2001
From: Mike Antipov <mantipov@productengine.com>
Date: Wed, 4 Nov 2009 16:02:12 +0200
Subject: Fixed normal bug EXT-2061 ("All" list doesn't contain any friends
 while "Online" list isn't empty in "Friends" tab on People Panel) - added
 code to force fetching of Inventory "Friends/All" folder in case it is
 incomplete on startup.

--HG--
branch : product-engine
---
 indra/newview/llfriendcard.cpp | 71 +++++++++++++++++++++++++++++++++++++++++-
 indra/newview/llfriendcard.h   | 13 +++++++-
 2 files changed, 82 insertions(+), 2 deletions(-)

(limited to 'indra')

diff --git a/indra/newview/llfriendcard.cpp b/indra/newview/llfriendcard.cpp
index fbcaeee01f..724b18ded2 100644
--- a/indra/newview/llfriendcard.cpp
+++ b/indra/newview/llfriendcard.cpp
@@ -91,8 +91,44 @@ const LLUUID& get_folder_uuid(const LLUUID& parentFolderUUID, LLInventoryCollect
 	return LLUUID::null;
 }
 
+
+// LLViewerInventoryCategory::fetchDescendents has it own period of fetching.
+// for now it is FETCH_TIMER_EXPIRY = 10.0f; So made our period a bit more.
+const F32 FETCH_FRIENDS_DESCENDENTS_PERIOD = 11.0f;
+
+
+/**
+ * Intended to call passed callback after the specified period of time.
+ *
+ * Implemented to fix an issue when Inventory folders are in incomplete state. See EXT-2061, EXT-1935, EXT-813.
+ * For now it uses to periodically sync Inventory Friends/All folder with a Agent's Friends List
+ * until it is complete.
+ */ 
+class FriendListUpdater : public LLEventTimer
+{
+public:
+	typedef boost::function<bool()> callback_t;
+
+	FriendListUpdater(callback_t cb, F32 period)
+		:	LLEventTimer(period)
+		,	mCallback(cb)
+	{
+		mEventTimer.start();
+	}
+
+	virtual BOOL tick() // from LLEventTimer
+	{
+		return mCallback();
+	}
+
+private:
+	callback_t		mCallback;
+};
+
+
 // LLFriendCardsManager Constructor / Destructor
 LLFriendCardsManager::LLFriendCardsManager()
+: mFriendsAllFolderCompleted(true)
 {
 	LLAvatarTracker::instance().addObserver(this);
 }
@@ -269,7 +305,7 @@ bool LLFriendCardsManager::isAnyFriendCategory(const LLUUID& catID) const
 	return TRUE == gInventory.isObjectDescendentOf(catID, friendFolderID);
 }
 
-void LLFriendCardsManager::syncFriendsFolder()
+bool LLFriendCardsManager::syncFriendsFolder()
 {
 	//lets create "Friends" and "Friends/All" in the Inventory "Calling Cards" if they are absent
 	LLFriendCardsManager::instance().ensureFriendFoldersExist();
@@ -297,11 +333,35 @@ void LLFriendCardsManager::syncFriendsFolder()
 	// 2. Add missing Friend Cards for friends
 	LLAvatarTracker::buddy_map_t::const_iterator buddy_it = all_buddies.begin();
 	llinfos << "try to build friends, count: " << all_buddies.size() << llendl; 
+	mFriendsAllFolderCompleted = true;
 	for(; buddy_it != all_buddies.end(); ++buddy_it)
 	{
 		const LLUUID& buddy_id = (*buddy_it).first;
 		addFriendCardToInventory(buddy_id);
 	}
+
+	if (!mFriendsAllFolderCompleted)
+	{
+		forceFriendListIsLoaded(findFriendAllSubfolderUUIDImpl());
+
+		static bool timer_started = false;
+		if (!timer_started)
+		{
+			lldebugs << "Create and start timer to sync Inventory Friends All folder with Friends list" << llendl;
+
+			// do not worry about destruction of the FriendListUpdater. 
+			// It will be deleted by LLEventTimer::updateClass when FriendListUpdater::tick() returns true.
+			new FriendListUpdater(boost::bind(&LLFriendCardsManager::syncFriendsFolder, this),
+				FETCH_FRIENDS_DESCENDENTS_PERIOD);
+		}
+		timer_started = true;
+	}
+	else
+	{
+		lldebugs << "Friends/All Inventory folder is synchronized with the Agent's Friends List" << llendl;
+	}
+
+	return mFriendsAllFolderCompleted;
 }
 
 void LLFriendCardsManager::collectFriendsLists(folderid_buddies_map_t& folderBuddiesMap) const
@@ -461,7 +521,9 @@ bool LLFriendCardsManager::addFriendCardToInventory(const LLUUID& avatarID)
 	LLUUID friendListFolderID = findFriendAllSubfolderUUIDImpl();
 	if (shouldBeAdded && !invModel->isCategoryComplete(friendListFolderID))
 	{
+		mFriendsAllFolderCompleted = false;
 		shouldBeAdded = false;
+		lldebugs << "Friends/All category is not completed" << llendl; 
 	}
 	if (shouldBeAdded)
 	{
@@ -520,4 +582,11 @@ void LLFriendCardsManager::onFriendListUpdate(U32 changed_mask)
 	}
 }
 
+void LLFriendCardsManager::forceFriendListIsLoaded(const LLUUID& folder_id) const
+{
+	bool fetching_inventory = gInventory.fetchDescendentsOf(folder_id);
+	lldebugs << "Trying to fetch descendants of Friends/All Inventory folder, fetched: "
+		<< fetching_inventory << llendl;
+}
+
 // EOF
diff --git a/indra/newview/llfriendcard.h b/indra/newview/llfriendcard.h
index 6ada342831..feea05bc1d 100644
--- a/indra/newview/llfriendcard.h
+++ b/indra/newview/llfriendcard.h
@@ -89,8 +89,10 @@ public:
 
 	/**
 	 *	Synchronizes content of the Calling Card/Friends/All Global Inventory folder with Agent's Friend List
+	 *
+	 *	@return true - if folder is already synchronized, false otherwise.
 	 */
-	void syncFriendsFolder();
+	bool syncFriendsFolder();
 
 	/*!
 	 * \brief
@@ -144,11 +146,20 @@ private:
 
 	void onFriendListUpdate(U32 changed_mask);
 
+	/**
+	 * Force fetching of the Inventory folder specified by passed folder's LLUUID.
+	 *
+	 * It only sends request to server, server reply should be processed in other place.
+	 * Because request can be sent via UDP we need to periodically check if request was completed with success.
+	 */
+	void forceFriendListIsLoaded(const LLUUID& folder_id) const;
+
 
 private:
 	typedef std::set<LLUUID> avatar_uuid_set_t;
 
 	avatar_uuid_set_t mBuddyIDSet;
+	bool mFriendsAllFolderCompleted;
 };
 
 #endif // LL_LLFRIENDCARD_H
-- 
cgit v1.2.3


From e634f2f42d5a7165f4cab2910f144144bc7a31d0 Mon Sep 17 00:00:00 2001
From: Andrew Dyukov <adyukov@productengine.com>
Date: Wed, 4 Nov 2009 16:13:47 +0200
Subject: Fixed problems caused by a160d0dfb897

--HG--
branch : product-engine
---
 indra/newview/llnavigationbar.cpp                           | 10 ++++++++--
 indra/newview/skins/default/xui/en/panel_navigation_bar.xml |  2 +-
 2 files changed, 9 insertions(+), 3 deletions(-)

(limited to 'indra')

diff --git a/indra/newview/llnavigationbar.cpp b/indra/newview/llnavigationbar.cpp
index b35fd6134b..1312949f54 100644
--- a/indra/newview/llnavigationbar.cpp
+++ b/indra/newview/llnavigationbar.cpp
@@ -274,8 +274,14 @@ void LLNavigationBar::draw()
 
 BOOL LLNavigationBar::handleRightMouseDown(S32 x, S32 y, MASK mask)
 {
-	show_navbar_context_menu(this,x,y);
-	return TRUE;
+	BOOL handled = childrenHandleRightMouseDown( x, y, mask) != NULL;
+	if(!handled && !gMenuHolder->hasVisibleMenu())
+	{
+		show_navbar_context_menu(this,x,y);
+		handled = true;
+	}
+					
+	return handled;
 }
 
 void LLNavigationBar::onBackButtonClicked()
diff --git a/indra/newview/skins/default/xui/en/panel_navigation_bar.xml b/indra/newview/skins/default/xui/en/panel_navigation_bar.xml
index 4175d21639..a289ce3cf7 100644
--- a/indra/newview/skins/default/xui/en/panel_navigation_bar.xml
+++ b/indra/newview/skins/default/xui/en/panel_navigation_bar.xml
@@ -11,7 +11,7 @@
 	<icon
 	 follows="all"
 	 image_name="NavBar_BG"
-	 mouse_opaque="true"
+	 mouse_opaque="false"
 	 name="bg_icon"
 	 scale_image="true"
 	 visible="true"
-- 
cgit v1.2.3


From 347f2614804d2b681358822c6bd018409aadde83 Mon Sep 17 00:00:00 2001
From: Dmitry Oleshko <doleshko@productengine.com>
Date: Wed, 4 Nov 2009 16:35:48 +0200
Subject: implemented a normal Sub-task (EXT-988) Change indication of unread
 messges in chiclets

--HG--
branch : product-engine
---
 indra/newview/llchiclet.cpp | 98 ++++++++++++++++++++-------------------------
 indra/newview/llchiclet.h   | 32 +++++++++++----
 2 files changed, 68 insertions(+), 62 deletions(-)

(limited to 'indra')

diff --git a/indra/newview/llchiclet.cpp b/indra/newview/llchiclet.cpp
index 8a4650763f..594385b4ef 100644
--- a/indra/newview/llchiclet.cpp
+++ b/indra/newview/llchiclet.cpp
@@ -198,9 +198,38 @@ void LLChiclet::setValue(const LLSD& value)
 //////////////////////////////////////////////////////////////////////////
 //////////////////////////////////////////////////////////////////////////
 
-LLIMChiclet::LLIMChiclet(const LLChiclet::Params& p)
+LLIMChiclet::LLIMChiclet(const LLIMChiclet::Params& p)
 : LLChiclet(p)
+, mNewMessagesIcon(NULL)
+, mCounterCtrl(NULL)
+{
+	// initialize an overlay icon for new messages
+	LLIconCtrl::Params icon_params;
+	icon_params.visible = false;
+	icon_params.image = LLUI::getUIImage(p.new_messages_icon_name);
+	mNewMessagesIcon = LLUICtrlFactory::create<LLIconCtrl>(icon_params);
+	// adjust size and position of an icon
+	LLRect chiclet_rect = p.rect;
+	LLRect overlay_icon_rect = LLRect(chiclet_rect.getWidth()/2, chiclet_rect.mTop, chiclet_rect.mRight, chiclet_rect.getHeight()/2); 
+	// shift an icon a little bit to the right and up corner of a chiclet
+	overlay_icon_rect.translate(overlay_icon_rect.getWidth()/4, overlay_icon_rect.getHeight()/4);
+	mNewMessagesIcon->setRect(overlay_icon_rect);
+	addChild(mNewMessagesIcon);
+
+	setShowCounter(false);
+}
+
+void LLIMChiclet::setShowNewMessagesIcon(bool show)
+{
+	if(mNewMessagesIcon)
+	{
+		mNewMessagesIcon->setVisible(show);
+	}
+}
+
+bool LLIMChiclet::getShowNewMessagesIcon()
 {
+	return mNewMessagesIcon->getVisible();
 }
 
 void LLIMChiclet::onMouseDown()
@@ -274,7 +303,7 @@ LLIMP2PChiclet::Params::Params()
 , show_speaker("show_speaker")
 {
 	// *TODO Vadim: Get rid of hardcoded values.
-	rect(LLRect(0, 25, 45, 0));
+	rect(LLRect(0, 25, 25, 0));
 
 	avatar_icon.name("avatar_icon");
 	avatar_icon.follows.flags(FOLLOWS_LEFT | FOLLOWS_TOP | FOLLOWS_BOTTOM);
@@ -293,6 +322,7 @@ LLIMP2PChiclet::Params::Params()
 	unread_notifications.v_pad(5);
 	unread_notifications.text_color(LLColor4::white);
 	unread_notifications.mouse_opaque(false);
+	unread_notifications.visible(false);
 
 	speaker.name("speaker");
 	speaker.rect(LLRect(45, 25, 65, 0));
@@ -303,7 +333,6 @@ LLIMP2PChiclet::Params::Params()
 LLIMP2PChiclet::LLIMP2PChiclet(const Params& p)
 : LLIMChiclet(p)
 , mChicletIconCtrl(NULL)
-, mCounterCtrl(NULL)
 , mSpeakerCtrl(NULL)
 , mPopupMenu(NULL)
 {
@@ -322,28 +351,14 @@ LLIMP2PChiclet::LLIMP2PChiclet(const Params& p)
 	mSpeakerCtrl = LLUICtrlFactory::create<LLChicletSpeakerCtrl>(speaker_params);
 	addChild(mSpeakerCtrl);
 
+	sendChildToFront(mNewMessagesIcon);
 	setShowSpeaker(p.show_speaker);
 }
 
 void LLIMP2PChiclet::setCounter(S32 counter)
 {
 	mCounterCtrl->setCounter(counter);
-
-	if(getShowCounter())
-	{
-		LLRect counter_rect = mCounterCtrl->getRect();
-		LLRect required_rect = mCounterCtrl->getRequiredRect();
-		bool needs_resize = required_rect.getWidth() != counter_rect.getWidth();
-
-		if(needs_resize)
-		{
-			counter_rect.mRight = counter_rect.mLeft + required_rect.getWidth();
-			mCounterCtrl->reshape(counter_rect.getWidth(), counter_rect.getHeight());
-			mCounterCtrl->setRect(counter_rect);
-
-			onChicletSizeChanged();
-		}
-	}
+	setShowNewMessagesIcon(counter);
 }
 
 LLRect LLIMP2PChiclet::getRequiredRect()
@@ -458,7 +473,7 @@ LLAdHocChiclet::Params::Params()
 , avatar_icon_color("avatar_icon_color", LLColor4::green)
 {
 	// *TODO Vadim: Get rid of hardcoded values.
-	rect(LLRect(0, 25, 45, 0));
+	rect(LLRect(0, 25, 25, 0));
 
 	avatar_icon.name("avatar_icon");
 	avatar_icon.follows.flags(FOLLOWS_LEFT | FOLLOWS_TOP | FOLLOWS_BOTTOM);
@@ -477,6 +492,8 @@ LLAdHocChiclet::Params::Params()
 	unread_notifications.v_pad(5);
 	unread_notifications.text_color(LLColor4::white);
 	unread_notifications.mouse_opaque(false);
+	unread_notifications.visible(false);
+
 
 	speaker.name("speaker");
 	speaker.rect(LLRect(45, 25, 65, 0));
@@ -487,7 +504,6 @@ LLAdHocChiclet::Params::Params()
 LLAdHocChiclet::LLAdHocChiclet(const Params& p)
 : LLIMChiclet(p)
 , mChicletIconCtrl(NULL)
-, mCounterCtrl(NULL)
 , mSpeakerCtrl(NULL)
 , mPopupMenu(NULL)
 {
@@ -508,6 +524,7 @@ LLAdHocChiclet::LLAdHocChiclet(const Params& p)
 	mSpeakerCtrl = LLUICtrlFactory::create<LLChicletSpeakerCtrl>(speaker_params);
 	addChild(mSpeakerCtrl);
 
+	sendChildToFront(mNewMessagesIcon);
 	setShowSpeaker(p.show_speaker);
 }
 
@@ -521,22 +538,7 @@ void LLAdHocChiclet::setSessionId(const LLUUID& session_id)
 void LLAdHocChiclet::setCounter(S32 counter)
 {
 	mCounterCtrl->setCounter(counter);
-
-	if(getShowCounter())
-	{
-		LLRect counter_rect = mCounterCtrl->getRect();
-		LLRect required_rect = mCounterCtrl->getRequiredRect();
-		bool needs_resize = required_rect.getWidth() != counter_rect.getWidth();
-
-		if(needs_resize)
-		{
-			counter_rect.mRight = counter_rect.mLeft + required_rect.getWidth();
-			mCounterCtrl->reshape(counter_rect.getWidth(), counter_rect.getHeight());
-			mCounterCtrl->setRect(counter_rect);
-
-			onChicletSizeChanged();
-		}
-	}
+	setShowNewMessagesIcon(counter);
 }
 
 LLRect LLAdHocChiclet::getRequiredRect()
@@ -565,7 +567,7 @@ BOOL LLAdHocChiclet::handleRightMouseDown(S32 x, S32 y, MASK mask)
 LLIMGroupChiclet::Params::Params()
 : group_icon("group_icon")
 {
-	rect(LLRect(0, 25, 45, 0));
+	rect(LLRect(0, 25, 25, 0));
 
 	group_icon.name("group_icon");
 	
@@ -581,6 +583,7 @@ LLIMGroupChiclet::Params::Params()
 	unread_notifications.font_halign(LLFontGL::HCENTER);
 	unread_notifications.v_pad(5);
 	unread_notifications.text_color(LLColor4::white);
+	unread_notifications.visible(false);
 
 	speaker.name("speaker");
 	speaker.rect(LLRect(45, 25, 65, 0));
@@ -592,7 +595,6 @@ LLIMGroupChiclet::LLIMGroupChiclet(const Params& p)
 : LLIMChiclet(p)
 , LLGroupMgrObserver(LLUUID::null)
 , mChicletIconCtrl(NULL)
-, mCounterCtrl(NULL)
 , mSpeakerCtrl(NULL)
 , mPopupMenu(NULL)
 {
@@ -611,6 +613,7 @@ LLIMGroupChiclet::LLIMGroupChiclet(const Params& p)
 	mSpeakerCtrl = LLUICtrlFactory::create<LLChicletSpeakerCtrl>(speaker_params);
 	addChild(mSpeakerCtrl);
 
+	sendChildToFront(mNewMessagesIcon);
 	setShowSpeaker(p.show_speaker);
 }
 
@@ -622,22 +625,7 @@ LLIMGroupChiclet::~LLIMGroupChiclet()
 void LLIMGroupChiclet::setCounter(S32 counter)
 {
 	mCounterCtrl->setCounter(counter);
-
-	if(getShowCounter())
-	{
-		LLRect counter_rect = mCounterCtrl->getRect();
-		LLRect required_rect = mCounterCtrl->getRequiredRect();
-		bool needs_resize = required_rect.getWidth() != counter_rect.getWidth();
-
-		if(needs_resize)
-		{
-			counter_rect.mRight = counter_rect.mLeft + required_rect.getWidth();
-			mCounterCtrl->reshape(counter_rect.getWidth(), counter_rect.getHeight());
-			mCounterCtrl->setRect(counter_rect);
-
-			onChicletSizeChanged();
-		}
-	}
+	setShowNewMessagesIcon(counter);
 }
 
 LLRect LLIMGroupChiclet::getRequiredRect()
diff --git a/indra/newview/llchiclet.h b/indra/newview/llchiclet.h
index f82259c73e..a830240b7d 100644
--- a/indra/newview/llchiclet.h
+++ b/indra/newview/llchiclet.h
@@ -278,6 +278,14 @@ public:
 		TYPE_GROUP,
 		TYPE_AD_HOC
 	};
+	struct Params : public LLInitParam::Block<Params, LLChiclet::Params>
+	{
+		Optional<std::string> new_messages_icon_name;
+
+		Params() : new_messages_icon_name("new_messages_icon_name", "icn_voice-localchat.tga")
+		{}
+	};
+
 	
 	/*virtual*/ ~LLIMChiclet() {};
 
@@ -307,6 +315,16 @@ public:
 	*/
 	virtual bool getShowSpeaker() {return mShowSpeaker;};
 
+	/*
+	* Shows/hides overlay icon concerning new unread messages.
+	*/
+	virtual void setShowNewMessagesIcon(bool show);
+
+	/*
+	* Returns visibility of overlay icon concerning new unread messages.
+	*/
+	virtual bool getShowNewMessagesIcon();
+
 	/*
 	 * Draws border around chiclet.
 	*/
@@ -335,7 +353,7 @@ public:
 
 protected:
 
-	LLIMChiclet(const LLChiclet::Params& p);
+	LLIMChiclet(const LLIMChiclet::Params& p);
 
 	/*virtual*/ BOOL handleMouseDown(S32 x, S32 y, MASK mask);
 
@@ -343,6 +361,9 @@ protected:
 
 	bool mShowSpeaker;
 
+	LLIconCtrl* mNewMessagesIcon;
+	LLChicletNotificationCounterCtrl* mCounterCtrl;
+
 	/** the id of another participant, either an avatar id or a group id*/
 	LLUUID mOtherParticipantId;
 
@@ -374,7 +395,7 @@ public:
 class LLIMP2PChiclet : public LLIMChiclet
 {
 public:
-	struct Params : public LLInitParam::Block<Params, LLChiclet::Params>
+	struct Params : public LLInitParam::Block<Params, LLIMChiclet::Params>
 	{
 		Optional<LLChicletAvatarIconCtrl::Params> avatar_icon;
 
@@ -436,7 +457,6 @@ protected:
 private:
 
 	LLChicletAvatarIconCtrl* mChicletIconCtrl;
-	LLChicletNotificationCounterCtrl* mCounterCtrl;
 	LLChicletSpeakerCtrl* mSpeakerCtrl;
 	LLMenuGL* mPopupMenu;
 };
@@ -447,7 +467,7 @@ private:
 class LLAdHocChiclet : public LLIMChiclet
 {
 public:
-	struct Params : public LLInitParam::Block<Params, LLChiclet::Params>
+	struct Params : public LLInitParam::Block<Params, LLIMChiclet::Params>
 	{
 		Optional<LLChicletAvatarIconCtrl::Params> avatar_icon;
 
@@ -497,7 +517,6 @@ protected:
 private:
 
 	LLChicletAvatarIconCtrl* mChicletIconCtrl;
-	LLChicletNotificationCounterCtrl* mCounterCtrl;
 	LLChicletSpeakerCtrl* mSpeakerCtrl;
 	LLMenuGL* mPopupMenu;
 };
@@ -509,7 +528,7 @@ class LLIMGroupChiclet : public LLIMChiclet, public LLGroupMgrObserver
 {
 public:
 
-	struct Params : public LLInitParam::Block<Params, LLChiclet::Params>
+	struct Params : public LLInitParam::Block<Params, LLIMChiclet::Params>
 	{
 		Optional<LLChicletGroupIconCtrl::Params> group_icon;
 
@@ -578,7 +597,6 @@ protected:
 private:
 
 	LLChicletGroupIconCtrl* mChicletIconCtrl;
-	LLChicletNotificationCounterCtrl* mCounterCtrl;
 	LLChicletSpeakerCtrl* mSpeakerCtrl;
 	LLMenuGL* mPopupMenu;
 };
-- 
cgit v1.2.3


From a1e7bef9e70312929b6c1b437a17954e6198c1db Mon Sep 17 00:00:00 2001
From: Eugene Mutavchi <emutavchi@productengine.com>
Date: Wed, 4 Nov 2009 17:48:27 +0200
Subject: No ticket,has sorted xml attributes in alphabetical order.

--HG--
branch : product-engine
---
 .../default/xui/en/panel_adhoc_control_panel.xml   |  35 ++++----
 .../default/xui/en/panel_group_control_panel.xml   |  44 +++++----
 .../default/xui/en/panel_im_control_panel.xml      | 100 +++++++++++----------
 3 files changed, 100 insertions(+), 79 deletions(-)

(limited to 'indra')

diff --git a/indra/newview/skins/default/xui/en/panel_adhoc_control_panel.xml b/indra/newview/skins/default/xui/en/panel_adhoc_control_panel.xml
index 0c1e777fa1..8dbcfe6360 100644
--- a/indra/newview/skins/default/xui/en/panel_adhoc_control_panel.xml
+++ b/indra/newview/skins/default/xui/en/panel_adhoc_control_panel.xml
@@ -1,9 +1,10 @@
 <?xml version="1.0" encoding="utf-8" standalone="yes" ?>
 <panel
- name="panel_im_control_panel"
- width="180"
+ border="false"
  height="215"
- border="false">
+ name="panel_im_control_panel"
+ width="180">
+
     <avatar_list
      color="DkGray2"
      follows="left|top|right|bottom"
@@ -16,24 +17,28 @@
      show_info_btn="false"
      show_profile_btn="false"
      top="10"
-     width="180" />
+     width="180"/>
+
     <button
-     name="call_btn"
+     height="20"
      label="Call Group"
      left_delta="27"
-     width="125"
-     height="20" />
+     name="call_btn"
+     width="125"/>
+
     <button
-     name="end_call_btn"
+     height="20"
      label="Leave Call"
-     width="125"
-     height="20" 
-     visible="false"/>
+     name="end_call_btn"
+     visible="false"
+     width="125"/>
+
     <button
      enabled="false"
-     name="voice_ctrls_btn"
-     label="Open Voice Controls"
-     width="125"
      height="20"
-     visible="false"/>
+     label="Open Voice Controls"
+     name="voice_ctrls_btn"
+     visible="false"
+     width="125"/>
+
 </panel>
diff --git a/indra/newview/skins/default/xui/en/panel_group_control_panel.xml b/indra/newview/skins/default/xui/en/panel_group_control_panel.xml
index 560d353d00..737bb5bcb6 100644
--- a/indra/newview/skins/default/xui/en/panel_group_control_panel.xml
+++ b/indra/newview/skins/default/xui/en/panel_group_control_panel.xml
@@ -1,9 +1,10 @@
 <?xml version="1.0" encoding="utf-8" standalone="yes" ?>
 <panel
- name="panel_im_control_panel"
- width="180"
+ border="false"
  height="238"
- border="false">
+ name="panel_im_control_panel"
+ width="180">
+
     <avatar_list
      color="DkGray2"
      follows="left|top|right|bottom"
@@ -16,29 +17,34 @@
      show_info_btn="false"
      show_profile_btn="false"
      top="10"
-     width="180" />
+     width="180"/>
+
     <button
-     name="group_info_btn"
+     height="20"
      label="Group Info"
      left_delta="27"
-     width="125"
-     height="20" />
+     name="group_info_btn"
+     width="125"/>
+
     <button
-     name="call_btn"
+     height="20"
      label="Call Group"
-     width="125"
-     height="20" />
+     name="call_btn"
+     width="125"/>
+
     <button
-     name="end_call_btn"
+     height="20"
      label="Leave Call"
-     width="125"
-     height="20" 
-     visible="false"/>
+     name="end_call_btn"
+     visible="false"
+     width="125"/>
+
     <button
-	 enabled="false"
-     name="voice_ctrls_btn"
-     label="Open Voice Controls"
-     width="125"
+     enabled="false"
      height="20"
-     visible="false"/>
+     label="Open Voice Controls"
+     name="voice_ctrls_btn"
+     visible="false"
+     width="125"/>
+
 </panel>
diff --git a/indra/newview/skins/default/xui/en/panel_im_control_panel.xml b/indra/newview/skins/default/xui/en/panel_im_control_panel.xml
index 7308ca3c29..35be31983c 100644
--- a/indra/newview/skins/default/xui/en/panel_im_control_panel.xml
+++ b/indra/newview/skins/default/xui/en/panel_im_control_panel.xml
@@ -1,32 +1,37 @@
 <?xml version="1.0" encoding="utf-8" standalone="yes" ?>
-<panel name="panel_im_control_panel"
-       width="128"
-       height="327"
-       border="false">
+<panel
+ border="false"
+ height="327"
+ name="panel_im_control_panel"
+ width="128">
 
-  <avatar_icon name="avatar_icon"
-               follows="left|top"
-               left_delta="3"
-               width="125"
-               height="125" />
+    <avatar_icon
+     follows="left|top"
+     height="125"
+     left_delta="3"
+     name="avatar_icon"
+     width="125"/>
 
-  <button name="view_profile_btn"
-          follows="left|bottom"
-          label="View Profile"
-          width="125"
-		  height="20" />
+    <button
+     follows="left|bottom"
+     height="20"
+     label="View Profile"
+     name="view_profile_btn"
+     width="125"/>
 
-  <button name="add_friend_btn"
-          follows="left|bottom"
-          label="Add Friend"
-          width="125"
-          height="20" />
+    <button
+     follows="left|bottom"
+     height="20"
+     label="Add Friend"
+     name="add_friend_btn"
+     width="125"/>
 
-  <button name="call_btn"
-          follows="left|bottom"
-          label="Call"
-          width="125"
-          height="20" />
+    <button
+     follows="left|bottom"
+     height="20"
+     label="Call"
+     name="call_btn"
+     width="125"/>
 
     <button
      follows="left|bottom"
@@ -34,31 +39,36 @@
      label="Leave Call"
      name="end_call_btn"
      visible="false"
-     width="125" />
+     width="125"/>
 
-  <button
-	 enabled="false"
+    <button
+     enabled="false"
      follows="left|bottom"
-     name="voice_ctrls_btn"
+     height="20"
      label="Open Voice Controls"
-     width="125"
+     name="voice_ctrls_btn"
+     visible="false"
+     width="125"/>
+
+    <button
+     follows="left|bottom"
+     height="20"
+     label="Teleport"
+     name="teleport_btn"
+     width="125"/>
+
+    <button
+     follows="left|bottom"
      height="20"
-     visible="false"/>
+     label="Share"
+     name="share_btn"
+     width="125"/>
 
-  <button name="teleport_btn"
-          follows="left|bottom"
-          label="Teleport"
-          width="125"
-          height="20" />
-  <button name="share_btn"
-          follows="left|bottom"
-          label="Share"
-          width="125"
-          height="20" />
-  <button name="pay_btn"
-          follows="left|bottom"
-          label="Pay"
-          width="125"
-          height="20" />
+    <button
+     follows="left|bottom"
+     height="20"
+     label="Pay"
+     name="pay_btn"
+     width="125"/>
 
 </panel>
-- 
cgit v1.2.3


From 0fd7ff59f58dc9c5d9b043830d513020ac7a6cdd Mon Sep 17 00:00:00 2001
From: Eugene Mutavchi <emutavchi@productengine.com>
Date: Wed, 4 Nov 2009 18:19:32 +0200
Subject: Implemented normal sub-task EXT-2142 (Call, End Call and Oen Voice
 Controls buttons should be located on their own panel at the bottom of the
 control panel (all types of IMs))

--HG--
branch : product-engine
---
 .../skins/default/xui/en/floater_im_session.xml    |  10 +-
 .../default/xui/en/panel_adhoc_control_panel.xml   |  51 +++++----
 .../default/xui/en/panel_group_control_panel.xml   |  60 ++++++-----
 .../default/xui/en/panel_im_control_panel.xml      | 117 ++++++++++++---------
 4 files changed, 139 insertions(+), 99 deletions(-)

(limited to 'indra')

diff --git a/indra/newview/skins/default/xui/en/floater_im_session.xml b/indra/newview/skins/default/xui/en/floater_im_session.xml
index 88aca005cf..8eeff0a9e4 100644
--- a/indra/newview/skins/default/xui/en/floater_im_session.xml
+++ b/indra/newview/skins/default/xui/en/floater_im_session.xml
@@ -12,13 +12,13 @@
  can_dock="true"
  can_minimize="true"
  visible="true" 
- width="400"
+ width="520"
  can_resize="true"
  min_width="200"
  min_height="150">
   <layout_stack follows="left|top|right|bottom"
                 height="344"
-                width="400"
+                width="520"
                 layout="topleft"
                 orientation="horizontal"
                 name="im_panels"
@@ -34,7 +34,7 @@
       auto_resize="false"
       user_resize="false" />
     <layout_panel height="344"
-                  width="235"
+                  width="355"
                   left_delta="146" 
                   top="0"
                   user_resize="false">
@@ -61,9 +61,9 @@
        name="chat_history"
        parse_highlights="true"
        allow_html="true" 
-       width="230">
+       width="350">
       </chat_history>
-      <line_editor follows="left|right" name="chat_editor" height="20" layout="topleft" width="225">
+      <line_editor follows="left|right" name="chat_editor" height="20" layout="topleft" width="345">
       </line_editor>
     </layout_panel>
   </layout_stack>
diff --git a/indra/newview/skins/default/xui/en/panel_adhoc_control_panel.xml b/indra/newview/skins/default/xui/en/panel_adhoc_control_panel.xml
index 8dbcfe6360..52017218d6 100644
--- a/indra/newview/skins/default/xui/en/panel_adhoc_control_panel.xml
+++ b/indra/newview/skins/default/xui/en/panel_adhoc_control_panel.xml
@@ -19,26 +19,39 @@
      top="10"
      width="180"/>
 
-    <button
-     height="20"
-     label="Call Group"
-     left_delta="27"
-     name="call_btn"
-     width="125"/>
+    <panel
+     background_visible="true"
+     bg_alpha_color="0.2 0.2 0.2 1"
+     border="false"
+     bottom="1"
+     follows="left|bottom"
+     height="78"
+     left="0"
+     name="panel_buttons"
+     width="180">
 
-    <button
-     height="20"
-     label="Leave Call"
-     name="end_call_btn"
-     visible="false"
-     width="125"/>
+        <button
+         height="20"
+         label="Call Group"
+         left_delta="27"
+         name="call_btn"
+         width="125"/>
 
-    <button
-     enabled="false"
-     height="20"
-     label="Open Voice Controls"
-     name="voice_ctrls_btn"
-     visible="false"
-     width="125"/>
+        <button
+         height="20"
+         label="Leave Call"
+         name="end_call_btn"
+         visible="false"
+         width="125"/>
+
+        <button
+         enabled="false"
+         height="20"
+         label="Open Voice Controls"
+         name="voice_ctrls_btn"
+         visible="false"
+         width="125"/>
+
+    </panel>
 
 </panel>
diff --git a/indra/newview/skins/default/xui/en/panel_group_control_panel.xml b/indra/newview/skins/default/xui/en/panel_group_control_panel.xml
index 737bb5bcb6..daa44ac75c 100644
--- a/indra/newview/skins/default/xui/en/panel_group_control_panel.xml
+++ b/indra/newview/skins/default/xui/en/panel_group_control_panel.xml
@@ -19,32 +19,44 @@
      top="10"
      width="180"/>
 
-    <button
-     height="20"
-     label="Group Info"
-     left_delta="27"
-     name="group_info_btn"
-     width="125"/>
+    <panel
+     background_visible="true"
+     bg_alpha_color="0.2 0.2 0.2 1"
+     border="false"
+     bottom="1"
+     follows="left|bottom"
+     height="98"
+     left="0"
+     name="panel_buttons"
+     width="180">
 
-    <button
-     height="20"
-     label="Call Group"
-     name="call_btn"
-     width="125"/>
+        <button
+         height="20"
+         label="Group Info"
+         left_delta="28"
+         name="group_info_btn"
+         width="125"/>
 
-    <button
-     height="20"
-     label="Leave Call"
-     name="end_call_btn"
-     visible="false"
-     width="125"/>
+        <button
+         height="20"
+         label="Call Group"
+         name="call_btn"
+         width="125"/>
 
-    <button
-     enabled="false"
-     height="20"
-     label="Open Voice Controls"
-     name="voice_ctrls_btn"
-     visible="false"
-     width="125"/>
+        <button
+         height="20"
+         label="Leave Call"
+         name="end_call_btn"
+         visible="false"
+         width="125"/>
 
+        <button
+         enabled="false"
+         height="20"
+         label="Open Voice Controls"
+         name="voice_ctrls_btn"
+         visible="false"
+         width="125"/>
+
+    </panel>
 </panel>
diff --git a/indra/newview/skins/default/xui/en/panel_im_control_panel.xml b/indra/newview/skins/default/xui/en/panel_im_control_panel.xml
index 35be31983c..d144d71dce 100644
--- a/indra/newview/skins/default/xui/en/panel_im_control_panel.xml
+++ b/indra/newview/skins/default/xui/en/panel_im_control_panel.xml
@@ -2,73 +2,88 @@
 <panel
  border="false"
  height="327"
+ layout="topleft"
  name="panel_im_control_panel"
- width="128">
+ width="131">
 
     <avatar_icon
      follows="left|top"
      height="125"
      left_delta="3"
      name="avatar_icon"
+     top="-10"
      width="125"/>
 
-    <button
+    <panel
+     background_visible="true"
+     bg_alpha_color="0.2 0.2 0.2 1"
+     border="false"
+     bottom="1"
      follows="left|bottom"
-     height="20"
-     label="View Profile"
-     name="view_profile_btn"
-     width="125"/>
+     height="195"
+     left="0"
+     name="panel_buttons"
+     width="131">
 
-    <button
-     follows="left|bottom"
-     height="20"
-     label="Add Friend"
-     name="add_friend_btn"
-     width="125"/>
+        <button
+         follows="left|bottom"
+         height="20"
+         label="View Profile"
+         left_delta="3"
+         name="view_profile_btn"
+         width="125"/>
 
-    <button
-     follows="left|bottom"
-     height="20"
-     label="Call"
-     name="call_btn"
-     width="125"/>
+        <button
+         follows="left|bottom"
+         height="20"
+         label="Add Friend"
+         name="add_friend_btn"
+         width="125"/>
 
-    <button
-     follows="left|bottom"
-     height="20"
-     label="Leave Call"
-     name="end_call_btn"
-     visible="false"
-     width="125"/>
+        <button
+         follows="left|bottom"
+         height="20"
+         label="Call"
+         name="call_btn"
+         width="125"/>
 
-    <button
-     enabled="false"
-     follows="left|bottom"
-     height="20"
-     label="Open Voice Controls"
-     name="voice_ctrls_btn"
-     visible="false"
-     width="125"/>
+        <button
+         follows="left|bottom"
+         height="20"
+         label="Leave Call"
+         name="end_call_btn"
+         visible="false"
+         width="125"/>
 
-    <button
-     follows="left|bottom"
-     height="20"
-     label="Teleport"
-     name="teleport_btn"
-     width="125"/>
+        <button
+         enabled="false"
+         follows="left|bottom"
+         height="20"
+         label="Open Voice Controls"
+         name="voice_ctrls_btn"
+         visible="false"
+         width="125"/>
 
-    <button
-     follows="left|bottom"
-     height="20"
-     label="Share"
-     name="share_btn"
-     width="125"/>
+        <button
+         follows="left|bottom"
+         height="20"
+         label="Teleport"
+         name="teleport_btn"
+         width="125"/>
 
-    <button
-     follows="left|bottom"
-     height="20"
-     label="Pay"
-     name="pay_btn"
-     width="125"/>
+        <button
+         follows="left|bottom"
+         height="20"
+         label="Share"
+         name="share_btn"
+         width="125"/>
+
+        <button
+         follows="left|bottom"
+         height="20"
+         label="Pay"
+         name="pay_btn"
+         width="125"/>
 
+    </panel>
 </panel>
-- 
cgit v1.2.3


From 8346cd6806f479053a5b81b496dbb9b88ed26bb5 Mon Sep 17 00:00:00 2001
From: Sergei Litovchuk <slitovchuk@productengine.com>
Date: Wed, 4 Nov 2009 19:53:17 +0200
Subject: Fixed normal bug EXT-2192 "Remove "Share" button from all Places Tabs
 (including Place/Landmark info)". - Removed "Share" button and resized other
 buttons to take its place.

--HG--
branch : product-engine
---
 indra/newview/llpanelplaces.cpp                     | 11 -----------
 indra/newview/llpanelplaces.h                       |  2 --
 indra/newview/llpanelplacestab.cpp                  |  1 -
 indra/newview/llpanelplacestab.h                    |  3 ---
 indra/newview/skins/default/xui/en/panel_places.xml | 17 +++--------------
 5 files changed, 3 insertions(+), 31 deletions(-)

(limited to 'indra')

diff --git a/indra/newview/llpanelplaces.cpp b/indra/newview/llpanelplaces.cpp
index 6f15e53299..0784e4555f 100644
--- a/indra/newview/llpanelplaces.cpp
+++ b/indra/newview/llpanelplaces.cpp
@@ -160,9 +160,6 @@ BOOL LLPanelPlaces::postBuild()
 	
 	mShowOnMapBtn = getChild<LLButton>("map_btn");
 	mShowOnMapBtn->setClickedCallback(boost::bind(&LLPanelPlaces::onShowOnMapButtonClicked, this));
-	
-	mShareBtn = getChild<LLButton>("share_btn");
-	//mShareBtn->setClickedCallback(boost::bind(&LLPanelPlaces::onShareButtonClicked, this));
 
 	mEditBtn = getChild<LLButton>("edit_btn");
 	mEditBtn->setClickedCallback(boost::bind(&LLPanelPlaces::onEditButtonClicked, this));
@@ -413,13 +410,6 @@ void LLPanelPlaces::onTabSelected()
 	mActivePanel->updateVerbs();
 }
 
-/*
-void LLPanelPlaces::onShareButtonClicked()
-{
-	// TODO: Launch the "Things" Share wizard
-}
-*/
-
 void LLPanelPlaces::onTeleportButtonClicked()
 {
 	LLPanelPlaceInfo* panel = getCurrentInfoPanel();
@@ -852,7 +842,6 @@ void LLPanelPlaces::updateVerbs()
 
 	mTeleportBtn->setVisible(!is_create_landmark_visible && !isLandmarkEditModeOn);
 	mShowOnMapBtn->setVisible(!is_create_landmark_visible && !isLandmarkEditModeOn);
-	mShareBtn->setVisible(!is_create_landmark_visible && !isLandmarkEditModeOn);
 	mOverflowBtn->setVisible(!is_create_landmark_visible && !isLandmarkEditModeOn);
 	mEditBtn->setVisible(mPlaceInfoType == LANDMARK_INFO_TYPE && !isLandmarkEditModeOn);
 	mSaveBtn->setVisible(isLandmarkEditModeOn);
diff --git a/indra/newview/llpanelplaces.h b/indra/newview/llpanelplaces.h
index 8faed613f4..0d97353b66 100644
--- a/indra/newview/llpanelplaces.h
+++ b/indra/newview/llpanelplaces.h
@@ -73,7 +73,6 @@ private:
 	void onFilterEdit(const std::string& search_string, bool force_filter);
 	void onTabSelected();
 
-	//void onShareButtonClicked();
 	void onTeleportButtonClicked();
 	void onShowOnMapButtonClicked();
 	void onEditButtonClicked();
@@ -105,7 +104,6 @@ private:
 
 	LLButton*					mTeleportBtn;
 	LLButton*					mShowOnMapBtn;
-	LLButton*					mShareBtn;
 	LLButton*					mEditBtn;
 	LLButton*					mSaveBtn;
 	LLButton*					mCancelBtn;
diff --git a/indra/newview/llpanelplacestab.cpp b/indra/newview/llpanelplacestab.cpp
index f5e7ff3c40..42c871a41a 100644
--- a/indra/newview/llpanelplacestab.cpp
+++ b/indra/newview/llpanelplacestab.cpp
@@ -51,7 +51,6 @@ bool LLPanelPlacesTab::isTabVisible()
 
 void LLPanelPlacesTab::setPanelPlacesButtons(LLPanelPlaces* panel)
 {
-	//mShareBtn = panel->getChild<LLButton>("share_btn");
 	mTeleportBtn = panel->getChild<LLButton>("teleport_btn");
 	mShowOnMapBtn = panel->getChild<LLButton>("map_btn");
 }
diff --git a/indra/newview/llpanelplacestab.h b/indra/newview/llpanelplacestab.h
index 3f56dcb283..458694d766 100644
--- a/indra/newview/llpanelplacestab.h
+++ b/indra/newview/llpanelplacestab.h
@@ -44,10 +44,8 @@ public:
 
 	virtual void onSearchEdit(const std::string& string) = 0;
 	virtual void updateVerbs() = 0;		// Updates buttons at the bottom of Places panel
-	//virtual void onShare() = 0;
 	virtual void onShowOnMap() = 0;
 	virtual void onTeleport() = 0;
-	//virtual void onCopySLURL() = 0;
 
 	bool isTabVisible(); // Check if parent TabContainer is visible.
 
@@ -58,7 +56,6 @@ public:
 										const LLUUID& snapshot_id,
 										bool teleport);
 protected:
-	//LLButton*				mShareBtn;
 	LLButton*				mTeleportBtn;
 	LLButton*				mShowOnMapBtn;
 };
diff --git a/indra/newview/skins/default/xui/en/panel_places.xml b/indra/newview/skins/default/xui/en/panel_places.xml
index 87ac5be74a..488b9582d5 100644
--- a/indra/newview/skins/default/xui/en/panel_places.xml
+++ b/indra/newview/skins/default/xui/en/panel_places.xml
@@ -79,7 +79,7 @@ background_visible="true"
          left="5"
          name="teleport_btn"
          top="0"
-         width="77" />
+         width="100" />
         <button
          follows="bottom|left"
          font="SansSerifSmall"
@@ -89,18 +89,7 @@ background_visible="true"
          left_pad="5"
          name="map_btn"
          top="0"
-         width="50" />
-        <button
-         enabled="false"
-         follows="bottom|left"
-         font="SansSerifSmall"
-         height="19"
-         label="Share"
-         layout="topleft"
-         left_pad="5"
-         name="share_btn"
-         top="0"
-         width="60" />
+         width="70" />
         <button
          follows="bottom|left"
          font="SansSerifSmall"
@@ -110,7 +99,7 @@ background_visible="true"
          left_pad="5"
          name="edit_btn"
          top="0"
-         width="50" />
+         width="70" />
         <button
          follows="bottom|right"
          font="SansSerifSmall"
-- 
cgit v1.2.3


From 8f58f4e681a19a66c9c2bc83a11d5d2a6367661c Mon Sep 17 00:00:00 2001
From: "Eric M. Tulla (BigPapi)" <tulla@lindenlab.com>
Date: Wed, 4 Nov 2009 13:04:55 -0500
Subject: Fix for EXT-2086 & EXT-2087 - No Make Outfit button & Save As
 behaving as make outfit. Created a dedicated make outfit button, and made
 save as go back to saving a copy of the current wearable. -Reviewed by nyx

---
 indra/newview/skins/default/xui/en/floater_customize.xml | 10 ++++++++++
 1 file changed, 10 insertions(+)

(limited to 'indra')

diff --git a/indra/newview/skins/default/xui/en/floater_customize.xml b/indra/newview/skins/default/xui/en/floater_customize.xml
index 07d76f4810..c021dd79de 100644
--- a/indra/newview/skins/default/xui/en/floater_customize.xml
+++ b/indra/newview/skins/default/xui/en/floater_customize.xml
@@ -3378,6 +3378,16 @@ scratch and wear it.
          layout="topleft"
          name="panel_list" />
     </scroll_container>
+	<button
+     bottom="536"
+     follows="right|bottom"
+     height="20"
+     label="Make Outfit"
+     label_selected="Make Outfit"
+     layout="topleft"
+     name="make_outfit_btn"
+     right="-216"
+     width="100" />
     <button
      bottom="536"
      follows="right|bottom"
-- 
cgit v1.2.3


From f59c8b5e4e2625930e24ea28cd8e3a713cffed43 Mon Sep 17 00:00:00 2001
From: Sergey Borushevsky <sborushevsky@productengine.com>
Date: Wed, 4 Nov 2009 20:09:06 +0200
Subject: Implemented normal task EXT-2149 (IM Text Editors should display
 grayed text "TO [avatar_name/group_name/ad-hoc conference]")

--HG--
branch : product-engine
---
 indra/llui/lllineeditor.h                                 |  2 ++
 indra/newview/llimfloater.cpp                             | 12 ++++++++----
 indra/newview/skins/default/xui/en/floater_im_session.xml |  8 +++++++-
 3 files changed, 17 insertions(+), 5 deletions(-)

(limited to 'indra')

diff --git a/indra/llui/lllineeditor.h b/indra/llui/lllineeditor.h
index 3d7bbdff89..d3daa941cf 100644
--- a/indra/llui/lllineeditor.h
+++ b/indra/llui/lllineeditor.h
@@ -172,6 +172,8 @@ public:
 	virtual BOOL	setLabelArg( const std::string& key, const LLStringExplicit& text );
 
 	void			setLabel(const LLStringExplicit &new_label) { mLabel = new_label; }
+	const std::string& 	getLabel()	{ return mLabel.getString(); }
+
 	void			setText(const LLStringExplicit &new_text);
 
 	const std::string& getText() const		{ return mText.getString(); }
diff --git a/indra/newview/llimfloater.cpp b/indra/newview/llimfloater.cpp
index 19fa66fd0e..85863ed85b 100644
--- a/indra/newview/llimfloater.cpp
+++ b/indra/newview/llimfloater.cpp
@@ -225,6 +225,7 @@ BOOL LLIMFloater::postBuild()
 	// enable line history support for instant message bar
 	mInputEditor->setEnableLineHistory(TRUE);
 	
+	
 	mInputEditor->setFocusReceivedCallback( boost::bind(onInputEditorFocusReceived, _1, this) );
 	mInputEditor->setFocusLostCallback( boost::bind(onInputEditorFocusLost, _1, this) );
 	mInputEditor->setKeystrokeCallback( onInputEditorKeystroke, this );
@@ -232,14 +233,17 @@ BOOL LLIMFloater::postBuild()
 	mInputEditor->setRevertOnEsc( FALSE );
 	mInputEditor->setReplaceNewlinesWithSpaces( FALSE );
 
-	childSetCommitCallback("chat_editor", onSendMsg, this);
-	
-	mChatHistory = getChild<LLChatHistory>("chat_history");
-		
 	std::string session_name(LLIMModel::instance().getName(mSessionID));
+
+	mInputEditor->setLabel(mInputEditor->getLabel() + " " + session_name);
+
 	LLStringUtil::toUpper(session_name);
 	setTitle(session_name);
 
+	childSetCommitCallback("chat_editor", onSendMsg, this);
+	
+	mChatHistory = getChild<LLChatHistory>("chat_history");
+
 	setDocked(true);
 
 	mTypingStart = LLTrans::getString("IM_typing_start_string");
diff --git a/indra/newview/skins/default/xui/en/floater_im_session.xml b/indra/newview/skins/default/xui/en/floater_im_session.xml
index 8eeff0a9e4..1585d976b3 100644
--- a/indra/newview/skins/default/xui/en/floater_im_session.xml
+++ b/indra/newview/skins/default/xui/en/floater_im_session.xml
@@ -63,7 +63,13 @@
        allow_html="true" 
        width="350">
       </chat_history>
-      <line_editor follows="left|right" name="chat_editor" height="20" layout="topleft" width="345">
+      <line_editor
+       follows="left|right"
+       height="20"
+       label="To"
+       layout="topleft"
+       name="chat_editor"
+       width="345">
       </line_editor>
     </layout_panel>
   </layout_stack>
-- 
cgit v1.2.3


From ec8e27b8bf3cdc5056ecd1492b515e4ca79ad4f6 Mon Sep 17 00:00:00 2001
From: "Brad Payne (Vir Linden)" <vir@lindenlab.com>
Date: Wed, 4 Nov 2009 13:14:57 -0500
Subject: Remove existing wearables of a type when putting on new ones.  This
 will need to be revisited when we go to multi-wearables.

---
 indra/newview/llappearancemgr.cpp | 40 ++++++++++++++++++++++++++++++++++-----
 1 file changed, 35 insertions(+), 5 deletions(-)

(limited to 'indra')

diff --git a/indra/newview/llappearancemgr.cpp b/indra/newview/llappearancemgr.cpp
index 8d0f11e021..382947e464 100644
--- a/indra/newview/llappearancemgr.cpp
+++ b/indra/newview/llappearancemgr.cpp
@@ -300,14 +300,25 @@ struct LLWearableHoldingPattern
 {
 	LLInventoryModel::item_array_t new_items;
 	std::set<LLUUID> items_seen;
-	for (S32 i=0; i<items.count(); i++)
+	std::deque<LLViewerInventoryItem*> tmp_list;
+	// Traverse from the front and keep the first of each item
+	// encountered, so we actually keep the *last* of each duplicate
+	// item.  This is needed to give the right priority when adding
+	// duplicate items to an existing outfit.
+	for (S32 i=items.count()-1; i>=0; i--)
 	{
 		LLViewerInventoryItem *item = items.get(i);
 		LLUUID item_id = item->getLinkedUUID();
 		if (items_seen.find(item_id)!=items_seen.end())
 			continue;
 		items_seen.insert(item_id);
-		new_items.push_back(item);
+		tmp_list.push_front(item);
+	}
+	for (std::deque<LLViewerInventoryItem*>::iterator it = tmp_list.begin();
+		 it != tmp_list.end();
+		 ++it)
+	{
+		new_items.put(*it);
 	}
 	items = new_items;
 }
@@ -1068,9 +1079,21 @@ void LLAppearanceManager::wearOutfitByName(const std::string& name)
 	//dec_busy_count();
 }
 
+bool areMatchingWearables(const LLViewerInventoryItem *a, const LLViewerInventoryItem *b)
+{
+	return (a->isWearableType() && b->isWearableType() &&
+			(a->getWearableType() == b->getWearableType()));
+}
 /* static */
 void LLAppearanceManager::wearItem( LLInventoryItem* item, bool do_update )
 {
+	LLViewerInventoryItem *vitem = dynamic_cast<LLViewerInventoryItem*>(item);
+	if (!vitem)
+	{
+		llwarns << "not an llviewerinventoryitem, failed" << llendl;
+		return;
+	}
+		
 	LLInventoryModel::cat_array_t cat_array;
 	LLInventoryModel::item_array_t item_array;
 	gInventory.collectDescendents(LLAppearanceManager::getCOF(),
@@ -1080,12 +1103,19 @@ void LLAppearanceManager::wearItem( LLInventoryItem* item, bool do_update )
 	bool linked_already = false;
 	for (S32 i=0; i<item_array.count(); i++)
 	{
-		const LLInventoryItem* inv_item = item_array.get(i).get();
+		const LLViewerInventoryItem* inv_item = item_array.get(i).get();
 		if (inv_item->getLinkedUUID() == item->getLinkedUUID())
 		{
 			linked_already = true;
 			break;
 		}
+		// Are of same type but are not the same - new item will replace old.
+		if (areMatchingWearables(vitem,inv_item))
+		{
+			gAgentWearables.removeWearable(inv_item->getWearableType(),true,0);
+			gInventory.purgeObject(inv_item->getUUID());
+			gInventory.notifyObservers();
+		}
 	}
 	if (linked_already)
 	{
@@ -1096,9 +1126,9 @@ void LLAppearanceManager::wearItem( LLInventoryItem* item, bool do_update )
 	{
 		LLPointer<LLInventoryCallback> cb = do_update ? new ModifiedCOFCallback : 0;
 		link_inventory_item( gAgent.getID(),
-							 item->getLinkedUUID(),
+							 vitem->getLinkedUUID(),
 							 getCOF(),
-							 item->getName(),
+							 vitem->getName(),
 							 LLAssetType::AT_LINK,
 							 cb);
 	}
-- 
cgit v1.2.3


From e8ee119da107c0c473c836f1f0233621f14e2a15 Mon Sep 17 00:00:00 2001
From: Eugene Mutavchi <emutavchi@productengine.com>
Date: Wed, 4 Nov 2009 20:23:41 +0200
Subject: Major sub-task EXT-2142, additional commit: moved call buttons panel
 to control panel bottom, removed other buttons from panel_call_button

--HG--
branch : product-engine
---
 .../default/xui/en/panel_adhoc_control_panel.xml   | 13 +++-
 .../default/xui/en/panel_group_control_panel.xml   | 26 ++++---
 .../default/xui/en/panel_im_control_panel.xml      | 86 +++++++++++-----------
 3 files changed, 70 insertions(+), 55 deletions(-)

(limited to 'indra')

diff --git a/indra/newview/skins/default/xui/en/panel_adhoc_control_panel.xml b/indra/newview/skins/default/xui/en/panel_adhoc_control_panel.xml
index 52017218d6..24c46b314f 100644
--- a/indra/newview/skins/default/xui/en/panel_adhoc_control_panel.xml
+++ b/indra/newview/skins/default/xui/en/panel_adhoc_control_panel.xml
@@ -25,19 +25,23 @@
      border="false"
      bottom="1"
      follows="left|bottom"
-     height="78"
+     height="70"
      left="0"
-     name="panel_buttons"
+     left_pad="0"
+     name="panel_call_buttons"
+     top_pad="0"
      width="180">
 
         <button
+         bottom="10"
          height="20"
-         label="Call Group"
-         left_delta="27"
+         label="Call"
+         left_delta="28"
          name="call_btn"
          width="125"/>
 
         <button
+         bottom="40"
          height="20"
          label="Leave Call"
          name="end_call_btn"
@@ -46,6 +50,7 @@
 
         <button
          enabled="false"
+         bottom="10"
          height="20"
          label="Open Voice Controls"
          name="voice_ctrls_btn"
diff --git a/indra/newview/skins/default/xui/en/panel_group_control_panel.xml b/indra/newview/skins/default/xui/en/panel_group_control_panel.xml
index daa44ac75c..46f34949a8 100644
--- a/indra/newview/skins/default/xui/en/panel_group_control_panel.xml
+++ b/indra/newview/skins/default/xui/en/panel_group_control_panel.xml
@@ -19,31 +19,37 @@
      top="10"
      width="180"/>
 
+    <button
+     bottom_pad="0"
+     height="20"
+     label="Group Info"
+     left_delta="28"
+     name="group_info_btn"
+     width="125"/>
+
     <panel
      background_visible="true"
      bg_alpha_color="0.2 0.2 0.2 1"
      border="false"
      bottom="1"
      follows="left|bottom"
-     height="98"
+     height="70"
      left="0"
-     name="panel_buttons"
+     left_pad="0"
+     name="panel_call_buttons"
+     top_pad="0"
      width="180">
 
         <button
-         height="20"
-         label="Group Info"
-         left_delta="28"
-         name="group_info_btn"
-         width="125"/>
-
-        <button
+         bottom="10"
          height="20"
          label="Call Group"
+         left_delta="28"
          name="call_btn"
          width="125"/>
 
         <button
+         bottom="40"
          height="20"
          label="Leave Call"
          name="end_call_btn"
@@ -52,6 +58,7 @@
 
         <button
          enabled="false"
+         bottom="10"
          height="20"
          label="Open Voice Controls"
          name="voice_ctrls_btn"
@@ -59,4 +66,5 @@
          width="125"/>
 
     </panel>
+
 </panel>
diff --git a/indra/newview/skins/default/xui/en/panel_im_control_panel.xml b/indra/newview/skins/default/xui/en/panel_im_control_panel.xml
index d144d71dce..f77a2ec730 100644
--- a/indra/newview/skins/default/xui/en/panel_im_control_panel.xml
+++ b/indra/newview/skins/default/xui/en/panel_im_control_panel.xml
@@ -2,7 +2,6 @@
 <panel
  border="false"
  height="327"
- layout="topleft"
  name="panel_im_control_panel"
  width="131">
 
@@ -14,41 +13,64 @@
      top="-10"
      width="125"/>
 
+    <button
+     follows="left|bottom"
+     height="20"
+     label="View Profile"
+     name="view_profile_btn"
+     width="125"/>
+
+    <button
+     follows="left|bottom"
+     height="20"
+     label="Add Friend"
+     name="add_friend_btn"
+     width="125"/>
+
+    <button
+     follows="left|bottom"
+     height="20"
+     label="Teleport"
+     name="teleport_btn"
+     width="125"/>
+
+    <button
+     follows="left|bottom"
+     height="20"
+     label="Share"
+     name="share_btn"
+     width="125"/>
+
+    <button
+     follows="left|bottom"
+     height="20"
+     label="Pay"
+     name="pay_btn"
+     width="125"/>
+
     <panel
      background_visible="true"
      bg_alpha_color="0.2 0.2 0.2 1"
      border="false"
      bottom="1"
      follows="left|bottom"
-     height="195"
+     height="70"
      left="0"
-     name="panel_buttons"
+     left_pad="0"
+     name="panel_call_buttons"
+     top_pad="0"
      width="131">
 
         <button
-         follows="left|bottom"
-         height="20"
-         label="View Profile"
-         left_delta="3"
-         name="view_profile_btn"
-         width="125"/>
-
-        <button
-         follows="left|bottom"
-         height="20"
-         label="Add Friend"
-         name="add_friend_btn"
-         width="125"/>
-
-        <button
-         follows="left|bottom"
+         bottom="10"
          height="20"
          label="Call"
+         left_delta="3"
          name="call_btn"
          width="125"/>
 
         <button
-         follows="left|bottom"
+         bottom="40"
          height="20"
          label="Leave Call"
          name="end_call_btn"
@@ -57,33 +79,13 @@
 
         <button
          enabled="false"
-         follows="left|bottom"
+         bottom="10"
          height="20"
          label="Open Voice Controls"
          name="voice_ctrls_btn"
          visible="false"
          width="125"/>
 
-        <button
-         follows="left|bottom"
-         height="20"
-         label="Teleport"
-         name="teleport_btn"
-         width="125"/>
-
-        <button
-         follows="left|bottom"
-         height="20"
-         label="Share"
-         name="share_btn"
-         width="125"/>
-
-        <button
-         follows="left|bottom"
-         height="20"
-         label="Pay"
-         name="pay_btn"
-         width="125"/>
-
     </panel>
+
 </panel>
-- 
cgit v1.2.3


From 77f58385d8ec0440da8c943a8b814a73369ef0d3 Mon Sep 17 00:00:00 2001
From: Sergei Litovchuk <slitovchuk@productengine.com>
Date: Wed, 4 Nov 2009 20:24:34 +0200
Subject: Implemented normal task EXT-704 "Remove Place Media panel". - Removed
 Place Media panel. This also fixes bug EXT-454 "Place - Media: Gear near 'All
 nearby media' shoudl be removed according to the latest changes in the spec".

--HG--
branch : product-engine
---
 indra/newview/CMakeLists.txt | 2 --
 1 file changed, 2 deletions(-)

(limited to 'indra')

diff --git a/indra/newview/CMakeLists.txt b/indra/newview/CMakeLists.txt
index be736c57c8..fde942ad11 100644
--- a/indra/newview/CMakeLists.txt
+++ b/indra/newview/CMakeLists.txt
@@ -322,7 +322,6 @@ set(viewer_SOURCE_FILES
     llpanellogin.cpp
     llpanellookinfo.cpp
     llpanellooks.cpp
-    llpanelmedia.cpp
     llpanelmediasettingsgeneral.cpp
     llpanelmediasettingspermissions.cpp
     llpanelmediasettingssecurity.cpp
@@ -802,7 +801,6 @@ set(viewer_HEADER_FILES
     llpanellogin.h
     llpanellookinfo.h
     llpanellooks.h
-    llpanelmedia.h
     llpanelmediasettingsgeneral.h
     llpanelmediasettingspermissions.h
     llpanelmediasettingssecurity.h
-- 
cgit v1.2.3


From 0ee426016aeae605eeb8ab3aa535b2b52462a3d9 Mon Sep 17 00:00:00 2001
From: richard <none@none>
Date: Wed, 4 Nov 2009 10:37:13 -0800
Subject: added newline at end of llbutton.cpp removed non-localized, invisible
 labels from scrollbar and tab container arrows EXT-1626 - there is text
 overlaping in group info mini inspector

reviewed by James
---
 indra/llui/llbutton.cpp       | 2 +-
 indra/llui/llscrollbar.cpp    | 2 --
 indra/llui/lltabcontainer.cpp | 4 +---
 indra/llui/lltextbase.cpp     | 6 +-----
 4 files changed, 3 insertions(+), 11 deletions(-)

(limited to 'indra')

diff --git a/indra/llui/llbutton.cpp b/indra/llui/llbutton.cpp
index 8daceb9485..bbaf908d2e 100644
--- a/indra/llui/llbutton.cpp
+++ b/indra/llui/llbutton.cpp
@@ -1090,4 +1090,4 @@ void LLButton::resetMouseDownTimer()
 {
 	mMouseDownTimer.stop();
 	mMouseDownTimer.reset();
-}
\ No newline at end of file
+}
diff --git a/indra/llui/llscrollbar.cpp b/indra/llui/llscrollbar.cpp
index b450ecbbf9..dfd315d451 100644
--- a/indra/llui/llscrollbar.cpp
+++ b/indra/llui/llscrollbar.cpp
@@ -115,7 +115,6 @@ LLScrollbar::LLScrollbar(const Params & p)
 
 	LLButton::Params up_btn(mOrientation == VERTICAL ? p.up_button : p.left_button);
 	up_btn.name(std::string("Line Up"));
-	up_btn.label(std::string("Line Up"));
 	up_btn.rect(line_up_rect);
 	up_btn.click_callback.function(boost::bind(&LLScrollbar::onLineUpBtnPressed, this, _2));
 	up_btn.mouse_held_callback.function(boost::bind(&LLScrollbar::onLineUpBtnPressed, this, _2));
@@ -126,7 +125,6 @@ LLScrollbar::LLScrollbar(const Params & p)
 
 	LLButton::Params down_btn(mOrientation == VERTICAL ? p.down_button : p.right_button);
 	down_btn.name(std::string("Line Down"));
-	down_btn.label(std::string("Line Down"));
 	down_btn.rect(line_down_rect);
 	down_btn.follows.flags(FOLLOWS_RIGHT|FOLLOWS_BOTTOM);
 	down_btn.click_callback.function(boost::bind(&LLScrollbar::onLineDownBtnPressed, this, _2));
diff --git a/indra/llui/lltabcontainer.cpp b/indra/llui/lltabcontainer.cpp
index 6ca9c4ceda..6073b54371 100644
--- a/indra/llui/lltabcontainer.cpp
+++ b/indra/llui/lltabcontainer.cpp
@@ -986,7 +986,7 @@ void LLTabContainer::addTabPanel(const TabPanelParams& panel)
 				p.follows.flags = p.follows.flags() | FOLLOWS_BOTTOM;
 			}
 
-			btn = LLUICtrlFactory::create<LLButton>(p);
+++			btn = LLUICtrlFactory::create<LLButton>(p);
 		}
 	}
 	
@@ -1645,7 +1645,6 @@ void LLTabContainer::initButtons()
 
 		LLButton::Params prev_btn_params;
 		prev_btn_params.name(std::string("Up Arrow"));
-		prev_btn_params.label(std::string("Up Arrow"));
 		prev_btn_params.rect(up_arrow_btn_rect);
 		prev_btn_params.follows.flags(FOLLOWS_TOP | FOLLOWS_LEFT);
 		prev_btn_params.image_unselected.name("scrollbutton_up_out_blue.tga");
@@ -1655,7 +1654,6 @@ void LLTabContainer::initButtons()
 
 		LLButton::Params next_btn_params;
 		next_btn_params.name(std::string("Down Arrow"));
-		next_btn_params.label(std::string("Down Arrow"));
 		next_btn_params.rect(down_arrow_btn_rect);
 		next_btn_params.follows.flags(FOLLOWS_BOTTOM | FOLLOWS_LEFT);
 		next_btn_params.image_unselected.name("scrollbutton_down_out_blue.tga");
diff --git a/indra/llui/lltextbase.cpp b/indra/llui/lltextbase.cpp
index 9a26f0b472..8cbb53dda2 100644
--- a/indra/llui/lltextbase.cpp
+++ b/indra/llui/lltextbase.cpp
@@ -1450,9 +1450,7 @@ void LLTextBase::setText(const LLStringExplicit &utf8str)
 
 	appendText(text, false);
 
-	//resetDirty();
 	onValueChange(0, getLength());
-	needsReflow();
 }
 
 //virtual
@@ -1630,8 +1628,6 @@ void LLTextBase::appendAndHighlightText(const std::string &new_text, bool prepen
 		insertStringNoUndo(getLength(), wide_text, &segments);
 	}
 
-	needsReflow();
-	
 	// Set the cursor and scroll position
 	if( selection_start != selection_end )
 	{
@@ -2115,7 +2111,7 @@ LLRect LLTextBase::getVisibleDocumentRect() const
 		LLRect doc_rect = mDocumentView->getLocalRect();
 		doc_rect.mLeft -= mDocumentView->getRect().mLeft;
 		// adjust for height of text above widget baseline
-		doc_rect.mBottom = llmin(0, doc_rect.getHeight() - mTextRect.getHeight());
+		doc_rect.mBottom = doc_rect.getHeight() - mTextRect.getHeight();
 		return doc_rect;
 	}
 }
-- 
cgit v1.2.3


From ad25be8af388ee38c2f0af731d30a6336caf3ad5 Mon Sep 17 00:00:00 2001
From: richard <none@none>
Date: Wed, 4 Nov 2009 10:50:14 -0800
Subject: fixed up bad merge

---
 indra/newview/skins/default/xui/en/floater_tools.xml | 19 +++++++------------
 1 file changed, 7 insertions(+), 12 deletions(-)

(limited to 'indra')

diff --git a/indra/newview/skins/default/xui/en/floater_tools.xml b/indra/newview/skins/default/xui/en/floater_tools.xml
index 0202e8b582..0614653d76 100644
--- a/indra/newview/skins/default/xui/en/floater_tools.xml
+++ b/indra/newview/skins/default/xui/en/floater_tools.xml
@@ -1011,8 +1011,11 @@
            label="Original"
            value="1" />
       </combo_box>
-<!-- NEW PRICE SPINNER -->
-      <spinner
+<!-- NEW PRICE SPINNER
+Objects are allowed to be for sale for L$0 to invoke buy UI behavior
+even though the user gets a free copy.
+-->
+    <spinner
         follows="left|top"
         decimal_digits="0"
         increment="1"
@@ -1023,7 +1026,7 @@
         label="Price: L$"
         label_width="65"
         width="150"
-        min_val="1"
+        min_val="0"
         height="20"
         max_val="999999999" />
       <check_box
@@ -2767,7 +2770,7 @@
              left_pad="8"
              name="button permissions"
              width="130" />
-            <panel_inventory
+            <panel_inventory_object
              follows="left|top"
              height="210"
              layout="topleft"
@@ -2842,14 +2845,6 @@
          tool_tip="Colorize the parcels according to the type of owner: &#10;&#10;Green = Your land &#10;Aqua = Your group&apos;s land &#10;Red = Owned by others &#10;Yellow = For sale &#10;Purple = For auction &#10;Grey = Public"
          top_pad="8"
          width="205" />
-        <!--TODO: HOOK UP TO HELP VIEWER-->
-       <!-- <button
-         image_overlay="Arrow_Right_Off"
-         left_pad="5"
-         name="button show owners help"
-         tool_tip="See an explanation of colors"
-         width="26"
-         height="22" />-->
         <text
          type="string"
          length="1"
-- 
cgit v1.2.3


From eb02d77ff5d20b99cc35fe9082cf5a22f634a7e1 Mon Sep 17 00:00:00 2001
From: Eugene Kondrashev <ekondrashev@productengine.com>
Date: Wed, 4 Nov 2009 21:33:14 +0200
Subject: Implemented major sub-task EXT-2131 - Output monitor contols should
 only be shown for Group Chat and Adhoc Chat when in a Voice Call. Added
 onStateChange callback support for voice channel. Added showing/hiding logic
 of speaking indicator.

--HG--
branch : product-engine
---
 indra/newview/llavatarlist.cpp                     | 17 ++++++++++++
 indra/newview/llavatarlist.h                       |  3 ++
 indra/newview/llavatarlistitem.cpp                 | 13 +++++++++
 indra/newview/llavatarlistitem.h                   |  6 ++--
 indra/newview/llpanelimcontrolpanel.cpp            | 32 ++++++++++++++++------
 indra/newview/llpanelimcontrolpanel.h              |  6 +++-
 indra/newview/llvoicechannel.cpp                   | 14 ++++++++--
 indra/newview/llvoicechannel.h                     | 11 ++++++++
 .../default/xui/en/panel_adhoc_control_panel.xml   |  1 +
 .../default/xui/en/panel_group_control_panel.xml   |  1 +
 10 files changed, 89 insertions(+), 15 deletions(-)

(limited to 'indra')

diff --git a/indra/newview/llavatarlist.cpp b/indra/newview/llavatarlist.cpp
index 8609ba8b1c..bb03f47f46 100644
--- a/indra/newview/llavatarlist.cpp
+++ b/indra/newview/llavatarlist.cpp
@@ -65,6 +65,20 @@ void LLAvatarList::toggleIcons()
 	}
 }
 
+void LLAvatarList::setSpeakingIndicatorsVisible(bool visible)
+{
+	// Save the new value for new items to use.
+	mShowSpeakingIndicator = visible;
+	
+	// Show/hide icons for all existing items.
+	std::vector<LLPanel*> items;
+	getItems(items);
+	for( std::vector<LLPanel*>::const_iterator it = items.begin(); it != items.end(); it++)
+	{
+		static_cast<LLAvatarListItem*>(*it)->setSpeakingIndicatorVisible(mShowSpeakingIndicator);
+	}
+}
+
 static bool findInsensitive(std::string haystack, const std::string& needle_upper)
 {
     LLStringUtil::toUpper(haystack);
@@ -81,6 +95,7 @@ LLAvatarList::Params::Params()
 , show_last_interaction_time("show_last_interaction_time", false)
 , show_info_btn("show_info_btn", true)
 , show_profile_btn("show_profile_btn", true)
+, show_speaking_indicator("show_speaking_indicator", true)
 {
 }
 
@@ -94,6 +109,7 @@ LLAvatarList::LLAvatarList(const Params& p)
 , mShowIcons(true)
 , mShowInfoBtn(p.show_info_btn)
 , mShowProfileBtn(p.show_profile_btn)
+, mShowSpeakingIndicator(p.show_speaking_indicator)
 {
 	setCommitOnSelectionChange(true);
 
@@ -295,6 +311,7 @@ void LLAvatarList::addNewItem(const LLUUID& id, const std::string& name, BOOL is
 	item->setAvatarIconVisible(mShowIcons);
 	item->setShowInfoBtn(mShowInfoBtn);
 	item->setShowProfileBtn(mShowProfileBtn);
+	item->setSpeakingIndicatorVisible(mShowSpeakingIndicator);
 
 	addItem(item, id, pos);
 }
diff --git a/indra/newview/llavatarlist.h b/indra/newview/llavatarlist.h
index 195d9e5b55..490f93e501 100644
--- a/indra/newview/llavatarlist.h
+++ b/indra/newview/llavatarlist.h
@@ -61,6 +61,7 @@ public:
 		Optional<bool> show_last_interaction_time; // show most recent interaction time. *HACK: move this to a derived class
 		Optional<bool> show_info_btn;
 		Optional<bool> show_profile_btn;
+		Optional<bool> show_speaking_indicator;
 		Params();
 	};
 
@@ -76,6 +77,7 @@ public:
 	void setContextMenu(LLAvatarListItem::ContextMenu* menu) { mContextMenu = menu; }
 
 	void toggleIcons();
+	void setSpeakingIndicatorsVisible(bool visible);
 	void sortByName();
 	void setShowIcons(std::string param_name);
 	bool getIconsVisible() const { return mShowIcons; }
@@ -105,6 +107,7 @@ private:
 	bool mShowIcons;
 	bool mShowInfoBtn;
 	bool mShowProfileBtn;
+	bool mShowSpeakingIndicator;
 
 	LLTimer*				mLITUpdateTimer; // last interaction time update timer
 	std::string				mIconParamName;
diff --git a/indra/newview/llavatarlistitem.cpp b/indra/newview/llavatarlistitem.cpp
index a7ac14c948..7df278d887 100644
--- a/indra/newview/llavatarlistitem.cpp
+++ b/indra/newview/llavatarlistitem.cpp
@@ -62,6 +62,7 @@ LLAvatarListItem::LLAvatarListItem()
 	mIconWidth = mAvatarName->getRect().mLeft - mAvatarIcon->getRect().mLeft;
 	mInfoBtnWidth = mInfoBtn->getRect().mRight - mSpeakingIndicator->getRect().mRight;
 	mProfileBtnWidth = mProfileBtn->getRect().mRight - mInfoBtn->getRect().mRight;
+	mSpeakingIndicatorWidth = mSpeakingIndicator->getRect().mRight - mAvatarName->getRect().mRight; 
 }
 
 LLAvatarListItem::~LLAvatarListItem()
@@ -230,6 +231,18 @@ void LLAvatarListItem::setShowProfileBtn(bool show)
 	mAvatarName->reshape(mAvatarName->getRect().getWidth() + width_delta, mAvatarName->getRect().getHeight());
 }
 
+void LLAvatarListItem::setSpeakingIndicatorVisible(bool visible)
+{
+	// Already done? Then do nothing.
+	if (mSpeakingIndicator->getVisible() == (BOOL)visible)
+		return;
+	mSpeakingIndicator->setVisible(visible);
+	S32 width_delta = visible ? - mSpeakingIndicatorWidth : mSpeakingIndicatorWidth;
+
+	//Reshaping avatar name
+	mAvatarName->reshape(mAvatarName->getRect().getWidth() + width_delta, mAvatarName->getRect().getHeight());
+}
+
 void LLAvatarListItem::setAvatarIconVisible(bool visible)
 {
 	// Already done? Then do nothing.
diff --git a/indra/newview/llavatarlistitem.h b/indra/newview/llavatarlistitem.h
index cd7a85c3dc..d379797a46 100644
--- a/indra/newview/llavatarlistitem.h
+++ b/indra/newview/llavatarlistitem.h
@@ -65,8 +65,9 @@ public:
 	void setAvatarId(const LLUUID& id, bool ignore_status_changes = false);
 	void setLastInteractionTime(const std::string& val);
 	//Show/hide profile/info btn, translating speaker indicator and avatar name coordinates accordingly
-	void setShowProfileBtn(bool hide);
-	void setShowInfoBtn(bool hide);
+	void setShowProfileBtn(bool show);
+	void setShowInfoBtn(bool show);
+	void setSpeakingIndicatorVisible(bool visible);
 	void setAvatarIconVisible(bool visible);
 	
 	const LLUUID& getAvatarId() const;
@@ -109,6 +110,7 @@ private:
 	S32	 mIconWidth; // icon width + padding
 	S32  mInfoBtnWidth; //info btn width + padding
 	S32  mProfileBtnWidth; //profile btn width + padding
+	S32  mSpeakingIndicatorWidth; //speaking indicator width + padding
 };
 
 #endif //LL_LLAVATARLISTITEM_H
diff --git a/indra/newview/llpanelimcontrolpanel.cpp b/indra/newview/llpanelimcontrolpanel.cpp
index 21e88b6d07..80b29c4fa7 100644
--- a/indra/newview/llpanelimcontrolpanel.cpp
+++ b/indra/newview/llpanelimcontrolpanel.cpp
@@ -59,6 +59,14 @@ void LLPanelChatControlPanel::onOpenVoiceControlsClicked()
 	// TODO: implement Voice Control Panel opening
 }
 
+void LLPanelChatControlPanel::onVoiceChannelStateChanged(const LLVoiceChannel::EState& old_state, const LLVoiceChannel::EState& new_state)
+{
+	bool is_call_started = ( new_state >= LLVoiceChannel::STATE_CALL_STARTED );
+	childSetVisible("end_call_btn", is_call_started);
+	childSetVisible("voice_ctrls_btn", is_call_started);
+	childSetVisible("call_btn", ! is_call_started);
+}
+
 BOOL LLPanelChatControlPanel::postBuild()
 {
 	childSetAction("call_btn", boost::bind(&LLPanelChatControlPanel::onCallButtonClicked, this));
@@ -76,15 +84,6 @@ void LLPanelChatControlPanel::draw()
 	LLIMModel::LLIMSession* session = LLIMModel::getInstance()->findIMSession(mSessionId);
 	if (!session) return;
 
-	LLVoiceChannel* voice_channel = session->mVoiceChannel;
-	if (voice_channel && voice_enabled)
-	{
-		bool is_call_started = ( voice_channel->getState() >= LLVoiceChannel::STATE_CALL_STARTED );
-		childSetVisible("end_call_btn", is_call_started);
-		childSetVisible("voice_ctrls_btn", is_call_started);
-		childSetVisible("call_btn", ! is_call_started);
-	}
-
 	bool session_initialized = session->mSessionInitialized;
 	bool callback_enabled = session->mCallBackEnabled;
 	LLViewerRegion* region = gAgent.getRegion();
@@ -98,6 +97,15 @@ void LLPanelChatControlPanel::draw()
 	LLPanel::draw();
 }
 
+void LLPanelChatControlPanel::setSessionId(const LLUUID& session_id)
+{
+	//Method is called twice for AdHoc and Group chat. Second time when server init reply received
+	mSessionId = session_id;
+	LLVoiceChannel* voice_channel = LLIMModel::getInstance()->getVoiceChannel(mSessionId);
+	if(voice_channel)
+		voice_channel->setStateChangedCallback(boost::bind(&LLPanelChatControlPanel::onVoiceChannelStateChanged, this, _1, _2));
+}
+
 LLPanelIMControlPanel::LLPanelIMControlPanel()
 {
 }
@@ -214,6 +222,12 @@ void LLPanelGroupControlPanel::onSortMenuItemClicked(const LLSD& userdata)
 
 }
 
+void LLPanelGroupControlPanel::onVoiceChannelStateChanged(const LLVoiceChannel::EState& old_state, const LLVoiceChannel::EState& new_state)
+{
+	LLPanelChatControlPanel::onVoiceChannelStateChanged(old_state, new_state);
+	mAvatarList->setSpeakingIndicatorsVisible(new_state >= LLVoiceChannel::STATE_CALL_STARTED);
+}
+
 void LLPanelGroupControlPanel::setSessionId(const LLUUID& session_id)
 {
 	LLPanelChatControlPanel::setSessionId(session_id);
diff --git a/indra/newview/llpanelimcontrolpanel.h b/indra/newview/llpanelimcontrolpanel.h
index fa101f4280..1f38bffb53 100644
--- a/indra/newview/llpanelimcontrolpanel.h
+++ b/indra/newview/llpanelimcontrolpanel.h
@@ -34,6 +34,7 @@
 #define LL_LLPANELIMCONTROLPANEL_H
 
 #include "llpanel.h"
+#include "llvoicechannel.h"
 
 class LLSpeakerMgr;
 class LLAvatarList;
@@ -52,7 +53,9 @@ public:
 	void onEndCallButtonClicked();
 	void onOpenVoiceControlsClicked();
 
-	virtual void setSessionId(const LLUUID& session_id) { mSessionId = session_id; }
+	virtual void onVoiceChannelStateChanged(const LLVoiceChannel::EState& old_state, const LLVoiceChannel::EState& new_state);
+
+	virtual void setSessionId(const LLUUID& session_id);
 
 private:
 	LLUUID mSessionId;
@@ -100,6 +103,7 @@ protected:
 private:
 	void onGroupInfoButtonClicked();
 	void onSortMenuItemClicked(const LLSD& userdata);
+	/*virtual*/ void onVoiceChannelStateChanged(const LLVoiceChannel::EState& old_state, const LLVoiceChannel::EState& new_state);
 };
 
 class LLPanelAdHocControlPanel : public LLPanelGroupControlPanel
diff --git a/indra/newview/llvoicechannel.cpp b/indra/newview/llvoicechannel.cpp
index 96fcf61e62..cefc88ebee 100644
--- a/indra/newview/llvoicechannel.cpp
+++ b/indra/newview/llvoicechannel.cpp
@@ -390,7 +390,15 @@ void LLVoiceChannel::setState(EState state)
 		break;
 	}
 
-	mState = state;
+	doSetState(state);
+}
+
+void LLVoiceChannel::doSetState(const EState& new_state)
+{
+	EState old_state = mState;
+	mState = new_state;
+	if (!mStateChangedCallback.empty())
+		mStateChangedCallback(old_state, mState);
 }
 
 void LLVoiceChannel::toggleCallWindowIfNeeded(EState state)
@@ -620,7 +628,7 @@ void LLVoiceChannelGroup::setState(EState state)
 			gIMMgr->addSystemMessage(mSessionID, "ringing", mNotifyArgs);
 		}
 
-		mState = state;
+		doSetState(state);
 		break;
 	default:
 		LLVoiceChannel::setState(state);
@@ -865,7 +873,7 @@ void LLVoiceChannelP2P::setState(EState state)
 	if (mReceivedCall && state == STATE_RINGING)
 	{
 		gIMMgr->addSystemMessage(mSessionID, "answering", mNotifyArgs);
-		mState = state;
+		doSetState(state);
 		return;
 	}
 	LLVoiceChannel::setState(state);
diff --git a/indra/newview/llvoicechannel.h b/indra/newview/llvoicechannel.h
index 9966bdd5ab..8f1e9ff02d 100644
--- a/indra/newview/llvoicechannel.h
+++ b/indra/newview/llvoicechannel.h
@@ -52,6 +52,8 @@ public:
 		STATE_CONNECTED
 	} EState;
 
+	typedef boost::function<void(const EState& old_state, const EState& new_state)> state_changed_callback_t;
+
 	LLVoiceChannel(const LLUUID& session_id, const std::string& session_name);
 	virtual ~LLVoiceChannel();
 
@@ -69,6 +71,8 @@ public:
 	virtual BOOL callStarted();
 	const std::string& getSessionName() const { return mSessionName; }
 
+	void setStateChangedCallback(state_changed_callback_t callback) { mStateChangedCallback = callback; }
+
 	const LLUUID getSessionID() { return mSessionID; }
 	EState getState() { return mState; }
 
@@ -85,6 +89,10 @@ public:
 
 protected:
 	virtual void setState(EState state);
+	/**
+	 * Use this method if you want mStateChangedCallback to be executed while state is changed
+	 */
+	void doSetState(const EState& state);
 	void toggleCallWindowIfNeeded(EState state);
 	void setURI(std::string uri);
 
@@ -106,6 +114,9 @@ protected:
 	static LLVoiceChannel* sCurrentVoiceChannel;
 	static LLVoiceChannel* sSuspendedVoiceChannel;
 	static BOOL sSuspended;
+
+private:
+	state_changed_callback_t mStateChangedCallback;
 };
 
 class LLVoiceChannelGroup : public LLVoiceChannel
diff --git a/indra/newview/skins/default/xui/en/panel_adhoc_control_panel.xml b/indra/newview/skins/default/xui/en/panel_adhoc_control_panel.xml
index 24c46b314f..0246e21d25 100644
--- a/indra/newview/skins/default/xui/en/panel_adhoc_control_panel.xml
+++ b/indra/newview/skins/default/xui/en/panel_adhoc_control_panel.xml
@@ -16,6 +16,7 @@
      opaque="false"
      show_info_btn="false"
      show_profile_btn="false"
+     show_speaking_indicator="false"
      top="10"
      width="180"/>
 
diff --git a/indra/newview/skins/default/xui/en/panel_group_control_panel.xml b/indra/newview/skins/default/xui/en/panel_group_control_panel.xml
index 46f34949a8..763dd7b922 100644
--- a/indra/newview/skins/default/xui/en/panel_group_control_panel.xml
+++ b/indra/newview/skins/default/xui/en/panel_group_control_panel.xml
@@ -16,6 +16,7 @@
      opaque="false"
      show_info_btn="false"
      show_profile_btn="false"
+     show_speaking_indicator="false"
      top="10"
      width="180"/>
 
-- 
cgit v1.2.3


From 5a2424d01026327ae8eb17ec2b319495c6f5e9b1 Mon Sep 17 00:00:00 2001
From: Vadim Savchuk <vsavchuk@productengine.com>
Date: Wed, 4 Nov 2009 21:45:16 +0200
Subject: Fixed minor bug EXT-1769 (Edit Pick: '+' icon blinks on mouse over)

--HG--
branch : product-engine
---
 indra/newview/llpanelpick.cpp | 24 ++++++++++++++++++++++--
 indra/newview/llpanelpick.h   | 11 +++++++++++
 2 files changed, 33 insertions(+), 2 deletions(-)

(limited to 'indra')

diff --git a/indra/newview/llpanelpick.cpp b/indra/newview/llpanelpick.cpp
index e725479abb..103f041686 100644
--- a/indra/newview/llpanelpick.cpp
+++ b/indra/newview/llpanelpick.cpp
@@ -40,6 +40,7 @@
 #include "llagent.h"
 #include "llagentpicksinfo.h"
 #include "llbutton.h"
+#include "lliconctrl.h"
 #include "lllineeditor.h"
 #include "llparcel.h"
 #include "llviewerparcelmgr.h"
@@ -62,6 +63,7 @@
 #define XML_SNAPSHOT	"pick_snapshot"
 #define XML_LOCATION	"pick_location"
 
+#define XML_BTN_ON_TXTR "edit_icon"
 #define XML_BTN_SAVE "save_changes_btn"
 
 #define SAVE_BTN_LABEL "[WHAT]"
@@ -401,8 +403,6 @@ BOOL LLPanelPickEdit::postBuild()
 	LLPanelPickInfo::postBuild();
 
 	mSnapshotCtrl->setOnSelectCallback(boost::bind(&LLPanelPickEdit::onPickChanged, this, _1));
-	mSnapshotCtrl->setMouseEnterCallback(boost::bind(&LLPanelPickEdit::childSetVisible, this, "edit_icon", true));
-	mSnapshotCtrl->setMouseLeaveCallback(boost::bind(&LLPanelPickEdit::childSetVisible, this, "edit_icon", false));
 
 	LLLineEditor* line_edit = getChild<LLLineEditor>("pick_name");
 	line_edit->setKeystrokeCallback(boost::bind(&LLPanelPickEdit::onPickChanged, this, _1), NULL);
@@ -547,3 +547,23 @@ void LLPanelPickEdit::processProperties(void* data, EAvatarProcessorType type)
 		LLPanelPickInfo::processProperties(data, type);
 	}
 }
+
+// PRIVATE AREA
+
+void LLPanelPickEdit::initTexturePickerMouseEvents()
+{
+	text_icon = getChild<LLIconCtrl>(XML_BTN_ON_TXTR);
+	mSnapshotCtrl->setMouseEnterCallback(boost::bind(&LLPanelPickEdit::onTexturePickerMouseEnter, this, _1));
+	mSnapshotCtrl->setMouseLeaveCallback(boost::bind(&LLPanelPickEdit::onTexturePickerMouseLeave, this, _1));
+	text_icon->setVisible(FALSE);
+}
+		
+void LLPanelPickEdit::onTexturePickerMouseEnter(LLUICtrl* ctrl)
+{
+        text_icon->setVisible(TRUE);
+}
+
+void LLPanelPickEdit::onTexturePickerMouseLeave(LLUICtrl* ctrl)
+{
+	text_icon->setVisible(FALSE);
+}
diff --git a/indra/newview/llpanelpick.h b/indra/newview/llpanelpick.h
index 9b605cd6b1..2c0830f2ac 100644
--- a/indra/newview/llpanelpick.h
+++ b/indra/newview/llpanelpick.h
@@ -41,6 +41,7 @@
 #include "llremoteparcelrequest.h"
 #include "llavatarpropertiesprocessor.h"
 
+class LLIconCtrl;
 class LLTextureCtrl;
 class LLMessageSystem;
 class LLAvatarPropertiesObserver;
@@ -236,6 +237,16 @@ protected:
 	bool mLocationChanged;
 	bool mNeedData;
 	bool mNewPick;
+
+private:
+
+	void initTexturePickerMouseEvents();
+        void onTexturePickerMouseEnter(LLUICtrl* ctrl);
+	void onTexturePickerMouseLeave(LLUICtrl* ctrl);
+
+private:
+
+	LLIconCtrl* text_icon;
 };
 
 #endif // LL_LLPANELPICK_H
-- 
cgit v1.2.3


From c3e9536b6fae9fbd751d4a63e243f502e056175d Mon Sep 17 00:00:00 2001
From: richard <none@none>
Date: Wed, 4 Nov 2009 11:58:39 -0800
Subject: updated floater_test_textbox to test case of texbox too big for its
 text removed picture_style from sidepanel_object_info.xml made mime_type
 error notification unique on mime type

reviewed by Leyla
---
 indra/newview/skins/default/xui/en/floater_test_textbox.xml | 4 ++--
 indra/newview/skins/default/xui/en/notifications.xml        | 3 +++
 2 files changed, 5 insertions(+), 2 deletions(-)

(limited to 'indra')

diff --git a/indra/newview/skins/default/xui/en/floater_test_textbox.xml b/indra/newview/skins/default/xui/en/floater_test_textbox.xml
index f39d27761c..9e2e9e74e3 100644
--- a/indra/newview/skins/default/xui/en/floater_test_textbox.xml
+++ b/indra/newview/skins/default/xui/en/floater_test_textbox.xml
@@ -145,11 +145,11 @@
   <text
  type="string"
  length="1"
- bottom="390"
+ height="60" 
  label="N"
  layout="topleft"
  left="10"
- name="centered_text"
+ name="left_aligned_text"
  width="380"
  halign="left"
  text_color="1 1 1 0.7"
diff --git a/indra/newview/skins/default/xui/en/notifications.xml b/indra/newview/skins/default/xui/en/notifications.xml
index babed28f10..8679e87f49 100644
--- a/indra/newview/skins/default/xui/en/notifications.xml
+++ b/indra/newview/skins/default/xui/en/notifications.xml
@@ -4629,6 +4629,9 @@ If you want to view streaming media on parcels that support it you should go to
    name="NoPlugin"
    type="notify">
 No Media Plugin was found to handle the "[MIME_TYPE]" mime type.  Media of this type will be unavailable.
+  <unique>
+    <context key="MIME_TYPE" />
+  </unique>
   </notification>
   <notification
    icon="alertmodal.tga"
-- 
cgit v1.2.3


From 321f5ac36ce04b01bd24d62eb4c7585e83c110f9 Mon Sep 17 00:00:00 2001
From: "Eric M. Tulla (BigPapi)" <tulla@lindenlab.com>
Date: Wed, 4 Nov 2009 15:06:52 -0500
Subject: Fix for EXT-2050 - Duplicate entries in strings.xml Removed all
 duplicates (verifying their dupe status and removing the second example).

---
 indra/newview/skins/default/xui/en/strings.xml | 45 --------------------------
 1 file changed, 45 deletions(-)

(limited to 'indra')

diff --git a/indra/newview/skins/default/xui/en/strings.xml b/indra/newview/skins/default/xui/en/strings.xml
index 0f7e8cb137..ec2673644f 100644
--- a/indra/newview/skins/default/xui/en/strings.xml
+++ b/indra/newview/skins/default/xui/en/strings.xml
@@ -2047,9 +2047,6 @@ this texture in your inventory
 	<!-- panel contents -->
 	<string name="PanelContentsNewScript">New Script</string>
 	
-	<!-- panel avatar -->
-	<!-- <string name="None">None</string>	Duplicate-->
-	
 	<!-- Mute -->
 	<string name="MuteByName">(by name)</string>
 	<string name="MuteAgent">(resident)</string>
@@ -2306,9 +2303,6 @@ If you continue to receive this message, contact the [SUPPORT_SITE].
 <string name="Body Thick">Body Thick</string>
 <string name="Body Thickness">Body Thickness</string>
 <string name="Body Thin">Body Thin</string>
-<string name="Bottom">Bottom</string>
-<string name="Bottom Left">Bottom Left</string>
-<string name="Bottom Right">Bottom Right</string>
 
 <string name="Bow Legged">Bow Legged</string>
 <string name="Breast Buoyancy">Breast Buoyancy</string>
@@ -2330,13 +2324,9 @@ If you continue to receive this message, contact the [SUPPORT_SITE].
 <string name="no bustle">No Bustle</string>
 <string name="more bustle">More Bustle</string>
 
-<string name="Center">Center</string>
-<string name="Center 2">Center 2</string>
 <string name="Chaplin">Chaplin</string>
 <string name="Cheek Bones">Cheek Bones</string>
-<string name="Chest">Chest</string>
 <string name="Chest Size">Chest Size</string>
-<string name="Chin">Chin</string>
 <string name="Chin Angle">Chin Angle</string>
 <string name="Chin Cleft">Chin Cleft</string>
 <string name="Chin Curtains">Chin Curtains</string>
@@ -2500,22 +2490,10 @@ If you continue to receive this message, contact the [SUPPORT_SITE].
 <string name="Jowls">Jowls</string>
 <string name="Knee Angle">Knee Angle</string>
 <string name="Knock Kneed">Knock Kneed</string>
-<string name="L Forearm">L Forearm</string>
-<string name="L Lower Leg">L Lower Leg</string>
-<string name="L Upper Arm">L Upper Arm</string>
-<string name="L Upper Leg">L Upper Leg</string>
 
 <string name="Large">Large</string>
 <string name="Large Hands">Large Hands</string>
-<string name="Left">Left</string>
-<string name="Left Ear">Left Ear</string>
-<string name="Left Eyeball">Left Eyeball</string>
-<string name="Left Foot">Left Foot</string>
-<string name="Left Hand">Left Hand</string>
-<string name="Left Hip">Left Hip</string>
 <string name="Left Part">Left Part</string>
-<string name="Left Pec">Left Pec</string>
-<string name="Left Shoulder">Left Shoulder</string>
 <string name="Leg Length">Leg Length</string>
 <string name="Leg Muscles">Leg Muscles</string>
 <string name="Less">Less</string>
@@ -2533,7 +2511,6 @@ If you continue to receive this message, contact the [SUPPORT_SITE].
 <string name="Less Square">Less Square</string>
 <string name="Less Volume">Less Volume</string>
 <string name="Less soul">Less soul</string>
-<string name="Light">Light</string>
 <string name="Lighter">Lighter</string>
 <string name="Lip Cleft">Lip Cleft</string>
 <string name="Lip Cleft Depth">Lip Cleft Depth</string>
@@ -2596,7 +2573,6 @@ If you continue to receive this message, contact the [SUPPORT_SITE].
 <string name="More soul">More soul</string>
 <string name="Moustache">Moustache</string>
 
-<string name="Mouth">Mouth</string>
 <string name="Mouth Corner">Mouth Corner</string>
 <string name="Mouth Position">Mouth Position</string>
 <string name="Mowhawk">Mowhawk</string>
@@ -2624,10 +2600,8 @@ If you continue to receive this message, contact the [SUPPORT_SITE].
 <string name="No Spikes">No Spikes</string>
 <string name="No White">No White</string>
 <string name="No Wrinkles">No Wrinkles</string>
-<string name="None">None</string>
 <string name="Normal Lower">Normal Lower</string>
 <string name="Normal Upper">Normal Upper</string>
-<string name="Nose">Nose</string>
 <string name="Nose Left">Nose Left</string>
 <string name="Nose Right">Nose Right</string>
 <string name="Nose Size">Nose Size</string>
@@ -2667,7 +2641,6 @@ If you continue to receive this message, contact the [SUPPORT_SITE].
 <string name="Part">Part</string>
 <string name="Part Bangs">Part Bangs</string>
 <string name="Pectorals">Pectorals</string>
-<string name="Pelvis">Pelvis</string>
 <string name="Pigment">Pigment</string>
 <string name="Pigtails">Pigtails</string>
 <string name="Pink">Pink</string>
@@ -2683,24 +2656,12 @@ If you continue to receive this message, contact the [SUPPORT_SITE].
 <string name="Pop Right Eye">Pop Right Eye</string>
 <string name="Puffy">Puffy</string>
 <string name="Puffy Eyelids">Puffy Eyelids</string>
-<string name="R Forearm">R Forearm</string>
-<string name="R Lower Leg">R Lower Leg</string>
-<string name="R Upper Arm">R Upper Arm</string>
-<string name="R Upper Leg">R Upper Leg</string>
 <string name="Rainbow Color">Rainbow Color</string>
 <string name="Red Hair">Red Hair</string>
 <string name="Red Skin">Red Skin</string>
 <string name="Regular">Regular</string>
 <string name="Regular Muscles">Regular Muscles</string>
-<string name="Right">Right</string>
-<string name="Right Ear">Right Ear</string>
-<string name="Right Eyeball">Right Eyeball</string>
-<string name="Right Foot">Right Foot</string>
-<string name="Right Hand">Right Hand</string>
-<string name="Right Hip">Right Hip</string>
 <string name="Right Part">Right Part</string>
-<string name="Right Pec">Right Pec</string>
-<string name="Right Shoulder">Right Shoulder</string>
 <string name="Rosy Complexion">Rosy Complexion</string>
 <string name="Round">Round</string>
 <string name="Round Forehead">Round Forehead</string>
@@ -2757,7 +2718,6 @@ If you continue to receive this message, contact the [SUPPORT_SITE].
 <string name="Skinny Neck">Skinny Neck</string>
 <string name="Skirt Fit">Skirt Fit</string>
 <string name="Skirt Length">Skirt Length</string>
-<string name="Skull">Skull</string>
 <string name="Slanted Forehead">Slanted Forehead</string>
 <string name="Sleeve Length">Sleeve Length</string>
 
@@ -2780,12 +2740,10 @@ If you continue to receive this message, contact the [SUPPORT_SITE].
 
 <string name="Sparse">Sparse</string>
 <string name="Spiked Hair">Spiked Hair</string>
-<string name="Spine">Spine</string>
 <string name="Square">Square</string>
 <string name="Square Toe">Square Toe</string>
 <string name="Squash Head">Squash Head</string>
 <string name="Squash/Stretch Head">Squash/Stretch Head</string>
-<string name="Stomach">Stomach</string>
 <string name="Stretch Head">Stretch Head</string>
 <string name="Sunken">Sunken</string>
 <string name="Sunken Chest">Sunken Chest</string>
@@ -2817,9 +2775,6 @@ If you continue to receive this message, contact the [SUPPORT_SITE].
 <string name="Tilt Right">Tilt Right</string>
 <string name="Toe Shape">Toe Shape</string>
 <string name="Toe Thickness">Toe Thickness</string>
-<string name="Top">Top</string>
-<string name="Top Left">Top Left</string>
-<string name="Top Right">Top Right</string>
 <string name="Torso Length">Torso Length</string>
 <string name="Torso Muscles">Torso Muscles</string>
 <string name="Torso Scrawny">Torso Scrawny</string>
-- 
cgit v1.2.3


From 8c27615aa5c1fc61fa0a5877717699d5df47476d Mon Sep 17 00:00:00 2001
From: Eugene Mutavchi <emutavchi@productengine.com>
Date: Wed, 4 Nov 2009 22:17:23 +0200
Subject: Implemented normal sub-task EXT-2144 (IM P2p control panel should
 contain avatar name under avatar icon aligned to the left side)

--HG--
branch : product-engine
---
 indra/newview/llpanelimcontrolpanel.cpp                | 18 ++++++++++++++++++
 indra/newview/llpanelimcontrolpanel.h                  |  3 +++
 .../skins/default/xui/en/floater_im_session.xml        | 14 +++++++-------
 .../skins/default/xui/en/panel_im_control_panel.xml    | 12 +++++++++++-
 4 files changed, 39 insertions(+), 8 deletions(-)

(limited to 'indra')

diff --git a/indra/newview/llpanelimcontrolpanel.cpp b/indra/newview/llpanelimcontrolpanel.cpp
index 80b29c4fa7..76612f2dd1 100644
--- a/indra/newview/llpanelimcontrolpanel.cpp
+++ b/indra/newview/llpanelimcontrolpanel.cpp
@@ -123,6 +123,8 @@ BOOL LLPanelIMControlPanel::postBuild()
 	childSetAction("teleport_btn", boost::bind(&LLPanelIMControlPanel::onTeleportButtonClicked, this));
 	childSetAction("pay_btn", boost::bind(&LLPanelIMControlPanel::onPayButtonClicked, this));
 	childSetEnabled("add_friend_btn", !LLAvatarActions::isFriend(getChild<LLAvatarIconCtrl>("avatar_icon")->getAvatarId()));
+
+	
 	
 	return LLPanelChatControlPanel::postBuild();
 }
@@ -166,6 +168,9 @@ void LLPanelIMControlPanel::setSessionId(const LLUUID& session_id)
 
 	getChild<LLAvatarIconCtrl>("avatar_icon")->setValue(mAvatarID);
 
+	// Fetch the currect name
+	gCacheName->get(mAvatarID, FALSE, boost::bind(&LLPanelIMControlPanel::nameUpdatedCallback, this, _1, _2, _3, _4));
+	llwarns << "gCacheName->get" << llendl;
 	// Disable profile button if participant is not realy SL avatar
 	LLIMModel::LLIMSession* im_session =
 		im_model.findIMSession(session_id);
@@ -173,6 +178,19 @@ void LLPanelIMControlPanel::setSessionId(const LLUUID& session_id)
 		childSetEnabled("view_profile_btn", FALSE);
 }
 
+void LLPanelIMControlPanel::nameUpdatedCallback(const LLUUID& id, const std::string& first, const std::string& last, BOOL is_group)
+{
+	llwarns << "LLPanelIMControlPanel::nameUpdatedCallback" << llendl;
+	if ( id == mAvatarID )
+	{
+		llwarns << "LLPanelIMControlPanel::nameUpdatedCallback id == mAvatarID" << llendl;
+		std::string avatar_name;
+		avatar_name.assign(first);
+		avatar_name.append(" ");
+		avatar_name.append(last);
+		getChild<LLTextBox>("avatar_name")->setValue(avatar_name);
+	}
+}
 
 LLPanelGroupControlPanel::LLPanelGroupControlPanel(const LLUUID& session_id)
 {
diff --git a/indra/newview/llpanelimcontrolpanel.h b/indra/newview/llpanelimcontrolpanel.h
index 1f38bffb53..ac5d86345e 100644
--- a/indra/newview/llpanelimcontrolpanel.h
+++ b/indra/newview/llpanelimcontrolpanel.h
@@ -72,6 +72,9 @@ public:
 
 	void setSessionId(const LLUUID& session_id);
 
+protected:
+	void nameUpdatedCallback(const LLUUID& id, const std::string& first, const std::string& last, BOOL is_group);
+
 private:
 	void onViewProfileButtonClicked();
 	void onAddFriendButtonClicked();
diff --git a/indra/newview/skins/default/xui/en/floater_im_session.xml b/indra/newview/skins/default/xui/en/floater_im_session.xml
index 1585d976b3..70af2f63b6 100644
--- a/indra/newview/skins/default/xui/en/floater_im_session.xml
+++ b/indra/newview/skins/default/xui/en/floater_im_session.xml
@@ -3,7 +3,7 @@
  legacy_header_height="18"
  background_visible="true"
  follows="left|top|right|bottom"
- height="359"
+ height="369"
  layout="topleft"
  left="0"
  name="panel_im"
@@ -14,10 +14,10 @@
  visible="true" 
  width="520"
  can_resize="true"
- min_width="200"
- min_height="150">
+ min_width="350"
+ min_height="350">
   <layout_stack follows="left|top|right|bottom"
-                height="344"
+                height="354"
                 width="520"
                 layout="topleft"
                 orientation="horizontal"
@@ -28,12 +28,12 @@
       name="panel_im_control_panel"
       layout="topleft"
       top_delta="-3"
-      height="344"
+      height="354"
       follows="left"
       label="IM Control Panel"
       auto_resize="false"
       user_resize="false" />
-    <layout_panel height="344"
+    <layout_panel height="354"
                   width="355"
                   left_delta="146" 
                   top="0"
@@ -56,7 +56,7 @@
        length="1"
        follows="left|top|right|bottom"
        font="SansSerif"
-       height="290"
+       height="300"
        layout="topleft"
        name="chat_history"
        parse_highlights="true"
diff --git a/indra/newview/skins/default/xui/en/panel_im_control_panel.xml b/indra/newview/skins/default/xui/en/panel_im_control_panel.xml
index f77a2ec730..c8b134cdf0 100644
--- a/indra/newview/skins/default/xui/en/panel_im_control_panel.xml
+++ b/indra/newview/skins/default/xui/en/panel_im_control_panel.xml
@@ -1,7 +1,7 @@
 <?xml version="1.0" encoding="utf-8" standalone="yes" ?>
 <panel
  border="false"
- height="327"
+ height="350"
  name="panel_im_control_panel"
  width="131">
 
@@ -13,6 +13,16 @@
      top="-10"
      width="125"/>
 
+    <text
+     follows="left|right"
+     font="SansSerifBig"
+     height="16"
+     layout="topleft"
+     name="avatar_name"
+     use_ellipses="true"
+     value="Unknown"
+     width="125" />
+
     <button
      follows="left|bottom"
      height="20"
-- 
cgit v1.2.3


From eca4416855b97ee017e55581616b8e4aa0c5e4d4 Mon Sep 17 00:00:00 2001
From: richard <none@none>
Date: Wed, 4 Nov 2009 12:22:06 -0800
Subject: reverted uniqueness constraint on mime_type errors due to bug in
 notifications uniqueness filtering

---
 indra/newview/skins/default/xui/en/notifications.xml | 3 ---
 1 file changed, 3 deletions(-)

(limited to 'indra')

diff --git a/indra/newview/skins/default/xui/en/notifications.xml b/indra/newview/skins/default/xui/en/notifications.xml
index 8679e87f49..babed28f10 100644
--- a/indra/newview/skins/default/xui/en/notifications.xml
+++ b/indra/newview/skins/default/xui/en/notifications.xml
@@ -4629,9 +4629,6 @@ If you want to view streaming media on parcels that support it you should go to
    name="NoPlugin"
    type="notify">
 No Media Plugin was found to handle the "[MIME_TYPE]" mime type.  Media of this type will be unavailable.
-  <unique>
-    <context key="MIME_TYPE" />
-  </unique>
   </notification>
   <notification
    icon="alertmodal.tga"
-- 
cgit v1.2.3


From 15df55ecafd2f6d72f25988401ddb7ed58030b79 Mon Sep 17 00:00:00 2001
From: Eugene Mutavchi <emutavchi@productengine.com>
Date: Wed, 4 Nov 2009 22:37:46 +0200
Subject: No ticket, removed unnecessary warnings from 3d35bc1f0cc6 commit.

--HG--
branch : product-engine
---
 indra/newview/llpanelimcontrolpanel.cpp | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

(limited to 'indra')

diff --git a/indra/newview/llpanelimcontrolpanel.cpp b/indra/newview/llpanelimcontrolpanel.cpp
index 76612f2dd1..c9168670d5 100644
--- a/indra/newview/llpanelimcontrolpanel.cpp
+++ b/indra/newview/llpanelimcontrolpanel.cpp
@@ -170,7 +170,7 @@ void LLPanelIMControlPanel::setSessionId(const LLUUID& session_id)
 
 	// Fetch the currect name
 	gCacheName->get(mAvatarID, FALSE, boost::bind(&LLPanelIMControlPanel::nameUpdatedCallback, this, _1, _2, _3, _4));
-	llwarns << "gCacheName->get" << llendl;
+
 	// Disable profile button if participant is not realy SL avatar
 	LLIMModel::LLIMSession* im_session =
 		im_model.findIMSession(session_id);
@@ -180,10 +180,8 @@ void LLPanelIMControlPanel::setSessionId(const LLUUID& session_id)
 
 void LLPanelIMControlPanel::nameUpdatedCallback(const LLUUID& id, const std::string& first, const std::string& last, BOOL is_group)
 {
-	llwarns << "LLPanelIMControlPanel::nameUpdatedCallback" << llendl;
 	if ( id == mAvatarID )
 	{
-		llwarns << "LLPanelIMControlPanel::nameUpdatedCallback id == mAvatarID" << llendl;
 		std::string avatar_name;
 		avatar_name.assign(first);
 		avatar_name.append(" ");
-- 
cgit v1.2.3


From b806edf4ac47d18e1a43fb8dbb5fbcad8d13192f Mon Sep 17 00:00:00 2001
From: Bryan O'Sullivan <bos@lindenlab.com>
Date: Wed, 4 Nov 2009 14:59:23 -0800
Subject: Redo Bao's broken merge

---
 indra/llcommon/CMakeLists.txt                      |   2 +
 indra/llcommon/llassettype.cpp                     | 154 +---
 indra/llcommon/llassettype.h                       |  62 +-
 indra/llcommon/llfoldertype.cpp                    | 165 ++++
 indra/llcommon/llfoldertype.h                      | 123 +++
 indra/llinventory/llinventory.cpp                  |  62 +-
 indra/llinventory/llinventory.h                    |  13 +-
 indra/llinventory/llinventorytype.cpp              |  34 -
 indra/llinventory/llinventorytype.h                |   3 +-
 indra/llinventory/tests/inventorymisc_test.cpp     |   4 +-
 indra/llmessage/lltransfersourceasset.cpp          |   1 -
 indra/llprimitive/llmediaentry.cpp                 |   1 +
 indra/llprimitive/tests/llmediaentry_test.cpp      | 116 +--
 indra/llui/llfloater.cpp                           |   6 +
 indra/llui/llfloater.h                             |   3 +
 indra/llui/llfloaterreg.cpp                        |   3 +-
 indra/newview/CMakeLists.txt                       |  10 +-
 indra/newview/app_settings/foldertypes.xml         |  25 +-
 indra/newview/llagentpicksinfo.cpp                 |   3 +-
 indra/newview/llagentui.cpp                        |   5 +-
 indra/newview/llagentwearables.cpp                 |  17 +-
 indra/newview/llappearancemgr.cpp                  |  24 +-
 indra/newview/llassetuploadresponders.cpp          |   2 +-
 indra/newview/llavataractions.cpp                  |   4 +-
 indra/newview/llavatarlist.cpp                     |  35 +
 indra/newview/llavatarlist.h                       |   7 +
 indra/newview/llchiclet.cpp                        |  38 +-
 indra/newview/llfavoritesbar.cpp                   |   6 +-
 indra/newview/llfloateranimpreview.cpp             |   2 +-
 indra/newview/llfloaterbulkpermission.cpp          |   1 -
 indra/newview/llfloaterbuy.cpp                     |   2 +-
 indra/newview/llfloaterbuycontents.cpp             |   2 +-
 indra/newview/llfloaterinventory.cpp               |   1 +
 indra/newview/llfloaterinventory.h                 |   1 +
 indra/newview/llfloaternamedesc.cpp                |   2 +-
 indra/newview/llfloateropenobject.cpp              |   4 +-
 indra/newview/llfloaterreporter.cpp                |   4 +-
 indra/newview/llfloatersnapshot.cpp                |   2 +-
 indra/newview/llfloaterworldmap.cpp                |   2 +-
 indra/newview/llfolderview.cpp                     |   5 +-
 indra/newview/llfolderview.h                       |   2 +-
 indra/newview/llfoldervieweventlistener.h          |   3 +-
 indra/newview/llfolderviewitem.cpp                 |  10 +-
 indra/newview/llfriendcard.cpp                     |   8 +-
 indra/newview/llimfloater.cpp                      |   7 +-
 indra/newview/llinspectavatar.cpp                  |  19 +-
 indra/newview/llinventorybridge.cpp                |  95 +-
 indra/newview/llinventorybridge.h                  |   8 +-
 indra/newview/llinventoryfunctions.cpp             |   4 -
 indra/newview/llinventorymodel.cpp                 |  63 +-
 indra/newview/llinventorymodel.h                   |  13 +-
 indra/newview/llinventorypanel.cpp                 |  30 +-
 indra/newview/llinventorypanel.h                   |   2 +-
 indra/newview/lllandmarkactions.cpp                |  14 +-
 indra/newview/lllandmarkactions.h                  |   2 +-
 indra/newview/llnavigationbar.cpp                  |   7 +
 indra/newview/llnavigationbar.h                    |   1 +
 indra/newview/llnearbychat.cpp                     |  37 +-
 indra/newview/llnearbychat.h                       |   7 +-
 indra/newview/llnearbychatbar.cpp                  |   9 +-
 indra/newview/llnearbychatbar.h                    |   2 +-
 indra/newview/lloutputmonitorctrl.cpp              |  12 +-
 indra/newview/lloutputmonitorctrl.h                |   3 +
 indra/newview/llpanelcontents.cpp                  |   3 +-
 indra/newview/llpanelimcontrolpanel.cpp            |  35 +-
 indra/newview/llpanelimcontrolpanel.h              |   3 +
 indra/newview/llpanellandmarkinfo.cpp              | 437 +++++++++
 indra/newview/llpanellandmarkinfo.h                |  85 ++
 indra/newview/llpanellandmarks.cpp                 |  33 +-
 indra/newview/llpanelmaininventory.cpp             |   4 +-
 indra/newview/llpanelobjectinventory.cpp           |  14 +-
 indra/newview/llpanelpeople.cpp                    |  67 +-
 indra/newview/llpanelpeople.h                      |   6 +
 indra/newview/llpanelplaceinfo.cpp                 | 931 ++------------------
 indra/newview/llpanelplaceinfo.h                   | 146 +--
 indra/newview/llpanelplaceprofile.cpp              | 541 ++++++++++++
 indra/newview/llpanelplaceprofile.h                | 114 +++
 indra/newview/llpanelplaces.cpp                    | 231 ++---
 indra/newview/llpanelplaces.h                      |  11 +-
 indra/newview/llpanelprofileview.h                 |  14 +
 indra/newview/llparticipantlist.cpp                | 110 ++-
 indra/newview/llparticipantlist.h                  |  58 +-
 indra/newview/llpreview.cpp                        |   5 +-
 indra/newview/llpreviewgesture.cpp                 |   4 +-
 indra/newview/llresourcedata.h                     |   3 +-
 indra/newview/llselectmgr.cpp                      |   2 +-
 indra/newview/llstartup.cpp                        |   6 +-
 indra/newview/lltexturectrl.cpp                    |   4 +-
 indra/newview/lltoastgroupnotifypanel.cpp          |   1 -
 indra/newview/lltooldraganddrop.cpp                |  21 +-
 indra/newview/llviewerassettype.cpp                | 114 +++
 indra/newview/llviewerassettype.h                  |  54 ++
 indra/newview/llviewerfoldertype.cpp               | 263 ++++++
 indra/newview/llviewerfoldertype.h                 |  57 ++
 indra/newview/llviewerinventory.cpp                | 112 ++-
 indra/newview/llviewerinventory.h                  |   4 +-
 indra/newview/llviewermenu.cpp                     |  13 +-
 indra/newview/llviewermenufile.cpp                 |  16 +-
 indra/newview/llviewermenufile.h                   |   6 +-
 indra/newview/llviewermessage.cpp                  |  42 +-
 indra/newview/llviewertexteditor.cpp               |  20 +-
 indra/newview/llvoavatarself.cpp                   |  35 +-
 indra/newview/llwearable.cpp                       |   2 +-
 .../skins/default/textures/inv_folder_inbox.tga    | Bin 0 -> 2085 bytes
 .../skins/default/xui/en/floater_im_session.xml    |  22 +-
 .../skins/default/xui/en/inspect_avatar.xml        |  12 +
 .../default/xui/en/menu_inspect_avatar_gear.xml    |  15 +-
 .../default/xui/en/menu_inspect_self_gear.xml      |   7 +-
 .../default/xui/en/panel_adhoc_control_panel.xml   |   5 +-
 .../skins/default/xui/en/panel_bottomtray.xml      |   4 +-
 .../default/xui/en/panel_group_control_panel.xml   |   6 +-
 .../skins/default/xui/en/panel_group_general.xml   |   6 +-
 .../default/xui/en/panel_group_info_sidetray.xml   | 141 ++-
 .../default/xui/en/panel_group_land_money.xml      | 207 ++---
 .../skins/default/xui/en/panel_group_notices.xml   | 243 +++--
 .../skins/default/xui/en/panel_group_roles.xml     | 503 ++++-------
 .../default/xui/en/panel_im_control_panel.xml      |  27 +-
 .../skins/default/xui/en/panel_landmark_info.xml   | 257 ++++++
 .../skins/default/xui/en/panel_landmarks.xml       |  18 +-
 .../skins/default/xui/en/panel_nearby_chat_bar.xml |   6 +-
 .../skins/default/xui/en/panel_pick_info.xml       |   2 +-
 .../skins/default/xui/en/panel_place_profile.xml   | 979 +++++++++++++++++++++
 .../newview/skins/default/xui/en/panel_places.xml  |  18 +-
 .../newview/skins/default/xui/en/panel_profile.xml |   2 +-
 .../skins/default/xui/en/panel_profile_view.xml    |   2 +-
 .../default/xui/en/widgets/gesture_combo_box.xml   |  10 +-
 .../skins/default/xui/en/widgets/talk_button.xml   |  37 +
 127 files changed, 4882 insertions(+), 2588 deletions(-)
 create mode 100644 indra/llcommon/llfoldertype.cpp
 create mode 100644 indra/llcommon/llfoldertype.h
 create mode 100644 indra/newview/llpanellandmarkinfo.cpp
 create mode 100644 indra/newview/llpanellandmarkinfo.h
 create mode 100644 indra/newview/llpanelplaceprofile.cpp
 create mode 100644 indra/newview/llpanelplaceprofile.h
 create mode 100644 indra/newview/llviewerassettype.cpp
 create mode 100644 indra/newview/llviewerassettype.h
 create mode 100644 indra/newview/llviewerfoldertype.cpp
 create mode 100644 indra/newview/llviewerfoldertype.h
 create mode 100644 indra/newview/skins/default/textures/inv_folder_inbox.tga
 create mode 100644 indra/newview/skins/default/xui/en/panel_landmark_info.xml
 create mode 100644 indra/newview/skins/default/xui/en/panel_place_profile.xml
 create mode 100644 indra/newview/skins/default/xui/en/widgets/talk_button.xml

(limited to 'indra')

diff --git a/indra/llcommon/CMakeLists.txt b/indra/llcommon/CMakeLists.txt
index e7aaf3c984..f785698612 100644
--- a/indra/llcommon/CMakeLists.txt
+++ b/indra/llcommon/CMakeLists.txt
@@ -50,6 +50,7 @@ set(llcommon_SOURCE_FILES
     llfile.cpp
     llfindlocale.cpp
     llfixedbuffer.cpp
+    llfoldertype.cpp
     llformat.cpp
     llframetimer.cpp
     llheartbeat.cpp
@@ -150,6 +151,7 @@ set(llcommon_HEADER_FILES
     llfile.h
     llfindlocale.h
     llfixedbuffer.h
+    llfoldertype.h
     llformat.h
     llframetimer.h
     llhash.h
diff --git a/indra/llcommon/llassettype.cpp b/indra/llcommon/llassettype.cpp
index b2a92861cc..6d5b12d840 100644
--- a/indra/llcommon/llassettype.cpp
+++ b/indra/llcommon/llassettype.cpp
@@ -43,30 +43,21 @@
 struct AssetEntry : public LLDictionaryEntry
 {
 	AssetEntry(const char *desc_name,
-			   const char *type_name, // 8 character limit!
-			   const char *human_name, // for decoding to human readable form; put any and as many printable characters you want in each one
-			   const char *category_name, // used by llinventorymodel when creating new categories
-			   EDragAndDropType dad_type,
-			   bool can_link, // can you create a link to this type?
-			   bool is_protected) // can the viewer change categories of this type?
+			   const char *type_name, 	// 8 character limit!
+			   const char *human_name, 	// for decoding to human readable form; put any and as many printable characters you want in each one
+			   bool can_link) 			// can you create a link to this type?
 		:
 		LLDictionaryEntry(desc_name),
 		mTypeName(type_name),
 		mHumanName(human_name),
-		mCategoryName(category_name),
-		mDadType(dad_type),
-		mCanLink(can_link),
-		mIsProtected(is_protected)
+		mCanLink(can_link)
 	{
 		llassert(strlen(mTypeName) <= 8);
 	}
 
 	const char *mTypeName;
 	const char *mHumanName;
-	const char *mCategoryName;
-	EDragAndDropType mDadType;
 	bool mCanLink;
-	bool mIsProtected;
 };
 
 class LLAssetDictionary : public LLSingleton<LLAssetDictionary>,
@@ -78,48 +69,32 @@ public:
 
 LLAssetDictionary::LLAssetDictionary()
 {
-	//       												   DESCRIPTION			TYPE NAME	HUMAN NAME			CATEGORY NAME 		DRAG&DROP		CAN LINK?	PROTECTED?
-	//      												  |--------------------|-----------|-------------------|-------------------|---------------|-----------|-----------|
-	addEntry(LLAssetType::AT_TEXTURE, 			new AssetEntry("TEXTURE",			"texture",	"texture",			"Textures", 		DAD_TEXTURE,	TRUE,		TRUE));
-	addEntry(LLAssetType::AT_SOUND, 			new AssetEntry("SOUND",				"sound",	"sound",			"Sounds", 			DAD_SOUND,		TRUE,		TRUE));
-	addEntry(LLAssetType::AT_CALLINGCARD, 		new AssetEntry("CALLINGCARD",		"callcard",	"calling card",		"Calling Cards", 	DAD_CALLINGCARD, TRUE,		TRUE));
-	addEntry(LLAssetType::AT_LANDMARK, 			new AssetEntry("LANDMARK",			"landmark",	"landmark",			"Landmarks", 		DAD_LANDMARK,	TRUE,		TRUE));
-	addEntry(LLAssetType::AT_SCRIPT, 			new AssetEntry("SCRIPT",			"script",	"legacy script",	"Scripts", 			DAD_NONE,		TRUE,		TRUE));
-	addEntry(LLAssetType::AT_CLOTHING, 			new AssetEntry("CLOTHING",			"clothing",	"clothing",			"Clothing", 		DAD_CLOTHING,	TRUE,		TRUE));
-	addEntry(LLAssetType::AT_OBJECT, 			new AssetEntry("OBJECT",			"object",	"object",			"Objects", 			DAD_OBJECT,		TRUE,		TRUE));
-	addEntry(LLAssetType::AT_NOTECARD, 			new AssetEntry("NOTECARD",			"notecard",	"note card",		"Notecards", 		DAD_NOTECARD,	TRUE,		TRUE));
-	addEntry(LLAssetType::AT_CATEGORY, 			new AssetEntry("CATEGORY",			"category",	"folder",			"New Folder", 		DAD_CATEGORY,	TRUE,		TRUE));
-	addEntry(LLAssetType::AT_ROOT_CATEGORY, 	new AssetEntry("ROOT_CATEGORY",		"root",		"root",				"Inventory", 		DAD_ROOT_CATEGORY, TRUE,	TRUE));
-	addEntry(LLAssetType::AT_LSL_TEXT, 			new AssetEntry("LSL_TEXT",			"lsltext",	"lsl2 script",		"Scripts", 			DAD_SCRIPT,		TRUE,		TRUE));
-	addEntry(LLAssetType::AT_LSL_BYTECODE, 		new AssetEntry("LSL_BYTECODE",		"lslbyte",	"lsl bytecode",		"Scripts", 			DAD_NONE,		TRUE,		TRUE));
-	addEntry(LLAssetType::AT_TEXTURE_TGA, 		new AssetEntry("TEXTURE_TGA",		"txtr_tga",	"tga texture",		"Uncompressed Images", DAD_NONE,	TRUE,		TRUE));
-	addEntry(LLAssetType::AT_BODYPART, 			new AssetEntry("BODYPART",			"bodypart",	"body part",		"Body Parts", 		DAD_BODYPART,	TRUE,		TRUE));
-	addEntry(LLAssetType::AT_TRASH, 			new AssetEntry("TRASH",				"trash",	"trash",			"Trash", 			DAD_NONE,		FALSE,		TRUE));
-	addEntry(LLAssetType::AT_SNAPSHOT_CATEGORY, new AssetEntry("SNAPSHOT_CATEGORY", "snapshot",	"snapshot",			"Photo Album", 		DAD_NONE,		FALSE,		TRUE));
-	addEntry(LLAssetType::AT_LOST_AND_FOUND, 	new AssetEntry("LOST_AND_FOUND", 	"lstndfnd",	"lost and found",	"Lost And Found", 	DAD_NONE,		FALSE,		TRUE));
-	addEntry(LLAssetType::AT_SOUND_WAV, 		new AssetEntry("SOUND_WAV",			"snd_wav",	"sound",			"Uncompressed SoundS", DAD_NONE,	TRUE,		TRUE));
-	addEntry(LLAssetType::AT_IMAGE_TGA, 		new AssetEntry("IMAGE_TGA",			"img_tga",	"targa image",		"Uncompressed Images", DAD_NONE,	TRUE,		TRUE));
-	addEntry(LLAssetType::AT_IMAGE_JPEG, 		new AssetEntry("IMAGE_JPEG",		"jpeg",		"jpeg image",		"Uncompressed Images", DAD_NONE,	TRUE,		TRUE));
-	addEntry(LLAssetType::AT_ANIMATION, 		new AssetEntry("ANIMATION",			"animatn",	"animation",		"Animations", 		DAD_ANIMATION,	TRUE,		TRUE));
-	addEntry(LLAssetType::AT_GESTURE, 			new AssetEntry("GESTURE",			"gesture",	"gesture",			"Gestures", 		DAD_GESTURE,	TRUE,		TRUE));
-	addEntry(LLAssetType::AT_SIMSTATE, 			new AssetEntry("SIMSTATE",			"simstate",	"simstate",			"New Folder", 		DAD_NONE,		FALSE,		TRUE));
-	addEntry(LLAssetType::AT_FAVORITE, 			new AssetEntry("FAVORITE",			"favorite",	"favorite",			"favorite", 		DAD_NONE,		FALSE,		TRUE));
-
-	addEntry(LLAssetType::AT_LINK, 				new AssetEntry("LINK",				"link",		"symbolic link",	"Link", 			DAD_LINK,		FALSE,		TRUE));
-	addEntry(LLAssetType::AT_LINK_FOLDER, 		new AssetEntry("FOLDER_LINK",		"link_f", 	"symbolic folder link", "New Folder", 	DAD_LINK,		FALSE,		TRUE));
-
-	for (S32 ensemble_num = S32(LLAssetType::AT_FOLDER_ENSEMBLE_START); 
-		 ensemble_num <= S32(LLAssetType::AT_FOLDER_ENSEMBLE_END); 
-		 ensemble_num++)
-	{
-		addEntry(LLAssetType::EType(ensemble_num), new AssetEntry("ENSEMBLE",		"ensemble", "ensemble", 		"New Folder", 		DAD_CATEGORY,	FALSE,		FALSE)); 
-	}
-
-	addEntry(LLAssetType::AT_CURRENT_OUTFIT, 	new AssetEntry("CURRENT",			"current",	"current outfit",	"Current Look", 	DAD_CATEGORY,	FALSE,		TRUE));
-	addEntry(LLAssetType::AT_OUTFIT, 			new AssetEntry("OUTFIT",			"outfit",	"outfit",			"New Look", 		DAD_CATEGORY,	FALSE,		FALSE));
-	addEntry(LLAssetType::AT_MY_OUTFITS, 		new AssetEntry("MY_OUTFITS",		"my_otfts",	"my outfits",		"My Looks", 		DAD_CATEGORY,	FALSE,		TRUE));
-		 
-	addEntry(LLAssetType::AT_NONE, 				new AssetEntry("NONE",				"-1",		NULL,		  		"New Folder", 		DAD_NONE,		FALSE,		FALSE));
+	//       												   DESCRIPTION			TYPE NAME	HUMAN NAME			CAN LINK?	
+	//      												  |--------------------|-----------|-------------------|-----------|
+	addEntry(LLAssetType::AT_TEXTURE, 			new AssetEntry("TEXTURE",			"texture",	"texture",			FALSE));
+	addEntry(LLAssetType::AT_SOUND, 			new AssetEntry("SOUND",				"sound",	"sound",			FALSE));
+	addEntry(LLAssetType::AT_CALLINGCARD, 		new AssetEntry("CALLINGCARD",		"callcard",	"calling card",		FALSE));
+	addEntry(LLAssetType::AT_LANDMARK, 			new AssetEntry("LANDMARK",			"landmark",	"landmark",			FALSE));
+	addEntry(LLAssetType::AT_SCRIPT, 			new AssetEntry("SCRIPT",			"script",	"legacy script",	FALSE));
+	addEntry(LLAssetType::AT_CLOTHING, 			new AssetEntry("CLOTHING",			"clothing",	"clothing",			TRUE));
+	addEntry(LLAssetType::AT_OBJECT, 			new AssetEntry("OBJECT",			"object",	"object",			TRUE));
+	addEntry(LLAssetType::AT_NOTECARD, 			new AssetEntry("NOTECARD",			"notecard",	"note card",		FALSE));
+	addEntry(LLAssetType::AT_CATEGORY, 			new AssetEntry("CATEGORY",			"category",	"folder",			TRUE));
+	addEntry(LLAssetType::AT_LSL_TEXT, 			new AssetEntry("LSL_TEXT",			"lsltext",	"lsl2 script",		FALSE));
+	addEntry(LLAssetType::AT_LSL_BYTECODE, 		new AssetEntry("LSL_BYTECODE",		"lslbyte",	"lsl bytecode",		FALSE));
+	addEntry(LLAssetType::AT_TEXTURE_TGA, 		new AssetEntry("TEXTURE_TGA",		"txtr_tga",	"tga texture",		FALSE));
+	addEntry(LLAssetType::AT_BODYPART, 			new AssetEntry("BODYPART",			"bodypart",	"body part",		TRUE));
+	addEntry(LLAssetType::AT_SOUND_WAV, 		new AssetEntry("SOUND_WAV",			"snd_wav",	"sound",			FALSE));
+	addEntry(LLAssetType::AT_IMAGE_TGA, 		new AssetEntry("IMAGE_TGA",			"img_tga",	"targa image",		FALSE));
+	addEntry(LLAssetType::AT_IMAGE_JPEG, 		new AssetEntry("IMAGE_JPEG",		"jpeg",		"jpeg image",		FALSE));
+	addEntry(LLAssetType::AT_ANIMATION, 		new AssetEntry("ANIMATION",			"animatn",	"animation",		FALSE));
+	addEntry(LLAssetType::AT_GESTURE, 			new AssetEntry("GESTURE",			"gesture",	"gesture",			TRUE));
+	addEntry(LLAssetType::AT_SIMSTATE, 			new AssetEntry("SIMSTATE",			"simstate",	"simstate",			FALSE));
+
+	addEntry(LLAssetType::AT_LINK, 				new AssetEntry("LINK",				"link",		"symbolic link",	FALSE));
+	addEntry(LLAssetType::AT_LINK_FOLDER, 		new AssetEntry("FOLDER_LINK",		"link_f", 	"symbolic folder link", FALSE));
+
+	addEntry(LLAssetType::AT_NONE, 				new AssetEntry("NONE",				"-1",		NULL,		  		FALSE));
 };
 
 // static
@@ -140,8 +115,7 @@ const std::string &LLAssetType::getDesc(LLAssetType::EType asset_type)
 	}
 	else
 	{
-		static const std::string error_string = "BAD TYPE";
-		return error_string;
+		return badLookup();
 	}
 }
 
@@ -156,7 +130,7 @@ const char *LLAssetType::lookup(LLAssetType::EType asset_type)
 	}
 	else
 	{
-		return "-1";
+		return badLookup().c_str();
 	}
 }
 
@@ -166,6 +140,7 @@ LLAssetType::EType LLAssetType::lookup(const char* name)
 	return lookup(ll_safe_string(name));
 }
 
+// static
 LLAssetType::EType LLAssetType::lookup(const std::string& type_name)
 {
 	const LLAssetDictionary *dict = LLAssetDictionary::getInstance();
@@ -193,7 +168,7 @@ const char *LLAssetType::lookupHumanReadable(LLAssetType::EType asset_type)
 	}
 	else
 	{
-		return NULL;
+		return badLookup().c_str();
 	}
 }
 
@@ -203,6 +178,7 @@ LLAssetType::EType LLAssetType::lookupHumanReadable(const char* name)
 	return lookupHumanReadable(ll_safe_string(name));
 }
 
+// static
 LLAssetType::EType LLAssetType::lookupHumanReadable(const std::string& readable_name)
 {
 	const LLAssetDictionary *dict = LLAssetDictionary::getInstance();
@@ -219,32 +195,6 @@ LLAssetType::EType LLAssetType::lookupHumanReadable(const std::string& readable_
 	return AT_NONE;
 }
 
-// static
-const char *LLAssetType::lookupCategoryName(LLAssetType::EType asset_type)
-{
-	const LLAssetDictionary *dict = LLAssetDictionary::getInstance();
-	const AssetEntry *entry = dict->lookup(asset_type);
-	if (entry)
-	{
-		return entry->mCategoryName;
-	}
-	else
-	{
-		return "New Folder";
-	}
-}
-
-// static
-EDragAndDropType LLAssetType::lookupDragAndDropType(EType asset_type)
-{
-	const LLAssetDictionary *dict = LLAssetDictionary::getInstance();
-	const AssetEntry *entry = dict->lookup(asset_type);
-	if (entry)
-		return entry->mDadType;
-	else
-		return DAD_NONE;
-}
-
 // static
 bool LLAssetType::lookupCanLink(EType asset_type)
 {
@@ -269,37 +219,9 @@ bool LLAssetType::lookupIsLinkType(EType asset_type)
 }
 
 // static
-// Only ensembles and plain folders aren't protected.  "Protected" means
-// you can't change certain properties such as their type.
-bool LLAssetType::lookupIsProtectedCategoryType(EType asset_type)
+const std::string &LLAssetType::badLookup()
 {
-	const LLAssetDictionary *dict = LLAssetDictionary::getInstance();
-	const AssetEntry *entry = dict->lookup(asset_type);
-	if (entry)
-	{
-		return entry->mIsProtected;
-	}
-	return true;
-}
+	static const std::string sBadLookup = "llassettype_bad_lookup";
+	return sBadLookup;
 
-// static
-bool LLAssetType::lookupIsEnsembleCategoryType(EType asset_type)
-{
-	return (asset_type >= AT_FOLDER_ENSEMBLE_START &&
-			asset_type <= AT_FOLDER_ENSEMBLE_END);
-}
-
-
-// static. Generate a good default description
-void LLAssetType::generateDescriptionFor(LLAssetType::EType asset_type,
-										 std::string& description)
-{
-	const S32 BUF_SIZE = 30;
-	char time_str[BUF_SIZE];	/* Flawfinder: ignore */
-	time_t now;
-	time(&now);
-	memset(time_str, '\0', BUF_SIZE);
-	strftime(time_str, BUF_SIZE - 1, "%Y-%m-%d %H:%M:%S ", localtime(&now));
-	description.assign(time_str);
-	description.append(LLAssetType::lookupHumanReadable(asset_type));
 }
diff --git a/indra/llcommon/llassettype.h b/indra/llcommon/llassettype.h
index 3c760e4d91..ec2290d30e 100644
--- a/indra/llcommon/llassettype.h
+++ b/indra/llcommon/llassettype.h
@@ -94,18 +94,6 @@ public:
 		AT_BODYPART = 13,
 			// A collection of textures and parameters that can be worn by an avatar.
 
-		AT_TRASH = 14,
-			// Only to be used as a marker for a category preferred type. 
-			// Using this, we can throw things in the trash before completely deleting.
-
-		AT_SNAPSHOT_CATEGORY = 15,
-			// A marker for a folder meant for snapshots. 
-			// No actual assets will be snapshots, though if there were, you
-			// could interpret them as textures.
-
-		AT_LOST_AND_FOUND = 16,
-			// Used to stuff lost&found items into.
-
 		AT_SOUND_WAV = 17,
 			// Uncompressed sound.
 
@@ -126,38 +114,22 @@ public:
 		AT_SIMSTATE = 22,
 			// Simstate file.
 
-		AT_FAVORITE = 23,
-			// favorite items
-
 		AT_LINK = 24,
 			// Inventory symbolic link
 
 		AT_LINK_FOLDER = 25,
 			// Inventory folder link
-
-		AT_FOLDER_ENSEMBLE_START = 26,
-		AT_FOLDER_ENSEMBLE_END = 45,
-			// This range is reserved for special clothing folder types.
-
-		AT_CURRENT_OUTFIT = 46,
-			// Current outfit
-
-		AT_OUTFIT = 47,
-			// Predefined outfit ("look")
-
-		AT_MY_OUTFITS = 48,
-			// Folder that holds your outfits.
-
 		
-		AT_COUNT = 49,
+		AT_COUNT = 26,
 
 			// +*********************************************************+
 			// |  TO ADD AN ELEMENT TO THIS ENUM:                        |
 			// +*********************************************************+
 			// | 1. INSERT BEFORE AT_COUNT                               |
 			// | 2. INCREMENT AT_COUNT BY 1                              |
-			// | 3. ADD TO LLAssetDictionary in LLAssetType.cpp          |
-			// | 3. ADD TO DEFAULT_ASSET_FOR_INV in LLInventoryType.cpp  |
+			// | 3. ADD TO LLAssetType.cpp                               |
+			// | 4. ADD TO LLViewerAssetType.cpp                         |
+			// | 5. ADD TO DEFAULT_ASSET_FOR_INV in LLInventoryType.cpp  |
 			// +*********************************************************+
 
 		AT_NONE = -1
@@ -173,33 +145,17 @@ public:
 	static EType 				lookupHumanReadable(const std::string& readable_name);
 	static const char*			lookupHumanReadable(EType asset_type);
 
-	// Generate a good default description. You may want to add a verb
-	// or agent name after this depending on your application.
-	static void 				generateDescriptionFor(LLAssetType::EType asset_type,
-													   std::string& description);
-
 	static EType 				getType(const std::string& desc_name);
 	static const std::string&	getDesc(EType asset_type);
-	static EDragAndDropType   	lookupDragAndDropType(EType asset_type);
 
 	static bool 				lookupCanLink(EType asset_type);
 	static bool 				lookupIsLinkType(EType asset_type);
 
-	static const char*  		lookupCategoryName(EType asset_type);
-	static bool 				lookupIsProtectedCategoryType(EType asset_type);
-	static bool 				lookupIsEnsembleCategoryType(EType asset_type);
-
-	/* TODO: Change return types from "const char *" to "const std::string &".
-	This is fairly straightforward, but requires changing some calls to use .c_str().
-	e.g.:
-	-	fprintf(fp, "\t\ttype\t%s\n", LLAssetType::lookup(mType));
-	+	fprintf(fp, "\t\ttype\t%s\n", LLAssetType::lookup(mType).c_str());
-	*/
-	
-private:
-	// don't instantiate or derive one of these objects
-	LLAssetType( void ) {}
-	~LLAssetType( void ) {}
+	static const std::string&	badLookup(); // error string when a lookup fails
+
+protected:
+	LLAssetType() {}
+	~LLAssetType() {}
 };
 
 #endif // LL_LLASSETTYPE_H
diff --git a/indra/llcommon/llfoldertype.cpp b/indra/llcommon/llfoldertype.cpp
new file mode 100644
index 0000000000..9107b11597
--- /dev/null
+++ b/indra/llcommon/llfoldertype.cpp
@@ -0,0 +1,165 @@
+/** 
+ * @file llfoldertype.cpp
+ * @brief Implementatino of LLFolderType functionality.
+ *
+ * $LicenseInfo:firstyear=2001&license=viewergpl$
+ * 
+ * Copyright (c) 2001-2009, Linden Research, Inc.
+ * 
+ * Second Life Viewer Source Code
+ * The source code in this file ("Source Code") is provided by Linden Lab
+ * to you under the terms of the GNU General Public License, version 2.0
+ * ("GPL"), unless you have obtained a separate licensing agreement
+ * ("Other License"), formally executed by you and Linden Lab.  Terms of
+ * the GPL can be found in doc/GPL-license.txt in this distribution, or
+ * online at http://secondlifegrid.net/programs/open_source/licensing/gplv2
+ * 
+ * There are special exceptions to the terms and conditions of the GPL as
+ * it is applied to this Source Code. View the full text of the exception
+ * in the file doc/FLOSS-exception.txt in this software distribution, or
+ * online at
+ * http://secondlifegrid.net/programs/open_source/licensing/flossexception
+ * 
+ * By copying, modifying or distributing this software, you acknowledge
+ * that you have read and understood your obligations described above,
+ * and agree to abide by those obligations.
+ * 
+ * ALL LINDEN LAB SOURCE CODE IS PROVIDED "AS IS." LINDEN LAB MAKES NO
+ * WARRANTIES, EXPRESS, IMPLIED OR OTHERWISE, REGARDING ITS ACCURACY,
+ * COMPLETENESS OR PERFORMANCE.
+ * $/LicenseInfo$
+ */
+
+#include "linden_common.h"
+
+#include "llfoldertype.h"
+#include "lldictionary.h"
+#include "llmemory.h"
+#include "llsingleton.h"
+
+///----------------------------------------------------------------------------
+/// Class LLFolderType
+///----------------------------------------------------------------------------
+struct FolderEntry : public LLDictionaryEntry
+{
+	FolderEntry(const std::string &type_name, // 8 character limit!
+				bool is_protected) // can the viewer change categories of this type?
+		:
+	LLDictionaryEntry(type_name),
+	mIsProtected(is_protected)
+	{
+		llassert(type_name.length() <= 8);
+	}
+
+	const bool mIsProtected;
+};
+
+class LLFolderDictionary : public LLSingleton<LLFolderDictionary>,
+						   public LLDictionary<LLFolderType::EType, FolderEntry>
+{
+public:
+	LLFolderDictionary();
+};
+
+LLFolderDictionary::LLFolderDictionary()
+{
+	//       													    TYPE NAME	PROTECTED
+	//      													   |-----------|---------|
+	addEntry(LLFolderType::FT_TEXTURE, 				new FolderEntry("texture",	TRUE));
+	addEntry(LLFolderType::FT_SOUND, 				new FolderEntry("sound",	TRUE));
+	addEntry(LLFolderType::FT_CALLINGCARD, 			new FolderEntry("callcard",	TRUE));
+	addEntry(LLFolderType::FT_LANDMARK, 			new FolderEntry("landmark",	TRUE));
+	addEntry(LLFolderType::FT_CLOTHING, 			new FolderEntry("clothing",	TRUE));
+	addEntry(LLFolderType::FT_OBJECT, 				new FolderEntry("object",	TRUE));
+	addEntry(LLFolderType::FT_NOTECARD, 			new FolderEntry("notecard",	TRUE));
+	addEntry(LLFolderType::FT_CATEGORY, 			new FolderEntry("category",	TRUE));
+	addEntry(LLFolderType::FT_ROOT_CATEGORY, 		new FolderEntry("root",		TRUE));
+	addEntry(LLFolderType::FT_LSL_TEXT, 			new FolderEntry("lsltext",	TRUE));
+	addEntry(LLFolderType::FT_BODYPART, 			new FolderEntry("bodypart",	TRUE));
+	addEntry(LLFolderType::FT_TRASH, 				new FolderEntry("trash",	TRUE));
+	addEntry(LLFolderType::FT_SNAPSHOT_CATEGORY, 	new FolderEntry("snapshot", TRUE));
+	addEntry(LLFolderType::FT_LOST_AND_FOUND, 		new FolderEntry("lstndfnd",	TRUE));
+	addEntry(LLFolderType::FT_ANIMATION, 			new FolderEntry("animatn",	TRUE));
+	addEntry(LLFolderType::FT_GESTURE, 				new FolderEntry("gesture",	TRUE));
+	addEntry(LLFolderType::FT_FAVORITE, 			new FolderEntry("favorite",	TRUE));
+	
+	for (S32 ensemble_num = S32(LLFolderType::FT_ENSEMBLE_START); ensemble_num <= S32(LLFolderType::FT_ENSEMBLE_END); ensemble_num++)
+	{
+		addEntry(LLFolderType::EType(ensemble_num), new FolderEntry("ensemble", FALSE)); 
+	}
+
+	addEntry(LLFolderType::FT_CURRENT_OUTFIT, 		new FolderEntry("current",	TRUE));
+	addEntry(LLFolderType::FT_OUTFIT, 				new FolderEntry("outfit",	FALSE));
+	addEntry(LLFolderType::FT_MY_OUTFITS, 			new FolderEntry("my_otfts",	TRUE));
+	addEntry(LLFolderType::FT_INBOX, 				new FolderEntry("inbox",	TRUE));
+		 
+	addEntry(LLFolderType::FT_NONE, 				new FolderEntry("-1",		FALSE));
+};
+
+// static
+LLFolderType::EType LLFolderType::lookup(const std::string& name)
+{
+	return LLFolderDictionary::getInstance()->lookup(name);
+}
+
+// static
+const std::string &LLFolderType::lookup(LLFolderType::EType folder_type)
+{
+	const FolderEntry *entry = LLFolderDictionary::getInstance()->lookup(folder_type);
+	if (entry)
+	{
+		return entry->mName;
+	}
+	else
+	{
+		return badLookup();
+	}
+}
+
+// static
+// Only ensembles and plain folders aren't protected.  "Protected" means
+// you can't change certain properties such as their type.
+bool LLFolderType::lookupIsProtectedType(EType folder_type)
+{
+	const LLFolderDictionary *dict = LLFolderDictionary::getInstance();
+	const FolderEntry *entry = dict->lookup(folder_type);
+	if (entry)
+	{
+		return entry->mIsProtected;
+	}
+	return true;
+}
+
+// static
+bool LLFolderType::lookupIsEnsembleType(EType folder_type)
+{
+	return (folder_type >= FT_ENSEMBLE_START &&
+			folder_type <= FT_ENSEMBLE_END);
+}
+
+// static
+LLAssetType::EType LLFolderType::folderTypeToAssetType(LLFolderType::EType folder_type)
+{
+	if (LLAssetType::lookup(LLAssetType::EType(folder_type)) == LLAssetType::badLookup())
+	{
+		llwarns << "Converting to unknown asset type " << folder_type << llendl;
+	}
+	return (LLAssetType::EType)folder_type;
+}
+
+// static
+LLFolderType::EType LLFolderType::assetTypeToFolderType(LLAssetType::EType asset_type)
+{
+	if (LLFolderType::lookup(LLFolderType::EType(asset_type)) == LLFolderType::badLookup())
+	{
+		llwarns << "Converting to unknown folder type " << asset_type << llendl;
+	}
+	return (LLFolderType::EType)asset_type;
+}
+
+// static
+const std::string &LLFolderType::badLookup()
+{
+	static const std::string sBadLookup = "llfoldertype_bad_lookup";
+	return sBadLookup;
+}
diff --git a/indra/llcommon/llfoldertype.h b/indra/llcommon/llfoldertype.h
new file mode 100644
index 0000000000..5374ffd829
--- /dev/null
+++ b/indra/llcommon/llfoldertype.h
@@ -0,0 +1,123 @@
+/** 
+ * @file llfoldertype.h
+ * @brief Declaration of LLFolderType.
+ *
+ * $LicenseInfo:firstyear=2001&license=viewergpl$
+ * 
+ * Copyright (c) 2001-2009, Linden Research, Inc.
+ * 
+ * Second Life Viewer Source Code
+ * The source code in this file ("Source Code") is provided by Linden Lab
+ * to you under the terms of the GNU General Public License, version 2.0
+ * ("GPL"), unless you have obtained a separate licensing agreement
+ * ("Other License"), formally executed by you and Linden Lab.  Terms of
+ * the GPL can be found in doc/GPL-license.txt in this distribution, or
+ * online at http://secondlifegrid.net/programs/open_source/licensing/gplv2
+ * 
+ * There are special exceptions to the terms and conditions of the GPL as
+ * it is applied to this Source Code. View the full text of the exception
+ * in the file doc/FLOSS-exception.txt in this software distribution, or
+ * online at
+ * http://secondlifegrid.net/programs/open_source/licensing/flossexception
+ * 
+ * By copying, modifying or distributing this software, you acknowledge
+ * that you have read and understood your obligations described above,
+ * and agree to abide by those obligations.
+ * 
+ * ALL LINDEN LAB SOURCE CODE IS PROVIDED "AS IS." LINDEN LAB MAKES NO
+ * WARRANTIES, EXPRESS, IMPLIED OR OTHERWISE, REGARDING ITS ACCURACY,
+ * COMPLETENESS OR PERFORMANCE.
+ * $/LicenseInfo$
+ */
+
+#ifndef LL_LLFOLDERTYPE_H
+#define LL_LLFOLDERTYPE_H
+
+#include <string>
+#include "llassettype.h"
+
+// This class handles folder types (similar to assettype, except for folders)
+// and operations on those.
+class LL_COMMON_API LLFolderType
+{
+public:
+	// ! BACKWARDS COMPATIBILITY ! Folder type enums must match asset type enums.
+	enum EType
+	{
+		FT_TEXTURE = 0,
+
+		FT_SOUND = 1, 
+
+		FT_CALLINGCARD = 2,
+
+		FT_LANDMARK = 3,
+
+		// FT_SCRIPT = 4,
+
+		FT_CLOTHING = 5,
+
+		FT_OBJECT = 6,
+
+		FT_NOTECARD = 7,
+
+		FT_CATEGORY = 8,
+
+		FT_ROOT_CATEGORY = 9,
+
+		FT_LSL_TEXT = 10,
+
+		// FT_LSL_BYTECODE = 11,
+		// FT_TEXTURE_TGA = 12,
+
+		FT_BODYPART = 13,
+
+		FT_TRASH = 14,
+
+		FT_SNAPSHOT_CATEGORY = 15,
+
+		FT_LOST_AND_FOUND = 16,
+
+		// FT_SOUND_WAV = 17,
+		// FT_IMAGE_TGA = 18,
+		// FT_IMAGE_JPEG = 19,
+
+		FT_ANIMATION = 20,
+
+		FT_GESTURE = 21,
+
+		// FT_SIMSTATE = 22,
+
+		FT_FAVORITE = 23,
+
+		FT_ENSEMBLE_START = 26,
+		FT_ENSEMBLE_END = 45,
+			// This range is reserved for special clothing folder types.
+
+		FT_CURRENT_OUTFIT = 46,
+		FT_OUTFIT = 47,
+		FT_MY_OUTFITS = 48,
+		
+		FT_INBOX = 49,
+
+		FT_COUNT = 50,
+
+		FT_NONE = -1
+	};
+
+	static EType 				lookup(const std::string& type_name);
+	static const std::string&	lookup(EType folder_type);
+
+	static bool 				lookupIsProtectedType(EType folder_type);
+	static bool 				lookupIsEnsembleType(EType folder_type);
+
+	static LLAssetType::EType	folderTypeToAssetType(LLFolderType::EType folder_type);
+	static LLFolderType::EType	assetTypeToFolderType(LLAssetType::EType asset_type);
+
+	static const std::string&	badLookup(); // error string when a lookup fails
+
+protected:
+	LLFolderType() {}
+	~LLFolderType() {}
+};
+
+#endif // LL_LLFOLDERTYPE_H
diff --git a/indra/llinventory/llinventory.cpp b/indra/llinventory/llinventory.cpp
index 5d3fbe5128..d665deb605 100644
--- a/indra/llinventory/llinventory.cpp
+++ b/indra/llinventory/llinventory.cpp
@@ -1324,7 +1324,7 @@ BOOL item_date_sort( LLInventoryItem* a, LLInventoryItem* b )
 LLInventoryCategory::LLInventoryCategory(
 	const LLUUID& uuid,
 	const LLUUID& parent_uuid,
-	LLAssetType::EType preferred_type,
+	LLFolderType::EType preferred_type,
 	const std::string& name) :
 	LLInventoryObject(uuid, parent_uuid, LLAssetType::AT_CATEGORY, name),
 	mPreferredType(preferred_type)
@@ -1332,7 +1332,7 @@ LLInventoryCategory::LLInventoryCategory(
 }
 
 LLInventoryCategory::LLInventoryCategory() :
-	mPreferredType(LLAssetType::AT_NONE)
+	mPreferredType(LLFolderType::FT_NONE)
 {
 	mType = LLAssetType::AT_CATEGORY;
 }
@@ -1354,12 +1354,12 @@ void LLInventoryCategory::copyCategory(const LLInventoryCategory* other)
 	mPreferredType = other->mPreferredType;
 }
 
-LLAssetType::EType LLInventoryCategory::getPreferredType() const
+LLFolderType::EType LLInventoryCategory::getPreferredType() const
 {
 	return mPreferredType;
 }
 
-void LLInventoryCategory::setPreferredType(LLAssetType::EType type)
+void LLInventoryCategory::setPreferredType(LLFolderType::EType type)
 {
 	mPreferredType = type;
 }
@@ -1405,13 +1405,13 @@ bool LLInventoryCategory::fromLLSD(const LLSD& sd)
     if (sd.has(w))
     {
         S8 type = (U8)sd[w].asInteger();
-        mPreferredType = static_cast<LLAssetType::EType>(type);
+        mPreferredType = static_cast<LLFolderType::EType>(type);
     }
 	w = INV_ASSET_TYPE_LABEL_WS;
 	if (sd.has(w))
 	{
 		S8 type = (U8)sd[w].asInteger();
-        mPreferredType = static_cast<LLAssetType::EType>(type);
+        mPreferredType = static_cast<LLFolderType::EType>(type);
 	}
 
     w = INV_NAME_LABEL;
@@ -1433,7 +1433,7 @@ void LLInventoryCategory::unpackMessage(LLMessageSystem* msg,
 	msg->getUUIDFast(block, _PREHASH_ParentID, mParentUUID, block_num);
 	S8 type;
 	msg->getS8Fast(block, _PREHASH_Type, type, block_num);
-	mPreferredType = static_cast<LLAssetType::EType>(type);
+	mPreferredType = static_cast<LLFolderType::EType>(type);
 	msg->getStringFast(block, _PREHASH_Name, mName, block_num);
 	LLStringUtil::replaceNonstandardASCII(mName, ' ');
 }
@@ -1482,7 +1482,7 @@ BOOL LLInventoryCategory::importFile(LLFILE* fp)
 		}
 		else if(0 == strcmp("pref_type", keyword))
 		{
-			mPreferredType = LLAssetType::lookup(valuestr);
+			mPreferredType = LLFolderType::lookup(valuestr);
 		}
 		else if(0 == strcmp("name", keyword))
 		{
@@ -1514,7 +1514,7 @@ BOOL LLInventoryCategory::exportFile(LLFILE* fp, BOOL) const
 	mParentUUID.toString(uuid_str);
 	fprintf(fp, "\t\tparent_id\t%s\n", uuid_str.c_str());
 	fprintf(fp, "\t\ttype\t%s\n", LLAssetType::lookup(mType));
-	fprintf(fp, "\t\tpref_type\t%s\n", LLAssetType::lookup(mPreferredType));
+	fprintf(fp, "\t\tpref_type\t%s\n", LLFolderType::lookup(mPreferredType).c_str());
 	fprintf(fp, "\t\tname\t%s|\n", mName.c_str());
 	fprintf(fp,"\t}\n");
 	return TRUE;
@@ -1561,7 +1561,7 @@ BOOL LLInventoryCategory::importLegacyStream(std::istream& input_stream)
 		}
 		else if(0 == strcmp("pref_type", keyword))
 		{
-			mPreferredType = LLAssetType::lookup(valuestr);
+			mPreferredType = LLFolderType::lookup(valuestr);
 		}
 		else if(0 == strcmp("name", keyword))
 		{
@@ -1593,7 +1593,7 @@ BOOL LLInventoryCategory::exportLegacyStream(std::ostream& output_stream, BOOL)
 	mParentUUID.toString(uuid_str);
 	output_stream << "\t\tparent_id\t" << uuid_str << "\n";
 	output_stream << "\t\ttype\t" << LLAssetType::lookup(mType) << "\n";
-	output_stream << "\t\tpref_type\t" << LLAssetType::lookup(mPreferredType) << "\n";
+	output_stream << "\t\tpref_type\t" << LLFolderType::lookup(mPreferredType) << "\n";
 	output_stream << "\t\tname\t" << mName.c_str() << "|\n";
 	output_stream << "\t}\n";
 	return TRUE;
@@ -1629,38 +1629,6 @@ LLSD ll_create_sd_from_inventory_item(LLPointer<LLInventoryItem> item)
 	return rv;
 }
 
-/* deprecated, use LLInventoryItem::fromLLSD() instead
-LLPointer<LLInventoryItem> ll_create_item_from_sd(const LLSD& sd_item)
-{
-	LLPointer<LLInventoryItem> rv = new LLInventoryItem;
-	rv->setUUID(sd_item[INV_ITEM_ID_LABEL].asUUID());
-	rv->setParent(sd_item[INV_PARENT_ID_LABEL].asUUID());
-	rv->rename(sd_item[INV_NAME_LABEL].asString());
-	rv->setType(
-		LLAssetType::lookup(sd_item[INV_ASSET_TYPE_LABEL].asString()));
-	if (sd_item.has("shadow_id"))
-	{
-		LLUUID asset_id = sd_item["shadow_id"];
-		LLXORCipher cipher(MAGIC_ID.mData, UUID_BYTES);
-		cipher.decrypt(asset_id.mData, UUID_BYTES);
-		rv->setAssetUUID(asset_id);
-	}
-	if (sd_item.has(INV_ASSET_ID_LABEL))
-	{
-		rv->setAssetUUID(sd_item[INV_ASSET_ID_LABEL].asUUID());
-	}
-	rv->setDescription(sd_item[INV_DESC_LABEL].asString());
-	rv->setSaleInfo(ll_sale_info_from_sd(sd_item[INV_SALE_INFO_LABEL]));
-	rv->setPermissions(ll_permissions_from_sd(sd_item[INV_PERMISSIONS_LABEL]));
-	rv->setInventoryType(
-		LLInventoryType::lookup(
-			sd_item[INV_INVENTORY_TYPE_LABEL].asString()));
-	rv->setFlags((U32)(sd_item[INV_FLAGS_LABEL].asInteger()));
-	rv->setCreationDate(sd_item[INV_CREATION_DATE_LABEL].asInteger());
-	return rv;
-}
-*/
-
 LLSD ll_create_sd_from_inventory_category(LLPointer<LLInventoryCategory> cat)
 {
 	LLSD rv;
@@ -1675,10 +1643,10 @@ LLSD ll_create_sd_from_inventory_category(LLPointer<LLInventoryCategory> cat)
 	rv[INV_PARENT_ID_LABEL] = cat->getParentUUID();
 	rv[INV_NAME_LABEL] = cat->getName();
 	rv[INV_ASSET_TYPE_LABEL] = LLAssetType::lookup(cat->getType());
-	if(LLAssetType::lookupIsProtectedCategoryType(cat->getPreferredType()))
+	if(LLFolderType::lookupIsProtectedType(cat->getPreferredType()))
 	{
 		rv[INV_PREFERRED_TYPE_LABEL] =
-			LLAssetType::lookup(cat->getPreferredType());
+			LLFolderType::lookup(cat->getPreferredType()).c_str();
 	}
 	return rv;
 }
@@ -1692,7 +1660,7 @@ LLPointer<LLInventoryCategory> ll_create_category_from_sd(const LLSD& sd_cat)
 	rv->setType(
 		LLAssetType::lookup(sd_cat[INV_ASSET_TYPE_LABEL].asString()));
 	rv->setPreferredType(
-		LLAssetType::lookup(
-			sd_cat[INV_PREFERRED_TYPE_LABEL].asString()));
+			LLFolderType::lookup(
+				sd_cat[INV_PREFERRED_TYPE_LABEL].asString()));
 	return rv;
 }
diff --git a/indra/llinventory/llinventory.h b/indra/llinventory/llinventory.h
index bd581e860f..3de9d14f54 100644
--- a/indra/llinventory/llinventory.h
+++ b/indra/llinventory/llinventory.h
@@ -37,6 +37,7 @@
 
 #include "llassetstorage.h"
 #include "lldarray.h"
+#include "llfoldertype.h"
 #include "llinventorytype.h"
 #include "llmemtype.h"
 #include "llpermissions.h"
@@ -321,15 +322,15 @@ protected:
 public:
 	MEM_TYPE_NEW(LLMemType::MTYPE_INVENTORY);
 	LLInventoryCategory(const LLUUID& uuid, const LLUUID& parent_uuid,
-						LLAssetType::EType preferred_type,
+						LLFolderType::EType preferred_type,
 						const std::string& name);
 	LLInventoryCategory();
 	LLInventoryCategory(const LLInventoryCategory* other);
 	void copyCategory(const LLInventoryCategory* other); // LLRefCount requires custom copy
 
 	// accessors and mutators
-	LLAssetType::EType getPreferredType() const;
-	void setPreferredType(LLAssetType::EType type);
+	LLFolderType::EType getPreferredType() const;
+	void setPreferredType(LLFolderType::EType type);
 	// For messaging system support
 	virtual void packMessage(LLMessageSystem* msg) const;
 	virtual void unpackMessage(LLMessageSystem* msg, const char* block, S32 block_num = 0);
@@ -345,10 +346,8 @@ public:
 	virtual BOOL exportLegacyStream(std::ostream& output_stream, BOOL include_asset_key = TRUE) const;
 
 protected:
-	// The type of asset that this category was "meant" to hold
-	// (although it may in fact hold any type).
-	LLAssetType::EType	mPreferredType;		
-
+	// May be the type that this category was "meant" to hold (although it may hold any type).	
+	LLFolderType::EType	mPreferredType;		
 };
 
 
diff --git a/indra/llinventory/llinventorytype.cpp b/indra/llinventory/llinventorytype.cpp
index a445466b26..0e71c0d12d 100644
--- a/indra/llinventory/llinventorytype.cpp
+++ b/indra/llinventory/llinventorytype.cpp
@@ -79,24 +79,16 @@ LLInventoryDictionary::LLInventoryDictionary()
 	addEntry(LLInventoryType::IT_SOUND,               new InventoryEntry("sound",     "sound",         1, LLAssetType::AT_SOUND));
 	addEntry(LLInventoryType::IT_CALLINGCARD,         new InventoryEntry("callcard",  "calling card",  1, LLAssetType::AT_CALLINGCARD));
 	addEntry(LLInventoryType::IT_LANDMARK,            new InventoryEntry("landmark",  "landmark",      1, LLAssetType::AT_LANDMARK));
-	//addEntry(LLInventoryType::IT_SCRIPT,            new InventoryEntry(NULL,NULL));
-	//addEntry(LLInventoryType::IT_CLOTHING,          new InventoryEntry(NULL,NULL));
 	addEntry(LLInventoryType::IT_OBJECT,              new InventoryEntry("object",    "object",        1, LLAssetType::AT_OBJECT));
 	addEntry(LLInventoryType::IT_NOTECARD,            new InventoryEntry("notecard",  "note card",     1, LLAssetType::AT_NOTECARD));
 	addEntry(LLInventoryType::IT_CATEGORY,            new InventoryEntry("category",  "folder"         ));
 	addEntry(LLInventoryType::IT_ROOT_CATEGORY,       new InventoryEntry("root",      "root"           ));
 	addEntry(LLInventoryType::IT_LSL,                 new InventoryEntry("script",    "script",        2, LLAssetType::AT_LSL_TEXT, LLAssetType::AT_LSL_BYTECODE));
-	//addEntry(LLInventoryType::IT_LSL_BYTECODE,      new InventoryEntry(NULL,NULL));
-	//addEntry(LLInventoryType::IT_TEXTURE_TGA,       new InventoryEntry(NULL,NULL));
-	//addEntry(LLInventoryType::IT_BODYPART,          new InventoryEntry(NULL,NULL));
-	//addEntry(LLInventoryType::IT_TRASH,             new InventoryEntry(NULL,NULL));
 	addEntry(LLInventoryType::IT_SNAPSHOT,            new InventoryEntry("snapshot",  "snapshot",      1, LLAssetType::AT_TEXTURE));
-	//addEntry(LLInventoryType::IT_LOST_AND_FOUND,    new InventoryEntry(NULL,NULL, ));
 	addEntry(LLInventoryType::IT_ATTACHMENT,          new InventoryEntry("attach",    "attachment",    1, LLAssetType::AT_OBJECT));
 	addEntry(LLInventoryType::IT_WEARABLE,            new InventoryEntry("wearable",  "wearable",      2, LLAssetType::AT_CLOTHING, LLAssetType::AT_BODYPART));
 	addEntry(LLInventoryType::IT_ANIMATION,           new InventoryEntry("animation", "animation",     1, LLAssetType::AT_ANIMATION));  
 	addEntry(LLInventoryType::IT_GESTURE,             new InventoryEntry("gesture",   "gesture",       1, LLAssetType::AT_GESTURE)); 
-	addEntry(LLInventoryType::IT_FAVORITE,            new InventoryEntry("favorite",  "favorite",      1, LLAssetType::AT_FAVORITE)); 
 }
 
 
@@ -128,35 +120,9 @@ DEFAULT_ASSET_FOR_INV_TYPE[LLAssetType::AT_COUNT] =
 	LLInventoryType::IT_ANIMATION,		// AT_ANIMATION
 	LLInventoryType::IT_GESTURE,		// AT_GESTURE
 	LLInventoryType::IT_NONE,			// AT_SIMSTATE
-	LLInventoryType::IT_FAVORITE,		// AT_FAVORITE
 
 	LLInventoryType::IT_NONE,			// AT_LINK
 	LLInventoryType::IT_NONE,			// AT_LINK_FOLDER
-
-	LLInventoryType::IT_CATEGORY,		// AT_ENSEMBLE
-	LLInventoryType::IT_CATEGORY,		// AT_ENSEMBLE
-	LLInventoryType::IT_CATEGORY,		// AT_ENSEMBLE
-	LLInventoryType::IT_CATEGORY,		// AT_ENSEMBLE
-	LLInventoryType::IT_CATEGORY,		// AT_ENSEMBLE
-	LLInventoryType::IT_CATEGORY,		// AT_ENSEMBLE
-	LLInventoryType::IT_CATEGORY,		// AT_ENSEMBLE
-	LLInventoryType::IT_CATEGORY,		// AT_ENSEMBLE
-	LLInventoryType::IT_CATEGORY,		// AT_ENSEMBLE
-	LLInventoryType::IT_CATEGORY,		// AT_ENSEMBLE
-	LLInventoryType::IT_CATEGORY,		// AT_ENSEMBLE
-	LLInventoryType::IT_CATEGORY,		// AT_ENSEMBLE
-	LLInventoryType::IT_CATEGORY,		// AT_ENSEMBLE
-	LLInventoryType::IT_CATEGORY,		// AT_ENSEMBLE
-	LLInventoryType::IT_CATEGORY,		// AT_ENSEMBLE
-	LLInventoryType::IT_CATEGORY,		// AT_ENSEMBLE
-	LLInventoryType::IT_CATEGORY,		// AT_ENSEMBLE
-	LLInventoryType::IT_CATEGORY,		// AT_ENSEMBLE
-	LLInventoryType::IT_CATEGORY,		// AT_ENSEMBLE
-	LLInventoryType::IT_CATEGORY,		// AT_ENSEMBLE
-
-	LLInventoryType::IT_CATEGORY,		// AT_CURRENT_OUTFIT
-	LLInventoryType::IT_CATEGORY,		// AT_OUTFIT
-	LLInventoryType::IT_CATEGORY,		// AT_MY_OUTFITS
 };
 
 // static
diff --git a/indra/llinventory/llinventorytype.h b/indra/llinventory/llinventorytype.h
index 14b28bfe4b..e515b8a304 100644
--- a/indra/llinventory/llinventorytype.h
+++ b/indra/llinventory/llinventorytype.h
@@ -67,8 +67,7 @@ public:
 		IT_WEARABLE = 18,
 		IT_ANIMATION = 19,
 		IT_GESTURE = 20,
-		IT_FAVORITE = 21,
-		IT_COUNT = 22,
+		IT_COUNT = 21,
 
 		IT_NONE = -1
 	};
diff --git a/indra/llinventory/tests/inventorymisc_test.cpp b/indra/llinventory/tests/inventorymisc_test.cpp
index 770594dc9d..c797a70c50 100644
--- a/indra/llinventory/tests/inventorymisc_test.cpp
+++ b/indra/llinventory/tests/inventorymisc_test.cpp
@@ -94,7 +94,7 @@ LLPointer<LLInventoryCategory> create_random_inventory_cat()
 	LLPointer<LLInventoryCategory> cat = new LLInventoryCategory(
 		item_id,
 		parent_id,
-		LLAssetType::AT_NONE,
+		LLFolderType::FT_NONE,
 		std::string("Sample category"));
 	return cat;
 }
@@ -452,7 +452,7 @@ namespace tut
 		ensure_equals("4.type::getType() failed", dst->getType(), src->getType());
 		ensure_equals("5.preferred type::getPreferredType() failed", dst->getPreferredType(), src->getPreferredType());
 
-		src->setPreferredType( LLAssetType::AT_TEXTURE);
+		src->setPreferredType( LLFolderType::FT_TEXTURE);
 		sd = ll_create_sd_from_inventory_category(src);
 		dst = ll_create_category_from_sd(sd);
 		ensure_equals("6.preferred type::getPreferredType() failed", dst->getPreferredType(), src->getPreferredType());
diff --git a/indra/llmessage/lltransfersourceasset.cpp b/indra/llmessage/lltransfersourceasset.cpp
index 41f3f3f607..7332f5c954 100644
--- a/indra/llmessage/lltransfersourceasset.cpp
+++ b/indra/llmessage/lltransfersourceasset.cpp
@@ -292,7 +292,6 @@ bool is_asset_id_knowable(LLAssetType::EType type)
 		case LLAssetType::AT_BODYPART:
 		case LLAssetType::AT_ANIMATION:
 		case LLAssetType::AT_GESTURE:
-		case LLAssetType::AT_FAVORITE:
 		case LLAssetType::AT_LINK:
 		case LLAssetType::AT_LINK_FOLDER:
 			rv = true;
diff --git a/indra/llprimitive/llmediaentry.cpp b/indra/llprimitive/llmediaentry.cpp
index fa04bf80e7..701300163a 100644
--- a/indra/llprimitive/llmediaentry.cpp
+++ b/indra/llprimitive/llmediaentry.cpp
@@ -164,6 +164,7 @@ void LLMediaEntry::asLLSD(LLSD& sd) const
 
     // "security" fields
     sd[WHITELIST_ENABLE_KEY] = mWhiteListEnable;
+	sd.erase(WHITELIST_KEY);
     for (U32 i=0; i<mWhiteList.size(); i++) 
 	{
         sd[WHITELIST_KEY].append(mWhiteList[i]);
diff --git a/indra/llprimitive/tests/llmediaentry_test.cpp b/indra/llprimitive/tests/llmediaentry_test.cpp
index 9ce6560923..cd9608d56b 100644
--- a/indra/llprimitive/tests/llmediaentry_test.cpp
+++ b/indra/llprimitive/tests/llmediaentry_test.cpp
@@ -223,8 +223,7 @@ namespace tut
 	{
 		set_test_name("Test LLMediaEntry Instantiation");
 		LLMediaEntry entry;
-        ensure_llsd_equals(get_test_name(), defaultMediaEntryLLSD, entry.asLLSD());
-
+        ensure_llsd_equals(get_test_name() + " failed", defaultMediaEntryLLSD, entry.asLLSD());
 	}
 
 	template<> template<>
@@ -251,12 +250,27 @@ namespace tut
         ensure_llsd_equals(get_test_name() + " failed", golden, entry.asLLSD());
     }
 
+    template<> template<>
+    void object::test<4>()
+    {
+        set_test_name("Test LLMediaEntry::asLLSD()");
+        LLMediaEntry entry;
+        LLSD sd;
+		// Put some cruft in the LLSD
+        sd[LLMediaEntry::CURRENT_URL_KEY] = "http://www.example.com";
+		LLSD whitelist;
+		whitelist.append("*.example.com");
+        sd[LLMediaEntry::WHITELIST_KEY] = whitelist;
+        entry.asLLSD(sd);
+        ensure_llsd_equals(get_test_name() + " failed", defaultMediaEntryLLSD, sd);
+    }
+
     // limit tests
     const char *URL_OK = "http://www.example.com";
     const char *URL_TOO_BIG = "http://www.example.com.qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq";
 
     template<> template<>
-    void object::test<4>()
+    void object::test<5>()
     {
         set_test_name("Test Limits on setting current URL");
         LLMediaEntry entry;
@@ -267,7 +281,7 @@ namespace tut
     }    
 
     template<> template<>
-    void object::test<5>()
+    void object::test<6>()
     {
         set_test_name("Test Limits on setting home URL");
         LLMediaEntry entry;
@@ -278,7 +292,7 @@ namespace tut
     }
 
     template<> template<>
-    void object::test<6>()
+    void object::test<7>()
     {
         set_test_name("Test Limits on setting whitelist");
         
@@ -292,7 +306,7 @@ namespace tut
     }
 
     template<> template<>
-    void object::test<7>()
+    void object::test<8>()
     {
         set_test_name("Test Limits on setting whitelist too big");
         
@@ -307,7 +321,7 @@ namespace tut
     }
 
     template<> template<>
-    void object::test<8>()
+    void object::test<9>()
     {
         set_test_name("Test Limits on setting whitelist too many");
         
@@ -323,7 +337,7 @@ namespace tut
     }
 
     template<> template<>
-    void object::test<9>()
+    void object::test<10>()
     {
         set_test_name("Test to make sure both setWhiteList() functions behave the same");
         
@@ -341,7 +355,7 @@ namespace tut
     }
     
     template<> template<>
-    void object::test<10>()
+    void object::test<11>()
     {
         set_test_name("Test to make sure both setWhiteList() functions behave the same");
 
@@ -362,7 +376,7 @@ namespace tut
     }
 
     template<> template<>
-    void object::test<11>()
+    void object::test<12>()
     {
         set_test_name("Test to make sure both setWhiteList() functions behave the same");
 
@@ -386,99 +400,99 @@ namespace tut
     
     // Check the "empty whitelist" case
     template<> template<>
-    void object::test<12>() { whitelist_test("", "http://www.example.com", true); }
+    void object::test<13>() { whitelist_test("", "http://www.example.com", true); }
 
     // Check the "missing scheme" case
     template<> template<>
-    void object::test<13>() { whitelist_test("www.example.com", "http://www.example.com", true); }
+    void object::test<14>() { whitelist_test("www.example.com", "http://www.example.com", true); }
 
     // Check the "exactly the same" case
     template<> template<>
-    void object::test<14>() { whitelist_test("http://example.com", "http://example.com", true); }
+    void object::test<15>() { whitelist_test("http://example.com", "http://example.com", true); }
 
     // Check the enable flag
     template<> template<>
-    void object::test<15>() { whitelist_test(false, "www.example.com", "http://www.secondlife.com", true); }
+    void object::test<16>() { whitelist_test(false, "www.example.com", "http://www.secondlife.com", true); }
     template<> template<>
-    void object::test<16>() { whitelist_test(true, "www.example.com", "http://www.secondlife.com", false); }
+    void object::test<17>() { whitelist_test(true, "www.example.com", "http://www.secondlife.com", false); }
 
     // Check permutations of trailing slash:
     template<> template<>
-    void object::test<17>() { whitelist_test("http://www.example.com", "http://www.example.com/", true); }
+    void object::test<18>() { whitelist_test("http://www.example.com", "http://www.example.com/", true); }
     template<> template<>
-    void object::test<18>() { whitelist_test("http://www.example.com/", "http://www.example.com/", true); }
+    void object::test<19>() { whitelist_test("http://www.example.com/", "http://www.example.com/", true); }
     template<> template<>
-    void object::test<19>() { whitelist_test("http://www.example.com/", "http://www.example.com", false); }
+    void object::test<20>() { whitelist_test("http://www.example.com/", "http://www.example.com", false); }
     template<> template<>
-    void object::test<20>() { whitelist_test("http://www.example.com", "http://www.example.com/foobar", true); }
+    void object::test<21>() { whitelist_test("http://www.example.com", "http://www.example.com/foobar", true); }
     template<> template<>
-    void object::test<21>() { whitelist_test("http://www.example.com/", "http://www.example.com/foobar", false); }
+    void object::test<22>() { whitelist_test("http://www.example.com/", "http://www.example.com/foobar", false); }
 
     
     // More cases...
     template<> template<>
-    void object::test<22>() { whitelist_test("http://example.com", "http://example.com/wiki", true); }
+    void object::test<23>() { whitelist_test("http://example.com", "http://example.com/wiki", true); }
     template<> template<>
-    void object::test<23>() { whitelist_test("www.example.com", "http://www.example.com/help", true); }
+    void object::test<24>() { whitelist_test("www.example.com", "http://www.example.com/help", true); }
     template<> template<>
-    void object::test<24>() { whitelist_test("http://www.example.com", "http://wwwexample.com", false); }
+    void object::test<25>() { whitelist_test("http://www.example.com", "http://wwwexample.com", false); }
     template<> template<>
-    void object::test<25>() { whitelist_test("http://www.example.com", "http://www.example.com/wiki", true); }
+    void object::test<26>() { whitelist_test("http://www.example.com", "http://www.example.com/wiki", true); }
     template<> template<>
-    void object::test<26>() { whitelist_test("example.com", "http://wwwexample.com", false); }
+    void object::test<27>() { whitelist_test("example.com", "http://wwwexample.com", false); }
     template<> template<>
-    void object::test<27>() { whitelist_test("http://www.example.com/", "http://www.amazon.com/wiki", false); }
+    void object::test<28>() { whitelist_test("http://www.example.com/", "http://www.amazon.com/wiki", false); }
     template<> template<>
-    void object::test<28>() { whitelist_test("www.example.com", "http://www.amazon.com", false); }
+    void object::test<29>() { whitelist_test("www.example.com", "http://www.amazon.com", false); }
 
     // regexp cases
     template<> template<>
-    void object::test<29>() { whitelist_test("*.example.com", "http://www.example.com", true); }
+    void object::test<30>() { whitelist_test("*.example.com", "http://www.example.com", true); }
     template<> template<>
-    void object::test<30>() { whitelist_test("*.example.com", "http://www.amazon.com", false); }
+    void object::test<31>() { whitelist_test("*.example.com", "http://www.amazon.com", false); }
     template<> template<>
-    void object::test<31>() { whitelist_test("*.example.com", "http://www.example.com/foo/bar", true); }
+    void object::test<32>() { whitelist_test("*.example.com", "http://www.example.com/foo/bar", true); }
     template<> template<>
-    void object::test<32>() { whitelist_test("*.example.com", "http:/example.com/foo/bar", false); }
+    void object::test<33>() { whitelist_test("*.example.com", "http:/example.com/foo/bar", false); }
     template<> template<>
-    void object::test<33>() { whitelist_test("*example.com", "http://example.com/foo/bar", true); }
+    void object::test<34>() { whitelist_test("*example.com", "http://example.com/foo/bar", true); }
     template<> template<>
-    void object::test<34>() { whitelist_test("*example.com", "http://my.virus.com/foo/bar?example.com", false); }
+    void object::test<35>() { whitelist_test("*example.com", "http://my.virus.com/foo/bar?example.com", false); }
     template<> template<>
-    void object::test<35>() { whitelist_test("example.com", "http://my.virus.com/foo/bar?example.com", false); }
+    void object::test<36>() { whitelist_test("example.com", "http://my.virus.com/foo/bar?example.com", false); }
     template<> template<>
-    void object::test<36>() { whitelist_test("*example.com", "http://my.virus.com/foo/bar?*example.com", false); }
+    void object::test<37>() { whitelist_test("*example.com", "http://my.virus.com/foo/bar?*example.com", false); }
     template<> template<>
-    void object::test<37>() { whitelist_test("http://*example.com", "http://www.example.com", true); }
+    void object::test<38>() { whitelist_test("http://*example.com", "http://www.example.com", true); }
     template<> template<>
-    void object::test<38>() { whitelist_test("http://*.example.com", "http://www.example.com", true); }
+    void object::test<39>() { whitelist_test("http://*.example.com", "http://www.example.com", true); }
     template<> template<>
-    void object::test<39>() { whitelist_test("http://*.e$?^.com", "http://www.e$?^.com", true); }
+    void object::test<40>() { whitelist_test("http://*.e$?^.com", "http://www.e$?^.com", true); }
     template<> template<>
-    void object::test<40>() { whitelist_test("*.example.com/foo/bar", "http://www.example.com/", false); }
+    void object::test<41>() { whitelist_test("*.example.com/foo/bar", "http://www.example.com/", false); }
     template<> template<>
-    void object::test<41>() { whitelist_test("*.example.com/foo/bar", "http://example.com/foo/bar", false); }
+    void object::test<42>() { whitelist_test("*.example.com/foo/bar", "http://example.com/foo/bar", false); }
     template<> template<>
-    void object::test<42>() { whitelist_test("http://*.example.com/foo/bar", "http://www.example.com", false); }
+    void object::test<43>() { whitelist_test("http://*.example.com/foo/bar", "http://www.example.com", false); }
     template<> template<>
-    void object::test<43>() { whitelist_test("http://*.example.com", "https://www.example.com", false); }
+    void object::test<44>() { whitelist_test("http://*.example.com", "https://www.example.com", false); }
     template<> template<>
-    void object::test<44>() { whitelist_test("http*://*.example.com", "rtsp://www.example.com", false); }
+    void object::test<45>() { whitelist_test("http*://*.example.com", "rtsp://www.example.com", false); }
     template<> template<>
-    void object::test<45>() { whitelist_test("http*://*.example.com", "https://www.example.com", true); }
+    void object::test<46>() { whitelist_test("http*://*.example.com", "https://www.example.com", true); }
     template<> template<>
-    void object::test<46>() { whitelist_test("example.com", "http://www.example.com", false); }
+    void object::test<47>() { whitelist_test("example.com", "http://www.example.com", false); }
     template<> template<>
-    void object::test<47>() { whitelist_test("www.example.com", "http://www.example.com:80", false); }
+    void object::test<48>() { whitelist_test("www.example.com", "http://www.example.com:80", false); }
     template<> template<>
-    void object::test<48>() { whitelist_test("www.example.com", "http://www.example.com", true); }
+    void object::test<49>() { whitelist_test("www.example.com", "http://www.example.com", true); }
     template<> template<>
-    void object::test<49>() { whitelist_test("www.example.com/", "http://www.example.com", false); }
+    void object::test<50>() { whitelist_test("www.example.com/", "http://www.example.com", false); }
     template<> template<>
-    void object::test<50>() { whitelist_test("www.example.com/foo/bar/*", "http://www.example.com/foo/bar/baz", true); }
+    void object::test<51>() { whitelist_test("www.example.com/foo/bar/*", "http://www.example.com/foo/bar/baz", true); }
     // Path only
     template<> template<>
-    void object::test<51>() { whitelist_test("/foo/*/baz", "http://www.example.com/foo/bar/baz", true); }
+    void object::test<52>() { whitelist_test("/foo/*/baz", "http://www.example.com/foo/bar/baz", true); }
     template<> template<>
-    void object::test<52>() { whitelist_test("/foo/*/baz", "http://www.example.com/foo/bar/", false); }
+    void object::test<53>() { whitelist_test("/foo/*/baz", "http://www.example.com/foo/bar/", false); }
 }
diff --git a/indra/llui/llfloater.cpp b/indra/llui/llfloater.cpp
index 8c72b079ee..99aebbcb30 100644
--- a/indra/llui/llfloater.cpp
+++ b/indra/llui/llfloater.cpp
@@ -772,6 +772,12 @@ LLMultiFloater* LLFloater::getHost()
 	return (LLMultiFloater*)mHostHandle.get(); 
 }
 
+void    LLFloater::applySavedVariables()
+{
+	applyRectControl();
+	applyDockState();
+}
+
 void LLFloater::applyRectControl()
 {
 	if (mRectControl.size() > 1)
diff --git a/indra/llui/llfloater.h b/indra/llui/llfloater.h
index ef0d06a58e..95c8dd84f6 100644
--- a/indra/llui/llfloater.h
+++ b/indra/llui/llfloater.h
@@ -280,6 +280,9 @@ public:
 protected:
 
 	void			setRectControl(const std::string& rectname) { mRectControl = rectname; };
+
+	virtual void    applySavedVariables();
+
 	void			applyRectControl();
 	void			applyDockState();
 	void			storeRectControl();
diff --git a/indra/llui/llfloaterreg.cpp b/indra/llui/llfloaterreg.cpp
index aca4dc56ee..f8e07913fb 100644
--- a/indra/llui/llfloaterreg.cpp
+++ b/indra/llui/llfloaterreg.cpp
@@ -134,8 +134,7 @@ LLFloater* LLFloaterReg::getInstance(const std::string& name, const LLSD& key)
 				// Note: key should eventually be a non optional LLFloater arg; for now, set mKey to be safe
 				res->mKey = key;
 				res->setInstanceName(name);
-				res->applyRectControl(); // Can't apply rect control until setting instance name
-				res->applyDockState();//same...
+				res->applySavedVariables(); // Can't apply rect and dock state until setting instance name
 				if (res->mAutoTile && !res->getHost() && index > 0)
 				{
 					const LLRect& cur_rect = res->getRect();
diff --git a/indra/newview/CMakeLists.txt b/indra/newview/CMakeLists.txt
index e138b431c5..643f89068f 100644
--- a/indra/newview/CMakeLists.txt
+++ b/indra/newview/CMakeLists.txt
@@ -216,7 +216,6 @@ set(viewer_SOURCE_FILES
     llfloaterwhitelistentry.cpp
     llfloaterwindlight.cpp
     llfloaterworldmap.cpp
-    llfoldertype.cpp
     llfolderview.cpp
     llfolderviewitem.cpp
     llfollowcam.cpp
@@ -317,6 +316,7 @@ set(viewer_SOURCE_FILES
     llpanelimcontrolpanel.cpp
     llpanelland.cpp
     llpanellandaudio.cpp
+    llpanellandmarkinfo.cpp
     llpanellandmarks.cpp
     llpanellandmedia.cpp
     llpanellogin.cpp
@@ -337,6 +337,7 @@ set(viewer_SOURCE_FILES
     llpanelpicks.cpp
     llpanelplace.cpp
     llpanelplaceinfo.cpp
+    llpanelplaceprofile.cpp
     llpanelplaces.cpp
     llpanelplacestab.cpp
     llpanelprimmediacontrols.cpp
@@ -436,12 +437,14 @@ set(viewer_SOURCE_FILES
     llvectorperfoptions.cpp
     llviewchildren.cpp
     llviewerassetstorage.cpp
+    llviewerassettype.cpp
     llvieweraudio.cpp
     llviewercamera.cpp
     llviewercontrol.cpp
     llviewercontrollistener.cpp
     llviewerdisplay.cpp
     llviewerfloaterreg.cpp
+    llviewerfoldertype.cpp
     llviewergenericmessage.cpp
     llviewergesture.cpp    
     llviewerhelp.cpp
@@ -702,7 +705,6 @@ set(viewer_HEADER_FILES
     llfloaterwhitelistentry.h
     llfloaterwindlight.h
     llfloaterworldmap.h
-    llfoldertype.h
     llfolderview.h
     llfoldervieweventlistener.h
     llfolderviewitem.h
@@ -800,6 +802,7 @@ set(viewer_HEADER_FILES
     llpanelimcontrolpanel.h
     llpanelland.h
     llpanellandaudio.h
+    llpanellandmarkinfo.h
     llpanellandmarks.h
     llpanellandmedia.h
     llpanellogin.h
@@ -820,6 +823,7 @@ set(viewer_HEADER_FILES
     llpanelpicks.h
     llpanelplace.h
     llpanelplaceinfo.h
+    llpanelplaceprofile.h
     llpanelplaces.h
     llpanelplacestab.h
     llpanelprimmediacontrols.h
@@ -923,6 +927,7 @@ set(viewer_HEADER_FILES
     llvectorperfoptions.h
     llviewchildren.h
     llviewerassetstorage.h
+    llviewerassettype.h
     llvieweraudio.h
     llviewerbuild.h
     llviewercamera.h
@@ -930,6 +935,7 @@ set(viewer_HEADER_FILES
     llviewercontrollistener.h
     llviewerdisplay.h
     llviewerfloaterreg.h
+    llviewerfoldertype.h
     llviewergenericmessage.h
     llviewergesture.h    
     llviewerhelp.h
diff --git a/indra/newview/app_settings/foldertypes.xml b/indra/newview/app_settings/foldertypes.xml
index 2038779c4f..0d539177f3 100644
--- a/indra/newview/app_settings/foldertypes.xml
+++ b/indra/newview/app_settings/foldertypes.xml
@@ -1,66 +1,61 @@
 <?xml version="1.0" encoding="utf-8" standalone="yes"?>
 <ensemble_defs>
   <ensemble
-    asset_num="-1"
-    xui_name="default"
-    icon_name="inv_plain_closed.tga"
-     />
-  <ensemble
-    asset_num="27"
+    foldertype_num="27"
     xui_name="head"
     icon_name="inv_folder_outfit_head.tga"
 	allowed="hair,eyes"
      />
   <ensemble
-    asset_num="28"
+    foldertype_num="28"
     xui_name="gloves"
     icon_name="inv_folder_outfit_gloves.tga"
 	allowed="gloves"
      />
   <ensemble
-    asset_num="29"
+    foldertype_num="29"
     xui_name="jacket"
     icon_name="inv_folder_outfit_jacket.tga"
 	allowed="jacket"
      />
   <ensemble
-    asset_num="30"
+    foldertype_num="30"
     xui_name="pants"
     icon_name="inv_folder_outfit_pants.tga"
 	allowed="pants,underpants"
      />
   <ensemble
-    asset_num="31"
+    foldertype_num="31"
     xui_name="shape"
     icon_name="inv_folder_outfit_shape.tga"
 	allowed="shape,skin,hair,eyes"
      />
   <ensemble
-    asset_num="32"
+    foldertype_num="32"
     xui_name="shoes"
     icon_name="inv_folder_outfit_shoes.tga"
 	allowed="shoes,socks"
      />
   <ensemble
-    asset_num="33"
+    foldertype_num="33"
     xui_name="shirt"
     icon_name="inv_folder_outfit_shirt.tga"
 	allowed="shirt,undershirt"
      />
   <ensemble
-    asset_num="34"
+    foldertype_num="34"
     xui_name="skirt"
     icon_name="inv_folder_outfit_skirt.tga"
 	allowed=""
      />
   <ensemble
-    asset_num="35"
+    foldertype_num="35"
     xui_name="underpants"
     icon_name="inv_folder_outfit_underpants.tga"
 	allowed="underpants"
      />
   <ensemble
-    asset_num="36"
+    foldertype_num="36"
     xui_name="undershirt"
     icon_name="inv_folder_outfit_undershirt.tga"
 	allowed="undershirt"
diff --git a/indra/newview/llagentpicksinfo.cpp b/indra/newview/llagentpicksinfo.cpp
index 6e5835bace..3c8d0dac42 100644
--- a/indra/newview/llagentpicksinfo.cpp
+++ b/indra/newview/llagentpicksinfo.cpp
@@ -47,7 +47,8 @@ public:
 
 	~LLAgentPicksObserver()
 	{
-		LLAvatarPropertiesProcessor::getInstance()->removeObserver(gAgent.getID(), this);
+		if (LLAvatarPropertiesProcessor::instanceExists())
+			LLAvatarPropertiesProcessor::getInstance()->removeObserver(gAgent.getID(), this);
 	}
 
 	void sendAgentPicksRequest()
diff --git a/indra/newview/llagentui.cpp b/indra/newview/llagentui.cpp
index 09f7c49f23..2911a35581 100644
--- a/indra/newview/llagentui.cpp
+++ b/indra/newview/llagentui.cpp
@@ -92,7 +92,10 @@ std::string LLAgentUI::buildSLURL(const bool escaped /*= true*/)
 //static
 BOOL LLAgentUI::checkAgentDistance(const LLVector3& pole, F32 radius)
 {
-	return  (gAgent.getPositionAgent() - pole).length() < radius;
+	F32 delta_x = gAgent.getPositionAgent().mV[VX] - pole.mV[VX];
+	F32 delta_y = gAgent.getPositionAgent().mV[VY] - pole.mV[VY];
+	
+	return  sqrt( delta_x* delta_x + delta_y* delta_y ) < radius;
 }
 BOOL LLAgentUI::buildLocationString(std::string& str, ELocationFormat fmt,const LLVector3& agent_pos_region)
 {
diff --git a/indra/newview/llagentwearables.cpp b/indra/newview/llagentwearables.cpp
index 4b3d27767c..8c76a219a0 100644
--- a/indra/newview/llagentwearables.cpp
+++ b/indra/newview/llagentwearables.cpp
@@ -434,7 +434,7 @@ void LLAgentWearables::saveWearableAs(const EWearableType type,
 	if (save_in_lost_and_found)
 	{
 		category_id = gInventory.findCategoryUUIDForType(
-			LLAssetType::AT_LOST_AND_FOUND);
+			LLFolderType::FT_LOST_AND_FOUND);
 	}
 	else
 	{
@@ -840,7 +840,7 @@ void LLAgentWearables::processAgentInitialWearablesUpdate(LLMessageSystem* mesgs
 		}
 
 		// Get the UUID of the current outfit folder (will be created if it doesn't exist)
-		LLUUID current_outfit_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_CURRENT_OUTFIT);
+		const LLUUID current_outfit_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_CURRENT_OUTFIT);
 		
 		LLInitialWearablesFetch* outfit = new LLInitialWearablesFetch();
 		
@@ -981,8 +981,7 @@ void LLAgentWearables::recoverMissingWearable(const EWearableType type, U32 inde
 	// Add a new one in the lost and found folder.
 	// (We used to overwrite the "not found" one, but that could potentially
 	// destory content.) JC
-	LLUUID lost_and_found_id = 
-		gInventory.findCategoryUUIDForType(LLAssetType::AT_LOST_AND_FOUND);
+	const LLUUID lost_and_found_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_LOST_AND_FOUND);
 	LLPointer<LLInventoryCallback> cb =
 		new addWearableToAgentInventoryCallback(
 			LLPointer<LLRefCount>(NULL),
@@ -1123,8 +1122,8 @@ void LLAgentWearables::makeNewOutfit(const std::string& new_folder_name,
 
 	// First, make a folder in the Clothes directory.
 	LLUUID folder_id = gInventory.createNewCategory(
-		gInventory.findCategoryUUIDForType(LLAssetType::AT_CLOTHING),
-		LLAssetType::AT_NONE,
+		gInventory.findCategoryUUIDForType(LLFolderType::FT_CLOTHING),
+		LLFolderType::FT_NONE,
 		new_folder_name);
 
 	bool found_first_item = false;
@@ -1257,10 +1256,10 @@ LLUUID LLAgentWearables::makeNewOutfitLinks(const std::string& new_folder_name)
 	}
 
 	// First, make a folder in the My Outfits directory.
-	LLUUID parent_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_MY_OUTFITS);
+	const LLUUID parent_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_MY_OUTFITS);
 	LLUUID folder_id = gInventory.createNewCategory(
 		parent_id,
-		LLAssetType::AT_OUTFIT,
+		LLFolderType::FT_OUTFIT,
 		new_folder_name);
 
 	LLAppearanceManager::shallowCopyCategory(LLAppearanceManager::getCOF(),folder_id, NULL);
@@ -2032,7 +2031,7 @@ void LLInitialWearablesFetch::processWearablesMessage()
 {
 	if (!mAgentInitialWearables.empty()) // We have an empty current outfit folder, use the message data instead.
 	{
-		LLUUID current_outfit_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_CURRENT_OUTFIT);
+		const LLUUID current_outfit_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_CURRENT_OUTFIT);
 		for (U8 i = 0; i < mAgentInitialWearables.size(); ++i)
 		{
 			// Populate the current outfit folder with links to the wearables passed in the message
diff --git a/indra/newview/llappearancemgr.cpp b/indra/newview/llappearancemgr.cpp
index 8d0f11e021..80086de3dc 100644
--- a/indra/newview/llappearancemgr.cpp
+++ b/indra/newview/llappearancemgr.cpp
@@ -130,11 +130,11 @@ void LLOutfitObserver::done()
 			{
 				if(LLInventoryType::IT_GESTURE == item->getInventoryType())
 				{
-					pid = gInventory.findCategoryUUIDForType(LLAssetType::AT_GESTURE);
+					pid = gInventory.findCategoryUUIDForType(LLFolderType::FT_GESTURE);
 				}
 				else
 				{
-					pid = gInventory.findCategoryUUIDForType(LLAssetType::AT_CLOTHING);
+					pid = gInventory.findCategoryUUIDForType(LLFolderType::FT_CLOTHING);
 				}
 				break;
 			}
@@ -146,7 +146,7 @@ void LLOutfitObserver::done()
 		
 		LLUUID cat_id = gInventory.createNewCategory(
 			pid,
-			LLAssetType::AT_NONE,
+			LLFolderType::FT_NONE,
 			name);
 		mCatID = cat_id;
 		LLPointer<LLInventoryCallback> cb = new LLWearInventoryCategoryCallback(mCatID, mAppend);
@@ -353,7 +353,7 @@ void removeDuplicateItems(LLInventoryModel::item_array_t& dst, const LLInventory
 /* static */ 
 LLUUID LLAppearanceManager::getCOF()
 {
-	return gInventory.findCategoryUUIDForType(LLAssetType::AT_CURRENT_OUTFIT);
+	return gInventory.findCategoryUUIDForType(LLFolderType::FT_CURRENT_OUTFIT);
 }
 
 // Update appearance from outfit folder.
@@ -373,12 +373,12 @@ void LLAppearanceManager::changeOutfit(bool proceed, const LLUUID& category, boo
 	else
 	{
 		LLViewerInventoryCategory* catp = gInventory.getCategory(category);
-		if (catp->getPreferredType() == LLAssetType::AT_NONE ||
-			LLAssetType::lookupIsEnsembleCategoryType(catp->getPreferredType()))
+		if (catp->getPreferredType() == LLFolderType::FT_NONE ||
+			LLFolderType::lookupIsEnsembleType(catp->getPreferredType()))
 		{
 			updateCOFFromCategory(category, append);  // append is false - rebuild COF.
 		}
-		else if (catp->getPreferredType() == LLAssetType::AT_OUTFIT)
+		else if (catp->getPreferredType() == LLFolderType::FT_OUTFIT)
 		{
 			rebuildCOFFromOutfit(category);
 		}
@@ -405,7 +405,7 @@ void LLAppearanceManager::updateCOFFromCategory(const LLUUID& category, bool app
 		return;
 	}
 		
-	const LLUUID &current_outfit_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_CURRENT_OUTFIT);
+	const LLUUID current_outfit_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_CURRENT_OUTFIT);
 	// Processes that take time should show the busy cursor
 	//inc_busy_count();
 		
@@ -503,7 +503,7 @@ void LLAppearanceManager::shallowCopyCategory(const LLUUID& src_id, const LLUUID
 		{
 			LLViewerInventoryCategory *catp = item->getLinkedCategory();
 			// Skip copying outfit links.
-			if (catp && catp->getPreferredType() != LLAssetType::AT_OUTFIT)
+			if (catp && catp->getPreferredType() != LLFolderType::FT_OUTFIT)
 			{
 				link_inventory_item(gAgent.getID(),
 									item->getLinkedUUID(),
@@ -641,7 +641,7 @@ void LLAppearanceManager::shallowCopyCategory(const LLUUID& src_id, const LLUUID
 
 	// Add link to outfit if category is an outfit. 
 	LLViewerInventoryCategory* catp = gInventory.getCategory(category);
-	if (!append && catp && catp->getPreferredType() == LLAssetType::AT_OUTFIT)
+	if (!append && catp && catp->getPreferredType() == LLFolderType::FT_OUTFIT)
 	{
 		link_inventory_item(gAgent.getID(), category, cof, catp->getName(),
 							LLAssetType::AT_LINK_FOLDER, link_waiter);
@@ -732,7 +732,7 @@ void LLAppearanceManager::rebuildCOFFromOutfit(const LLUUID& category)
 		LLNotifications::instance().add("CouldNotPutOnOutfit");
 		return;
 	}
-		
+
 	// Processes that take time should show the busy cursor
 	//inc_busy_count();
 
@@ -750,7 +750,7 @@ void LLAppearanceManager::rebuildCOFFromOutfit(const LLUUID& category)
 
 	// Create a link to the outfit that we wore.
 	LLViewerInventoryCategory* catp = gInventory.getCategory(category);
-	if (catp && catp->getPreferredType() == LLAssetType::AT_OUTFIT)
+	if (catp && catp->getPreferredType() == LLFolderType::FT_OUTFIT)
 	{
 		link_inventory_item(gAgent.getID(), category, current_outfit_id, catp->getName(),
 							LLAssetType::AT_LINK_FOLDER, link_waiter);
diff --git a/indra/newview/llassetuploadresponders.cpp b/indra/newview/llassetuploadresponders.cpp
index 5dbf57c9be..d4df6dfbe7 100644
--- a/indra/newview/llassetuploadresponders.cpp
+++ b/indra/newview/llassetuploadresponders.cpp
@@ -334,7 +334,7 @@ void LLNewAgentInventoryResponder::uploadComplete(const LLSD& content)
 		LLAssetStorage::LLStoreAssetCallback callback = NULL;
 		void *userdata = NULL;
 		upload_new_resource(next_file, asset_name, asset_name,
-				    0, LLAssetType::AT_NONE, LLInventoryType::IT_NONE,
+				    0, LLFolderType::FT_NONE, LLInventoryType::IT_NONE,
 				    next_owner_perms, group_perms,
 				    everyone_perms, display_name,
 				    callback, expected_upload_cost, userdata);
diff --git a/indra/newview/llavataractions.cpp b/indra/newview/llavataractions.cpp
index 2f67401301..97e0aa5f46 100644
--- a/indra/newview/llavataractions.cpp
+++ b/indra/newview/llavataractions.cpp
@@ -343,7 +343,7 @@ bool LLAvatarActions::callbackAddFriend(const LLSD& notification, const LLSD& re
 		// Servers older than 1.25 require the text of the message to be the
 		// calling card folder ID for the offering user. JC
 		LLUUID calling_card_folder_id = 
-			gInventory.findCategoryUUIDForType(LLAssetType::AT_CALLINGCARD);
+			gInventory.findCategoryUUIDForType(LLFolderType::FT_CALLINGCARD);
 		std::string message = calling_card_folder_id.asString();
 		requestFriendship(notification["payload"]["id"].asUUID(), 
 		    notification["payload"]["name"].asString(),
@@ -355,7 +355,7 @@ bool LLAvatarActions::callbackAddFriend(const LLSD& notification, const LLSD& re
 // static
 void LLAvatarActions::requestFriendship(const LLUUID& target_id, const std::string& target_name, const std::string& message)
 {
-	LLUUID calling_card_folder_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_CALLINGCARD);
+	const LLUUID calling_card_folder_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_CALLINGCARD);
 	send_improved_im(target_id,
 					 target_name,
 					 message,
diff --git a/indra/newview/llavatarlist.cpp b/indra/newview/llavatarlist.cpp
index 7b2dc02864..8609ba8b1c 100644
--- a/indra/newview/llavatarlist.cpp
+++ b/indra/newview/llavatarlist.cpp
@@ -239,11 +239,46 @@ void LLAvatarList::refresh()
 	bool dirty = add_limit_exceeded || (have_filter && !have_names);
 	setDirty(dirty);
 
+	// Refreshed all items, lets send refresh_complete signal.
+	if(!dirty)
+	{
+		std::vector<LLSD> cur_values;
+		getValues(cur_values);
+		mRefreshCompleteSignal(this, LLSD((S32)cur_values.size()));
+	}
+
 	// Commit if we've added/removed items.
 	if (modified)
 		onCommit();
 }
 
+bool LLAvatarList::filterHasMatches()
+{
+	uuid_vector_t values = getIDs();
+
+	for (uuid_vector_t::const_iterator it=values.begin(); it != values.end(); it++)
+	{
+		std::string name;
+		const LLUUID& buddy_id = *it;
+		BOOL have_name = gCacheName->getFullName(buddy_id, name);
+
+		// If name has not been loaded yet we consider it as a match.
+		// When the name will be loaded the filter will be applied again(in refresh()).
+
+		if (have_name && !findInsensitive(name, mNameFilter))
+		{
+			continue;
+		}
+
+		return true;
+	}
+	return false;
+}
+
+boost::signals2::connection LLAvatarList::setRefreshCompleteCallback(const commit_signal_t::slot_type& cb)
+{
+	return mRefreshCompleteSignal.connect(cb);
+}
 
 void LLAvatarList::addNewItem(const LLUUID& id, const std::string& name, BOOL is_online, EAddPosition pos)
 {
diff --git a/indra/newview/llavatarlist.h b/indra/newview/llavatarlist.h
index 51d3760d39..195d9e5b55 100644
--- a/indra/newview/llavatarlist.h
+++ b/indra/newview/llavatarlist.h
@@ -82,6 +82,11 @@ public:
 	const std::string getIconParamName() const{return mIconParamName;}
 	virtual BOOL handleRightMouseDown(S32 x, S32 y, MASK mask);
 
+	// Return true if filter has at least one match.
+	bool filterHasMatches();
+
+	boost::signals2::connection setRefreshCompleteCallback(const commit_signal_t::slot_type& cb);
+
 protected:
 	void refresh();
 
@@ -107,6 +112,8 @@ private:
 	uuid_vector_t			mIDs;
 
 	LLAvatarListItem::ContextMenu* mContextMenu;
+
+	commit_signal_t mRefreshCompleteSignal;
 };
 
 /** Abstract comparator for avatar items */
diff --git a/indra/newview/llchiclet.cpp b/indra/newview/llchiclet.cpp
index bad61101c1..b9e8c5394d 100644
--- a/indra/newview/llchiclet.cpp
+++ b/indra/newview/llchiclet.cpp
@@ -51,7 +51,7 @@
 #include "lltransientfloatermgr.h"
 
 static LLDefaultChildRegistry::Register<LLChicletPanel> t1("chiclet_panel");
-static LLDefaultChildRegistry::Register<LLTalkButton> t2("chiclet_talk");
+static LLDefaultChildRegistry::Register<LLTalkButton> t2("talk_button");
 static LLDefaultChildRegistry::Register<LLNotificationChiclet> t3("chiclet_notification");
 static LLDefaultChildRegistry::Register<LLIMP2PChiclet> t4("chiclet_im_p2p");
 static LLDefaultChildRegistry::Register<LLIMGroupChiclet> t5("chiclet_im_group");
@@ -830,13 +830,21 @@ LLChicletPanel::~LLChicletPanel()
 void im_chiclet_callback(LLChicletPanel* panel, const LLSD& data){
 	
 	LLUUID session_id = data["session_id"].asUUID();
+	S32 unread = data["num_unread"].asInteger();
+
+	LLIMFloater* im_floater = LLIMFloater::findInstance(session_id);
+	if (im_floater && im_floater->getVisible())
+	{
+		unread = 0;
+	}
+
 	std::list<LLChiclet*> chiclets = LLIMChiclet::sFindChicletsSignal(session_id);
 	std::list<LLChiclet *>::iterator iter;
 	for (iter = chiclets.begin(); iter != chiclets.end(); iter++) {
 		LLChiclet* chiclet = *iter;
 		if (chiclet != NULL)
 		{
-			chiclet->setCounter(data["num_unread"].asInteger());
+			chiclet->setCounter(unread);
 		}
 	    else
 	    {
@@ -1257,30 +1265,7 @@ LLTalkButton::Params::Params()
  , show_button("show_button")
  , monitor("monitor")
 {
-	// *TODO Vadim: move hardcoded labels (!) and other params to XUI.
-	speak_button.name("left");
-	speak_button.label("Speak");
-	speak_button.label_selected("Speak");
-	speak_button.font(LLFontGL::getFontSansSerifSmall());
-	speak_button.tab_stop(false);
-	speak_button.is_toggle(true);
-	speak_button.picture_style(true);
-	// Use default button art. JC
-	//speak_button.image_selected(LLUI::getUIImage("SegmentedBtn_Left_Selected"));
-	//speak_button.image_unselected(LLUI::getUIImage("SegmentedBtn_Left_Off"));
-
-	show_button.name("right");
-	show_button.label(LLStringUtil::null);
-	show_button.rect(LLRect(0, 0, 20, 0));
-	show_button.tab_stop(false);
-	show_button.is_toggle(true);
-	show_button.picture_style(true);
-	show_button.image_selected(LLUI::getUIImage("ComboButton_Selected"));
-	show_button.image_unselected(LLUI::getUIImage("ComboButton_Off"));
-
-	monitor.name("monitor");
-	// *TODO: Make this data driven.
-	monitor.rect(LLRect(0, 18, 18, 0));
+	// See widgets/talk_button.xml
 }
 
 LLTalkButton::LLTalkButton(const Params& p)
@@ -1336,6 +1321,7 @@ LLTalkButton::LLTalkButton(const Params& p)
 
 	// never show "muted" because you can't mute yourself
 	mOutputMonitor->setIsMuted(false);
+	mOutputMonitor->setIsAgentControl(true);
 }
 
 LLTalkButton::~LLTalkButton()
diff --git a/indra/newview/llfavoritesbar.cpp b/indra/newview/llfavoritesbar.cpp
index a6afbc05be..a3980457b9 100644
--- a/indra/newview/llfavoritesbar.cpp
+++ b/indra/newview/llfavoritesbar.cpp
@@ -437,7 +437,7 @@ BOOL LLFavoritesBarCtrl::handleDragAndDrop(S32 x, S32 y, MASK mask, BOOL drop,
 			}
 			else
 			{
-				LLUUID favorites_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_FAVORITE);
+				const LLUUID favorites_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_FAVORITE);
 				if (item->getParentUUID() == favorites_id)
 				{
 					llwarns << "Attemt to copy a favorite item into the same folder." << llendl;
@@ -539,7 +539,7 @@ void LLFavoritesBarCtrl::handleNewFavoriteDragAndDrop(LLInventoryItem *item, con
 	LLToolDragAndDrop* tool_dad = LLToolDragAndDrop::getInstance();
 	if (tool_dad->getSource() == LLToolDragAndDrop::SOURCE_NOTECARD)
 	{
-		viewer_item->setType(LLAssetType::AT_FAVORITE);
+		viewer_item->setType(LLAssetType::AT_LANDMARK);
 		copy_inventory_from_notecard(tool_dad->getObjectID(), tool_dad->getSourceID(), viewer_item.get(), gInventoryCallbacks.registerCB(cb));
 	}
 	else
@@ -561,7 +561,7 @@ void LLFavoritesBarCtrl::changed(U32 mask)
 {
 	if (mFavoriteFolderId.isNull())
 	{
-		mFavoriteFolderId = gInventory.findCategoryUUIDForType(LLAssetType::AT_FAVORITE);
+		mFavoriteFolderId = gInventory.findCategoryUUIDForType(LLFolderType::FT_FAVORITE);
 		
 		if (mFavoriteFolderId.notNull())
 		{
diff --git a/indra/newview/llfloateranimpreview.cpp b/indra/newview/llfloateranimpreview.cpp
index 55b7ed0c99..095fe0a220 100644
--- a/indra/newview/llfloateranimpreview.cpp
+++ b/indra/newview/llfloateranimpreview.cpp
@@ -989,7 +989,7 @@ void LLFloaterAnimPreview::onBtnOK(void* userdata)
 						    name,
 						    desc,
 						    0,
-						    LLAssetType::AT_NONE,
+						    LLFolderType::FT_NONE,
 						    LLInventoryType::IT_ANIMATION,
 						    LLFloaterPerms::getNextOwnerPerms(), LLFloaterPerms::getGroupPerms(), LLFloaterPerms::getEveryonePerms(),
 						    name,
diff --git a/indra/newview/llfloaterbulkpermission.cpp b/indra/newview/llfloaterbulkpermission.cpp
index 7cb8987879..538b44c056 100644
--- a/indra/newview/llfloaterbulkpermission.cpp
+++ b/indra/newview/llfloaterbulkpermission.cpp
@@ -264,7 +264,6 @@ void LLFloaterBulkPermission::handleInventory(LLViewerObject* viewer_obj, Invent
 			( asstype == LLAssetType::AT_BODYPART  && gSavedSettings.getBOOL("BulkChangeIncludeBodyParts" )) ||
 			( asstype == LLAssetType::AT_CLOTHING  && gSavedSettings.getBOOL("BulkChangeIncludeClothing"  )) ||
 			( asstype == LLAssetType::AT_GESTURE   && gSavedSettings.getBOOL("BulkChangeIncludeGestures"  )) ||
-			( asstype == LLAssetType::AT_FAVORITE  && gSavedSettings.getBOOL("BulkChangeIncludeFavourite" )) ||
 			( asstype == LLAssetType::AT_NOTECARD  && gSavedSettings.getBOOL("BulkChangeIncludeNotecards" )) ||
 			( asstype == LLAssetType::AT_OBJECT    && gSavedSettings.getBOOL("BulkChangeIncludeObjects"   )) ||
 			( asstype == LLAssetType::AT_LSL_TEXT  && gSavedSettings.getBOOL("BulkChangeIncludeScripts"   )) ||
diff --git a/indra/newview/llfloaterbuy.cpp b/indra/newview/llfloaterbuy.cpp
index 3da06fa7b3..cefd7a3808 100644
--- a/indra/newview/llfloaterbuy.cpp
+++ b/indra/newview/llfloaterbuy.cpp
@@ -293,7 +293,7 @@ void LLFloaterBuy::onClickBuy()
 {
 	// Put the items where we put new folders.
 	LLUUID category_id;
-	category_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_OBJECT);
+	category_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_OBJECT);
 
 	// *NOTE: doesn't work for multiple object buy, which UI does not
 	// currently support sale info is used for verification only, if
diff --git a/indra/newview/llfloaterbuycontents.cpp b/indra/newview/llfloaterbuycontents.cpp
index f3eaa0c916..32802f6a20 100644
--- a/indra/newview/llfloaterbuycontents.cpp
+++ b/indra/newview/llfloaterbuycontents.cpp
@@ -286,7 +286,7 @@ void LLFloaterBuyContents::onClickBuy()
 
 	// Put the items where we put new folders.
 	LLUUID category_id;
-	category_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_CATEGORY);
+	category_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_CATEGORY);
 
 	// *NOTE: doesn't work for multiple object buy, which UI does not
 	// currently support sale info is used for verification only, if
diff --git a/indra/newview/llfloaterinventory.cpp b/indra/newview/llfloaterinventory.cpp
index 8570b5eb4a..92778510e7 100644
--- a/indra/newview/llfloaterinventory.cpp
+++ b/indra/newview/llfloaterinventory.cpp
@@ -40,6 +40,7 @@
 #include "llinventorymodel.h"
 #include "llpanelmaininventory.h"
 #include "llresmgr.h"
+#include "llviewerfoldertype.h"
 
 ///----------------------------------------------------------------------------
 /// LLFloaterInventory
diff --git a/indra/newview/llfloaterinventory.h b/indra/newview/llfloaterinventory.h
index f2f2963a33..c0de89bff2 100644
--- a/indra/newview/llfloaterinventory.h
+++ b/indra/newview/llfloaterinventory.h
@@ -35,6 +35,7 @@
 #define LL_LLFLOATERINVENTORY_H
 
 #include "llfloater.h"
+#include "llfoldertype.h"
 
 class LLInventoryPanel;
 class LLPanelMainInventory;
diff --git a/indra/newview/llfloaternamedesc.cpp b/indra/newview/llfloaternamedesc.cpp
index ed7d2c71ea..b7296518d4 100644
--- a/indra/newview/llfloaternamedesc.cpp
+++ b/indra/newview/llfloaternamedesc.cpp
@@ -176,7 +176,7 @@ void LLFloaterNameDesc::onBtnOK( )
 	upload_new_resource(mFilenameAndPath, // file
 			    childGetValue("name_form").asString(), 
 			    childGetValue("description_form").asString(), 
-			    0, LLAssetType::AT_NONE, LLInventoryType::IT_NONE,
+			    0, LLFolderType::FT_NONE, LLInventoryType::IT_NONE,
 			    LLFloaterPerms::getNextOwnerPerms(), LLFloaterPerms::getGroupPerms(), LLFloaterPerms::getEveryonePerms(),
 			    display_name, callback, expected_upload_cost, nruserdata);
 	closeFloater(false);
diff --git a/indra/newview/llfloateropenobject.cpp b/indra/newview/llfloateropenobject.cpp
index b6ec0868cf..e277aba493 100644
--- a/indra/newview/llfloateropenobject.cpp
+++ b/indra/newview/llfloateropenobject.cpp
@@ -158,14 +158,14 @@ void LLFloaterOpenObject::moveToInventory(bool wear)
 	if (wear)
 	{
 		parent_category_id = gInventory.findCategoryUUIDForType(
-			LLAssetType::AT_CLOTHING);
+			LLFolderType::FT_CLOTHING);
 	}
 	else
 	{
 		parent_category_id = gInventory.getRootFolderID();
 	}
 	LLUUID category_id = gInventory.createNewCategory(parent_category_id, 
-		LLAssetType::AT_NONE, 
+		LLFolderType::FT_NONE, 
 		name);
 
 	LLCatAndWear* data = new LLCatAndWear;
diff --git a/indra/newview/llfloaterreporter.cpp b/indra/newview/llfloaterreporter.cpp
index ad2fe34e95..0f4d6e33a3 100644
--- a/indra/newview/llfloaterreporter.cpp
+++ b/indra/newview/llfloaterreporter.cpp
@@ -770,7 +770,7 @@ void LLFloaterReporter::takeScreenshot()
 	if (COMPLAINT_REPORT == mReportType)
 	{
 		mResourceDatap->mAssetInfo.mType = LLAssetType::AT_TEXTURE;
-		mResourceDatap->mPreferredLocation = LLAssetType::EType(-2);
+		mResourceDatap->mPreferredLocation = LLFolderType::EType(LLResourceData::INVALID_LOCATION);
 	}
 	else
 	{
@@ -838,7 +838,7 @@ void LLFloaterReporter::uploadDoneCallback(const LLUUID &uuid, void *user_data,
 	}
 
 	EReportType report_type = UNKNOWN_REPORT;
-	if (data->mPreferredLocation == -2)
+	if (data->mPreferredLocation == LLResourceData::INVALID_LOCATION)
 	{
 		report_type = COMPLAINT_REPORT;
 	}
diff --git a/indra/newview/llfloatersnapshot.cpp b/indra/newview/llfloatersnapshot.cpp
index 235e819218..541e2a2664 100644
--- a/indra/newview/llfloatersnapshot.cpp
+++ b/indra/newview/llfloatersnapshot.cpp
@@ -980,7 +980,7 @@ void LLSnapshotLivePreview::saveTexture()
 				    "Snapshot : " + pos_string,
 				    "Taken by " + who_took_it + " at " + pos_string,
 				    0,
-				    LLAssetType::AT_SNAPSHOT_CATEGORY,
+				    LLFolderType::FT_SNAPSHOT_CATEGORY,
 				    LLInventoryType::IT_SNAPSHOT,
 				    PERM_ALL,  // Note: Snapshots to inventory is a special case of content upload
 				    PERM_NONE, // that ignores the user's premissions preferences and continues to
diff --git a/indra/newview/llfloaterworldmap.cpp b/indra/newview/llfloaterworldmap.cpp
index f3f600149f..6567c1a649 100644
--- a/indra/newview/llfloaterworldmap.cpp
+++ b/indra/newview/llfloaterworldmap.cpp
@@ -327,7 +327,7 @@ void LLFloaterWorldMap::onOpen(const LLSD& key)
 		LLFirstUse::useMap();
 
 		// Start speculative download of landmarks
-		LLUUID landmark_folder_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_LANDMARK);
+		const LLUUID landmark_folder_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_LANDMARK);
 		gInventory.startBackgroundFetch(landmark_folder_id);
 
 		childSetFocus("location", TRUE);
diff --git a/indra/newview/llfolderview.cpp b/indra/newview/llfolderview.cpp
index a963c96da4..7863c373c6 100644
--- a/indra/newview/llfolderview.cpp
+++ b/indra/newview/llfolderview.cpp
@@ -55,6 +55,7 @@
 #include "llviewermenu.h"
 #include "lluictrlfactory.h"
 #include "llviewercontrol.h"
+#include "llviewerfoldertype.h"
 #include "llviewerwindow.h"
 #include "llvoavatar.h"
 #include "llfloaterproperties.h"
@@ -1108,7 +1109,7 @@ void LLFolderView::propertiesSelectedItems( void )
 	}
 }
 
-void LLFolderView::changeType(LLInventoryModel *model, LLAssetType::EType new_folder_type)
+void LLFolderView::changeType(LLInventoryModel *model, LLFolderType::EType new_folder_type)
 {
 	LLFolderBridge *folder_bridge = LLFolderBridge::sSelf;
 
@@ -1958,7 +1959,7 @@ bool LLFolderView::doToSelected(LLInventoryModel* model, const LLSD& userdata)
 	if (action.length() > change_folder_string.length() && 
 		(action.compare(0,change_folder_string.length(),"change_folder_type_") == 0))
 	{
-		LLAssetType::EType new_folder_type = LLFolderType::lookupTypeFromXUIName(action.substr(change_folder_string.length()));
+		LLFolderType::EType new_folder_type = LLViewerFolderType::lookupTypeFromXUIName(action.substr(change_folder_string.length()));
 		changeType(model, new_folder_type);
 		return true;
 	}
diff --git a/indra/newview/llfolderview.h b/indra/newview/llfolderview.h
index ebfb4efde2..0bd65b5f90 100644
--- a/indra/newview/llfolderview.h
+++ b/indra/newview/llfolderview.h
@@ -192,7 +192,7 @@ public:
 	void propertiesSelectedItems( void );
 
 	// change the folder type
-	void changeType(LLInventoryModel *model, LLAssetType::EType new_folder_type);
+	void changeType(LLInventoryModel *model, LLFolderType::EType new_folder_type);
 
 	void autoOpenItem(LLFolderViewFolder* item);
 	void closeAutoOpenedFolders();
diff --git a/indra/newview/llfoldervieweventlistener.h b/indra/newview/llfoldervieweventlistener.h
index ff38da279a..60ece75cea 100644
--- a/indra/newview/llfoldervieweventlistener.h
+++ b/indra/newview/llfoldervieweventlistener.h
@@ -32,6 +32,7 @@
 #define LLFOLDERVIEWEVENTLISTENER_H
 
 #include "lldarray.h"	// JAMESDEBUG convert to std::vector
+#include "llfoldertype.h"
 #include "llfontgl.h"	// just for StyleFlags enum
 #include "llpointer.h"
 
@@ -57,7 +58,7 @@ public:
 	virtual const LLUUID& getUUID() const = 0;
 	virtual time_t getCreationDate() const = 0;	// UTC seconds
 	virtual PermissionMask getPermissionMask() const = 0;
-	virtual LLAssetType::EType getPreferredType() const = 0;
+	virtual LLFolderType::EType getPreferredType() const = 0;
 	virtual LLPointer<LLUIImage> getIcon() const = 0;
 	virtual LLFontGL::StyleFlags getLabelStyle() const = 0;
 	virtual std::string getLabelSuffix() const = 0;
diff --git a/indra/newview/llfolderviewitem.cpp b/indra/newview/llfolderviewitem.cpp
index f83a426cda..6fdaefd21a 100644
--- a/indra/newview/llfolderviewitem.cpp
+++ b/indra/newview/llfolderviewitem.cpp
@@ -248,13 +248,13 @@ void LLFolderViewItem::refreshFromListener()
 	if(mListener)
 	{
 		mLabel = mListener->getDisplayName();
-		LLAssetType::EType preferred_type = mListener->getPreferredType();
+		LLFolderType::EType preferred_type = mListener->getPreferredType();
 
 		// *TODO: to be removed when database supports multi language. This is a
 		// temporary attempt to display the inventory folder in the user locale.
 		// mantipov: *NOTE: be sure this code is synchronized with LLFriendCardsManager::findChildFolderUUID
 		//		it uses the same way to find localized string
-		if (LLAssetType::lookupIsProtectedCategoryType(preferred_type))
+		if (LLFolderType::lookupIsProtectedType(preferred_type))
 		{
 			LLTrans::findString(mLabel, "InvFolder " + mLabel);
 		};
@@ -1753,7 +1753,7 @@ bool LLFolderViewFolder::isTrash() const
 {
 	if (mAmTrash == LLFolderViewFolder::UNKNOWN)
 	{
-		mAmTrash = mListener->getUUID() == gInventory.findCategoryUUIDForType(LLAssetType::AT_TRASH, false) ? LLFolderViewFolder::TRASH : LLFolderViewFolder::NOT_TRASH;
+		mAmTrash = mListener->getUUID() == gInventory.findCategoryUUIDForType(LLFolderType::FT_TRASH, false) ? LLFolderViewFolder::TRASH : LLFolderViewFolder::NOT_TRASH;
 	}
 	return mAmTrash == LLFolderViewFolder::TRASH;
 }
@@ -2167,7 +2167,7 @@ BOOL LLFolderViewFolder::handleDoubleClick( S32 x, S32 y, MASK mask )
 {
 	const LLUUID &cat_uuid = getListener()->getUUID();
 	const LLViewerInventoryCategory *cat = gInventory.getCategory(cat_uuid);
-	if (cat && cat->getPreferredType() == LLAssetType::AT_OUTFIT)
+	if (cat && cat->getPreferredType() == LLFolderType::FT_OUTFIT)
 	{
 		getListener()->performAction(NULL, NULL,"replaceoutfit");
 		return TRUE;
@@ -2490,7 +2490,7 @@ bool LLInventorySort::operator()(const LLFolderViewItem* const& a, const LLFolde
 		&& b->getListener()->getInventoryType() == LLInventoryType::IT_LANDMARK)
 	{
 
-		static LLUUID favorites_folder_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_FAVORITE);
+		static const LLUUID& favorites_folder_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_FAVORITE);
 
 		LLUUID a_uuid = a->getParentFolder()->getListener()->getUUID();
 		LLUUID b_uuid = b->getParentFolder()->getListener()->getUUID();
diff --git a/indra/newview/llfriendcard.cpp b/indra/newview/llfriendcard.cpp
index fbcaeee01f..5f79fe8b20 100644
--- a/indra/newview/llfriendcard.cpp
+++ b/indra/newview/llfriendcard.cpp
@@ -135,14 +135,14 @@ const LLUUID LLFriendCardsManager::extractAvatarID(const LLUUID& avatarID)
 // and this method must be called before any actions with friend list
 void LLFriendCardsManager::ensureFriendFoldersExist()
 {
-	LLUUID callingCardsFolderID = gInventory.findCategoryUUIDForType(LLAssetType::AT_CALLINGCARD);
+	const LLUUID callingCardsFolderID = gInventory.findCategoryUUIDForType(LLFolderType::FT_CALLINGCARD);
 
 	LLUUID friendFolderUUID = findFriendFolderUUIDImpl();
 
 	if (friendFolderUUID.isNull())
 	{
 		friendFolderUUID = gInventory.createNewCategory(callingCardsFolderID,
-			LLAssetType::AT_CALLINGCARD, get_friend_folder_name());
+			LLFolderType::FT_CALLINGCARD, get_friend_folder_name());
 	}
 
 	LLUUID friendAllSubfolderUUID = findFriendAllSubfolderUUIDImpl();
@@ -150,7 +150,7 @@ void LLFriendCardsManager::ensureFriendFoldersExist()
 	if (friendAllSubfolderUUID.isNull())
 	{
 		friendAllSubfolderUUID = gInventory.createNewCategory(friendFolderUUID,
-			LLAssetType::AT_CALLINGCARD, get_friend_all_subfolder_name());
+			LLFolderType::FT_CALLINGCARD, get_friend_all_subfolder_name());
 	}
 }
 
@@ -351,7 +351,7 @@ void LLFriendCardsManager::collectFriendsLists(folderid_buddies_map_t& folderBud
 /************************************************************************/
 const LLUUID& LLFriendCardsManager::findFriendFolderUUIDImpl() const
 {
-	LLUUID callingCardsFolderID = gInventory.findCategoryUUIDForType(LLAssetType::AT_CALLINGCARD);
+	const LLUUID callingCardsFolderID = gInventory.findCategoryUUIDForType(LLFolderType::FT_CALLINGCARD);
 
 	std::string friendFolderName = get_friend_folder_name();
 
diff --git a/indra/newview/llimfloater.cpp b/indra/newview/llimfloater.cpp
index dee86f4a22..19fa66fd0e 100644
--- a/indra/newview/llimfloater.cpp
+++ b/indra/newview/llimfloater.cpp
@@ -106,6 +106,8 @@ void LLIMFloater::onFocusReceived()
 // virtual
 void LLIMFloater::onClose(bool app_quitting)
 {
+	if (!gIMMgr->hasSession(mSessionID)) return;
+	
 	setTyping(false);
 	gIMMgr->leaveSession(mSessionID);
 }
@@ -234,7 +236,10 @@ BOOL LLIMFloater::postBuild()
 	
 	mChatHistory = getChild<LLChatHistory>("chat_history");
 		
-	setTitle(LLIMModel::instance().getName(mSessionID));
+	std::string session_name(LLIMModel::instance().getName(mSessionID));
+	LLStringUtil::toUpper(session_name);
+	setTitle(session_name);
+
 	setDocked(true);
 
 	mTypingStart = LLTrans::getString("IM_typing_start_string");
diff --git a/indra/newview/llinspectavatar.cpp b/indra/newview/llinspectavatar.cpp
index bfad2b1624..9989a3b473 100644
--- a/indra/newview/llinspectavatar.cpp
+++ b/indra/newview/llinspectavatar.cpp
@@ -188,7 +188,8 @@ LLInspectAvatar::LLInspectAvatar(const LLSD& sd)
 {
 	mCommitCallbackRegistrar.add("InspectAvatar.ViewProfile",	boost::bind(&LLInspectAvatar::onClickViewProfile, this));	
 	mCommitCallbackRegistrar.add("InspectAvatar.AddFriend",	boost::bind(&LLInspectAvatar::onClickAddFriend, this));	
-	mCommitCallbackRegistrar.add("InspectAvatar.IM",	boost::bind(&LLInspectAvatar::onClickIM, this));	
+	mCommitCallbackRegistrar.add("InspectAvatar.IM",
+		boost::bind(&LLInspectAvatar::onClickIM, this));	
 	mCommitCallbackRegistrar.add("InspectAvatar.Teleport",	boost::bind(&LLInspectAvatar::onClickTeleport, this));	
 	mCommitCallbackRegistrar.add("InspectAvatar.InviteToGroup",	boost::bind(&LLInspectAvatar::onClickInviteToGroup, this));	
 	mCommitCallbackRegistrar.add("InspectAvatar.Pay",	boost::bind(&LLInspectAvatar::onClickPay, this));	
@@ -306,7 +307,21 @@ void LLInspectAvatar::requestUpdate()
 	// You can't re-add someone as a friend if they are already your friend
 	bool is_friend = LLAvatarTracker::instance().getBuddyInfo(mAvatarID) != NULL;
 	bool is_self = (mAvatarID == gAgentID);
-	childSetEnabled("add_friend_btn", !is_friend && !is_self);
+	if (is_self)
+	{
+		getChild<LLUICtrl>("add_friend_btn")->setVisible(false);
+		getChild<LLUICtrl>("im_btn")->setVisible(false);
+	}
+	else if (is_friend)
+	{
+		getChild<LLUICtrl>("add_friend_btn")->setVisible(false);
+		getChild<LLUICtrl>("im_btn")->setVisible(true);
+	}
+	else
+	{
+		getChild<LLUICtrl>("add_friend_btn")->setVisible(true);
+		getChild<LLUICtrl>("im_btn")->setVisible(false);
+	}
 
 	// Use an avatar_icon even though the image id will come down with the
 	// avatar properties because the avatar_icon code maintains a cache of icons
diff --git a/indra/newview/llinventorybridge.cpp b/indra/newview/llinventorybridge.cpp
index b9775cf0e9..b9a25d5dc7 100644
--- a/indra/newview/llinventorybridge.cpp
+++ b/indra/newview/llinventorybridge.cpp
@@ -78,6 +78,7 @@
 #include "llscrollcontainer.h"
 #include "llimview.h"
 #include "lltooldraganddrop.h"
+#include "llviewerfoldertype.h"
 #include "llviewertexturelist.h"
 #include "llviewerinventory.h"
 #include "llviewerobjectlist.h"
@@ -85,6 +86,7 @@
 #include "llvoavatar.h"
 #include "llwearable.h"
 #include "llwearablelist.h"
+#include "llviewerassettype.h"
 #include "llviewermessage.h"
 #include "llviewerregion.h"
 #include "llvoavatarself.h"
@@ -202,9 +204,9 @@ PermissionMask LLInvFVBridge::getPermissionMask() const
 }
 
 // virtual
-LLAssetType::EType LLInvFVBridge::getPreferredType() const
+LLFolderType::EType LLInvFVBridge::getPreferredType() const
 {
-	return LLAssetType::AT_NONE;
+	return LLFolderType::FT_NONE;
 }
 
 
@@ -339,7 +341,7 @@ void LLInvFVBridge::removeBatchNoCheck(LLDynamicArray<LLFolderViewEventListener*
 	LLInventoryModel* model = getInventoryModel();
 	if(!model) return;
 	LLMessageSystem* msg = gMessageSystem;
-	LLUUID trash_id = model->findCategoryUUIDForType(LLAssetType::AT_TRASH);
+	const LLUUID trash_id = model->findCategoryUUIDForType(LLFolderType::FT_TRASH);
 	LLViewerInventoryItem* item = NULL;
 	LLViewerInventoryCategory* cat = NULL;
 	std::vector<LLUUID> move_ids;
@@ -504,7 +506,7 @@ BOOL LLInvFVBridge::isClipboardPasteableAsLink() const
 			}
 		}
 		const LLViewerInventoryCategory *cat = model->getCategory(objects.get(i));
-		if (cat && !LLAssetType::lookupCanLink(cat->getPreferredType()))
+		if (cat && !LLFolderType::lookupIsProtectedType(cat->getPreferredType()))
 		{
 			return FALSE;
 		}
@@ -645,7 +647,7 @@ BOOL LLInvFVBridge::startDrag(EDragAndDropType* type, LLUUID* id) const
 
 	if(obj)
 	{
-		*type = LLAssetType::lookupDragAndDropType(obj->getActualType());
+		*type = LLViewerAssetType::lookupDragAndDropType(obj->getActualType());
 		if(*type == DAD_NONE)
 		{
 			return FALSE;
@@ -686,7 +688,7 @@ BOOL LLInvFVBridge::isInTrash() const
 {
 	LLInventoryModel* model = getInventoryModel();
 	if(!model) return FALSE;
-	const LLUUID trash_id = model->findCategoryUUIDForType(LLAssetType::AT_TRASH);
+	const LLUUID trash_id = model->findCategoryUUIDForType(LLFolderType::FT_TRASH);
 	return model->isObjectDescendentOf(mUUID, trash_id);
 }
 
@@ -699,7 +701,7 @@ BOOL LLInvFVBridge::isLinkedObjectInTrash() const
 	{
 		LLInventoryModel* model = getInventoryModel();
 		if(!model) return FALSE;
-		const LLUUID trash_id = model->findCategoryUUIDForType(LLAssetType::AT_TRASH);
+		const LLUUID trash_id = model->findCategoryUUIDForType(LLFolderType::FT_TRASH);
 		return model->isObjectDescendentOf(obj->getLinkedUUID(), trash_id);
 	}
 	return FALSE;
@@ -717,7 +719,7 @@ BOOL LLInvFVBridge::isCOFFolder() const
 {
 	const LLInventoryModel* model = getInventoryModel();
 	if(!model) return TRUE;
-	const LLUUID cof_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_CURRENT_OUTFIT);
+	const LLUUID cof_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_CURRENT_OUTFIT);
 	if (mUUID == cof_id || model->isObjectDescendentOf(mUUID, cof_id))
 	{
 		return TRUE;
@@ -1044,7 +1046,7 @@ void LLItemBridge::restoreItem()
 	if(item)
 	{
 		LLInventoryModel* model = getInventoryModel();
-		const LLUUID new_parent = model->findCategoryUUIDForType(item->getType());
+		const LLUUID new_parent = model->findCategoryUUIDForType(LLFolderType::assetTypeToFolderType(item->getType()));
 		// do not restamp on restore.
 		LLInvFVBridge::changeItemParent(model, item, new_parent, FALSE);
 	}
@@ -1077,7 +1079,7 @@ void LLItemBridge::restoreToWorld()
 	}
 
 	// Check if it's in the trash. (again similar to the normal rez logic)
-	const LLUUID trash_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_TRASH);
+	const LLUUID trash_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_TRASH);
 	if(gInventory.isObjectDescendentOf(itemp->getUUID(), trash_id))
 	{
 		remove_from_inventory = TRUE;
@@ -1272,7 +1274,7 @@ BOOL LLItemBridge::removeItem()
 	LLPreview::hide(mUUID, TRUE);
 	LLInventoryModel* model = getInventoryModel();
 	if(!model) return FALSE;
-	LLUUID trash_id = model->findCategoryUUIDForType(LLAssetType::AT_TRASH);
+	const LLUUID trash_id = model->findCategoryUUIDForType(LLFolderType::FT_TRASH);
 	LLViewerInventoryItem* item = getItem();
 
 	// if item is not already in trash
@@ -1365,7 +1367,7 @@ BOOL LLFolderBridge::isItemMovable() const
 	LLInventoryObject* obj = getInventoryObject();
 	if(obj)
 	{
-		return (!LLAssetType::lookupIsProtectedCategoryType(((LLInventoryCategory*)obj)->getPreferredType()));
+		return (!LLFolderType::lookupIsProtectedType(((LLInventoryCategory*)obj)->getPreferredType()));
 	}
 	return FALSE;
 }
@@ -1401,7 +1403,7 @@ BOOL LLFolderBridge::isItemRemovable()
 		return FALSE;
 	}
 
-	if(LLAssetType::lookupIsProtectedCategoryType(category->getPreferredType()))
+	if(LLFolderType::lookupIsProtectedType(category->getPreferredType()))
 	{
 		return FALSE;
 	}
@@ -1414,7 +1416,7 @@ BOOL LLFolderBridge::isItemRemovable()
 	for( i = 0; i < descendent_categories.count(); i++ )
 	{
 		LLInventoryCategory* category = descendent_categories[i];
-		if(LLAssetType::lookupIsProtectedCategoryType(category->getPreferredType()))
+		if(LLFolderType::lookupIsProtectedType(category->getPreferredType()))
 		{
 			return FALSE;
 		}
@@ -1591,20 +1593,20 @@ BOOL LLFolderBridge::dragCategoryIntoFolder(LLInventoryCategory* inv_cat,
 		const LLUUID& cat_id = inv_cat->getUUID();
 
 		// Is the destination the trash?
-		const LLUUID trash_id = model->findCategoryUUIDForType(LLAssetType::AT_TRASH);
+		const LLUUID trash_id = model->findCategoryUUIDForType(LLFolderType::FT_TRASH);
 		BOOL move_is_into_trash = (mUUID == trash_id)
 				|| model->isObjectDescendentOf(mUUID, trash_id);
-		BOOL is_movable = (!LLAssetType::lookupIsProtectedCategoryType(inv_cat->getPreferredType()));
-		LLUUID current_outfit_id = model->findCategoryUUIDForType(LLAssetType::AT_CURRENT_OUTFIT);
+		BOOL is_movable = (!LLFolderType::lookupIsProtectedType(inv_cat->getPreferredType()));
+		const LLUUID current_outfit_id = model->findCategoryUUIDForType(LLFolderType::FT_CURRENT_OUTFIT);
 		BOOL move_is_into_current_outfit = (mUUID == current_outfit_id);
-		BOOL move_is_into_outfit = (getCategory() && getCategory()->getPreferredType()==LLAssetType::AT_OUTFIT);
+		BOOL move_is_into_outfit = (getCategory() && getCategory()->getPreferredType()==LLFolderType::FT_OUTFIT);
 		if (move_is_into_current_outfit || move_is_into_outfit)
 		{
 			// BAP - restrictions?
 			is_movable = true;
 		}
 
-		if (mUUID == gInventory.findCategoryUUIDForType(LLAssetType::AT_FAVORITE))
+		if (mUUID == gInventory.findCategoryUUIDForType(LLFolderType::FT_FAVORITE))
 		{
 			is_movable = FALSE; // It's generally movable but not into Favorites folder. EXT-1604
 		}
@@ -1616,7 +1618,7 @@ BOOL LLFolderBridge::dragCategoryIntoFolder(LLInventoryCategory* inv_cat,
 			for( i = 0; i < descendent_categories.count(); i++ )
 			{
 				LLInventoryCategory* category = descendent_categories[i];
-				if(LLAssetType::lookupIsProtectedCategoryType(category->getPreferredType()))
+				if(LLFolderType::lookupIsProtectedType(category->getPreferredType()))
 				{
 					// ...can't move "special folders" like Textures
 					is_movable = FALSE;
@@ -1849,8 +1851,8 @@ bool LLFindCOFValidItems::operator()(LLInventoryCategory* cat,
 		LLViewerInventoryCategory *linked_category = ((LLViewerInventoryItem*)item)->getLinkedCategory(); // BAP - safe?
 		// BAP remove AT_NONE support after ensembles are fully working?
 		return (linked_category &&
-				((linked_category->getPreferredType() == LLAssetType::AT_NONE) ||
-				 (LLAssetType::lookupIsEnsembleCategoryType(linked_category->getPreferredType()))));
+				((linked_category->getPreferredType() == LLFolderType::FT_NONE) ||
+				 (LLFolderType::lookupIsEnsembleType(linked_category->getPreferredType()))));
 	}
 }
 
@@ -2152,7 +2154,7 @@ void LLFolderBridge::determineFolderType()
 BOOL LLFolderBridge::isItemRenameable() const
 {
 	LLViewerInventoryCategory* cat = (LLViewerInventoryCategory*)getCategory();
-	if(cat && !LLAssetType::lookupIsProtectedCategoryType(cat->getPreferredType())
+	if(cat && !LLFolderType::lookupIsProtectedType(cat->getPreferredType())
 	   && (cat->getOwnerID() == gAgent.getID()))
 	{
 		return TRUE;
@@ -2167,15 +2169,15 @@ void LLFolderBridge::restoreItem()
 	if(cat)
 	{
 		LLInventoryModel* model = getInventoryModel();
-		LLUUID new_parent = model->findCategoryUUIDForType(cat->getType());
+		const LLUUID new_parent = model->findCategoryUUIDForType(LLFolderType::assetTypeToFolderType(cat->getType()));
 		// do not restamp children on restore
 		LLInvFVBridge::changeCategoryParent(model, cat, new_parent, FALSE);
 	}
 }
 
-LLAssetType::EType LLFolderBridge::getPreferredType() const
+LLFolderType::EType LLFolderBridge::getPreferredType() const
 {
-	LLAssetType::EType preferred_type = LLAssetType::AT_NONE;
+	LLFolderType::EType preferred_type = LLFolderType::FT_NONE;
 	LLViewerInventoryCategory* cat = getCategory();
 	if(cat)
 	{
@@ -2188,7 +2190,7 @@ LLAssetType::EType LLFolderBridge::getPreferredType() const
 // Icons for folders are based on the preferred type
 LLUIImagePtr LLFolderBridge::getIcon() const
 {
-	LLAssetType::EType preferred_type = LLAssetType::AT_NONE;
+	LLFolderType::EType preferred_type = LLFolderType::FT_NONE;
 	LLViewerInventoryCategory* cat = getCategory();
 	if(cat)
 	{
@@ -2197,7 +2199,7 @@ LLUIImagePtr LLFolderBridge::getIcon() const
 	return getIcon(preferred_type);
 }
 
-LLUIImagePtr LLFolderBridge::getIcon(LLAssetType::EType preferred_type)
+LLUIImagePtr LLFolderBridge::getIcon(LLFolderType::EType preferred_type)
 {
 	// we only have one folder image now
 	return LLUI::getUIImage("Inv_FolderClosed");
@@ -2236,7 +2238,7 @@ BOOL LLFolderBridge::removeItem()
 	LLInventoryModel* model = getInventoryModel();
 	if(!model) return FALSE;
 
-	LLUUID trash_id = model->findCategoryUUIDForType(LLAssetType::AT_TRASH);
+	const LLUUID trash_id = model->findCategoryUUIDForType(LLFolderType::FT_TRASH);
 
 	// Look for any gestures and deactivate them
 	LLInventoryModel::cat_array_t	descendent_categories;
@@ -2354,11 +2356,11 @@ void LLFolderBridge::folderOptionsMenu()
 	if(!model) return;
 
 	const LLInventoryCategory* category = model->getCategory(mUUID);
-	LLAssetType::EType type = category->getPreferredType();
-	const bool is_default_folder = category && LLAssetType::lookupIsProtectedCategoryType(type);
+	LLFolderType::EType type = category->getPreferredType();
+	const bool is_default_folder = category && LLFolderType::lookupIsProtectedType(type);
 	// BAP change once we're no longer treating regular categories as ensembles.
-	const bool is_ensemble = category && (type == LLAssetType::AT_NONE ||
-										  LLAssetType::lookupIsEnsembleCategoryType(type));
+	const bool is_ensemble = category && (type == LLFolderType::FT_NONE ||
+										  LLFolderType::lookupIsEnsembleType(type));
 
 	// calling card related functionality for folders.
 
@@ -2424,8 +2426,8 @@ void LLFolderBridge::buildContextMenu(LLMenuGL& menu, U32 flags)
 //	std::vector<std::string> disabled_items;
 	LLInventoryModel* model = getInventoryModel();
 	if(!model) return;
-	LLUUID trash_id = model->findCategoryUUIDForType(LLAssetType::AT_TRASH);
-	LLUUID lost_and_found_id = model->findCategoryUUIDForType(LLAssetType::AT_LOST_AND_FOUND);
+	const LLUUID trash_id = model->findCategoryUUIDForType(LLFolderType::FT_TRASH);
+	const LLUUID lost_and_found_id = model->findCategoryUUIDForType(LLFolderType::FT_LOST_AND_FOUND);
 
 	mItems.clear(); //adding code to clear out member Items (which means Items should not have other data here at this point)
 	mDisabledItems.clear(); //adding code to clear out disabled members from previous
@@ -2455,7 +2457,6 @@ void LLFolderBridge::buildContextMenu(LLMenuGL& menu, U32 flags)
 	else if(isAgentInventory()) // do not allow creating in library
 	{
 		LLViewerInventoryCategory *cat =  getCategory();
-
 		// BAP removed protected check to re-enable standard ops in untyped folders.
 		// Not sure what the right thing is to do here.
 		if (!isCOFFolder() && cat /*&&
@@ -2472,7 +2473,7 @@ void LLFolderBridge::buildContextMenu(LLMenuGL& menu, U32 flags)
 			mItems.push_back(std::string("Change Type"));
 
 			LLViewerInventoryCategory *cat = getCategory();
-			if (cat && LLAssetType::lookupIsProtectedCategoryType(cat->getPreferredType()))
+			if (cat && LLFolderType::lookupIsProtectedType(cat->getPreferredType()))
 			{
 				mDisabledItems.push_back(std::string("Change Type"));
 			}
@@ -2482,7 +2483,7 @@ void LLFolderBridge::buildContextMenu(LLMenuGL& menu, U32 flags)
 		else
 		{
 			// Want some but not all of the items from getClipboardEntries for outfits.
-			if (cat && cat->getPreferredType()==LLAssetType::AT_OUTFIT)
+			if (cat && cat->getPreferredType()==LLFolderType::FT_OUTFIT)
 			{
 				mItems.push_back(std::string("Rename"));
 				mItems.push_back(std::string("Delete"));
@@ -2618,7 +2619,7 @@ void LLFolderBridge::createNewCategory(void* user_data)
 	if(!model) return;
 	LLUUID id;
 	id = model->createNewCategory(bridge->getUUID(),
-								  LLAssetType::AT_NONE,
+								  LLFolderType::FT_NONE,
 								  LLStringUtil::null);
 	model->notifyObservers();
 
@@ -2703,7 +2704,7 @@ void LLFolderBridge::createWearable(LLFolderBridge* bridge, EWearableType type)
 // Separate function so can be called by global menu as well as right-click
 // menu.
 // static
-void LLFolderBridge::createWearable(LLUUID parent_id, EWearableType type)
+void LLFolderBridge::createWearable(const LLUUID &parent_id, EWearableType type)
 {
 	LLWearable* wearable = LLWearableList::instance().createNewWearable(type);
 	LLAssetType::EType asset_type = wearable->getAssetType();
@@ -2846,17 +2847,17 @@ BOOL LLFolderBridge::dragItemIntoFolder(LLInventoryItem* inv_item,
 			break;
 
 		case LLAssetType::AT_CATEGORY:
-			is_movable = !LLAssetType::lookupIsProtectedCategoryType(((LLInventoryCategory*)inv_item)->getPreferredType());
+			is_movable = !LLFolderType::lookupIsProtectedType(((LLInventoryCategory*)inv_item)->getPreferredType());
 			break;
 		default:
 			break;
 		}
 
-		LLUUID trash_id = model->findCategoryUUIDForType(LLAssetType::AT_TRASH);
+		const LLUUID trash_id = model->findCategoryUUIDForType(LLFolderType::FT_TRASH);
 		BOOL move_is_into_trash = (mUUID == trash_id) || model->isObjectDescendentOf(mUUID, trash_id);
-		LLUUID current_outfit_id = model->findCategoryUUIDForType(LLAssetType::AT_CURRENT_OUTFIT);
+		const LLUUID current_outfit_id = model->findCategoryUUIDForType(LLFolderType::FT_CURRENT_OUTFIT);
 		BOOL move_is_into_current_outfit = (mUUID == current_outfit_id);
-		BOOL move_is_into_outfit = (getCategory() && getCategory()->getPreferredType()==LLAssetType::AT_OUTFIT);
+		BOOL move_is_into_outfit = (getCategory() && getCategory()->getPreferredType()==LLFolderType::FT_OUTFIT);
 
 		if(is_movable && move_is_into_trash)
 		{
@@ -2886,7 +2887,7 @@ BOOL LLFolderBridge::dragItemIntoFolder(LLInventoryItem* inv_item,
 				.isObjDirectDescendentOfCategory (inv_item, getCategory());
 		}
 
-		LLUUID favorites_id = model->findCategoryUUIDForType(LLAssetType::AT_FAVORITE);
+		const LLUUID& favorites_id = model->findCategoryUUIDForType(LLFolderType::FT_FAVORITE);
 
 		// we can move item inside a folder only if this folder is Favorites. See EXT-719
 		accept = is_movable && ((mUUID != inv_item->getParentUUID()) || (mUUID == favorites_id));
@@ -4934,7 +4935,7 @@ void	LLLSLTextBridgeAction::doIt()
 BOOL LLWearableBridgeAction::isInTrash() const
 {
 	if(!mModel) return FALSE;
-	LLUUID trash_id = mModel->findCategoryUUIDForType(LLAssetType::AT_TRASH);
+	const LLUUID trash_id = mModel->findCategoryUUIDForType(LLFolderType::FT_TRASH);
 	return mModel->isObjectDescendentOf(mUUID, trash_id);
 }
 
@@ -5073,7 +5074,7 @@ std::string LLLinkFolderBridge::sPrefix("Link: ");
 
 LLUIImagePtr LLLinkFolderBridge::getIcon() const
 {
-	LLAssetType::EType preferred_type = LLAssetType::AT_NONE;
+	LLFolderType::EType preferred_type = LLFolderType::FT_NONE;
 	if (LLViewerInventoryItem *item = getItem())
 	{
 		if (const LLViewerInventoryCategory* cat = item->getLinkedCategory())
diff --git a/indra/newview/llinventorybridge.h b/indra/newview/llinventorybridge.h
index 3f3513a665..f95e8f9361 100644
--- a/indra/newview/llinventorybridge.h
+++ b/indra/newview/llinventorybridge.h
@@ -159,7 +159,7 @@ public:
 	virtual const std::string& getName() const;
 	virtual const std::string& getDisplayName() const;
 	virtual PermissionMask getPermissionMask() const;
-	virtual LLAssetType::EType getPreferredType() const;
+	virtual LLFolderType::EType getPreferredType() const;
 	virtual time_t getCreationDate() const;
 	virtual LLFontGL::StyleFlags getLabelStyle() const
 	{
@@ -298,9 +298,9 @@ public:
 	virtual void selectItem();
 	virtual void restoreItem();
 
-	virtual LLAssetType::EType getPreferredType() const;
+	virtual LLFolderType::EType getPreferredType() const;
 	virtual LLUIImagePtr getIcon() const;
-	static LLUIImagePtr getIcon(LLAssetType::EType asset_type);
+	static LLUIImagePtr getIcon(LLFolderType::EType preferred_type);
 
 	virtual BOOL renameItem(const std::string& new_name);
 	virtual BOOL removeItem();
@@ -321,7 +321,7 @@ public:
 	virtual BOOL copyToClipboard() const;
 	
 	static void createWearable(LLFolderBridge* bridge, EWearableType type);
-	static void createWearable(LLUUID parent_folder_id, EWearableType type);
+	static void createWearable(const LLUUID &parent_folder_id, EWearableType type);
 
 	LLViewerInventoryCategory* getCategory() const;
 
diff --git a/indra/newview/llinventoryfunctions.cpp b/indra/newview/llinventoryfunctions.cpp
index 77121bd922..75218e98e0 100644
--- a/indra/newview/llinventoryfunctions.cpp
+++ b/indra/newview/llinventoryfunctions.cpp
@@ -317,10 +317,6 @@ const std::string& get_item_icon_name(LLAssetType::EType asset_type,
 	case LLAssetType::AT_GESTURE:
 		idx = GESTURE_ICON_NAME;
 		break;
-	case LLAssetType::AT_FAVORITE:
-		//TODO - need bette idx
-		idx = LANDMARK_ICON_NAME;
-		break;
 	case LLAssetType::AT_LINK:
 		idx = LINKITEM_ICON_NAME;
 		break;
diff --git a/indra/newview/llinventorymodel.cpp b/indra/newview/llinventorymodel.cpp
index 23439191f3..baf34b42ff 100644
--- a/indra/newview/llinventorymodel.cpp
+++ b/indra/newview/llinventorymodel.cpp
@@ -49,6 +49,7 @@
 #include "llinventoryfunctions.h"
 #include "llinventorypanel.h"
 #include "llfloaterinventory.h"
+#include "llviewerfoldertype.h"
 #include "llviewerinventory.h"
 #include "llviewermessage.h"
 #include "llviewerwindow.h"
@@ -316,7 +317,7 @@ void LLInventoryModel::unlockDirectDescendentArrays(const LLUUID& cat_id)
 // specifies 'type' as what it defaults to containing. The category is
 // not necessarily only for that type. *NOTE: This will create a new
 // inventory category on the fly if one does not exist.
-LLUUID LLInventoryModel::findCategoryUUIDForType(LLAssetType::EType t, bool create_folder)
+const LLUUID LLInventoryModel::findCategoryUUIDForType(LLFolderType::EType t, bool create_folder)
 {
 	const LLUUID &rv = findCatUUID(t);
 	if(rv.isNull() && isInventoryUsable() && create_folder)
@@ -332,10 +333,10 @@ LLUUID LLInventoryModel::findCategoryUUIDForType(LLAssetType::EType t, bool crea
 
 // Internal method which looks for a category with the specified
 // preferred type. Returns LLUUID::null if not found.
-const LLUUID &LLInventoryModel::findCatUUID(LLAssetType::EType preferred_type) const
+const LLUUID &LLInventoryModel::findCatUUID(LLFolderType::EType preferred_type) const
 {
 	const LLUUID &root_id = gInventory.getRootFolderID();
-	if(LLAssetType::AT_CATEGORY == preferred_type)
+	if(LLFolderType::FT_CATEGORY == preferred_type)
 	{
 		return root_id;
 	}
@@ -363,7 +364,7 @@ const LLUUID &LLInventoryModel::findCatUUID(LLAssetType::EType preferred_type) c
 // version will take care of details like what the name should be
 // based on preferred type. Returns the UUID of the new category.
 LLUUID LLInventoryModel::createNewCategory(const LLUUID& parent_id,
-										   LLAssetType::EType preferred_type,
+										   LLFolderType::EType preferred_type,
 										   const std::string& pname)
 {
 	LLUUID id;
@@ -373,9 +374,9 @@ LLUUID LLInventoryModel::createNewCategory(const LLUUID& parent_id,
 		return id;
 	}
 
-	if(preferred_type == LLAssetType::AT_SIMSTATE)
+	if(LLFolderType::lookup(preferred_type) == LLFolderType::badLookup())
 	{
-		lldebugs << "Attempt to create simstate category." << llendl;
+		lldebugs << "Attempt to create undefined category." << llendl;
 		return id;
 	}
 
@@ -387,7 +388,7 @@ LLUUID LLInventoryModel::createNewCategory(const LLUUID& parent_id,
 	}
 	else
 	{
-		name.assign(LLAssetType::lookupCategoryName(preferred_type));
+		name.assign(LLViewerFolderType::lookupNewCategoryName(preferred_type));
 	}
 
 	// Add the category to the internal representation
@@ -451,7 +452,7 @@ void LLInventoryModel::collectDescendentsIf(const LLUUID& id,
 	// Start with categories
 	if(!include_trash)
 	{
-		const LLUUID trash_id = findCategoryUUIDForType(LLAssetType::AT_TRASH);
+		const LLUUID trash_id = findCategoryUUIDForType(LLFolderType::FT_TRASH);
 		if(trash_id.notNull() && (trash_id == id))
 			return;
 	}
@@ -485,7 +486,7 @@ void LLInventoryModel::collectDescendentsIf(const LLUUID& id,
 			if (item->getActualType() == LLAssetType::AT_LINK_FOLDER)
 			{
 				LLViewerInventoryCategory *linked_cat = item->getLinkedCategory();
-				if (linked_cat && linked_cat->getPreferredType() != LLAssetType::AT_OUTFIT)
+				if (linked_cat && linked_cat->getPreferredType() != LLFolderType::FT_OUTFIT)
 					// BAP - was 
 					// LLAssetType::lookupIsEnsembleCategoryType(linked_cat->getPreferredType()))
 					// Change back once ensemble typing is in place.
@@ -665,7 +666,7 @@ U32 LLInventoryModel::updateItem(const LLViewerInventoryItem* item)
 
 		if(item->getParentUUID().isNull())
 		{
-			LLUUID category_id = findCategoryUUIDForType(new_item->getType());
+			const LLUUID category_id = findCategoryUUIDForType(LLFolderType::assetTypeToFolderType(new_item->getType()));
 			new_item->setParent(category_id);
 			item_array_t* item_array = get_ptr_in_map(mParentChildItemTree, category_id);
 			if( item_array )
@@ -689,7 +690,7 @@ U32 LLInventoryModel::updateItem(const LLViewerInventoryItem* item)
 			LLUUID parent_id = item->getParentUUID();
 			if(parent_id == CATEGORIZE_LOST_AND_FOUND_ID)
 			{
-				parent_id = findCategoryUUIDForType(LLAssetType::AT_LOST_AND_FOUND);
+				parent_id = findCategoryUUIDForType(LLFolderType::FT_LOST_AND_FOUND);
 				new_item->setParent(parent_id);
 			}
 			item_array_t* item_array = get_ptr_in_map(mParentChildItemTree, parent_id);
@@ -702,7 +703,7 @@ U32 LLInventoryModel::updateItem(const LLViewerInventoryItem* item)
 				// Whoops! No such parent, make one.
 				llinfos << "Lost item: " << new_item->getUUID() << " - "
 						<< new_item->getName() << llendl;
-				parent_id = findCategoryUUIDForType(LLAssetType::AT_LOST_AND_FOUND);
+				parent_id = findCategoryUUIDForType(LLFolderType::FT_LOST_AND_FOUND);
 				new_item->setParent(parent_id);
 				item_array = get_ptr_in_map(mParentChildItemTree, parent_id);
 				if(item_array)
@@ -1184,7 +1185,7 @@ void LLInventoryModel::mock(const LLUUID& root_id)
 		root_id,
 		LLUUID::null,
 		LLAssetType::AT_CATEGORY,
-		LLAssetType::lookupCategoryName(LLAssetType::AT_ROOT_CATEGORY),
+		LLFolderType::lookupNewCategoryName(LLFolderType::FT_ROOT_CATEGORY),
 		gAgent.getID());
 	addCategory(cat);
 	gInventory.buildParentChildMap();
@@ -1342,7 +1343,7 @@ void  fetchDescendentsResponder::result(const LLSD& content)
 				    item_it != folder_sd["items"].endArray();
 				    ++item_it)
 			    {	
-                    LLUUID lost_uuid = gInventory.findCategoryUUIDForType(LLAssetType::AT_LOST_AND_FOUND);
+                    const LLUUID lost_uuid = gInventory.findCategoryUUIDForType(LLFolderType::FT_LOST_AND_FOUND);
                     if (lost_uuid.notNull())
                     {
 				        LLSD item = *item_it;
@@ -2049,11 +2050,11 @@ bool LLInventoryModel::loadSkeleton(
 			cat->setUUID(folder_id.asUUID());
 			cat->setParent(parent_id.asUUID());
 
-			LLAssetType::EType preferred_type = LLAssetType::AT_NONE;
+			LLFolderType::EType preferred_type = LLFolderType::FT_NONE;
 			LLSD type_default = (*it)["type_default"];
 			if(type_default.isDefined())
             {
-				preferred_type = (LLAssetType::EType)type_default.asInteger();
+				preferred_type = (LLFolderType::EType)type_default.asInteger();
             }
             cat->setPreferredType(preferred_type);
 			cat->setVersion(version.asInteger());
@@ -2400,12 +2401,12 @@ void LLInventoryModel::buildParentChildMap()
 					<< cat->getName() << llendl;
 			++lost;
 			// plop it into the lost & found.
-			LLAssetType::EType pref = cat->getPreferredType();
-			if(LLAssetType::AT_NONE == pref)
+			LLFolderType::EType pref = cat->getPreferredType();
+			if(LLFolderType::FT_NONE == pref)
 			{
-				cat->setParent(findCategoryUUIDForType(LLAssetType::AT_LOST_AND_FOUND));
+				cat->setParent(findCategoryUUIDForType(LLFolderType::FT_LOST_AND_FOUND));
 			}
-			else if(LLAssetType::AT_CATEGORY == pref)
+			else if(LLFolderType::FT_CATEGORY == pref)
 			{
 				// it's the root
 				cat->setParent(LLUUID::null);
@@ -2464,7 +2465,7 @@ void LLInventoryModel::buildParentChildMap()
 			++lost;
 			// plop it into the lost & found.
 			//
-			item->setParent(findCategoryUUIDForType(LLAssetType::AT_LOST_AND_FOUND));
+			item->setParent(findCategoryUUIDForType(LLFolderType::FT_LOST_AND_FOUND));
 			// move it later using a special message to move items. If
 			// we update server here, the client might crash.
 			//item->updateServer();
@@ -2485,7 +2486,7 @@ void LLInventoryModel::buildParentChildMap()
 		llwarns << "Found " << lost << " lost items." << llendl;
 		LLMessageSystem* msg = gMessageSystem;
 		BOOL start_new_message = TRUE;
-		LLUUID lnf = findCategoryUUIDForType(LLAssetType::AT_LOST_AND_FOUND);
+		const LLUUID lnf = findCategoryUUIDForType(LLFolderType::FT_LOST_AND_FOUND);
 		for(std::vector<LLUUID>::iterator it = lost_item_ids.begin() ; it < lost_item_ids.end(); ++it)
 		{
 			if(start_new_message)
@@ -2938,7 +2939,7 @@ void LLInventoryModel::processUpdateInventoryFolder(LLMessageSystem* msg,
 		lastfolder = tfolder;
 		tfolder->unpackMessage(msg, _PREHASH_FolderData, i);
 		// make sure it's not a protected folder
-		tfolder->setPreferredType(LLAssetType::AT_NONE);
+		tfolder->setPreferredType(LLFolderType::FT_NONE);
 		folders.push_back(tfolder);
 		// examine update for changes.
 		LLViewerInventoryCategory* folderp = gInventory.getCategory(tfolder->getUUID());
@@ -3325,31 +3326,31 @@ void LLInventoryModel::processMoveInventoryItem(LLMessageSystem* msg, void**)
 
 //----------------------------------------------------------------------------
 
-// Trash: LLAssetType::AT_TRASH, "ConfirmEmptyTrash"
-// Lost&Found: LLAssetType::AT_LOST_AND_FOUND, "ConfirmEmptyLostAndFound"
+// Trash: LLFolderType::FT_TRASH, "ConfirmEmptyTrash"
+// Lost&Found: LLFolderType::FT_LOST_AND_FOUND, "ConfirmEmptyLostAndFound"
 
-bool LLInventoryModel::callbackEmptyFolderType(const LLSD& notification, const LLSD& response, LLAssetType::EType folder_type)
+bool LLInventoryModel::callbackEmptyFolderType(const LLSD& notification, const LLSD& response, LLFolderType::EType preferred_type)
 {
 	S32 option = LLNotification::getSelectedOption(notification, response);
 	if (option == 0) // YES
 	{
-		LLUUID folder_id = findCategoryUUIDForType(folder_type);
+		const LLUUID folder_id = findCategoryUUIDForType(preferred_type);
 		purgeDescendentsOf(folder_id);
 		notifyObservers();
 	}
 	return false;
 }
 
-void LLInventoryModel::emptyFolderType(const std::string notification, LLAssetType::EType folder_type)
+void LLInventoryModel::emptyFolderType(const std::string notification, LLFolderType::EType preferred_type)
 {
 	if (!notification.empty())
 	{
 		LLNotifications::instance().add(notification, LLSD(), LLSD(),
-										boost::bind(&LLInventoryModel::callbackEmptyFolderType, this, _1, _2, folder_type));
+										boost::bind(&LLInventoryModel::callbackEmptyFolderType, this, _1, _2, preferred_type));
 	}
 	else
 	{
-		LLUUID folder_id = findCategoryUUIDForType(folder_type);
+		const LLUUID folder_id = findCategoryUUIDForType(preferred_type);
 		purgeDescendentsOf(folder_id);
 		notifyObservers();
 	}
@@ -3360,7 +3361,7 @@ void LLInventoryModel::emptyFolderType(const std::string notification, LLAssetTy
 void LLInventoryModel::removeItem(const LLUUID& item_id)
 {
 	LLViewerInventoryItem* item = getItem(item_id);
-	const LLUUID new_parent = findCategoryUUIDForType(LLAssetType::AT_TRASH);
+	const LLUUID new_parent = findCategoryUUIDForType(LLFolderType::FT_TRASH);
 	if (item && item->getParentUUID() != new_parent)
 	{
 		LLInventoryModel::update_list_t update;
diff --git a/indra/newview/llinventorymodel.h b/indra/newview/llinventorymodel.h
index d51460b374..aba0a619db 100644
--- a/indra/newview/llinventorymodel.h
+++ b/indra/newview/llinventorymodel.h
@@ -34,6 +34,7 @@
 #define LL_LLINVENTORYMODEL_H
 
 #include "llassettype.h"
+#include "llfoldertype.h"
 #include "lldarray.h"
 #include "llframetimer.h"
 #include "llhttpclient.h"
@@ -280,7 +281,7 @@ public:
 
 	// SDK: Added flag to specify whether the folder should be created if not found.  This fixes the horrible
 	// multiple trash can bug.
-	LLUUID findCategoryUUIDForType(LLAssetType::EType preferred_type, bool create_folder = true);
+	const LLUUID findCategoryUUIDForType(LLFolderType::EType preferred_type, bool create_folder = true);
 
 	// Call this method when it's time to update everyone on a new
 	// state, by default, the inventory model will not update
@@ -329,7 +330,7 @@ public:
 	// category. If you want to use the default name based on type,
 	// pass in a NULL to the 'name parameter.
 	LLUUID createNewCategory(const LLUUID& parent_id,
-							 LLAssetType::EType preferred_type,
+							 LLFolderType::EType preferred_type,
 							 const std::string& name);
 
 	// methods to load up inventory skeleton & meat. These are used
@@ -385,9 +386,9 @@ public:
 	bool isCategoryComplete(const LLUUID& cat_id) const;
 	
 	// callbacks
-	// Trigger a notification and empty the folder type (AT_TRASH or AT_LOST_AND_FOUND) if confirmed
-	void emptyFolderType(const std::string notification, LLAssetType::EType folder_type);
-	bool callbackEmptyFolderType(const LLSD& notification, const LLSD& response, LLAssetType::EType folder_type);
+	// Trigger a notification and empty the folder type (FT_TRASH or FT_LOST_AND_FOUND) if confirmed
+	void emptyFolderType(const std::string notification, LLFolderType::EType folder_type);
+	bool callbackEmptyFolderType(const LLSD& notification, const LLSD& response, LLFolderType::EType preferred_type);
 
 	// Utility Functions
 	void removeItem(const LLUUID& item_id);
@@ -431,7 +432,7 @@ protected:
 	// 
 	// Internal method which looks for a category with the specified
 	// preferred type. Returns LLUUID::null if not found
- 	const LLUUID &findCatUUID(LLAssetType::EType preferred_type) const;
+ 	const LLUUID &findCatUUID(LLFolderType::EType preferred_type) const;
 
 	// Empty the entire contents
 	void empty();
diff --git a/indra/newview/llinventorypanel.cpp b/indra/newview/llinventorypanel.cpp
index d1ca0efed3..178e7d0823 100644
--- a/indra/newview/llinventorypanel.cpp
+++ b/indra/newview/llinventorypanel.cpp
@@ -78,6 +78,7 @@
 #include "lltabcontainer.h"
 #include "lltooldraganddrop.h"
 #include "lluictrlfactory.h"
+#include "llviewerfoldertype.h"
 #include "llviewerinventory.h"
 #include "llviewermessage.h"
 #include "llviewerobjectlist.h"
@@ -110,8 +111,8 @@ LLInventoryPanel::LLInventoryPanel(const LLInventoryPanel::Params& p) :
 
 	// contex menu callbacks
 	mCommitCallbackRegistrar.add("Inventory.DoToSelected", boost::bind(&LLInventoryPanel::doToSelected, this, _2));
-	mCommitCallbackRegistrar.add("Inventory.EmptyTrash", boost::bind(&LLInventoryModel::emptyFolderType, &gInventory, "ConfirmEmptyTrash", LLAssetType::AT_TRASH));
-	mCommitCallbackRegistrar.add("Inventory.EmptyLostAndFound", boost::bind(&LLInventoryModel::emptyFolderType, &gInventory, "ConfirmEmptyLostAndFound", LLAssetType::AT_LOST_AND_FOUND));
+	mCommitCallbackRegistrar.add("Inventory.EmptyTrash", boost::bind(&LLInventoryModel::emptyFolderType, &gInventory, "ConfirmEmptyTrash", LLFolderType::FT_TRASH));
+	mCommitCallbackRegistrar.add("Inventory.EmptyLostAndFound", boost::bind(&LLInventoryModel::emptyFolderType, &gInventory, "ConfirmEmptyLostAndFound", LLFolderType::FT_LOST_AND_FOUND));
 	mCommitCallbackRegistrar.add("Inventory.DoCreate", boost::bind(&LLInventoryPanel::doCreate, this, _2));
 	mCommitCallbackRegistrar.add("Inventory.AttachObject", boost::bind(&LLInventoryPanel::attachObject, this, _2));
 	mCommitCallbackRegistrar.add("Inventory.BeginIMSession", boost::bind(&LLInventoryPanel::beginIMSession, this));
@@ -169,19 +170,19 @@ BOOL LLInventoryPanel::postBuild()
 
 	// determine the root folder, if any, so inventory contents show just the children
 	// of that folder (i.e. not including the folder itself).
-	const LLAssetType::EType preferred_type = LLAssetType::lookupHumanReadable(mStartFolderString);
+	const LLFolderType::EType preferred_type = LLViewerFolderType::lookupTypeFromNewCategoryName(mStartFolderString);
 
-	if ("inventory" == mStartFolderString)
+	if ("INVENTORY" == mStartFolderString)
 	{
 		mStartFolderID = gInventory.getRootFolderID();
 	}
-	else if ("library" == mStartFolderString)
+	else if ("LIBRARY" == mStartFolderString)
 	{
 		mStartFolderID = gInventory.getLibraryRootFolderID();
 	}
 	else
 	{
-		mStartFolderID = (preferred_type != LLAssetType::AT_NONE ? gInventory.findCategoryUUIDForType(preferred_type) : LLUUID::null);
+		mStartFolderID = (preferred_type != LLFolderType::FT_NONE ? gInventory.findCategoryUUIDForType(preferred_type) : LLUUID::null);
 	}
 
 	// build view of inventory if we need default full hierarchy and inventory ready, otherwise wait for modelChanged() callback
@@ -192,7 +193,7 @@ BOOL LLInventoryPanel::postBuild()
 	}
 
 	// bit of a hack to make sure the inventory is open.
-	mFolders->openFolder(preferred_type != LLAssetType::AT_NONE ? LLAssetType::lookupCategoryName(preferred_type) : "My Inventory");
+	mFolders->openFolder(preferred_type != LLFolderType::FT_NONE ? LLViewerFolderType::lookupNewCategoryName(preferred_type) : "My Inventory");
 
 	if (mSortOrderSetting != INHERIT_SORT_ORDER)
 	{
@@ -382,6 +383,19 @@ void LLInventoryPanel::modelChanged(U32 mask)
 							view_item->getParentFolder()->extractItem(view_item);
 							view_item->addToFolder(new_parent, mFolders);
 						}
+/*
+						 on the other side in case Inventory Panel has content of the any folder
+						 it is possible that item moved to some folder which is absent in current
+						 Panel. For ex. removing item (via moving to trash).
+						 In this case we need to check if new parent is other then inventory start folder
+						 and simply remove its View from the hierarchy.
+						 See details in EXT-2098.
+*/
+						// So, let check if item was moved into folder out of this Inventory Panel.
+						else if (mStartFolderID.notNull() && NULL == new_parent && model_item->getParentUUID() != mStartFolderID)
+						{
+							view_item->getParentFolder()->extractItem(view_item);
+						}
 					}
 				}
 				else
@@ -650,7 +664,7 @@ void LLInventoryPanel::openAllFolders()
 	mFolders->arrangeAll();
 }
 
-void LLInventoryPanel::openDefaultFolderForType(LLAssetType::EType type)
+void LLInventoryPanel::openDefaultFolderForType(LLFolderType::EType type)
 {
 	LLUUID category_id = mInventory->findCategoryUUIDForType(type);
 	LLOpenFolderByID opener(category_id);
diff --git a/indra/newview/llinventorypanel.h b/indra/newview/llinventorypanel.h
index 997678a478..9f74fad5c1 100644
--- a/indra/newview/llinventorypanel.h
+++ b/indra/newview/llinventorypanel.h
@@ -122,7 +122,7 @@ public:
 
 	// Call this method to set the selection.
 	void openAllFolders();
-	void openDefaultFolderForType(LLAssetType::EType);
+	void openDefaultFolderForType(LLFolderType::EType);
 	void setSelection(const LLUUID& obj_id, BOOL take_keyboard_focus);
 	void setSelectCallback(const LLFolderView::signal_t::slot_type& cb) { if (mFolders) mFolders->setSelectCallback(cb); }
 	void clearSelection();
diff --git a/indra/newview/lllandmarkactions.cpp b/indra/newview/lllandmarkactions.cpp
index 0b07dd4f21..b1829b3945 100644
--- a/indra/newview/lllandmarkactions.cpp
+++ b/indra/newview/lllandmarkactions.cpp
@@ -135,13 +135,13 @@ public:
 
 // Returns true if the given inventory item is a landmark pointing to the current parcel.
 // Used to find out if there is at least one landmark from current parcel.
-class LLFistAgentParcelLandmark : public LLInventoryCollectFunctor
+class LLFirstAgentParcelLandmark : public LLInventoryCollectFunctor
 {
 private:	
 	bool mFounded;// to avoid unnecessary  check
 	
 public:
-	LLFistAgentParcelLandmark(): mFounded(false){}
+	LLFirstAgentParcelLandmark(): mFounded(false){}
 	
 	/*virtual*/ bool operator()(LLInventoryCategory* cat, LLInventoryItem* item)
 	{
@@ -165,8 +165,7 @@ static void fetch_landmarks(LLInventoryModel::cat_array_t& cats,
 							LLInventoryCollectFunctor& add)
 {
 	// Look in "My Favorites"
-	LLUUID favorites_folder_id =
-		gInventory.findCategoryUUIDForType(LLAssetType::AT_FAVORITE);
+	const LLUUID favorites_folder_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_FAVORITE);
 	gInventory.collectDescendentsIf(favorites_folder_id,
 		cats,
 		items,
@@ -174,8 +173,7 @@ static void fetch_landmarks(LLInventoryModel::cat_array_t& cats,
 		add);
 
 	// Look in "Landmarks"
-	LLUUID landmarks_folder_id = 
-		gInventory.findCategoryUUIDForType(LLAssetType::AT_LANDMARK);
+	const LLUUID landmarks_folder_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_LANDMARK);
 	gInventory.collectDescendentsIf(landmarks_folder_id,
 		cats,
 		items,
@@ -202,7 +200,7 @@ bool LLLandmarkActions::landmarkAlreadyExists()
 //static
 bool LLLandmarkActions::hasParcelLandmark()
 {
-	LLFistAgentParcelLandmark get_first_agent_landmark;
+	LLFirstAgentParcelLandmark get_first_agent_landmark;
 	LLInventoryModel::cat_array_t cats;
 	LLInventoryModel::item_array_t items;
 	fetch_landmarks(cats, items, get_first_agent_landmark);
@@ -287,7 +285,7 @@ void LLLandmarkActions::createLandmarkHere()
 
 	LLAgentUI::buildLocationString(landmark_name, LLAgentUI::LOCATION_FORMAT_LANDMARK);
 	LLAgentUI::buildLocationString(landmark_desc, LLAgentUI::LOCATION_FORMAT_FULL);
-	LLUUID folder_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_LANDMARK);
+	const LLUUID folder_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_LANDMARK);
 
 	createLandmarkHere(landmark_name, landmark_desc, folder_id);
 }
diff --git a/indra/newview/lllandmarkactions.h b/indra/newview/lllandmarkactions.h
index 312426cab0..1c524c820c 100644
--- a/indra/newview/lllandmarkactions.h
+++ b/indra/newview/lllandmarkactions.h
@@ -55,7 +55,7 @@ public:
 	static bool landmarkAlreadyExists();
 	
 	/**
-	 * @brief Checks whether landmark exists for current parcel.
+	 * @brief Checks whether landmark exists for current agent parcel.
 	 */
 	static bool hasParcelLandmark();
 
diff --git a/indra/newview/llnavigationbar.cpp b/indra/newview/llnavigationbar.cpp
index e63daac4af..b35fd6134b 100644
--- a/indra/newview/llnavigationbar.cpp
+++ b/indra/newview/llnavigationbar.cpp
@@ -50,6 +50,7 @@
 #include "llslurl.h"
 #include "llurlsimstring.h"
 #include "llviewerinventory.h"
+#include "llviewermenu.h"
 #include "llviewerparcelmgr.h"
 #include "llworldmap.h"
 #include "llappviewer.h"
@@ -271,6 +272,12 @@ void LLNavigationBar::draw()
 	LLPanel::draw();
 }
 
+BOOL LLNavigationBar::handleRightMouseDown(S32 x, S32 y, MASK mask)
+{
+	show_navbar_context_menu(this,x,y);
+	return TRUE;
+}
+
 void LLNavigationBar::onBackButtonClicked()
 {
 	LLTeleportHistory::getInstance()->goBack();
diff --git a/indra/newview/llnavigationbar.h b/indra/newview/llnavigationbar.h
index 04707d8d48..52f5a827e4 100644
--- a/indra/newview/llnavigationbar.h
+++ b/indra/newview/llnavigationbar.h
@@ -54,6 +54,7 @@ public:
 	virtual ~LLNavigationBar();
 	
 	/*virtual*/ void	draw();
+	/*virtual*/ BOOL handleRightMouseDown(S32 x, S32 y, MASK mask);
 	/*virtual*/ BOOL	postBuild();
 
 	void handleLoginComplete();
diff --git a/indra/newview/llnearbychat.cpp b/indra/newview/llnearbychat.cpp
index 12638ab855..81d033d7f9 100644
--- a/indra/newview/llnearbychat.cpp
+++ b/indra/newview/llnearbychat.cpp
@@ -97,14 +97,39 @@ BOOL LLNearbyChat::postBuild()
 	if (getDockControl() == NULL)
 	{
 		setDockControl(new LLDockControl(
-				LLBottomTray::getInstance()->getNearbyChatBar(), this,
-				getDockTongue(), LLDockControl::LEFT, boost::bind(&LLNearbyChat::getAllowedRect, this, _1)));
+			LLBottomTray::getInstance()->getNearbyChatBar(), this,
+			getDockTongue(), LLDockControl::LEFT, boost::bind(&LLNearbyChat::getAllowedRect, this, _1)));
 	}
 
 	return true;
 }
 
 
+void    LLNearbyChat::applySavedVariables()
+{
+
+	if (mRectControl.size() > 1)
+	{
+		const LLRect& rect = LLUI::sSettingGroups["floater"]->getRect(mRectControl);
+		reshape(rect.getWidth(), rect.getHeight());
+		setRect(rect);
+	}
+
+
+	if(!LLUI::sSettingGroups["floater"]->controlExists(mDocStateControl))
+	{
+		setDocked(true);
+	}
+	else
+	{
+		if (mDocStateControl.size() > 1)
+		{
+			bool dockState = LLUI::sSettingGroups["floater"]->getBOOL(mDocStateControl);
+			setDocked(dockState);
+		}
+	}
+}
+
 LLColor4 nearbychat_get_text_color(const LLChat& chat)
 {
 	LLColor4 text_color;
@@ -265,11 +290,5 @@ void LLNearbyChat::getAllowedRect(LLRect& rect)
 {
 	rect = gViewerWindow->getWorldViewRect();
 }
-void LLNearbyChat::setVisible	(BOOL visible)
-{
-	LLDockableFloater::setVisible(visible);
-}
-void LLNearbyChat::toggleWindow()
-{
-}
+
 
diff --git a/indra/newview/llnearbychat.h b/indra/newview/llnearbychat.h
index 20cbf7537d..cb4654654a 100644
--- a/indra/newview/llnearbychat.h
+++ b/indra/newview/llnearbychat.h
@@ -52,16 +52,15 @@ public:
 	void	onNearbyChatContextMenuItemClicked(const LLSD& userdata);
 	bool	onNearbyChatCheckContextMenuItem(const LLSD& userdata);
 
-	void	setDocked			(bool docked, bool pop_on_undock);
-	void	toggleWindow		();
+	void	setDocked			(bool docked, bool pop_on_undock = true);
 
 	/*virtual*/ void	onOpen	(const LLSD& key);
 
-	virtual void setVisible		(BOOL visible);
-
 	virtual void setRect		(const LLRect &rect);
 
 private:
+	virtual void    applySavedVariables();
+
 	void	getAllowedRect		(LLRect& rect);
 
 	void	onNearbySpeakers	();
diff --git a/indra/newview/llnearbychatbar.cpp b/indra/newview/llnearbychatbar.cpp
index 32dc5e5927..d7a5ff289c 100644
--- a/indra/newview/llnearbychatbar.cpp
+++ b/indra/newview/llnearbychatbar.cpp
@@ -77,6 +77,10 @@ LLGestureComboBox::LLGestureComboBox(const LLGestureComboBox::Params& p)
 
 	// refresh list from current active gestures
 	refreshGestures();
+
+	// This forces using of halign from xml, since LLComboBox
+	// sets it to LLFontGL::LEFT, if text entry is disabled
+	mButton->setHAlign(p.drop_down_button.font_halign);
 }
 
 LLGestureComboBox::~LLGestureComboBox()
@@ -207,6 +211,7 @@ LLNearbyChatBar::LLNearbyChatBar()
 	: LLPanel()
 	, mChatBox(NULL)
 {
+	mSpeakerMgr = LLLocalSpeakerMgr::getInstance();
 }
 
 //virtual
@@ -516,8 +521,8 @@ void LLNearbyChatBar::displaySpeakingIndicator()
 	LLUUID id;
 
 	id.setNull();
-	mSpeakerMgr.update(TRUE);
-	mSpeakerMgr.getSpeakerList(&speaker_list, FALSE);
+	mSpeakerMgr->update(TRUE);
+	mSpeakerMgr->getSpeakerList(&speaker_list, FALSE);
 
 	for (LLSpeakerMgr::speaker_list_t::iterator i = speaker_list.begin(); i != speaker_list.end(); ++i)
 	{
diff --git a/indra/newview/llnearbychatbar.h b/indra/newview/llnearbychatbar.h
index 06204e6367..0307eee7bf 100644
--- a/indra/newview/llnearbychatbar.h
+++ b/indra/newview/llnearbychatbar.h
@@ -127,7 +127,7 @@ protected:
 	LLLineEditor*		mChatBox;
 	LLTalkButton*		mTalkBtn;
 	LLOutputMonitorCtrl* mOutputMonitor;
-	LLActiveSpeakerMgr  mSpeakerMgr;
+	LLLocalSpeakerMgr*  mSpeakerMgr;
 };
 
 #endif
diff --git a/indra/newview/lloutputmonitorctrl.cpp b/indra/newview/lloutputmonitorctrl.cpp
index 8bac9937f0..39381e3faa 100644
--- a/indra/newview/lloutputmonitorctrl.cpp
+++ b/indra/newview/lloutputmonitorctrl.cpp
@@ -80,7 +80,8 @@ LLOutputMonitorCtrl::LLOutputMonitorCtrl(const LLOutputMonitorCtrl::Params& p)
 	mImageLevel2(p.image_level_2),
 	mImageLevel3(p.image_level_3),
 	mAutoUpdate(p.auto_update),
-	mSpeakerId(p.speaker_id)
+	mSpeakerId(p.speaker_id),
+	mIsAgentControl(false)
 {
 	//static LLUIColor output_monitor_muted_color = LLUIColorTable::instance().getColor("OutputMonitorMutedColor", LLColor4::orange);
 	//static LLUIColor output_monitor_overdriven_color = LLUIColorTable::instance().getColor("OutputMonitorOverdrivenColor", LLColor4::red);
@@ -132,7 +133,14 @@ void LLOutputMonitorCtrl::draw()
 	if (getVisible() && mAutoUpdate && !mIsMuted && mSpeakerId.notNull())
 	{
 		setPower(gVoiceClient->getCurrentPower(mSpeakerId));
-		setIsTalking(gVoiceClient->getIsSpeaking(mSpeakerId));
+		if(mIsAgentControl)
+		{
+			setIsTalking(gVoiceClient->getUserPTTState());
+		}
+		else
+		{
+			setIsTalking(gVoiceClient->getIsSpeaking(mSpeakerId));
+		}
 	}
 
 	LLPointer<LLUIImage> icon;
diff --git a/indra/newview/lloutputmonitorctrl.h b/indra/newview/lloutputmonitorctrl.h
index 7a7b8bc3a1..85ea552a57 100644
--- a/indra/newview/lloutputmonitorctrl.h
+++ b/indra/newview/lloutputmonitorctrl.h
@@ -81,6 +81,8 @@ public:
 
 	// For the current user, need to know the PTT state to show
 	// correct button image.
+	void			setIsAgentControl(bool val) { mIsAgentControl = val; }
+
 	void			setIsTalking(bool val) { mIsTalking = val; }
 
 	void			setSpeakerId(const LLUUID& speaker_id);
@@ -100,6 +102,7 @@ private:
 	
 
 	F32				mPower;
+	bool			mIsAgentControl;
 	bool			mIsMuted;
 	bool			mIsTalking;
 	LLPointer<LLUIImage> mImageMute;
diff --git a/indra/newview/llpanelcontents.cpp b/indra/newview/llpanelcontents.cpp
index c28792a711..9d591ef43d 100644
--- a/indra/newview/llpanelcontents.cpp
+++ b/indra/newview/llpanelcontents.cpp
@@ -59,6 +59,7 @@
 #include "lltoolcomp.h"
 #include "lltoolmgr.h"
 #include "lltrans.h"
+#include "llviewerassettype.h"
 #include "llviewerobject.h"
 #include "llviewerregion.h"
 #include "llviewerwindow.h"
@@ -167,7 +168,7 @@ void LLPanelContents::onClickNewScript(void *userdata)
 			PERM_NONE,
 			PERM_MOVE | PERM_TRANSFER);
 		std::string desc;
-		LLAssetType::generateDescriptionFor(LLAssetType::AT_LSL_TEXT, desc);
+		LLViewerAssetType::generateDescriptionFor(LLAssetType::AT_LSL_TEXT, desc);
 		LLPointer<LLViewerInventoryItem> new_item =
 			new LLViewerInventoryItem(
 				LLUUID::null,
diff --git a/indra/newview/llpanelimcontrolpanel.cpp b/indra/newview/llpanelimcontrolpanel.cpp
index b54975b76b..21e88b6d07 100644
--- a/indra/newview/llpanelimcontrolpanel.cpp
+++ b/indra/newview/llpanelimcontrolpanel.cpp
@@ -112,21 +112,32 @@ BOOL LLPanelIMControlPanel::postBuild()
 	childSetAction("add_friend_btn", boost::bind(&LLPanelIMControlPanel::onAddFriendButtonClicked, this));
 
 	childSetAction("share_btn", boost::bind(&LLPanelIMControlPanel::onShareButtonClicked, this));
+	childSetAction("teleport_btn", boost::bind(&LLPanelIMControlPanel::onTeleportButtonClicked, this));
+	childSetAction("pay_btn", boost::bind(&LLPanelIMControlPanel::onPayButtonClicked, this));
 	childSetEnabled("add_friend_btn", !LLAvatarActions::isFriend(getChild<LLAvatarIconCtrl>("avatar_icon")->getAvatarId()));
 	
 	return LLPanelChatControlPanel::postBuild();
 }
 
+void LLPanelIMControlPanel::onTeleportButtonClicked()
+{
+	LLAvatarActions::offerTeleport(mAvatarID);
+}
+void LLPanelIMControlPanel::onPayButtonClicked()
+{
+	LLAvatarActions::pay(mAvatarID);
+}
+
 void LLPanelIMControlPanel::onViewProfileButtonClicked()
 {
-	LLAvatarActions::showProfile(getChild<LLAvatarIconCtrl>("avatar_icon")->getAvatarId());
+	LLAvatarActions::showProfile(mAvatarID);
 }
 
 void LLPanelIMControlPanel::onAddFriendButtonClicked()
 {
 	LLAvatarIconCtrl* avatar_icon = getChild<LLAvatarIconCtrl>("avatar_icon");
 	std::string full_name = avatar_icon->getFirstName() + " " + avatar_icon->getLastName();
-	LLAvatarActions::requestFriendshipDialog(avatar_icon->getAvatarId(), full_name);
+	LLAvatarActions::requestFriendshipDialog(mAvatarID, full_name);
 }
 
 void LLPanelIMControlPanel::onShareButtonClicked()
@@ -140,12 +151,12 @@ void LLPanelIMControlPanel::setSessionId(const LLUUID& session_id)
 
 	LLIMModel& im_model = LLIMModel::instance();
 
-	LLUUID avatar_id = im_model.getOtherParticipantID(session_id);
+	mAvatarID = im_model.getOtherParticipantID(session_id);
 
 	// Disable "Add friend" button for friends.
-	childSetEnabled("add_friend_btn", !LLAvatarActions::isFriend(avatar_id));
+	childSetEnabled("add_friend_btn", !LLAvatarActions::isFriend(mAvatarID));
 
-	getChild<LLAvatarIconCtrl>("avatar_icon")->setValue(avatar_id);
+	getChild<LLAvatarIconCtrl>("avatar_icon")->setValue(mAvatarID);
 
 	// Disable profile button if participant is not realy SL avatar
 	LLIMModel::LLIMSession* im_session =
@@ -188,6 +199,20 @@ void LLPanelGroupControlPanel::onGroupInfoButtonClicked()
 	LLGroupActions::show(mGroupID);
 }
 
+void LLPanelGroupControlPanel::onSortMenuItemClicked(const LLSD& userdata)
+{
+	// TODO: Check this code when when sort order menu will be added. (EM)
+	if (false && !mParticipantList)
+		return;
+
+	std::string chosen_item = userdata.asString();
+
+	if (chosen_item == "sort_name")
+	{
+		mParticipantList->setSortOrder(LLParticipantList::E_SORT_BY_NAME);
+	}
+
+}
 
 void LLPanelGroupControlPanel::setSessionId(const LLUUID& session_id)
 {
diff --git a/indra/newview/llpanelimcontrolpanel.h b/indra/newview/llpanelimcontrolpanel.h
index d25f33935a..fa101f4280 100644
--- a/indra/newview/llpanelimcontrolpanel.h
+++ b/indra/newview/llpanelimcontrolpanel.h
@@ -73,6 +73,8 @@ private:
 	void onViewProfileButtonClicked();
 	void onAddFriendButtonClicked();
 	void onShareButtonClicked();
+	void onTeleportButtonClicked();
+	void onPayButtonClicked();
 
 	LLUUID mAvatarID;
 };
@@ -97,6 +99,7 @@ protected:
 
 private:
 	void onGroupInfoButtonClicked();
+	void onSortMenuItemClicked(const LLSD& userdata);
 };
 
 class LLPanelAdHocControlPanel : public LLPanelGroupControlPanel
diff --git a/indra/newview/llpanellandmarkinfo.cpp b/indra/newview/llpanellandmarkinfo.cpp
new file mode 100644
index 0000000000..1152ca6873
--- /dev/null
+++ b/indra/newview/llpanellandmarkinfo.cpp
@@ -0,0 +1,437 @@
+/**
+ * @file llpanellandmarkinfo.cpp
+ * @brief Displays landmark info in Side Tray.
+ *
+ * $LicenseInfo:firstyear=2009&license=viewergpl$
+ *
+ * Copyright (c) 2004-2009, Linden Research, Inc.
+ *
+ * Second Life Viewer Source Code
+ * The source code in this file ("Source Code") is provided by Linden Lab
+ * to you under the terms of the GNU General Public License, version 2.0
+ * ("GPL"), unless you have obtained a separate licensing agreement
+ * ("Other License"), formally executed by you and Linden Lab.  Terms of
+ * the GPL can be found in doc/GPL-license.txt in this distribution, or
+ * online at http://secondlifegrid.net/programs/open_source/licensing/gplv2
+ *
+ * There are special exceptions to the terms and conditions of the GPL as
+ * it is applied to this Source Code. View the full text of the exception
+ * in the file doc/FLOSS-exception.txt in this software distribution, or
+ * online at
+ * http://secondlifegrid.net/programs/open_source/licensing/flossexception
+ *
+ * By copying, modifying or distributing this software, you acknowledge
+ * that you have read and understood your obligations described above,
+ * and agree to abide by those obligations.
+ *
+ * ALL LINDEN LAB SOURCE CODE IS PROVIDED "AS IS." LINDEN LAB MAKES NO
+ * WARRANTIES, EXPRESS, IMPLIED OR OTHERWISE, REGARDING ITS ACCURACY,
+ * COMPLETENESS OR PERFORMANCE.
+ * $/LicenseInfo$
+ */
+
+#include "llviewerprecompiledheaders.h"
+
+#include "llpanellandmarkinfo.h"
+
+#include "llinventory.h"
+
+#include "llcombobox.h"
+#include "lllineeditor.h"
+#include "lltextbox.h"
+#include "lltexteditor.h"
+#include "lltrans.h"
+
+#include "llagent.h"
+#include "llagentui.h"
+#include "llinventorymodel.h"
+#include "lllandmarkactions.h"
+#include "llviewerinventory.h"
+#include "llviewerparcelmgr.h"
+#include "llviewerregion.h"
+
+//----------------------------------------------------------------------------
+// Aux types and methods
+//----------------------------------------------------------------------------
+
+typedef std::pair<LLUUID, std::string> folder_pair_t;
+
+static bool cmp_folders(const folder_pair_t& left, const folder_pair_t& right);
+static void collectLandmarkFolders(LLInventoryModel::cat_array_t& cats);
+
+static LLRegisterPanelClassWrapper<LLPanelLandmarkInfo> t_landmark_info("panel_landmark_info");
+
+LLPanelLandmarkInfo::LLPanelLandmarkInfo()
+:	LLPanelPlaceInfo()
+{}
+
+// virtual
+LLPanelLandmarkInfo::~LLPanelLandmarkInfo()
+{}
+
+// virtual
+BOOL LLPanelLandmarkInfo::postBuild()
+{
+	LLPanelPlaceInfo::postBuild();
+
+	mOwner = getChild<LLTextBox>("owner");
+	mCreator = getChild<LLTextBox>("creator");
+	mCreated = getChild<LLTextBox>("created");
+
+	mTitleEditor = getChild<LLLineEditor>("title_editor");
+	mNotesEditor = getChild<LLTextEditor>("notes_editor");
+	mFolderCombo = getChild<LLComboBox>("folder_combo");
+
+	return TRUE;
+}
+
+// virtual
+void LLPanelLandmarkInfo::resetLocation()
+{
+	LLPanelPlaceInfo::resetLocation();
+
+	std::string not_available = getString("not_available");
+	mCreator->setText(not_available);
+	mOwner->setText(not_available);
+	mCreated->setText(not_available);
+	mTitleEditor->setText(LLStringUtil::null);
+	mNotesEditor->setText(LLStringUtil::null);
+}
+
+// virtual
+void LLPanelLandmarkInfo::setInfoType(INFO_TYPE type)
+{
+	LLPanel* landmark_info_panel = getChild<LLPanel>("landmark_info_panel");
+
+	bool is_info_type_create_landmark = type == CREATE_LANDMARK;
+	bool is_info_type_landmark = type == LANDMARK;
+
+	landmark_info_panel->setVisible(is_info_type_landmark);
+
+	getChild<LLTextBox>("folder_label")->setVisible(is_info_type_create_landmark);
+	mFolderCombo->setVisible(is_info_type_create_landmark);
+
+	switch(type)
+	{
+		case CREATE_LANDMARK:
+			mCurrentTitle = getString("title_create_landmark");
+
+			mTitleEditor->setEnabled(TRUE);
+			mNotesEditor->setEnabled(TRUE);
+		break;
+
+		case LANDMARK:
+		default:
+			mCurrentTitle = getString("title_landmark");
+
+			mTitleEditor->setEnabled(FALSE);
+			mNotesEditor->setEnabled(FALSE);
+		break;
+	}
+
+	populateFoldersList();
+
+	LLPanelPlaceInfo::setInfoType(type);
+}
+
+// virtual
+void LLPanelLandmarkInfo::processParcelInfo(const LLParcelData& parcel_data)
+{
+	LLPanelPlaceInfo::processParcelInfo(parcel_data);
+
+	// HACK: Flag 0x2 == adult region,
+	// Flag 0x1 == mature region, otherwise assume PG
+	std::string rating = LLViewerRegion::accessToString(SIM_ACCESS_PG);
+	if (parcel_data.flags & 0x2)
+	{
+		rating = LLViewerRegion::accessToString(SIM_ACCESS_ADULT);
+	}
+	else if (parcel_data.flags & 0x1)
+	{
+		rating = LLViewerRegion::accessToString(SIM_ACCESS_MATURE);
+	}
+
+	mMaturityRatingText->setValue(rating);
+
+	S32 region_x;
+	S32 region_y;
+	S32 region_z;
+
+	// If the region position is zero, grab position from the global
+	if(mPosRegion.isExactlyZero())
+	{
+		region_x = llround(parcel_data.global_x) % REGION_WIDTH_UNITS;
+		region_y = llround(parcel_data.global_y) % REGION_WIDTH_UNITS;
+		region_z = llround(parcel_data.global_z);
+	}
+	else
+	{
+		region_x = llround(mPosRegion.mV[VX]);
+		region_y = llround(mPosRegion.mV[VY]);
+		region_z = llround(mPosRegion.mV[VZ]);
+	}
+
+	if (mInfoType == CREATE_LANDMARK)
+	{
+		if (parcel_data.name.empty())
+		{
+			mTitleEditor->setText(llformat("%s (%d, %d, %d)",
+								  parcel_data.sim_name.c_str(), region_x, region_y, region_z));
+		}
+		else
+		{
+			mTitleEditor->setText(parcel_data.name);
+		}
+
+		std::string desc;
+		LLAgentUI::buildLocationString(desc, LLAgentUI::LOCATION_FORMAT_FULL, gAgent.getPositionAgent());
+		mNotesEditor->setText(desc);
+
+		if (!LLLandmarkActions::landmarkAlreadyExists())
+		{
+			createLandmark(mFolderCombo->getValue().asUUID());
+		}
+	}
+}
+
+void LLPanelLandmarkInfo::displayItemInfo(const LLInventoryItem* pItem)
+{
+	if (!pItem)
+		return;
+
+	if(!gCacheName)
+		return;
+
+	const LLPermissions& perm = pItem->getPermissions();
+
+	//////////////////
+	// CREATOR NAME //
+	//////////////////
+	if (pItem->getCreatorUUID().notNull())
+	{
+		std::string name;
+		LLUUID creator_id = pItem->getCreatorUUID();
+		if (!gCacheName->getFullName(creator_id, name))
+		{
+			gCacheName->get(creator_id, FALSE,
+							boost::bind(&LLPanelPlaceInfo::nameUpdatedCallback, mCreator, _2, _3));
+		}
+		mCreator->setText(name);
+	}
+	else
+	{
+		mCreator->setText(getString("unknown"));
+	}
+
+	////////////////
+	// OWNER NAME //
+	////////////////
+	if(perm.isOwned())
+	{
+		std::string name;
+		if (perm.isGroupOwned())
+		{
+			LLUUID group_id = perm.getGroup();
+			if (!gCacheName->getGroupName(group_id, name))
+			{
+				gCacheName->get(group_id, TRUE,
+								boost::bind(&LLPanelPlaceInfo::nameUpdatedCallback, mOwner, _2, _3));
+			}
+		}
+		else
+		{
+			LLUUID owner_id = perm.getOwner();
+			if (!gCacheName->getFullName(owner_id, name))
+			{
+				gCacheName->get(owner_id, FALSE,
+								boost::bind(&LLPanelPlaceInfo::nameUpdatedCallback, mOwner, _2, _3));
+			}
+		}
+		mOwner->setText(name);
+	}
+	else
+	{
+		mOwner->setText(getString("public"));
+	}
+
+	//////////////////
+	// ACQUIRE DATE //
+	//////////////////
+	time_t time_utc = pItem->getCreationDate();
+	if (0 == time_utc)
+	{
+		mCreated->setText(getString("unknown"));
+	}
+	else
+	{
+		std::string timeStr = getString("acquired_date");
+		LLSD substitution;
+		substitution["datetime"] = (S32) time_utc;
+		LLStringUtil::format (timeStr, substitution);
+		mCreated->setText(timeStr);
+	}
+
+	mTitleEditor->setText(pItem->getName());
+	mNotesEditor->setText(pItem->getDescription());
+}
+
+void LLPanelLandmarkInfo::toggleLandmarkEditMode(BOOL enabled)
+{
+	// If switching to edit mode while creating landmark
+	// the "Create Landmark" title remains.
+	if (enabled && mInfoType != CREATE_LANDMARK)
+	{
+		mTitle->setText(getString("title_edit_landmark"));
+	}
+	else
+	{
+		mTitle->setText(mCurrentTitle);
+	}
+
+	if (mNotesEditor->getReadOnly() ==  (enabled == TRUE))
+	{
+		mTitleEditor->setEnabled(enabled);
+		mNotesEditor->setReadOnly(!enabled);
+		mFolderCombo->setVisible(enabled);
+		getChild<LLTextBox>("folder_label")->setVisible(enabled);
+
+		// HACK: To change the text color in a text editor
+		// when it was enabled/disabled we set the text once again.
+		mNotesEditor->setText(mNotesEditor->getText());
+	}
+}
+
+const std::string& LLPanelLandmarkInfo::getLandmarkTitle() const
+{
+	return mTitleEditor->getText();
+}
+
+const std::string LLPanelLandmarkInfo::getLandmarkNotes() const
+{
+	return mNotesEditor->getText();
+}
+
+const LLUUID LLPanelLandmarkInfo::getLandmarkFolder() const
+{
+	return mFolderCombo->getValue().asUUID();
+}
+
+BOOL LLPanelLandmarkInfo::setLandmarkFolder(const LLUUID& id)
+{
+	return mFolderCombo->setCurrentByID(id);
+}
+
+void LLPanelLandmarkInfo::createLandmark(const LLUUID& folder_id)
+{
+	std::string name = mTitleEditor->getText();
+	std::string desc = mNotesEditor->getText();
+
+	LLStringUtil::trim(name);
+	LLStringUtil::trim(desc);
+
+	// If typed name is empty use the parcel name instead.
+	if (name.empty())
+	{
+		name = mParcelName->getText();
+
+		// If no parcel exists use the region name instead.
+		if (name.empty())
+		{
+			name = mRegionName->getText();
+		}
+	}
+
+	LLStringUtil::replaceChar(desc, '\n', ' ');
+	// If no folder chosen use the "Landmarks" folder.
+	LLLandmarkActions::createLandmarkHere(name, desc,
+		folder_id.notNull() ? folder_id : gInventory.findCategoryUUIDForType(LLAssetType::AT_LANDMARK));
+}
+
+// static
+std::string LLPanelLandmarkInfo::getFullFolderName(const LLViewerInventoryCategory* cat)
+{
+	std::string name = cat->getName();
+	LLUUID parent_id;
+
+	// translate category name, if it's right below the root
+	// FIXME: it can throw notification about non existent string in strings.xml
+	if (cat->getParentUUID().notNull() && cat->getParentUUID() == gInventory.getRootFolderID())
+	{
+		LLTrans::findString(name, "InvFolder " + name);
+	}
+
+	// we don't want "My Inventory" to appear in the name
+	while ((parent_id = cat->getParentUUID()).notNull() && parent_id != gInventory.getRootFolderID())
+	{
+		cat = gInventory.getCategory(parent_id);
+		name = cat->getName() + "/" + name;
+	}
+
+	return name;
+}
+
+void LLPanelLandmarkInfo::populateFoldersList()
+{
+	// Collect all folders that can contain landmarks.
+	LLInventoryModel::cat_array_t cats;
+	collectLandmarkFolders(cats);
+
+	mFolderCombo->removeall();
+
+	// Put the "Landmarks" folder first in list.
+	LLUUID landmarks_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_LANDMARK);
+	const LLViewerInventoryCategory* cat = gInventory.getCategory(landmarks_id);
+	if (!cat)
+	{
+		llwarns << "Cannot find the landmarks folder" << llendl;
+	}
+	std::string cat_full_name = getFullFolderName(cat);
+	mFolderCombo->add(cat_full_name, cat->getUUID());
+
+	typedef std::vector<folder_pair_t> folder_vec_t;
+	folder_vec_t folders;
+	// Sort the folders by their full name.
+	for (S32 i = 0; i < cats.count(); i++)
+	{
+		cat = cats.get(i);
+		cat_full_name = getFullFolderName(cat);
+		folders.push_back(folder_pair_t(cat->getUUID(), cat_full_name));
+	}
+	sort(folders.begin(), folders.end(), cmp_folders);
+
+	// Finally, populate the combobox.
+	for (folder_vec_t::const_iterator it = folders.begin(); it != folders.end(); it++)
+		mFolderCombo->add(it->second, LLSD(it->first));
+}
+
+static bool cmp_folders(const folder_pair_t& left, const folder_pair_t& right)
+{
+	return left.second < right.second;
+}
+
+static void collectLandmarkFolders(LLInventoryModel::cat_array_t& cats)
+{
+	LLUUID landmarks_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_LANDMARK);
+
+	// Add descendent folders of the "Landmarks" category.
+	LLInventoryModel::item_array_t items; // unused
+	LLIsType is_category(LLAssetType::AT_CATEGORY);
+	gInventory.collectDescendentsIf(
+		landmarks_id,
+		cats,
+		items,
+		LLInventoryModel::EXCLUDE_TRASH,
+		is_category);
+
+	// Add the "My Favorites" category.
+	LLUUID favorites_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_FAVORITE);
+	LLViewerInventoryCategory* favorites_cat = gInventory.getCategory(favorites_id);
+	if (!favorites_cat)
+	{
+		llwarns << "Cannot find the favorites folder" << llendl;
+	}
+	else
+	{
+		cats.put(favorites_cat);
+	}
+}
diff --git a/indra/newview/llpanellandmarkinfo.h b/indra/newview/llpanellandmarkinfo.h
new file mode 100644
index 0000000000..03377986b3
--- /dev/null
+++ b/indra/newview/llpanellandmarkinfo.h
@@ -0,0 +1,85 @@
+/**
+ * @file llpanellandmarkinfo.h
+ * @brief Displays landmark info in Side Tray.
+ *
+ * $LicenseInfo:firstyear=2009&license=viewergpl$
+ *
+ * Copyright (c) 2004-2009, Linden Research, Inc.
+ *
+ * Second Life Viewer Source Code
+ * The source code in this file ("Source Code") is provided by Linden Lab
+ * to you under the terms of the GNU General Public License, version 2.0
+ * ("GPL"), unless you have obtained a separate licensing agreement
+ * ("Other License"), formally executed by you and Linden Lab.  Terms of
+ * the GPL can be found in doc/GPL-license.txt in this distribution, or
+ * online at http://secondlifegrid.net/programs/open_source/licensing/gplv2
+ *
+ * There are special exceptions to the terms and conditions of the GPL as
+ * it is applied to this Source Code. View the full text of the exception
+ * in the file doc/FLOSS-exception.txt in this software distribution, or
+ * online at
+ * http://secondlifegrid.net/programs/open_source/licensing/flossexception
+ *
+ * By copying, modifying or distributing this software, you acknowledge
+ * that you have read and understood your obligations described above,
+ * and agree to abide by those obligations.
+ *
+ * ALL LINDEN LAB SOURCE CODE IS PROVIDED "AS IS." LINDEN LAB MAKES NO
+ * WARRANTIES, EXPRESS, IMPLIED OR OTHERWISE, REGARDING ITS ACCURACY,
+ * COMPLETENESS OR PERFORMANCE.
+ * $/LicenseInfo$
+ */
+
+#ifndef LL_LLPANELLANDMARKINFO_H
+#define LL_LLPANELLANDMARKINFO_H
+
+#include "llpanelplaceinfo.h"
+
+class LLComboBox;
+class LLLineEditor;
+class LLTextEditor;
+
+class LLPanelLandmarkInfo : public LLPanelPlaceInfo
+{
+public:
+	LLPanelLandmarkInfo();
+	/*virtual*/ ~LLPanelLandmarkInfo();
+
+	/*virtual*/ BOOL postBuild();
+
+	/*virtual*/ void resetLocation();
+
+	/*virtual*/ void setInfoType(INFO_TYPE type);
+
+	/*virtual*/ void processParcelInfo(const LLParcelData& parcel_data);
+
+	// Displays landmark owner, creator and creation date info.
+	void displayItemInfo(const LLInventoryItem* pItem);
+
+	void toggleLandmarkEditMode(BOOL enabled);
+
+	const std::string& getLandmarkTitle() const;
+	const std::string getLandmarkNotes() const;
+	const LLUUID getLandmarkFolder() const;
+
+	// Select current landmark folder in combobox.
+	BOOL setLandmarkFolder(const LLUUID& id);
+
+	// Create a landmark for the current location
+	// in a folder specified by folder_id.
+	void createLandmark(const LLUUID& folder_id);
+
+	static std::string getFullFolderName(const LLViewerInventoryCategory* cat);
+
+private:
+	void populateFoldersList();
+
+	LLTextBox*			mOwner;
+	LLTextBox*			mCreator;
+	LLTextBox*			mCreated;
+	LLLineEditor*		mTitleEditor;
+	LLTextEditor*		mNotesEditor;
+	LLComboBox*			mFolderCombo;
+};
+
+#endif // LL_LLPANELLANDMARKINFO_H
diff --git a/indra/newview/llpanellandmarks.cpp b/indra/newview/llpanellandmarks.cpp
index 91e1590dc3..6d6fd38cce 100644
--- a/indra/newview/llpanellandmarks.cpp
+++ b/indra/newview/llpanellandmarks.cpp
@@ -553,14 +553,16 @@ void LLLandmarksPanel::onAddAction(const LLSD& userdata) const
 	std::string command_name = userdata.asString();
 	if("add_landmark" == command_name)
 	{
-		if(LLLandmarkActions::landmarkAlreadyExists())
+		LLViewerInventoryItem* landmark = LLLandmarkActions::findLandmarkForAgentPos();
+		if(landmark)
+		{
+			LLSideTray::getInstance()->showPanel("panel_places", 
+								LLSD().insert("type", "landmark").insert("id",landmark->getUUID()));
+		}
+		else
 		{
-			std::string location;
-			LLAgentUI::buildLocationString(location, LLAgentUI::LOCATION_FORMAT_FULL);
-			llwarns<<" Landmark already exists at location:  "<< location<<llendl;
-			return;
+			LLSideTray::getInstance()->showPanel("panel_places", LLSD().insert("type", "create_landmark"));
 		}
-		LLSideTray::getInstance()->showPanel("panel_places", LLSD().insert("type", "create_landmark"));
 	} 
 	else if ("category" == command_name)
 	{
@@ -584,7 +586,7 @@ void LLLandmarksPanel::onAddAction(const LLSD& userdata) const
 			menu_create_inventory_item(mCurrentSelectedList->getRootFolder(),
 					dynamic_cast<LLFolderBridge*> (folder_bridge), LLSD(
 							"category"), gInventory.findCategoryUUIDForType(
-							LLAssetType::AT_LANDMARK));
+							LLFolderType::FT_LANDMARK));
 		}
 	}
 }
@@ -616,19 +618,21 @@ void LLLandmarksPanel::onClipboardAction(const LLSD& userdata) const
 
 void LLLandmarksPanel::onFoldingAction(const LLSD& userdata)
 {
-	if(!mCurrentSelectedList) return;
-
-	LLFolderView* root_folder = mCurrentSelectedList->getRootFolder();
+	LLFolderView* landmarks_folder = mLandmarksInventoryPanel->getRootFolder();
+	LLFolderView* fav_folder = mFavoritesInventoryPanel->getRootFolder();
 	std::string command_name = userdata.asString();
 
 	if ("expand_all" == command_name)
 	{
-		root_folder->setOpenArrangeRecursively(TRUE, LLFolderViewFolder::RECURSE_DOWN);
-		root_folder->arrangeAll();
+		landmarks_folder->setOpenArrangeRecursively(TRUE, LLFolderViewFolder::RECURSE_DOWN);
+		fav_folder->setOpenArrangeRecursively(TRUE, LLFolderViewFolder::RECURSE_DOWN);
+		landmarks_folder->arrangeAll();
+		fav_folder->arrangeAll();
 	}
 	else if ("collapse_all" == command_name)
 	{
-		root_folder->closeAllFolders();
+		landmarks_folder->closeAllFolders();
+		fav_folder->closeAllFolders();
 	}
 	else if ( "sort_by_date" == command_name)
 	{
@@ -639,6 +643,9 @@ void LLLandmarksPanel::onFoldingAction(const LLSD& userdata)
 	}
 	else
 	{
+		if(!mCurrentSelectedList) return;
+
+		LLFolderView* root_folder = mCurrentSelectedList->getRootFolder();
 		root_folder->doToSelected(&gInventory, userdata);
 	}
 }
diff --git a/indra/newview/llpanelmaininventory.cpp b/indra/newview/llpanelmaininventory.cpp
index 617445a27f..25be09fa24 100644
--- a/indra/newview/llpanelmaininventory.cpp
+++ b/indra/newview/llpanelmaininventory.cpp
@@ -84,8 +84,8 @@ LLPanelMainInventory::LLPanelMainInventory()
 	// Menu Callbacks (non contex menus)
 	mCommitCallbackRegistrar.add("Inventory.DoToSelected", boost::bind(&LLPanelMainInventory::doToSelected, this, _2));
 	mCommitCallbackRegistrar.add("Inventory.CloseAllFolders", boost::bind(&LLPanelMainInventory::closeAllFolders, this));
-	mCommitCallbackRegistrar.add("Inventory.EmptyTrash", boost::bind(&LLInventoryModel::emptyFolderType, &gInventory, "ConfirmEmptyTrash", LLAssetType::AT_TRASH));
-	mCommitCallbackRegistrar.add("Inventory.EmptyLostAndFound", boost::bind(&LLInventoryModel::emptyFolderType, &gInventory, "ConfirmEmptyLostAndFound", LLAssetType::AT_LOST_AND_FOUND));
+	mCommitCallbackRegistrar.add("Inventory.EmptyTrash", boost::bind(&LLInventoryModel::emptyFolderType, &gInventory, "ConfirmEmptyTrash", LLFolderType::FT_TRASH));
+	mCommitCallbackRegistrar.add("Inventory.EmptyLostAndFound", boost::bind(&LLInventoryModel::emptyFolderType, &gInventory, "ConfirmEmptyLostAndFound", LLFolderType::FT_LOST_AND_FOUND));
 	mCommitCallbackRegistrar.add("Inventory.DoCreate", boost::bind(&LLPanelMainInventory::doCreate, this, _2));
  	mCommitCallbackRegistrar.add("Inventory.NewWindow", boost::bind(&LLPanelMainInventory::newWindow, this));
 	mCommitCallbackRegistrar.add("Inventory.ShowFilters", boost::bind(&LLPanelMainInventory::toggleFindOptions, this));
diff --git a/indra/newview/llpanelobjectinventory.cpp b/indra/newview/llpanelobjectinventory.cpp
index 68181f12b9..79b33e29f5 100644
--- a/indra/newview/llpanelobjectinventory.cpp
+++ b/indra/newview/llpanelobjectinventory.cpp
@@ -60,6 +60,7 @@
 #include "llsidetray.h"
 #include "llstatusbar.h"
 #include "lltrans.h"
+#include "llviewerassettype.h"
 #include "llviewerregion.h"
 #include "llviewerobjectlist.h"
 #include "llviewermessage.h"
@@ -102,7 +103,7 @@ public:
 	virtual const std::string& getName() const;
 	virtual const std::string& getDisplayName() const;
 	virtual PermissionMask getPermissionMask() const { return PERM_NONE; }
-	/*virtual*/ LLAssetType::EType getPreferredType() const { return LLAssetType::AT_NONE; }
+	/*virtual*/ LLFolderType::EType getPreferredType() const { return LLFolderType::FT_NONE; }
 	virtual const LLUUID& getUUID() const { return mUUID; }
 	virtual time_t getCreationDate() const;
 	virtual LLUIImagePtr getIcon() const;
@@ -275,7 +276,7 @@ bool LLTaskInvFVBridge::commitBuyItem(const LLSD& notification, const LLSD& resp
 		msg->addUUIDFast(_PREHASH_ObjectID, notification["payload"]["task_id"].asUUID());
 		msg->addUUIDFast(_PREHASH_ItemID, notification["payload"]["item_id"].asUUID());
 		msg->addUUIDFast(_PREHASH_FolderID,
-			gInventory.findCategoryUUIDForType((LLAssetType::EType)notification["payload"]["type"].asInteger()));
+			gInventory.findCategoryUUIDForType((LLFolderType::EType)notification["payload"]["type"].asInteger()));
 		msg->sendReliable(object->getRegion()->getHost());
 	}
 	return false;
@@ -573,7 +574,7 @@ BOOL LLTaskInvFVBridge::startDrag(EDragAndDropType* type, LLUUID* id) const
 //				   || gAgent.isGodlike())
 
 				{
-					*type = LLAssetType::lookupDragAndDropType(inv->getType());
+					*type = LLViewerAssetType::lookupDragAndDropType(inv->getType());
 
 					*id = inv->getUUID();
 					return TRUE;
@@ -778,7 +779,7 @@ BOOL LLTaskCategoryBridge::startDrag(EDragAndDropType* type, LLUUID* id) const
 //				   || gAgent.isGodlike())
 
 				{
-					*type = LLAssetType::lookupDragAndDropType(inv->getType());
+					*type = LLViewerAssetType::lookupDragAndDropType(inv->getType());
 
 					*id = inv->getUUID();
 					return TRUE;
@@ -1461,7 +1462,6 @@ LLTaskInvFVBridge* LLTaskInvFVBridge::createObjectBridge(LLPanelObjectInventory*
 											  item->getFlags());
 		break;
 	case LLAssetType::AT_CATEGORY:
-	case LLAssetType::AT_FAVORITE:
 		new_bridge = new LLTaskCategoryBridge(panel,
 											  object->getUUID(),
 											  object->getName());
@@ -1503,8 +1503,8 @@ LLPanelObjectInventory::LLPanelObjectInventory(const LLPanelObjectInventory::Par
 {
 	// Setup context menu callbacks
 	mCommitCallbackRegistrar.add("Inventory.DoToSelected", boost::bind(&LLPanelObjectInventory::doToSelected, this, _2));
-	mCommitCallbackRegistrar.add("Inventory.EmptyTrash", boost::bind(&LLInventoryModel::emptyFolderType, &gInventory, "ConfirmEmptyTrash", LLAssetType::AT_TRASH));
-	mCommitCallbackRegistrar.add("Inventory.EmptyLostAndFound", boost::bind(&LLInventoryModel::emptyFolderType, &gInventory, "ConfirmEmptyLostAndFound", LLAssetType::AT_LOST_AND_FOUND));
+	mCommitCallbackRegistrar.add("Inventory.EmptyTrash", boost::bind(&LLInventoryModel::emptyFolderType, &gInventory, "ConfirmEmptyTrash", LLFolderType::FT_TRASH));
+	mCommitCallbackRegistrar.add("Inventory.EmptyLostAndFound", boost::bind(&LLInventoryModel::emptyFolderType, &gInventory, "ConfirmEmptyLostAndFound", LLFolderType::FT_LOST_AND_FOUND));
 	mCommitCallbackRegistrar.add("Inventory.DoCreate", boost::bind(&do_nothing));
 	mCommitCallbackRegistrar.add("Inventory.AttachObject", boost::bind(&do_nothing));
 	mCommitCallbackRegistrar.add("Inventory.BeginIMSession", boost::bind(&do_nothing));
diff --git a/indra/newview/llpanelpeople.cpp b/indra/newview/llpanelpeople.cpp
index 4580eeb336..2f8fae0f5d 100644
--- a/indra/newview/llpanelpeople.cpp
+++ b/indra/newview/llpanelpeople.cpp
@@ -42,6 +42,7 @@
 #include "llpanelpeople.h"
 
 // newview
+#include "llaccordionctrl.h"
 #include "llaccordionctrltab.h"
 #include "llagent.h"
 #include "llavataractions.h"
@@ -516,6 +517,9 @@ BOOL LLPanelPeople::postBuild()
 	// call this method in case some list is empty and buttons can be in inconsistent state
 	updateButtons();
 
+	mOnlineFriendList->setRefreshCompleteCallback(boost::bind(&LLPanelPeople::onFriendListRefreshComplete, this, _1, _2));
+	mAllFriendList->setRefreshCompleteCallback(boost::bind(&LLPanelPeople::onFriendListRefreshComplete, this, _1, _2));
+
 	return TRUE;
 }
 
@@ -560,6 +564,8 @@ void LLPanelPeople::updateFriendList()
 
 	mOnlineFriendList->setDirty();
 	mAllFriendList->setDirty();
+
+	showFriendsAccordionsIfNeeded();
 }
 
 void LLPanelPeople::updateNearbyList()
@@ -797,14 +803,15 @@ void LLPanelPeople::reSelectedCurrentTab()
 
 void LLPanelPeople::onFilterEdit(const std::string& search_string)
 {
-	if (mFilterSubString == search_string)
-		return;
+	std::string search_upper = search_string;
+	// Searches are case-insensitive
+	LLStringUtil::toUpper(search_upper);
+	LLStringUtil::trimHead(search_upper);
 
-	mFilterSubString = search_string;
+	if (mFilterSubString == search_upper)
+		return;
 
-	// Searches are case-insensitive
-	LLStringUtil::toUpper(mFilterSubString);
-	LLStringUtil::trimHead(mFilterSubString);
+	mFilterSubString = search_upper;
 
 	// Apply new filter.
 	mNearbyList->setNameFilter(mFilterSubString);
@@ -812,6 +819,8 @@ void LLPanelPeople::onFilterEdit(const std::string& search_string)
 	mAllFriendList->setNameFilter(mFilterSubString);
 	mRecentList->setNameFilter(mFilterSubString);
 	mGroupList->setNameFilter(mFilterSubString);
+
+	showFriendsAccordionsIfNeeded();
 }
 
 void LLPanelPeople::onTabSelected(const LLSD& param)
@@ -1124,3 +1133,49 @@ void	LLPanelPeople::onOpen(const LLSD& key)
 	else
 		reSelectedCurrentTab();
 }
+
+void LLPanelPeople::showAccordion(const std::string name, bool show)
+{
+	if(name.empty())
+	{
+		llwarns << "No name provided" << llendl;
+		return;
+	}
+
+	LLAccordionCtrlTab* tab = getChild<LLAccordionCtrlTab>(name);
+	tab->setVisible(show);
+	if(show)
+	{
+		// expand accordion
+		tab->changeOpenClose(false);
+	}
+}
+
+void LLPanelPeople::showFriendsAccordionsIfNeeded()
+{
+	if(FRIENDS_TAB_NAME == getActiveTabName())
+	{
+		// Expand and show accordions if needed, else - hide them
+		showAccordion("tab_online", mOnlineFriendList->filterHasMatches());
+		showAccordion("tab_all", mAllFriendList->filterHasMatches());
+
+		// Rearrange accordions
+		LLAccordionCtrl* accordion = getChild<LLAccordionCtrl>("friends_accordion");
+		accordion->arrange();
+	}
+}
+
+void LLPanelPeople::onFriendListRefreshComplete(LLUICtrl*ctrl, const LLSD& param)
+{
+	if(ctrl == mOnlineFriendList)
+	{
+		showAccordion("tab_online", param.asInteger());
+	}
+	else if(ctrl == mAllFriendList)
+	{
+		showAccordion("tab_all", param.asInteger());
+	}
+
+	LLAccordionCtrl* accordion = getChild<LLAccordionCtrl>("friends_accordion");
+	accordion->arrange();
+}
diff --git a/indra/newview/llpanelpeople.h b/indra/newview/llpanelpeople.h
index dc0aaeb70f..9bf9befe90 100644
--- a/indra/newview/llpanelpeople.h
+++ b/indra/newview/llpanelpeople.h
@@ -124,6 +124,12 @@ private:
 
 	void					onFriendsAccordionExpandedCollapsed(const LLSD& param, LLAvatarList* avatar_list);
 
+	void					showAccordion(const std::string name, bool show);
+
+	void					showFriendsAccordionsIfNeeded();
+
+	void					onFriendListRefreshComplete(LLUICtrl*ctrl, const LLSD& param);
+
 	LLFilterEditor*			mFilterEditor;
 	LLTabContainer*			mTabContainer;
 	LLAvatarList*			mOnlineFriendList;
diff --git a/indra/newview/llpanelplaceinfo.cpp b/indra/newview/llpanelplaceinfo.cpp
index 34644cfe42..2c5f4b5afa 100644
--- a/indra/newview/llpanelplaceinfo.cpp
+++ b/indra/newview/llpanelplaceinfo.cpp
@@ -1,6 +1,6 @@
 /**
  * @file llpanelplaceinfo.cpp
- * @brief Displays place information in Side Tray.
+ * @brief Base class for place information in Side Tray.
  *
  * $LicenseInfo:firstyear=2009&license=viewergpl$
  * 
@@ -39,66 +39,34 @@
 #include "llsecondlifeurls.h"
 
 #include "llinventory.h"
-#include "llparcel.h"
 
-#include "llqueryflags.h"
+#include "llsdutil_math.h"
 
-#include "llbutton.h"
-#include "llcombobox.h"
-#include "lliconctrl.h"
 #include "llscrollcontainer.h"
 #include "lltextbox.h"
-#include "lltrans.h"
 
-#include "llaccordionctrl.h"
-#include "llaccordionctrltab.h"
 #include "llagent.h"
-#include "llagentui.h"
-#include "llappviewer.h"
 #include "llavatarpropertiesprocessor.h"
-#include "llcallbacklist.h"
 #include "llexpandabletextbox.h"
 #include "llfloaterworldmap.h"
-#include "llfloaterbuycurrency.h"
 #include "llinventorymodel.h"
-#include "lllandmarkactions.h"
 #include "llpanelpick.h"
 #include "lltexturectrl.h"
-#include "llstatusbar.h"
 #include "llviewerinventory.h"
 #include "llviewerparcelmgr.h"
 #include "llviewerregion.h"
-#include "llviewercontrol.h" 
 #include "llviewertexteditor.h"
 #include "llworldmap.h"
-#include "llsdutil_math.h"
-
-//----------------------------------------------------------------------------
-// Aux types and methods
-//----------------------------------------------------------------------------
-
-typedef std::pair<LLUUID, std::string> folder_pair_t;
-
-static bool cmp_folders(const folder_pair_t& left, const folder_pair_t& right);
-static void collectLandmarkFolders(LLInventoryModel::cat_array_t& cats);
-
-static LLRegisterPanelClassWrapper<LLPanelPlaceInfo> t_place_info("panel_place_info");
 
 LLPanelPlaceInfo::LLPanelPlaceInfo()
 :	LLPanel(),
 	mParcelID(),
 	mRequestedID(),
 	mPosRegion(),
-	mLandmarkID(),
-	mMinHeight(0),
-	mScrollingPanel(NULL),
-	mInfoPanel(NULL),
-	mMediaPanel(NULL),
-	mForSalePanel(NULL),
-	mYouAreHerePanel(NULL),
-	mSelectedParcelID(-1)
+	mMinHeight(0)
 {}
 
+//virtual
 LLPanelPlaceInfo::~LLPanelPlaceInfo()
 {
 	if (mParcelID.notNull())
@@ -107,220 +75,41 @@ LLPanelPlaceInfo::~LLPanelPlaceInfo()
 	}
 }
 
+//virtual
 BOOL LLPanelPlaceInfo::postBuild()
 {
-	mTitle = getChild<LLTextBox>("panel_title");
+	mTitle = getChild<LLTextBox>("title");
 	mCurrentTitle = mTitle->getText();
 
-	mForSalePanel = getChild<LLPanel>("for_sale_panel");
-	mYouAreHerePanel = getChild<LLPanel>("here_panel");
-	gIdleCallbacks.addFunction(&LLPanelPlaceInfo::updateYouAreHereBanner, this);
-	
-	//Icon value should contain sale price of last selected parcel. 
-	mForSalePanel->getChild<LLIconCtrl>("icon_for_sale")->
-				setMouseDownCallback(boost::bind(&LLPanelPlaceInfo::onForSaleBannerClick, this));
-
 	mSnapshotCtrl = getChild<LLTextureCtrl>("logo");
 	mRegionName = getChild<LLTextBox>("region_title");
 	mParcelName = getChild<LLTextBox>("parcel_title");
 	mDescEditor = getChild<LLExpandableTextBox>("description");
 
 	mMaturityRatingText = getChild<LLTextBox>("maturity_value");
-	mParcelOwner = getChild<LLTextBox>("owner_value");
-	mLastVisited = getChild<LLTextBox>("last_visited_value");
-
-	mRatingText = getChild<LLTextBox>("rating_value");
-	mVoiceText = getChild<LLTextBox>("voice_value");
-	mFlyText = getChild<LLTextBox>("fly_value");
-	mPushText = getChild<LLTextBox>("push_value");
-	mBuildText = getChild<LLTextBox>("build_value");
-	mScriptsText = getChild<LLTextBox>("scripts_value");
-	mDamageText = getChild<LLTextBox>("damage_value");
-
-	mRegionNameText = getChild<LLTextBox>("region_name");
-	mRegionTypeText = getChild<LLTextBox>("region_type");
-	mRegionRatingText = getChild<LLTextBox>("region_rating");
-	mRegionOwnerText = getChild<LLTextBox>("region_owner");
-	mRegionGroupText = getChild<LLTextBox>("region_group");
-
-	mEstateNameText = getChild<LLTextBox>("estate_name");
-	mEstateRatingText = getChild<LLTextBox>("estate_rating");
-	mEstateOwnerText = getChild<LLTextBox>("estate_owner");
-	mCovenantText = getChild<LLTextEditor>("covenant");
-
-	mSalesPriceText = getChild<LLTextBox>("sales_price");
-	mAreaText = getChild<LLTextBox>("area");
-	mTrafficText = getChild<LLTextBox>("traffic");
-	mPrimitivesText = getChild<LLTextBox>("primitives");
-	mParcelScriptsText = getChild<LLTextBox>("parcel_scripts");
-	mTerraformLimitsText = getChild<LLTextBox>("terraform_limits");
-	mSubdivideText = getChild<LLTextEditor>("subdivide");
-	mResaleText = getChild<LLTextEditor>("resale");
-	mSaleToText = getChild<LLTextBox>("sale_to");
 
-	mOwner = getChild<LLTextBox>("owner");
-	mCreator = getChild<LLTextBox>("creator");
-	mCreated = getChild<LLTextBox>("created");
-
-	mTitleEditor = getChild<LLLineEditor>("title_editor");
-	mNotesEditor = getChild<LLTextEditor>("notes_editor");
-	mFolderCombo = getChild<LLComboBox>("folder_combo");
-
-	LLScrollContainer* scroll_container = getChild<LLScrollContainer>("scroll_container");
+	LLScrollContainer* scroll_container = getChild<LLScrollContainer>("place_scroll");
 	scroll_container->setBorderVisible(FALSE);
 	mMinHeight = scroll_container->getScrolledViewRect().getHeight();
 
-	mScrollingPanel = getChild<LLPanel>("scrolling_panel");
-	mInfoPanel = getChild<LLPanel>("info_panel");
-	mMediaPanel = getChild<LLMediaPanel>("media_panel");
-	if (!mMediaPanel)
-		return FALSE;
-
 	return TRUE;
 }
 
-void LLPanelPlaceInfo::displayItemInfo(const LLInventoryItem* pItem)
-{
-	if (!pItem)
-		return;
-
-	mLandmarkID = pItem->getUUID();
-
-	if(!gCacheName)
-		return;
-
-	const LLPermissions& perm = pItem->getPermissions();
-
-	//////////////////
-	// CREATOR NAME //
-	//////////////////
-	if (pItem->getCreatorUUID().notNull())
-	{
-		std::string name;
-		LLUUID creator_id = pItem->getCreatorUUID();
-		if (!gCacheName->getFullName(creator_id, name))
-		{
-			gCacheName->get(creator_id, FALSE,
-							boost::bind(&LLPanelPlaceInfo::nameUpdatedCallback, this, mCreator, _2, _3));
-		}
-		mCreator->setText(name);
-	}
-	else
-	{
-		mCreator->setText(getString("unknown"));
-	}
-
-	////////////////
-	// OWNER NAME //
-	////////////////
-	if(perm.isOwned())
-	{
-		std::string name;
-		if (perm.isGroupOwned())
-		{
-			LLUUID group_id = perm.getGroup();
-			if (!gCacheName->getGroupName(group_id, name))
-			{
-				gCacheName->get(group_id, TRUE,
-								boost::bind(&LLPanelPlaceInfo::nameUpdatedCallback, this, mOwner, _2, _3));
-			}
-		}
-		else
-		{
-			LLUUID owner_id = perm.getOwner();
-			if (!gCacheName->getFullName(owner_id, name))
-			{
-				gCacheName->get(owner_id, FALSE,
-								boost::bind(&LLPanelPlaceInfo::nameUpdatedCallback, this, mOwner, _2, _3));
-			}
-		}
-		mOwner->setText(name);
-	}
-	else
-	{
-		mOwner->setText(getString("public"));
-	}
-	
-	//////////////////
-	// ACQUIRE DATE //
-	//////////////////
-	time_t time_utc = pItem->getCreationDate();
-	if (0 == time_utc)
-	{
-		mCreated->setText(getString("unknown"));
-	}
-	else
-	{
-		std::string timeStr = getString("acquired_date");
-		LLSD substitution;
-		substitution["datetime"] = (S32) time_utc;
-		LLStringUtil::format (timeStr, substitution);
-		mCreated->setText(timeStr);
-	}
-
-	mTitleEditor->setText(pItem->getName());
-	mNotesEditor->setText(pItem->getDescription());
-}
-
-void LLPanelPlaceInfo::nameUpdatedCallback(
-	LLTextBox* text,
-	const std::string& first,
-	const std::string& last)
-{
-	text->setText(first + " " + last);
-}
-
+//virtual
 void LLPanelPlaceInfo::resetLocation()
 {
 	mParcelID.setNull();
 	mRequestedID.setNull();
-	mLandmarkID.setNull();
 	mPosRegion.clearVec();
-	mForSalePanel->setVisible(FALSE);
-	mYouAreHerePanel->setVisible(FALSE);
+
 	std::string not_available = getString("not_available");
 	mMaturityRatingText->setValue(not_available);
-	mParcelOwner->setValue(not_available);
-	mLastVisited->setValue(not_available);
 	mRegionName->setText(not_available);
 	mParcelName->setText(not_available);
 	mDescEditor->setText(not_available);
-	mCreator->setText(not_available);
-	mOwner->setText(not_available);
-	mCreated->setText(not_available);
-	mTitleEditor->setText(LLStringUtil::null);
-	mNotesEditor->setText(LLStringUtil::null);
+
 	mSnapshotCtrl->setImageAssetID(LLUUID::null);
 	mSnapshotCtrl->setFallbackImageName("default_land_picture.j2c");
-
-	mRatingText->setText(not_available);
-	mVoiceText->setText(not_available);
-	mFlyText->setText(not_available);
-	mPushText->setText(not_available);
-	mBuildText->setText(not_available);
-	mParcelScriptsText->setText(not_available);
-	mDamageText->setText(not_available);
-
-	mRegionNameText->setValue(not_available);
-	mRegionTypeText->setValue(not_available);
-	mRegionRatingText->setValue(not_available);
-	mRegionOwnerText->setValue(not_available);
-	mRegionGroupText->setValue(not_available);
-
-	mEstateNameText->setValue(not_available);
-	mEstateRatingText->setValue(not_available);
-	mEstateOwnerText->setValue(not_available);
-	mCovenantText->setValue(not_available);
-
-	mSalesPriceText->setValue(not_available);
-	mAreaText->setValue(not_available);
-	mTrafficText->setValue(not_available);
-	mPrimitivesText->setValue(not_available);
-	mParcelScriptsText->setValue(not_available);
-	mTerraformLimitsText->setValue(not_available);
-	mSubdivideText->setValue(not_available);
-	mResaleText->setValue(not_available);
-	mSaleToText->setValue(not_available);
 }
 
 //virtual
@@ -330,108 +119,55 @@ void LLPanelPlaceInfo::setParcelID(const LLUUID& parcel_id)
 	sendParcelInfoRequest();
 }
 
+//virtual
 void LLPanelPlaceInfo::setInfoType(INFO_TYPE type)
 {
-	LLPanel* landmark_info_panel = getChild<LLPanel>("landmark_info_panel");
-	LLPanel* landmark_edit_panel = getChild<LLPanel>("landmark_edit_panel");
-
-	bool is_info_type_agent = type == AGENT;
-	bool is_info_type_create_landmark = type == CREATE_LANDMARK;
-	bool is_info_type_landmark = type == LANDMARK;
-	bool is_info_type_teleport_history = type == TELEPORT_HISTORY;
-
-	getChild<LLTextBox>("maturity_label")->setVisible(!is_info_type_agent);
-	mMaturityRatingText->setVisible(!is_info_type_agent);
-
-	getChild<LLTextBox>("owner_label")->setVisible(is_info_type_agent);
-	mParcelOwner->setVisible(is_info_type_agent);
-
-	getChild<LLTextBox>("last_visited_label")->setVisible(is_info_type_teleport_history);
-	mLastVisited->setVisible(is_info_type_teleport_history);
-
-	landmark_info_panel->setVisible(is_info_type_landmark);
-	landmark_edit_panel->setVisible(is_info_type_landmark || is_info_type_create_landmark);
-
-	getChild<LLTextBox>("folder_lable")->setVisible(is_info_type_create_landmark);
-	mFolderCombo->setVisible(is_info_type_create_landmark);
-
-	getChild<LLAccordionCtrl>("advanced_info_accordion")->setVisible(is_info_type_agent);
-
-	switch(type)
-	{
-		case CREATE_LANDMARK:
-			mCurrentTitle = getString("title_create_landmark");
-
-			mTitleEditor->setEnabled(TRUE);
-			mNotesEditor->setEnabled(TRUE);
-
-			populateFoldersList();
-		break;
-
-		case AGENT:
-		case PLACE:
-			mCurrentTitle = getString("title_place");
-
-			if (!isMediaPanelVisible())
-			{
-				mTitle->setText(mCurrentTitle);
-			}
-		break;
-
-		case LANDMARK:
-			mCurrentTitle = getString("title_landmark");
-
-			mTitleEditor->setEnabled(FALSE);
-			mNotesEditor->setEnabled(FALSE);
-
-			populateFoldersList();
-		break;
-
-		case TELEPORT_HISTORY:
-			mCurrentTitle = getString("title_teleport_history");
-		break;
-	}
-
-	if (type != AGENT)
-		toggleMediaPanel(FALSE);
+	mTitle->setText(mCurrentTitle);
 
 	mInfoType = type;
 }
 
-BOOL LLPanelPlaceInfo::isMediaPanelVisible()
+void LLPanelPlaceInfo::sendParcelInfoRequest()
 {
-	if (!mMediaPanel)
-		return FALSE;
+	if (mParcelID != mRequestedID)
+	{
+		LLRemoteParcelInfoProcessor::getInstance()->addObserver(mParcelID, this);
+		LLRemoteParcelInfoProcessor::getInstance()->sendParcelInfoRequest(mParcelID);
 
-	return mMediaPanel->getVisible();
+		mRequestedID = mParcelID;
+	}
 }
 
-void LLPanelPlaceInfo::toggleMediaPanel(BOOL visible)
+void LLPanelPlaceInfo::displayParcelInfo(const LLUUID& region_id,
+										 const LLVector3d& pos_global)
 {
-    if (!mMediaPanel)
-        return;
+	LLViewerRegion* region = gAgent.getRegion();
+	if (!region)
+		return;
+
+	mPosRegion.setVec((F32)fmod(pos_global.mdV[VX], (F64)REGION_WIDTH_METERS),
+					  (F32)fmod(pos_global.mdV[VY], (F64)REGION_WIDTH_METERS),
+					  (F32)pos_global.mdV[VZ]);
 
-    if (visible)
+	LLSD body;
+	std::string url = region->getCapability("RemoteParcelRequest");
+	if (!url.empty())
 	{
-		mTitle->setText(getString("title_media"));
+		body["location"] = ll_sd_from_vector3(mPosRegion);
+		if (!region_id.isNull())
+		{
+			body["region_id"] = region_id;
+		}
+		if (!pos_global.isExactlyZero())
+		{
+			U64 region_handle = to_region_handle(pos_global);
+			body["region_handle"] = ll_sd_from_U64(region_handle);
+		}
+		LLHTTPClient::post(url, body, new LLRemoteParcelRequestResponder(getObserverHandle()));
 	}
 	else
 	{
-		mTitle->setText(mCurrentTitle);
-	}
-
-    mInfoPanel->setVisible(!visible);
-    mMediaPanel->setVisible(visible);
-}
-
-void LLPanelPlaceInfo::sendParcelInfoRequest()
-{
-	if (mParcelID != mRequestedID)
-	{
-		LLRemoteParcelInfoProcessor::getInstance()->addObserver(mParcelID, this);
-		LLRemoteParcelInfoProcessor::getInstance()->sendParcelInfoRequest(mParcelID);
-
-		mRequestedID = mParcelID;
+		mDescEditor->setText(getString("server_update_text"));
 	}
 }
 
@@ -473,27 +209,6 @@ void LLPanelPlaceInfo::processParcelInfo(const LLParcelData& parcel_data)
 		mDescEditor->setText(parcel_data.desc);
 	}
 
-	// HACK: Flag 0x2 == adult region,
-	// Flag 0x1 == mature region, otherwise assume PG
-	std::string rating = LLViewerRegion::accessToString(SIM_ACCESS_PG);
-	if (parcel_data.flags & 0x2)
-	{
-		rating = LLViewerRegion::accessToString(SIM_ACCESS_ADULT);
-	}
-	else if (parcel_data.flags & 0x1)
-	{
-		rating = LLViewerRegion::accessToString(SIM_ACCESS_MATURE);
-	}
-
-	mMaturityRatingText->setValue(rating);
-	mRatingText->setValue(rating);
-
-	//update for_sale banner, here we should use DFQ_FOR_SALE instead of PF_FOR_SALE
-	//because we deal with remote parcel response format
-	bool is_for_sale = (parcel_data.flags & DFQ_FOR_SALE) &&
-					 mInfoType == AGENT ? TRUE : FALSE;
-	mForSalePanel->setVisible(is_for_sale);
-
 	S32 region_x;
 	S32 region_y;
 	S32 region_z;
@@ -521,408 +236,25 @@ void LLPanelPlaceInfo::processParcelInfo(const LLParcelData& parcel_data)
 	{
 		mParcelName->setText(getString("not_available"));
 	}
-
-	if (mInfoType == CREATE_LANDMARK)
-	{
-		if (parcel_data.name.empty())
-		{
-			mTitleEditor->setText(llformat("%s (%d, %d, %d)",
-								  parcel_data.sim_name.c_str(), region_x, region_y, region_z));
-		}
-		else
-		{
-			mTitleEditor->setText(parcel_data.name);
-		}
-
-		// FIXME: Creating landmark works only for current agent location.
-		std::string desc;
-		LLAgentUI::buildLocationString(desc, LLAgentUI::LOCATION_FORMAT_FULL, gAgent.getPositionAgent());
-		mNotesEditor->setText(desc);
-
-		if (!LLLandmarkActions::landmarkAlreadyExists())
-		{
-			createLandmark(mFolderCombo->getValue().asUUID());
-		}
-	}
 }
 
-void LLPanelPlaceInfo::displayParcelInfo(const LLUUID& region_id,
-										 const LLVector3d& pos_global)
+// virtual
+void LLPanelPlaceInfo::handleVisibilityChange(BOOL new_visibility)
 {
-	LLViewerRegion* region = gAgent.getRegion();
-	if (!region)
-		return;
-
-	mPosRegion.setVec((F32)fmod(pos_global.mdV[VX], (F64)REGION_WIDTH_METERS),
-					  (F32)fmod(pos_global.mdV[VY], (F64)REGION_WIDTH_METERS),
-					  (F32)pos_global.mdV[VZ]);
-
-	LLSD body;
-	std::string url = region->getCapability("RemoteParcelRequest");
-	if (!url.empty())
-	{
-		body["location"] = ll_sd_from_vector3(mPosRegion);
-		if (!region_id.isNull())
-		{
-			body["region_id"] = region_id;
-		}
-		if (!pos_global.isExactlyZero())
-		{
-			U64 region_handle = to_region_handle(pos_global);
-			body["region_handle"] = ll_sd_from_U64(region_handle);
-		}
-		LLHTTPClient::post(url, body, new LLRemoteParcelRequestResponder(getObserverHandle()));
-	}
-	else
-	{
-		mDescEditor->setText(getString("server_update_text"));
-	}
-}
+	LLPanel::handleVisibilityChange(new_visibility);
 
-void LLPanelPlaceInfo::displaySelectedParcelInfo(LLParcel* parcel,
-											  LLViewerRegion* region,
-											  const LLVector3d& pos_global,
-											  bool is_current_parcel)
-{
-	if (!region || !parcel)
+	LLViewerParcelMgr* parcel_mgr = LLViewerParcelMgr::getInstance();
+	if (!parcel_mgr)
 		return;
 
-	// send EstateCovenantInfo message
-	LLMessageSystem *msg = gMessageSystem;
-	msg->newMessage("EstateCovenantRequest");
-	msg->nextBlockFast(_PREHASH_AgentData);
-	msg->addUUIDFast(_PREHASH_AgentID,	gAgent.getID());
-	msg->addUUIDFast(_PREHASH_SessionID,gAgent.getSessionID());
-	msg->sendReliable(region->getHost());
-
-	LLParcelData parcel_data;
-
-	// HACK: Converting sim access flags to the format
-	// returned by remote parcel response.
-	switch(region->getSimAccess())
-	{
-	case SIM_ACCESS_MATURE:
-		parcel_data.flags = 0x1;
-		break;
-
-	case SIM_ACCESS_ADULT:
-		parcel_data.flags = 0x2;
-		break;
-
-	default:
-		parcel_data.flags = 0;
-	}
-	parcel_data.desc = parcel->getDesc();
-	parcel_data.name = parcel->getName();
-	parcel_data.sim_name = region->getName();
-	parcel_data.snapshot_id = parcel->getSnapshotID();
-	mPosRegion.setVec((F32)fmod(pos_global.mdV[VX], (F64)REGION_WIDTH_METERS),
-					  (F32)fmod(pos_global.mdV[VY], (F64)REGION_WIDTH_METERS),
-					  (F32)pos_global.mdV[VZ]);
-	parcel_data.global_x = pos_global.mdV[VX];
-	parcel_data.global_y = pos_global.mdV[VY];
-	parcel_data.global_z = pos_global.mdV[VZ];
-
-	std::string on = getString("on");
-	std::string off = getString("off");
-
-	// Processing parcel characteristics
-	if (parcel->getParcelFlagAllowVoice())
-	{
-		mVoiceText->setText(on);
-	}
-	else
-	{
-		mVoiceText->setText(off);
-	}
-
-	if (!region->getBlockFly() && parcel->getAllowFly())
-	{
-		mFlyText->setText(on);
-	}
-	else
-	{
-		mFlyText->setText(off);
-	}
-
-	if (region->getRestrictPushObject() || parcel->getRestrictPushObject())
-	{
-		mPushText->setText(off);
-	}
-	else
-	{
-		mPushText->setText(on);
-	}
-
-	if (parcel->getAllowModify())
-	{
-		mBuildText->setText(on);
-	}
-	else
-	{
-		mBuildText->setText(off);
-	}
-
-	if((region->getRegionFlags() & REGION_FLAGS_SKIP_SCRIPTS) ||
-	   (region->getRegionFlags() & REGION_FLAGS_ESTATE_SKIP_SCRIPTS) ||
-	   !parcel->getAllowOtherScripts())
-	{
-		mScriptsText->setText(off);
-	}
-	else
-	{
-		mScriptsText->setText(on);
-	}
-
-	if (region->getAllowDamage() || parcel->getAllowDamage())
-	{
-		mDamageText->setText(on);
-	}
-	else
-	{
-		mDamageText->setText(off);
-	}
-
-	mRegionNameText->setText(region->getName());
-	mRegionTypeText->setText(region->getSimProductName());
-	mRegionRatingText->setText(region->getSimAccessString());
-
-	// Determine parcel owner
-	if (parcel->isPublic())
-	{
-		mParcelOwner->setText(getString("public"));
-		mRegionOwnerText->setText(getString("public"));
-	}
-	else
-	{
-		if (parcel->getIsGroupOwned())
-		{
-			mRegionOwnerText->setText(getString("group_owned_text"));
-
-			if(!parcel->getGroupID().isNull())
-			{
-				// FIXME: Using parcel group as region group.
-				gCacheName->get(parcel->getGroupID(), TRUE,
-								boost::bind(&LLPanelPlaceInfo::nameUpdatedCallback, this, mRegionGroupText, _2, _3));
-
-				gCacheName->get(parcel->getGroupID(), TRUE,
-								boost::bind(&LLPanelPlaceInfo::nameUpdatedCallback, this, mParcelOwner, _2, _3));
-			}
-			else
-			{
-				std::string owner = getString("none_text");
-				mRegionGroupText->setText(owner);
-				mParcelOwner->setText(owner);
-			}
-		}
-		else
-		{
-			// Figure out the owner's name
-			gCacheName->get(parcel->getOwnerID(), FALSE,
-							boost::bind(&LLPanelPlaceInfo::nameUpdatedCallback, this, mParcelOwner, _2, _3));
-			gCacheName->get(region->getOwner(), FALSE,
-							boost::bind(&LLPanelPlaceInfo::nameUpdatedCallback, this, mRegionOwnerText, _2, _3));
-		}
-
-		if(LLParcel::OS_LEASE_PENDING == parcel->getOwnershipStatus())
-		{
-			mRegionOwnerText->setText(mRegionOwnerText->getText() + getString("sale_pending_text"));
-		}
-	}
-
-	mEstateRatingText->setText(region->getSimAccessString());
-
-	S32 area;
-	S32 claim_price;
-	S32 rent_price;
-	F32 dwell;
-	BOOL for_sale = parcel->getForSale();
-	LLViewerParcelMgr::getInstance()->getDisplayInfo(&area,
-													 &claim_price,
-													 &rent_price,
-													 &for_sale,
-													 &dwell);
-	if (for_sale)
-	{
-		// Adding "For Sale" flag in remote parcel response format.
-		parcel_data.flags |= DFQ_FOR_SALE;
-
-		const LLUUID& auth_buyer_id = parcel->getAuthorizedBuyerID();
-		if(auth_buyer_id.notNull())
-		{
-			gCacheName->get(auth_buyer_id, TRUE,
-							boost::bind(&LLPanelPlaceInfo::nameUpdatedCallback, this, mSaleToText, _2, _3));
-
-			// Show sales info to a specific person or a group he belongs to.
-			if (auth_buyer_id != gAgent.getID() && !gAgent.isInGroup(auth_buyer_id))
-			{
-				for_sale = FALSE;
-			}
-		}
-		else
-		{
-			mSaleToText->setText(getString("anyone"));
-		}
-
-		const U8* sign = (U8*)getString("price_text").c_str();
-		const U8* sqm = (U8*)getString("area_text").c_str();
-
-		mSalesPriceText->setText(llformat("%s%d ", sign, parcel->getSalePrice()));
-		mAreaText->setText(llformat("%d %s", area, sqm));
-		mTrafficText->setText(llformat("%.0f", dwell));
-
-		// Can't have more than region max tasks, regardless of parcel
-		// object bonus factor.
-		S32 primitives = llmin(llround(parcel->getMaxPrimCapacity() * parcel->getParcelPrimBonus()),
-							   (S32)region->getMaxTasks());
-
-		const U8* available = (U8*)getString("available").c_str();
-		const U8* allocated = (U8*)getString("allocated").c_str();
-
-		mPrimitivesText->setText(llformat("%d %s, %d %s", primitives, available, parcel->getPrimCount(), allocated));
-
-		if (parcel->getAllowOtherScripts())
-		{
-			mParcelScriptsText->setText(getString("all_residents_text"));
-		}
-		else if (parcel->getAllowGroupScripts())
-		{
-			mParcelScriptsText->setText(getString("group_text"));
-		}
-		else
-		{
-			mParcelScriptsText->setText(off);
-		}
-
-		mTerraformLimitsText->setText(parcel->getAllowTerraform() ? on : off);
-
-		if (region->getRegionFlags() & REGION_FLAGS_ALLOW_PARCEL_CHANGES)
-		{
-			mSubdivideText->setText(getString("can_change"));
-		}
-		else
-		{
-			mSubdivideText->setText(getString("can_not_change"));
-		}
-		if (region->getRegionFlags() & REGION_FLAGS_BLOCK_LAND_RESELL)
-		{
-			mResaleText->setText(getString("can_not_resell"));
-		}
-		else
-		{
-			mResaleText->setText(getString("can_resell"));
-		}
-	}
-
-	mSelectedParcelID = parcel->getLocalID();
-	mLastSelectedRegionID = region->getRegionID();
-	processParcelInfo(parcel_data);
-
-	mYouAreHerePanel->setVisible(is_current_parcel);
-	getChild<LLAccordionCtrlTab>("sales_tab")->setVisible(for_sale);
-}
-
-void LLPanelPlaceInfo::updateEstateName(const std::string& name)
-{
-	mEstateNameText->setText(name);
-}
-
-void LLPanelPlaceInfo::updateEstateOwnerName(const std::string& name)
-{
-	mEstateOwnerText->setText(name);
-}
-
-void LLPanelPlaceInfo::updateCovenantText(const std::string &text)
-{
-	mCovenantText->setText(text);
-}
-
-void LLPanelPlaceInfo::updateLastVisitedText(const LLDate &date)
-{
-	if (date.isNull())
-	{
-		mLastVisited->setText(getString("unknown"));
-	}
-	else
-	{
-		std::string timeStr = getString("acquired_date");
-		LLSD substitution;
-		substitution["datetime"] = (S32) date.secondsSinceEpoch();
-		LLStringUtil::format (timeStr, substitution);
-		mLastVisited->setText(timeStr);
-	}
-}
-
-void LLPanelPlaceInfo::toggleLandmarkEditMode(BOOL enabled)
-{
-	// If switching to edit mode while creating landmark
-	// the "Create Landmark" title remains.
-	if (enabled && mInfoType != CREATE_LANDMARK)
-	{
-		mTitle->setText(getString("title_edit_landmark"));
-	}
-	else
-	{
-		mTitle->setText(mCurrentTitle);
-	}
-
-	if (mNotesEditor->getReadOnly() ==  (enabled == TRUE))
-	{
-		mTitleEditor->setEnabled(enabled);
-		mNotesEditor->setReadOnly(!enabled);
-		mFolderCombo->setVisible(enabled);
-		getChild<LLTextBox>("folder_lable")->setVisible(enabled);
-
-		// HACK: To change the text color in a text editor
-		// when it was enabled/disabled we set the text once again.
-		mNotesEditor->setText(mNotesEditor->getText());
-	}
-}
-
-const std::string& LLPanelPlaceInfo::getLandmarkTitle() const
-{
-	return mTitleEditor->getText();
-}
-
-const std::string LLPanelPlaceInfo::getLandmarkNotes() const
-{
-	return mNotesEditor->getText();
-}
-
-const LLUUID LLPanelPlaceInfo::getLandmarkFolder() const
-{
-	return mFolderCombo->getValue().asUUID();
-}
-
-BOOL LLPanelPlaceInfo::setLandmarkFolder(const LLUUID& id)
-{
-	return mFolderCombo->setCurrentByID(id);
-}
-
-void LLPanelPlaceInfo::createLandmark(const LLUUID& folder_id)
-{
-	std::string name = mTitleEditor->getText();
-	std::string desc = mNotesEditor->getText();
-
-	LLStringUtil::trim(name);
-	LLStringUtil::trim(desc);
-
-	// If typed name is empty use the parcel name instead.
-	if (name.empty())
+	// Remove land selection when panel hides.
+	if (!new_visibility)
 	{
-		name = mParcelName->getText();
-
-		// If no parcel exists use the region name instead.
-		if (name.empty())
+		if (!parcel_mgr->selectionEmpty())
 		{
-			name = mRegionName->getText();
+			parcel_mgr->deselectLand();
 		}
 	}
-
-	LLStringUtil::replaceChar(desc, '\n', ' ');
-	// If no folder chosen use the "Landmarks" folder.
-	LLLandmarkActions::createLandmarkHere(name, desc,
-		folder_id.notNull() ? folder_id : gInventory.findCategoryUUIDForType(LLAssetType::AT_LANDMARK));
 }
 
 void LLPanelPlaceInfo::createPick(const LLVector3d& pos_global, LLPanelPickEdit* pick_panel)
@@ -942,159 +274,10 @@ void LLPanelPlaceInfo::createPick(const LLVector3d& pos_global, LLPanelPickEdit*
 	pick_panel->setPickData(&data);
 }
 
-// virtual
-void LLPanelPlaceInfo::handleVisibilityChange (BOOL new_visibility)
-{
-	LLPanel::handleVisibilityChange(new_visibility);
-
-	LLViewerParcelMgr* parcel_mgr = LLViewerParcelMgr::getInstance();
-	if (!parcel_mgr)
-		return;
-
-	// Remove land selection when panel hides.
-	if (!new_visibility)
-	{
-		if (!parcel_mgr->selectionEmpty())
-		{
-			parcel_mgr->deselectLand();
-		}
-	}
-}
-
-void LLPanelPlaceInfo::populateFoldersList()
+// static
+void LLPanelPlaceInfo::nameUpdatedCallback(LLTextBox* text,
+										   const std::string& first,
+										   const std::string& last)
 {
-	// Collect all folders that can contain landmarks.
-	LLInventoryModel::cat_array_t cats;
-	collectLandmarkFolders(cats);
-
-	mFolderCombo->removeall();
-
-	// Put the "Landmarks" folder first in list.
-	LLUUID landmarks_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_LANDMARK);
-	const LLViewerInventoryCategory* cat = gInventory.getCategory(landmarks_id);
-	if (!cat)
-	{
-		llwarns << "Cannot find the landmarks folder" << llendl;
-	}
-	std::string cat_full_name = getFullFolderName(cat);
-	mFolderCombo->add(cat_full_name, cat->getUUID());
-
-	typedef std::vector<folder_pair_t> folder_vec_t;
-	folder_vec_t folders;
-	// Sort the folders by their full name.
-	for (S32 i = 0; i < cats.count(); i++)
-	{
-		cat = cats.get(i);
-		cat_full_name = getFullFolderName(cat);
-		folders.push_back(folder_pair_t(cat->getUUID(), cat_full_name));
-	}
-	sort(folders.begin(), folders.end(), cmp_folders);
-
-	// Finally, populate the combobox.
-	for (folder_vec_t::const_iterator it = folders.begin(); it != folders.end(); it++)
-		mFolderCombo->add(it->second, LLSD(it->first));
-}
-
-//static
-void LLPanelPlaceInfo::updateYouAreHereBanner(void* userdata)
-{
-	//YouAreHere Banner should be displayed only for selected places, 
-	// If you want to display it for landmark or teleport history item, you should check by mParcelId
-	
-	LLPanelPlaceInfo* self  = static_cast<LLPanelPlaceInfo*>(userdata);
-	if(!self->getVisible())
-		return;
-	if(!gDisconnected)
-	{
-		static F32 radius  = gSavedSettings.getF32("YouAreHereDistance");
-
-		BOOL display_banner = gAgent.getRegion()->getRegionID() == self->mLastSelectedRegionID && 
-			LLAgentUI::checkAgentDistance(self->mPosRegion, radius);
-
-		self->mYouAreHerePanel->setVisible(display_banner);
-	}
-}
-
-void LLPanelPlaceInfo::onForSaleBannerClick()
-{
-	LLViewerParcelMgr* mgr = LLViewerParcelMgr::getInstance();
-	LLParcelSelectionHandle hParcel = mgr->getFloatingParcelSelection();
-	LLViewerRegion* selected_region =  mgr->getSelectionRegion();
-	if(!hParcel.isNull() && selected_region)
-	{
-		if(hParcel->getParcel()->getLocalID() == mSelectedParcelID && 
-				mLastSelectedRegionID ==selected_region->getRegionID())
-		{
-			if(hParcel->getParcel()->getSalePrice() - gStatusBar->getBalance() > 0)
-			{
-				LLFloaterBuyCurrency::buyCurrency("Buying selected land ", hParcel->getParcel()->getSalePrice());
-			}
-			else
-			{
-				LLViewerParcelMgr::getInstance()->startBuyLand();
-			}
-		}
-		else
-		{
-			LL_WARNS("Places") << "User  is trying  to buy remote parcel.Operation is not supported"<< LL_ENDL; 
-		}
-		
-	}
-	
-	
-}
-
-/*static*/
-std::string LLPanelPlaceInfo::getFullFolderName(const LLViewerInventoryCategory* cat)
-{
-	std::string name = cat->getName();
-	LLUUID parent_id;
-
-	// translate category name, if it's right below the root
-	// FIXME: it can throw notification about non existent string in strings.xml
-	if (cat->getParentUUID().notNull() && cat->getParentUUID() == gInventory.getRootFolderID())
-	{
-		LLTrans::findString(name, "InvFolder " + name);
-	}
-
-	// we don't want "My Inventory" to appear in the name
-	while ((parent_id = cat->getParentUUID()).notNull() && parent_id != gInventory.getRootFolderID())
-	{
-		cat = gInventory.getCategory(parent_id);
-		name = cat->getName() + "/" + name;
-	}
-
-	return name;
-}
-
-static bool cmp_folders(const folder_pair_t& left, const folder_pair_t& right)
-{
-	return left.second < right.second;
-}
-
-static void collectLandmarkFolders(LLInventoryModel::cat_array_t& cats)
-{
-	LLUUID landmarks_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_LANDMARK);
-
-	// Add descendent folders of the "Landmarks" category.
-	LLInventoryModel::item_array_t items; // unused
-	LLIsType is_category(LLAssetType::AT_CATEGORY);
-	gInventory.collectDescendentsIf(
-		landmarks_id,
-		cats,
-		items,
-		LLInventoryModel::EXCLUDE_TRASH,
-		is_category);
-
-	// Add the "My Favorites" category.
-	LLUUID favorites_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_FAVORITE);
-	LLViewerInventoryCategory* favorites_cat = gInventory.getCategory(favorites_id);
-	if (!favorites_cat)
-	{
-		llwarns << "Cannot find the favorites folder" << llendl;
-	}
-	else
-	{
-		cats.put(favorites_cat);
-	}
+	text->setText(first + " " + last);
 }
diff --git a/indra/newview/llpanelplaceinfo.h b/indra/newview/llpanelplaceinfo.h
index 07a2434d59..c9e1347542 100644
--- a/indra/newview/llpanelplaceinfo.h
+++ b/indra/newview/llpanelplaceinfo.h
@@ -1,6 +1,6 @@
 /** 
  * @file llpanelplaceinfo.h
- * @brief Displays place information in Side Tray.
+ * @brief Base class for place information in Side Tray.
  *
  * $LicenseInfo:firstyear=2009&license=viewergpl$
  * 
@@ -38,19 +38,13 @@
 #include "v3dmath.h"
 #include "lluuid.h"
 
-#include "llpanelmedia.h"
 #include "llremoteparcelrequest.h"
 
-class LLButton;
-class LLComboBox;
 class LLExpandableTextBox;
 class LLInventoryItem;
-class LLLineEditor;
 class LLPanelPickEdit;
 class LLParcel;
-class LLIconCtrl;
 class LLTextBox;
-class LLTextEditor;
 class LLTextureCtrl;
 class LLViewerRegion;
 class LLViewerInventoryCategory;
@@ -74,30 +68,18 @@ public:
 
 	// Ignore all old location information, useful if you are 
 	// recycling an existing dialog and need to clear it.
-	void resetLocation();
+	virtual void resetLocation();
 
 	// Sends a request for data about the given parcel, which will
 	// only update the location if there is none already available.
 	/*virtual*/ void setParcelID(const LLUUID& parcel_id);
 
-	// Depending on how the panel was triggered 
-	// (from landmark or current location, or other) 
+	// Depending on how the panel was triggered
+	// (from landmark or current location, or other)
 	// sets a corresponding title and contents.
-	void setInfoType(INFO_TYPE type);
-
-	// Create a landmark for the current location
-	// in a folder specified by folder_id.
-	void createLandmark(const LLUUID& folder_id);
-	
-	// Create a pick for the location specified
-	// by global_pos.
-	void createPick(const LLVector3d& pos_global, LLPanelPickEdit* pick_panel);
-
-	BOOL isMediaPanelVisible();
-	void toggleMediaPanel(BOOL visible);
-	void displayItemInfo(const LLInventoryItem* pItem);
-	/*virtual*/ void setErrorStatus(U32 status, const std::string& reason);
+	virtual void setInfoType(INFO_TYPE type);
 
+	// Requests remote parcel info by parcel ID.
 	void sendParcelInfoRequest();
 
 	// Displays information about a remote parcel.
@@ -105,109 +87,37 @@ public:
 	void displayParcelInfo(const LLUUID& region_id,
 						   const LLVector3d& pos_global);
 
-	// Displays information about the currently selected parcel
-	// without sending a request to the server.
-	// If is_current_parcel true shows "You Are Here" banner.
-	void displaySelectedParcelInfo(LLParcel* parcel,
-								LLViewerRegion* region,
-								const LLVector3d& pos_global,
-								bool is_current_parcel);
-
-	void updateEstateName(const std::string& name);
-	void updateEstateOwnerName(const std::string& name);
-	void updateCovenantText(const std::string &text);
-	void updateLastVisitedText(const LLDate &date);
-
-	void nameUpdatedCallback(LLTextBox* text,
-							 const std::string& first,
-							 const std::string& last);
-
-	void toggleLandmarkEditMode(BOOL enabled);
-
-	const std::string& getLandmarkTitle() const;
-	const std::string getLandmarkNotes() const;
-	const LLUUID getLandmarkFolder() const;
-
-	// Select current landmark folder in combobox.
-	BOOL setLandmarkFolder(const LLUUID& id);
+	/*virtual*/ void setErrorStatus(U32 status, const std::string& reason);
 
 	/*virtual*/ void processParcelInfo(const LLParcelData& parcel_data);
+
 	/*virtual*/ void handleVisibilityChange (BOOL new_visibility);
-	
-	 static std::string getFullFolderName(const LLViewerInventoryCategory* cat);
 
-private:
+	// Create a pick for the location specified
+	// by global_pos.
+	void createPick(const LLVector3d& pos_global, LLPanelPickEdit* pick_panel);
 
-	void populateFoldersList();
-	static void updateYouAreHereBanner(void*);// added to gIdleCallbacks
-	void onForSaleBannerClick();
+protected:
+	static void nameUpdatedCallback(LLTextBox* text,
+									const std::string& first,
+									const std::string& last);
 
 	/**
 	 * mParcelID is valid only for remote places, in other cases it's null. See resetLocation() 
 	 */
-	LLUUID			mParcelID;
-	LLUUID			mRequestedID;
-	LLUUID			mLandmarkID;
-	LLVector3		mPosRegion;
-	std::string		mCurrentTitle;
-	S32				mMinHeight;
-	INFO_TYPE 		mInfoType;
-
-	/**
-	 * Hold last displayed parcel. Needs for YouAreHere banner.
-	 */
-	S32			mSelectedParcelID;
-	LLUUID		mLastSelectedRegionID;
-
-	LLTextBox*			mTitle;
-	LLPanel*			mForSalePanel;
-	LLPanel*			mYouAreHerePanel;
-	LLTextureCtrl*		mSnapshotCtrl;
-	LLTextBox*			mRegionName;
-	LLTextBox*			mParcelName;
-	LLExpandableTextBox*mDescEditor;
-	LLTextBox*			mMaturityRatingText;
-	LLTextBox*			mParcelOwner;
-	LLTextBox*			mLastVisited;
-
-	LLTextBox*			mRatingText;
-	LLTextBox*			mVoiceText;
-	LLTextBox*			mFlyText;
-	LLTextBox*			mPushText;
-	LLTextBox*			mBuildText;
-	LLTextBox*			mScriptsText;
-	LLTextBox*			mDamageText;
-
-	LLTextBox*			mRegionNameText;
-	LLTextBox*			mRegionTypeText;
-	LLTextBox*			mRegionRatingText;
-	LLTextBox*			mRegionOwnerText;
-	LLTextBox*			mRegionGroupText;
-
-	LLTextBox*			mEstateNameText;
-	LLTextBox*			mEstateRatingText;
-	LLTextBox*			mEstateOwnerText;
-	LLTextEditor*		mCovenantText;
-
-	LLTextBox*			mSalesPriceText;
-	LLTextBox*			mAreaText;
-	LLTextBox*			mTrafficText;
-	LLTextBox*			mPrimitivesText;
-	LLTextBox*			mParcelScriptsText;
-	LLTextBox*			mTerraformLimitsText;
-	LLTextEditor*		mSubdivideText;
-	LLTextEditor*		mResaleText;
-	LLTextBox*			mSaleToText;
-
-	LLTextBox*			mOwner;
-	LLTextBox*			mCreator;
-	LLTextBox*			mCreated;
-	LLLineEditor*		mTitleEditor;
-	LLTextEditor*		mNotesEditor;
-	LLComboBox*			mFolderCombo;
-	LLPanel*            mScrollingPanel;
-	LLPanel*			mInfoPanel;
-	LLMediaPanel*		mMediaPanel;
+	LLUUID					mParcelID;
+	LLUUID					mRequestedID;
+	LLVector3				mPosRegion;
+	std::string				mCurrentTitle;
+	S32						mMinHeight;
+	INFO_TYPE 				mInfoType;
+
+	LLTextBox*				mTitle;
+	LLTextureCtrl*			mSnapshotCtrl;
+	LLTextBox*				mRegionName;
+	LLTextBox*				mParcelName;
+	LLExpandableTextBox*	mDescEditor;
+	LLTextBox*				mMaturityRatingText;
 };
 
 #endif // LL_LLPANELPLACEINFO_H
diff --git a/indra/newview/llpanelplaceprofile.cpp b/indra/newview/llpanelplaceprofile.cpp
new file mode 100644
index 0000000000..9ba72fe6cf
--- /dev/null
+++ b/indra/newview/llpanelplaceprofile.cpp
@@ -0,0 +1,541 @@
+/**
+ * @file llpanelplaceprofile.cpp
+ * @brief Displays place profile in Side Tray.
+ *
+ * $LicenseInfo:firstyear=2009&license=viewergpl$
+ *
+ * Copyright (c) 2004-2009, Linden Research, Inc.
+ *
+ * Second Life Viewer Source Code
+ * The source code in this file ("Source Code") is provided by Linden Lab
+ * to you under the terms of the GNU General Public License, version 2.0
+ * ("GPL"), unless you have obtained a separate licensing agreement
+ * ("Other License"), formally executed by you and Linden Lab.  Terms of
+ * the GPL can be found in doc/GPL-license.txt in this distribution, or
+ * online at http://secondlifegrid.net/programs/open_source/licensing/gplv2
+ *
+ * There are special exceptions to the terms and conditions of the GPL as
+ * it is applied to this Source Code. View the full text of the exception
+ * in the file doc/FLOSS-exception.txt in this software distribution, or
+ * online at
+ * http://secondlifegrid.net/programs/open_source/licensing/flossexception
+ *
+ * By copying, modifying or distributing this software, you acknowledge
+ * that you have read and understood your obligations described above,
+ * and agree to abide by those obligations.
+ *
+ * ALL LINDEN LAB SOURCE CODE IS PROVIDED "AS IS." LINDEN LAB MAKES NO
+ * WARRANTIES, EXPRESS, IMPLIED OR OTHERWISE, REGARDING ITS ACCURACY,
+ * COMPLETENESS OR PERFORMANCE.
+ * $/LicenseInfo$
+ */
+
+#include "llviewerprecompiledheaders.h"
+
+#include "llpanelplaceprofile.h"
+
+#include "llparcel.h"
+
+#include "llqueryflags.h"
+
+#include "lliconctrl.h"
+#include "lllineeditor.h"
+#include "lltextbox.h"
+#include "lltexteditor.h"
+
+#include "llaccordionctrl.h"
+#include "llaccordionctrltab.h"
+#include "llagent.h"
+#include "llagentui.h"
+#include "llappviewer.h"
+#include "llcallbacklist.h"
+#include "llfloaterbuycurrency.h"
+#include "llstatusbar.h"
+#include "llviewercontrol.h"
+#include "llviewerparcelmgr.h"
+#include "llviewerregion.h"
+
+static LLRegisterPanelClassWrapper<LLPanelPlaceProfile> t_place_profile("panel_place_profile");
+
+LLPanelPlaceProfile::LLPanelPlaceProfile()
+:	LLPanelPlaceInfo(),
+	mForSalePanel(NULL),
+	mYouAreHerePanel(NULL),
+	mSelectedParcelID(-1)
+{}
+
+// virtual
+LLPanelPlaceProfile::~LLPanelPlaceProfile()
+{}
+
+// virtual
+BOOL LLPanelPlaceProfile::postBuild()
+{
+	LLPanelPlaceInfo::postBuild();
+
+	mForSalePanel = getChild<LLPanel>("for_sale_panel");
+	mYouAreHerePanel = getChild<LLPanel>("here_panel");
+	gIdleCallbacks.addFunction(&LLPanelPlaceProfile::updateYouAreHereBanner, this);
+
+	//Icon value should contain sale price of last selected parcel.
+	mForSalePanel->getChild<LLIconCtrl>("icon_for_sale")->
+				setMouseDownCallback(boost::bind(&LLPanelPlaceProfile::onForSaleBannerClick, this));
+
+	mParcelOwner = getChild<LLTextBox>("owner_value");
+	mLastVisited = getChild<LLTextBox>("last_visited_value");
+
+	mRatingText = getChild<LLTextBox>("rating_value");
+	mVoiceText = getChild<LLTextBox>("voice_value");
+	mFlyText = getChild<LLTextBox>("fly_value");
+	mPushText = getChild<LLTextBox>("push_value");
+	mBuildText = getChild<LLTextBox>("build_value");
+	mScriptsText = getChild<LLTextBox>("scripts_value");
+	mDamageText = getChild<LLTextBox>("damage_value");
+
+	mRegionNameText = getChild<LLTextBox>("region_name");
+	mRegionTypeText = getChild<LLTextBox>("region_type");
+	mRegionRatingText = getChild<LLTextBox>("region_rating");
+	mRegionOwnerText = getChild<LLTextBox>("region_owner");
+	mRegionGroupText = getChild<LLTextBox>("region_group");
+
+	mEstateNameText = getChild<LLTextBox>("estate_name");
+	mEstateRatingText = getChild<LLTextBox>("estate_rating");
+	mEstateOwnerText = getChild<LLTextBox>("estate_owner");
+	mCovenantText = getChild<LLTextEditor>("covenant");
+
+	mSalesPriceText = getChild<LLTextBox>("sales_price");
+	mAreaText = getChild<LLTextBox>("area");
+	mTrafficText = getChild<LLTextBox>("traffic");
+	mPrimitivesText = getChild<LLTextBox>("primitives");
+	mParcelScriptsText = getChild<LLTextBox>("parcel_scripts");
+	mTerraformLimitsText = getChild<LLTextBox>("terraform_limits");
+	mSubdivideText = getChild<LLTextEditor>("subdivide");
+	mResaleText = getChild<LLTextEditor>("resale");
+	mSaleToText = getChild<LLTextBox>("sale_to");
+
+	return TRUE;
+}
+
+// virtual
+void LLPanelPlaceProfile::resetLocation()
+{
+	LLPanelPlaceInfo::resetLocation();
+
+	mForSalePanel->setVisible(FALSE);
+	mYouAreHerePanel->setVisible(FALSE);
+
+	std::string not_available = getString("not_available");
+	mParcelOwner->setValue(not_available);
+	mLastVisited->setValue(not_available);
+
+	mRatingText->setText(not_available);
+	mVoiceText->setText(not_available);
+	mFlyText->setText(not_available);
+	mPushText->setText(not_available);
+	mBuildText->setText(not_available);
+	mParcelScriptsText->setText(not_available);
+	mDamageText->setText(not_available);
+
+	mRegionNameText->setValue(not_available);
+	mRegionTypeText->setValue(not_available);
+	mRegionRatingText->setValue(not_available);
+	mRegionOwnerText->setValue(not_available);
+	mRegionGroupText->setValue(not_available);
+
+	mEstateNameText->setValue(not_available);
+	mEstateRatingText->setValue(not_available);
+	mEstateOwnerText->setValue(not_available);
+	mCovenantText->setValue(not_available);
+
+	mSalesPriceText->setValue(not_available);
+	mAreaText->setValue(not_available);
+	mTrafficText->setValue(not_available);
+	mPrimitivesText->setValue(not_available);
+	mParcelScriptsText->setValue(not_available);
+	mTerraformLimitsText->setValue(not_available);
+	mSubdivideText->setValue(not_available);
+	mResaleText->setValue(not_available);
+	mSaleToText->setValue(not_available);
+}
+
+// virtual
+void LLPanelPlaceProfile::setInfoType(INFO_TYPE type)
+{
+	bool is_info_type_agent = type == AGENT;
+	bool is_info_type_teleport_history = type == TELEPORT_HISTORY;
+
+	getChild<LLTextBox>("maturity_label")->setVisible(!is_info_type_agent);
+	mMaturityRatingText->setVisible(!is_info_type_agent);
+
+	getChild<LLTextBox>("owner_label")->setVisible(is_info_type_agent);
+	mParcelOwner->setVisible(is_info_type_agent);
+
+	getChild<LLTextBox>("last_visited_label")->setVisible(is_info_type_teleport_history);
+	mLastVisited->setVisible(is_info_type_teleport_history);
+
+	getChild<LLAccordionCtrl>("advanced_info_accordion")->setVisible(is_info_type_agent);
+
+	switch(type)
+	{
+		case AGENT:
+		case PLACE:
+		default:
+			mCurrentTitle = getString("title_place");
+		break;
+
+		case TELEPORT_HISTORY:
+			mCurrentTitle = getString("title_teleport_history");
+		break;
+	}
+
+	LLPanelPlaceInfo::setInfoType(type);
+}
+
+// virtual
+void LLPanelPlaceProfile::processParcelInfo(const LLParcelData& parcel_data)
+{
+	LLPanelPlaceInfo::processParcelInfo(parcel_data);
+
+	// HACK: Flag 0x2 == adult region,
+	// Flag 0x1 == mature region, otherwise assume PG
+	std::string rating = LLViewerRegion::accessToString(SIM_ACCESS_PG);
+	if (parcel_data.flags & 0x2)
+	{
+		rating = LLViewerRegion::accessToString(SIM_ACCESS_ADULT);
+	}
+	else if (parcel_data.flags & 0x1)
+	{
+		rating = LLViewerRegion::accessToString(SIM_ACCESS_MATURE);
+	}
+
+	mMaturityRatingText->setValue(rating);
+	mRatingText->setValue(rating);
+
+	//update for_sale banner, here we should use DFQ_FOR_SALE instead of PF_FOR_SALE
+	//because we deal with remote parcel response format
+	bool is_for_sale = (parcel_data.flags & DFQ_FOR_SALE) &&
+					 mInfoType == AGENT ? TRUE : FALSE;
+	mForSalePanel->setVisible(is_for_sale);
+}
+
+void LLPanelPlaceProfile::displaySelectedParcelInfo(LLParcel* parcel,
+													LLViewerRegion* region,
+													const LLVector3d& pos_global,
+													bool is_current_parcel)
+{
+	if (!region || !parcel)
+		return;
+
+	// send EstateCovenantInfo message
+	LLMessageSystem *msg = gMessageSystem;
+	msg->newMessage("EstateCovenantRequest");
+	msg->nextBlockFast(_PREHASH_AgentData);
+	msg->addUUIDFast(_PREHASH_AgentID,	gAgent.getID());
+	msg->addUUIDFast(_PREHASH_SessionID,gAgent.getSessionID());
+	msg->sendReliable(region->getHost());
+
+	LLParcelData parcel_data;
+
+	// HACK: Converting sim access flags to the format
+	// returned by remote parcel response.
+	switch(region->getSimAccess())
+	{
+	case SIM_ACCESS_MATURE:
+		parcel_data.flags = 0x1;
+		break;
+
+	case SIM_ACCESS_ADULT:
+		parcel_data.flags = 0x2;
+		break;
+
+	default:
+		parcel_data.flags = 0;
+	}
+	parcel_data.desc = parcel->getDesc();
+	parcel_data.name = parcel->getName();
+	parcel_data.sim_name = region->getName();
+	parcel_data.snapshot_id = parcel->getSnapshotID();
+	mPosRegion.setVec((F32)fmod(pos_global.mdV[VX], (F64)REGION_WIDTH_METERS),
+					  (F32)fmod(pos_global.mdV[VY], (F64)REGION_WIDTH_METERS),
+					  (F32)pos_global.mdV[VZ]);
+	parcel_data.global_x = pos_global.mdV[VX];
+	parcel_data.global_y = pos_global.mdV[VY];
+	parcel_data.global_z = pos_global.mdV[VZ];
+
+	std::string on = getString("on");
+	std::string off = getString("off");
+
+	// Processing parcel characteristics
+	if (parcel->getParcelFlagAllowVoice())
+	{
+		mVoiceText->setText(on);
+	}
+	else
+	{
+		mVoiceText->setText(off);
+	}
+
+	if (!region->getBlockFly() && parcel->getAllowFly())
+	{
+		mFlyText->setText(on);
+	}
+	else
+	{
+		mFlyText->setText(off);
+	}
+
+	if (region->getRestrictPushObject() || parcel->getRestrictPushObject())
+	{
+		mPushText->setText(off);
+	}
+	else
+	{
+		mPushText->setText(on);
+	}
+
+	if (parcel->getAllowModify())
+	{
+		mBuildText->setText(on);
+	}
+	else
+	{
+		mBuildText->setText(off);
+	}
+
+	if((region->getRegionFlags() & REGION_FLAGS_SKIP_SCRIPTS) ||
+	   (region->getRegionFlags() & REGION_FLAGS_ESTATE_SKIP_SCRIPTS) ||
+	   !parcel->getAllowOtherScripts())
+	{
+		mScriptsText->setText(off);
+	}
+	else
+	{
+		mScriptsText->setText(on);
+	}
+
+	if (region->getAllowDamage() || parcel->getAllowDamage())
+	{
+		mDamageText->setText(on);
+	}
+	else
+	{
+		mDamageText->setText(off);
+	}
+
+	mRegionNameText->setText(region->getName());
+	mRegionTypeText->setText(region->getSimProductName());
+	mRegionRatingText->setText(region->getSimAccessString());
+
+	// Determine parcel owner
+	if (parcel->isPublic())
+	{
+		mParcelOwner->setText(getString("public"));
+		mRegionOwnerText->setText(getString("public"));
+	}
+	else
+	{
+		if (parcel->getIsGroupOwned())
+		{
+			mRegionOwnerText->setText(getString("group_owned_text"));
+
+			if(!parcel->getGroupID().isNull())
+			{
+				// FIXME: Using parcel group as region group.
+				gCacheName->get(parcel->getGroupID(), TRUE,
+								boost::bind(&LLPanelPlaceInfo::nameUpdatedCallback, mRegionGroupText, _2, _3));
+
+				gCacheName->get(parcel->getGroupID(), TRUE,
+								boost::bind(&LLPanelPlaceInfo::nameUpdatedCallback, mParcelOwner, _2, _3));
+			}
+			else
+			{
+				std::string owner = getString("none_text");
+				mRegionGroupText->setText(owner);
+				mParcelOwner->setText(owner);
+			}
+		}
+		else
+		{
+			// Figure out the owner's name
+			gCacheName->get(parcel->getOwnerID(), FALSE,
+							boost::bind(&LLPanelPlaceInfo::nameUpdatedCallback, mParcelOwner, _2, _3));
+			gCacheName->get(region->getOwner(), FALSE,
+							boost::bind(&LLPanelPlaceInfo::nameUpdatedCallback, mRegionOwnerText, _2, _3));
+		}
+
+		if(LLParcel::OS_LEASE_PENDING == parcel->getOwnershipStatus())
+		{
+			mRegionOwnerText->setText(mRegionOwnerText->getText() + getString("sale_pending_text"));
+		}
+	}
+
+	mEstateRatingText->setText(region->getSimAccessString());
+
+	S32 area;
+	S32 claim_price;
+	S32 rent_price;
+	F32 dwell;
+	BOOL for_sale = parcel->getForSale();
+	LLViewerParcelMgr::getInstance()->getDisplayInfo(&area,
+													 &claim_price,
+													 &rent_price,
+													 &for_sale,
+													 &dwell);
+	if (for_sale)
+	{
+		// Adding "For Sale" flag in remote parcel response format.
+		parcel_data.flags |= DFQ_FOR_SALE;
+
+		const LLUUID& auth_buyer_id = parcel->getAuthorizedBuyerID();
+		if(auth_buyer_id.notNull())
+		{
+			gCacheName->get(auth_buyer_id, TRUE,
+							boost::bind(&LLPanelPlaceInfo::nameUpdatedCallback, mSaleToText, _2, _3));
+
+			// Show sales info to a specific person or a group he belongs to.
+			if (auth_buyer_id != gAgent.getID() && !gAgent.isInGroup(auth_buyer_id))
+			{
+				for_sale = FALSE;
+			}
+		}
+		else
+		{
+			mSaleToText->setText(getString("anyone"));
+		}
+
+		const U8* sign = (U8*)getString("price_text").c_str();
+		const U8* sqm = (U8*)getString("area_text").c_str();
+
+		mSalesPriceText->setText(llformat("%s%d ", sign, parcel->getSalePrice()));
+		mAreaText->setText(llformat("%d %s", area, sqm));
+		mTrafficText->setText(llformat("%.0f", dwell));
+
+		// Can't have more than region max tasks, regardless of parcel
+		// object bonus factor.
+		S32 primitives = llmin(llround(parcel->getMaxPrimCapacity() * parcel->getParcelPrimBonus()),
+							   (S32)region->getMaxTasks());
+
+		const U8* available = (U8*)getString("available").c_str();
+		const U8* allocated = (U8*)getString("allocated").c_str();
+
+		mPrimitivesText->setText(llformat("%d %s, %d %s", primitives, available, parcel->getPrimCount(), allocated));
+
+		if (parcel->getAllowOtherScripts())
+		{
+			mParcelScriptsText->setText(getString("all_residents_text"));
+		}
+		else if (parcel->getAllowGroupScripts())
+		{
+			mParcelScriptsText->setText(getString("group_text"));
+		}
+		else
+		{
+			mParcelScriptsText->setText(off);
+		}
+
+		mTerraformLimitsText->setText(parcel->getAllowTerraform() ? on : off);
+
+		if (region->getRegionFlags() & REGION_FLAGS_ALLOW_PARCEL_CHANGES)
+		{
+			mSubdivideText->setText(getString("can_change"));
+		}
+		else
+		{
+			mSubdivideText->setText(getString("can_not_change"));
+		}
+		if (region->getRegionFlags() & REGION_FLAGS_BLOCK_LAND_RESELL)
+		{
+			mResaleText->setText(getString("can_not_resell"));
+		}
+		else
+		{
+			mResaleText->setText(getString("can_resell"));
+		}
+	}
+
+	mSelectedParcelID = parcel->getLocalID();
+	mLastSelectedRegionID = region->getRegionID();
+	processParcelInfo(parcel_data);
+
+	mYouAreHerePanel->setVisible(is_current_parcel);
+	getChild<LLAccordionCtrlTab>("sales_tab")->setVisible(for_sale);
+}
+
+void LLPanelPlaceProfile::updateEstateName(const std::string& name)
+{
+	mEstateNameText->setText(name);
+}
+
+void LLPanelPlaceProfile::updateEstateOwnerName(const std::string& name)
+{
+	mEstateOwnerText->setText(name);
+}
+
+void LLPanelPlaceProfile::updateCovenantText(const std::string &text)
+{
+	mCovenantText->setText(text);
+}
+
+void LLPanelPlaceProfile::updateLastVisitedText(const LLDate &date)
+{
+	if (date.isNull())
+	{
+		mLastVisited->setText(getString("unknown"));
+	}
+	else
+	{
+		std::string timeStr = getString("acquired_date");
+		LLSD substitution;
+		substitution["datetime"] = (S32) date.secondsSinceEpoch();
+		LLStringUtil::format (timeStr, substitution);
+		mLastVisited->setText(timeStr);
+	}
+}
+
+void LLPanelPlaceProfile::onForSaleBannerClick()
+{
+	LLViewerParcelMgr* mgr = LLViewerParcelMgr::getInstance();
+	LLParcelSelectionHandle hParcel = mgr->getFloatingParcelSelection();
+	LLViewerRegion* selected_region =  mgr->getSelectionRegion();
+	if(!hParcel.isNull() && selected_region)
+	{
+		if(hParcel->getParcel()->getLocalID() == mSelectedParcelID &&
+				mLastSelectedRegionID ==selected_region->getRegionID())
+		{
+			if(hParcel->getParcel()->getSalePrice() - gStatusBar->getBalance() > 0)
+			{
+				LLFloaterBuyCurrency::buyCurrency("Buying selected land ", hParcel->getParcel()->getSalePrice());
+			}
+			else
+			{
+				LLViewerParcelMgr::getInstance()->startBuyLand();
+			}
+		}
+		else
+		{
+			LL_WARNS("Places") << "User  is trying  to buy remote parcel.Operation is not supported"<< LL_ENDL;
+		}
+
+	}
+}
+
+// static
+void LLPanelPlaceProfile::updateYouAreHereBanner(void* userdata)
+{
+	//YouAreHere Banner should be displayed only for selected places,
+	// If you want to display it for landmark or teleport history item, you should check by mParcelId
+
+	LLPanelPlaceProfile* self = static_cast<LLPanelPlaceProfile*>(userdata);
+	if(!self->getVisible())
+		return;
+
+	if(!gDisconnected)
+	{
+		static F32 radius = gSavedSettings.getF32("YouAreHereDistance");
+
+		BOOL display_banner = gAgent.getRegion()->getRegionID() == self->mLastSelectedRegionID &&
+										LLAgentUI::checkAgentDistance(self->mPosRegion, radius);
+
+		self->mYouAreHerePanel->setVisible(display_banner);
+	}
+}
diff --git a/indra/newview/llpanelplaceprofile.h b/indra/newview/llpanelplaceprofile.h
new file mode 100644
index 0000000000..d8e4bcb6bd
--- /dev/null
+++ b/indra/newview/llpanelplaceprofile.h
@@ -0,0 +1,114 @@
+/**
+ * @file llpanelplaceprofile.h
+ * @brief Displays place profile in Side Tray.
+ *
+ * $LicenseInfo:firstyear=2009&license=viewergpl$
+ *
+ * Copyright (c) 2004-2009, Linden Research, Inc.
+ *
+ * Second Life Viewer Source Code
+ * The source code in this file ("Source Code") is provided by Linden Lab
+ * to you under the terms of the GNU General Public License, version 2.0
+ * ("GPL"), unless you have obtained a separate licensing agreement
+ * ("Other License"), formally executed by you and Linden Lab.  Terms of
+ * the GPL can be found in doc/GPL-license.txt in this distribution, or
+ * online at http://secondlifegrid.net/programs/open_source/licensing/gplv2
+ *
+ * There are special exceptions to the terms and conditions of the GPL as
+ * it is applied to this Source Code. View the full text of the exception
+ * in the file doc/FLOSS-exception.txt in this software distribution, or
+ * online at
+ * http://secondlifegrid.net/programs/open_source/licensing/flossexception
+ *
+ * By copying, modifying or distributing this software, you acknowledge
+ * that you have read and understood your obligations described above,
+ * and agree to abide by those obligations.
+ *
+ * ALL LINDEN LAB SOURCE CODE IS PROVIDED "AS IS." LINDEN LAB MAKES NO
+ * WARRANTIES, EXPRESS, IMPLIED OR OTHERWISE, REGARDING ITS ACCURACY,
+ * COMPLETENESS OR PERFORMANCE.
+ * $/LicenseInfo$
+ */
+
+#ifndef LL_LLPANELPLACEPROFILE_H
+#define LL_LLPANELPLACEPROFILE_H
+
+#include "llpanelplaceinfo.h"
+
+class LLTextEditor;
+
+class LLPanelPlaceProfile : public LLPanelPlaceInfo
+{
+public:
+	LLPanelPlaceProfile();
+	/*virtual*/ ~LLPanelPlaceProfile();
+
+	/*virtual*/ BOOL postBuild();
+
+	/*virtual*/ void resetLocation();
+
+	/*virtual*/ void setInfoType(INFO_TYPE type);
+
+	/*virtual*/ void processParcelInfo(const LLParcelData& parcel_data);
+
+	// Displays information about the currently selected parcel
+	// without sending a request to the server.
+	// If is_current_parcel true shows "You Are Here" banner.
+	void displaySelectedParcelInfo(LLParcel* parcel,
+								   LLViewerRegion* region,
+								   const LLVector3d& pos_global,
+								   bool is_current_parcel);
+
+	void updateEstateName(const std::string& name);
+	void updateEstateOwnerName(const std::string& name);
+	void updateCovenantText(const std::string &text);
+	void updateLastVisitedText(const LLDate &date);
+
+private:
+	void onForSaleBannerClick();
+
+	static void updateYouAreHereBanner(void*);// added to gIdleCallbacks
+
+	/**
+	 * Holds last displayed parcel. Needed for YouAreHere banner.
+	 */
+	S32					mSelectedParcelID;
+	LLUUID				mLastSelectedRegionID;
+
+	LLPanel*			mForSalePanel;
+	LLPanel*			mYouAreHerePanel;
+
+	LLTextBox*			mParcelOwner;
+	LLTextBox*			mLastVisited;
+
+	LLTextBox*			mRatingText;
+	LLTextBox*			mVoiceText;
+	LLTextBox*			mFlyText;
+	LLTextBox*			mPushText;
+	LLTextBox*			mBuildText;
+	LLTextBox*			mScriptsText;
+	LLTextBox*			mDamageText;
+
+	LLTextBox*			mRegionNameText;
+	LLTextBox*			mRegionTypeText;
+	LLTextBox*			mRegionRatingText;
+	LLTextBox*			mRegionOwnerText;
+	LLTextBox*			mRegionGroupText;
+
+	LLTextBox*			mEstateNameText;
+	LLTextBox*			mEstateRatingText;
+	LLTextBox*			mEstateOwnerText;
+	LLTextEditor*		mCovenantText;
+
+	LLTextBox*			mSalesPriceText;
+	LLTextBox*			mAreaText;
+	LLTextBox*			mTrafficText;
+	LLTextBox*			mPrimitivesText;
+	LLTextBox*			mParcelScriptsText;
+	LLTextBox*			mTerraformLimitsText;
+	LLTextEditor*		mSubdivideText;
+	LLTextEditor*		mResaleText;
+	LLTextBox*			mSaleToText;
+};
+
+#endif // LL_LLPANELPLACEPROFILE_H
diff --git a/indra/newview/llpanelplaces.cpp b/indra/newview/llpanelplaces.cpp
index b2e9110e96..66efb96fc7 100644
--- a/indra/newview/llpanelplaces.cpp
+++ b/indra/newview/llpanelplaces.cpp
@@ -57,9 +57,10 @@
 #include "llinventorymodel.h"
 #include "lllandmarkactions.h"
 #include "lllandmarklist.h"
-#include "llpanelplaceinfo.h"
+#include "llpanellandmarkinfo.h"
 #include "llpanellandmarks.h"
 #include "llpanelpick.h"
+#include "llpanelplaceprofile.h"
 #include "llpanelteleporthistory.h"
 #include "llteleporthistorystorage.h"
 #include "lltoggleablemenu.h"
@@ -121,7 +122,8 @@ LLPanelPlaces::LLPanelPlaces()
 		mFilterSubString(LLStringUtil::null),
 		mActivePanel(NULL),
 		mFilterEditor(NULL),
-		mPlaceInfo(NULL),
+		mPlaceProfile(NULL),
+		mLandmarkInfo(NULL),
 		mPickPanel(NULL),
 		mItem(NULL),
 		mPlaceMenu(NULL),
@@ -135,7 +137,7 @@ LLPanelPlaces::LLPanelPlaces()
 	gInventory.addObserver(mInventoryObserver);
 
 	LLViewerParcelMgr::getInstance()->addAgentParcelChangedCallback(
-			boost::bind(&LLPanelPlaces::onAgentParcelChange, this));
+			boost::bind(&LLPanelPlaces::updateVerbs, this));
 
 	//LLUICtrlFactory::getInstance()->buildPanel(this, "panel_places.xml"); // Called from LLRegisterPanelClass::defaultPanelClassBuilder()
 }
@@ -206,25 +208,32 @@ BOOL LLPanelPlaces::postBuild()
 		mFilterEditor->setCommitCallback(boost::bind(&LLPanelPlaces::onFilterEdit, this, _2, false));
 	}
 
-	mPlaceInfo = getChild<LLPanelPlaceInfo>("panel_place_info");
+	mPlaceProfile = getChild<LLPanelPlaceProfile>("panel_place_profile");
+	mLandmarkInfo = getChild<LLPanelLandmarkInfo>("panel_landmark_info");
+	if (!mPlaceProfile || !mLandmarkInfo)
+		return FALSE;
 
-	LLButton* back_btn = mPlaceInfo->getChild<LLButton>("back_btn");
+	LLButton* back_btn = mPlaceProfile->getChild<LLButton>("back_btn");
 	back_btn->setClickedCallback(boost::bind(&LLPanelPlaces::onBackButtonClicked, this));
 
-	LLLineEditor* title_editor = mPlaceInfo->getChild<LLLineEditor>("title_editor");
+	back_btn = mLandmarkInfo->getChild<LLButton>("back_btn");
+	back_btn->setClickedCallback(boost::bind(&LLPanelPlaces::onBackButtonClicked, this));
+
+	LLLineEditor* title_editor = mLandmarkInfo->getChild<LLLineEditor>("title_editor");
 	title_editor->setKeystrokeCallback(boost::bind(&LLPanelPlaces::onEditButtonClicked, this), NULL);
 
-	LLTextEditor* notes_editor = mPlaceInfo->getChild<LLTextEditor>("notes_editor");
+	LLTextEditor* notes_editor = mLandmarkInfo->getChild<LLTextEditor>("notes_editor");
 	notes_editor->setKeystrokeCallback(boost::bind(&LLPanelPlaces::onEditButtonClicked, this));
 
-	LLComboBox* folder_combo = mPlaceInfo->getChild<LLComboBox>("folder_combo");
+	LLComboBox* folder_combo = mLandmarkInfo->getChild<LLComboBox>("folder_combo");
 	folder_combo->setSelectionCallback(boost::bind(&LLPanelPlaces::onEditButtonClicked, this));
+
 	return TRUE;
 }
 
 void LLPanelPlaces::onOpen(const LLSD& key)
 {
-	if(mPlaceInfo == NULL || key.size() == 0)
+	if(!mPlaceProfile || !mLandmarkInfo || key.size() == 0)
 		return;
 
 	mFilterEditor->clear();
@@ -239,11 +248,11 @@ void LLPanelPlaces::onOpen(const LLSD& key)
 
 	if (mPlaceInfoType == AGENT_INFO_TYPE)
 	{
-		mPlaceInfo->setInfoType(LLPanelPlaceInfo::AGENT);
+		mPlaceProfile->setInfoType(LLPanelPlaceInfo::AGENT);
 	}
 	else if (mPlaceInfoType == CREATE_LANDMARK_INFO_TYPE)
 	{
-		mPlaceInfo->setInfoType(LLPanelPlaceInfo::CREATE_LANDMARK);
+		mLandmarkInfo->setInfoType(LLPanelPlaceInfo::CREATE_LANDMARK);
 
 		if (key.has("x") && key.has("y") && key.has("z"))
 		{
@@ -256,11 +265,11 @@ void LLPanelPlaces::onOpen(const LLSD& key)
 			mPosGlobal = gAgent.getPositionGlobal();
 		}
 
-		mPlaceInfo->displayParcelInfo(LLUUID(), mPosGlobal);
+		mLandmarkInfo->displayParcelInfo(LLUUID(), mPosGlobal);
 	}
 	else if (mPlaceInfoType == LANDMARK_INFO_TYPE)
 	{
-		mPlaceInfo->setInfoType(LLPanelPlaceInfo::LANDMARK);
+		mLandmarkInfo->setInfoType(LLPanelPlaceInfo::LANDMARK);
 
 		LLInventoryItem* item = gInventory.getItem(key["id"].asUUID());
 		if (!item)
@@ -270,17 +279,12 @@ void LLPanelPlaces::onOpen(const LLSD& key)
 	}
 	else if (mPlaceInfoType == REMOTE_PLACE_INFO_TYPE)
 	{
-		if (mPlaceInfo->isMediaPanelVisible())
-		{
-			toggleMediaPanel();
-		}
-
 		mPosGlobal = LLVector3d(key["x"].asReal(),
 								key["y"].asReal(),
 								key["z"].asReal());
 
-		mPlaceInfo->setInfoType(LLPanelPlaceInfo::PLACE);
-		mPlaceInfo->displayParcelInfo(LLUUID(), mPosGlobal);
+		mPlaceProfile->setInfoType(LLPanelPlaceInfo::PLACE);
+		mPlaceProfile->displayParcelInfo(LLUUID(), mPosGlobal);
 	}
 	else if (mPlaceInfoType == TELEPORT_HISTORY_INFO_TYPE)
 	{
@@ -291,9 +295,9 @@ void LLPanelPlaces::onOpen(const LLSD& key)
 
 		mPosGlobal = hist_items[index].mGlobalPos;
 
-		mPlaceInfo->setInfoType(LLPanelPlaceInfo::TELEPORT_HISTORY);
-		mPlaceInfo->updateLastVisitedText(hist_items[index].mDate);
-		mPlaceInfo->displayParcelInfo(LLUUID(), mPosGlobal);
+		mPlaceProfile->setInfoType(LLPanelPlaceInfo::TELEPORT_HISTORY);
+		mPlaceProfile->updateLastVisitedText(hist_items[index].mDate);
+		mPlaceProfile->displayParcelInfo(LLUUID(), mPosGlobal);
 	}
 
 	LLViewerParcelMgr* parcel_mgr = LLViewerParcelMgr::getInstance();
@@ -321,7 +325,7 @@ void LLPanelPlaces::onOpen(const LLSD& key)
 
 void LLPanelPlaces::setItem(LLInventoryItem* item)
 {
-	if (!mPlaceInfo || !item)
+	if (!mLandmarkInfo || !item)
 		return;
 
 	mItem = item;
@@ -351,19 +355,19 @@ void LLPanelPlaces::setItem(LLInventoryItem* item)
 
 	if (is_landmark_editable)
 	{
-		if(!mPlaceInfo->setLandmarkFolder(mItem->getParentUUID()) && !mItem->getParentUUID().isNull())
+		if(!mLandmarkInfo->setLandmarkFolder(mItem->getParentUUID()) && !mItem->getParentUUID().isNull())
 		{
 			const LLViewerInventoryCategory* cat = gInventory.getCategory(mItem->getParentUUID());
-			if(cat)
+			if (cat)
 			{
-				std::string cat_fullname = LLPanelPlaceInfo::getFullFolderName(cat);
-				LLComboBox* folderList = mPlaceInfo->getChild<LLComboBox>("folder_combo");
-				folderList->add(cat_fullname, cat->getUUID(),ADD_TOP);
+				std::string cat_fullname = LLPanelLandmarkInfo::getFullFolderName(cat);
+				LLComboBox* folderList = mLandmarkInfo->getChild<LLComboBox>("folder_combo");
+				folderList->add(cat_fullname, cat->getUUID(), ADD_TOP);
 			}
 		}
 	}
 
-	mPlaceInfo->displayItemInfo(mItem);
+	mLandmarkInfo->displayItemInfo(mItem);
 
 	LLLandmark* lm = gLandmarkList.getAsset(mItem->getAssetUUID(),
 											boost::bind(&LLPanelPlaces::onLandmarkLoaded, this, _1));
@@ -375,13 +379,13 @@ void LLPanelPlaces::setItem(LLInventoryItem* item)
 
 void LLPanelPlaces::onLandmarkLoaded(LLLandmark* landmark)
 {
-	if (!mPlaceInfo)
+	if (!mLandmarkInfo)
 		return;
 
 	LLUUID region_id;
 	landmark->getRegionID(region_id);
 	landmark->getGlobalPos(mPosGlobal);
-	mPlaceInfo->displayParcelInfo(region_id, mPosGlobal);
+	mLandmarkInfo->displayParcelInfo(region_id, mPosGlobal);
 }
 
 void LLPanelPlaces::onFilterEdit(const std::string& search_string, bool force_filter)
@@ -418,10 +422,8 @@ void LLPanelPlaces::onShareButtonClicked()
 
 void LLPanelPlaces::onTeleportButtonClicked()
 {
-	if (!mPlaceInfo)
-		return;
-
-	if (mPlaceInfo->getVisible())
+	LLPanelPlaceInfo* panel = getCurrentInfoPanel();
+	if (panel && panel->getVisible())
 	{
 		if (mPlaceInfoType == LANDMARK_INFO_TYPE)
 		{
@@ -450,10 +452,8 @@ void LLPanelPlaces::onTeleportButtonClicked()
 
 void LLPanelPlaces::onShowOnMapButtonClicked()
 {
-	if (!mPlaceInfo)
-		return;
-
-	if (mPlaceInfo->getVisible())
+	LLPanelPlaceInfo* panel = getCurrentInfoPanel();
+	if (panel && panel->getVisible())
 	{
 		LLFloaterWorldMap* worldmap_instance = LLFloaterWorldMap::getInstance();
 		if(!worldmap_instance)
@@ -496,31 +496,31 @@ void LLPanelPlaces::onShowOnMapButtonClicked()
 
 void LLPanelPlaces::onEditButtonClicked()
 {
-	if (!mPlaceInfo || isLandmarkEditModeOn)
+	if (!mLandmarkInfo || isLandmarkEditModeOn)
 		return;
 
 	isLandmarkEditModeOn = true;
 
-	mPlaceInfo->toggleLandmarkEditMode(TRUE);
+	mLandmarkInfo->toggleLandmarkEditMode(TRUE);
 
 	updateVerbs();
 }
 
 void LLPanelPlaces::onSaveButtonClicked()
 {
-	if (!mPlaceInfo || mItem.isNull())
+	if (!mLandmarkInfo || mItem.isNull())
 		return;
 
-	std::string current_title_value = mPlaceInfo->getLandmarkTitle();
+	std::string current_title_value = mLandmarkInfo->getLandmarkTitle();
 	std::string item_title_value = mItem->getName();
-	std::string current_notes_value = mPlaceInfo->getLandmarkNotes();
+	std::string current_notes_value = mLandmarkInfo->getLandmarkNotes();
 	std::string item_notes_value = mItem->getDescription();
 
 	LLStringUtil::trim(current_title_value);
 	LLStringUtil::trim(current_notes_value);
 
 	LLUUID item_id = mItem->getUUID();
-	LLUUID folder_id = mPlaceInfo->getLandmarkFolder();
+	LLUUID folder_id = mLandmarkInfo->getLandmarkFolder();
 
 	LLPointer<LLViewerInventoryItem> new_item = new LLViewerInventoryItem(mItem);
 
@@ -553,7 +553,7 @@ void LLPanelPlaces::onSaveButtonClicked()
 
 void LLPanelPlaces::onCancelButtonClicked()
 {
-	if (!mPlaceInfo)
+	if (!mLandmarkInfo)
 		return;
 
 	if (mPlaceInfoType == CREATE_LANDMARK_INFO_TYPE)
@@ -562,13 +562,13 @@ void LLPanelPlaces::onCancelButtonClicked()
 	}
 	else
 	{
-		mPlaceInfo->toggleLandmarkEditMode(FALSE);
+		mLandmarkInfo->toggleLandmarkEditMode(FALSE);
 		isLandmarkEditModeOn = false;
 
 		updateVerbs();
 
 		// Reload the landmark properties.
-		mPlaceInfo->displayItemInfo(mItem);
+		mLandmarkInfo->displayItemInfo(mItem);
 	}
 }
 
@@ -597,7 +597,7 @@ void LLPanelPlaces::onOverflowButtonClicked()
 		if (mItem.notNull())
 		{
 			const LLUUID& item_id = mItem->getUUID();
-			const LLUUID& trash_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_TRASH);
+			const LLUUID trash_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_TRASH);
 			is_landmark_removable = gInventory.isObjectDescendentOf(item_id, gInventory.getRootFolderID()) &&
 									!gInventory.isObjectDescendentOf(item_id, trash_id);
 		}
@@ -652,9 +652,6 @@ void LLPanelPlaces::onOverflowMenuItemClicked(const LLSD& param)
 	}
 	else if (item == "pick")
 	{
-		if (!mPlaceInfo)
-			return;
-
 		if (mPickPanel == NULL)
 		{
 			mPickPanel = LLPanelPickEdit::create();
@@ -667,7 +664,12 @@ void LLPanelPlaces::onOverflowMenuItemClicked(const LLSD& param)
 
 		togglePickPanel(TRUE);
 		mPickPanel->onOpen(LLSD());
-		mPlaceInfo->createPick(mPosGlobal, mPickPanel);
+
+		LLPanelPlaceInfo* panel = getCurrentInfoPanel();
+		if (panel)
+		{
+			panel->createPick(mPosGlobal, mPickPanel);
+		}
 
 		LLRect rect = getRect();
 		mPickPanel->reshape(rect.getWidth(), rect.getHeight());
@@ -677,7 +679,7 @@ void LLPanelPlaces::onOverflowMenuItemClicked(const LLSD& param)
     {
         if ( mItem.notNull() ) 
         {
-            LLUUID favorites_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_FAVORITE);
+            const LLUUID& favorites_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_FAVORITE);
             if ( favorites_id.notNull() )
             {
                 copy_inventory_item(gAgent.getID(),
@@ -694,39 +696,16 @@ void LLPanelPlaces::onOverflowMenuItemClicked(const LLSD& param)
 
 void LLPanelPlaces::onBackButtonClicked()
 {
-	if (!mPlaceInfo)
-		return;
-	
-	if (mPlaceInfo->isMediaPanelVisible())
-	{
-		toggleMediaPanel();
-	}
-	else
-	{
-		togglePlaceInfoPanel(FALSE);
+	togglePlaceInfoPanel(FALSE);
 
-		// Resetting mPlaceInfoType when Place Info panel is closed.
-		mPlaceInfoType = LLStringUtil::null;
+	// Resetting mPlaceInfoType when Place Info panel is closed.
+	mPlaceInfoType = LLStringUtil::null;
 
-		isLandmarkEditModeOn = false;
-	}
+	isLandmarkEditModeOn = false;
 
 	updateVerbs();
 }
 
-void LLPanelPlaces::toggleMediaPanel()
-{
-	if (!mPlaceInfo)
-		return;
-
-	mPlaceInfo->toggleMediaPanel(!mPlaceInfo->isMediaPanelVisible());
-
-	// Refresh the current place info because
-	// the media panel controls can't refer to
-	// the remote parcel media.
-	onOpen(LLSD().insert("type", AGENT_INFO_TYPE));
-}
-
 void LLPanelPlaces::togglePickPanel(BOOL visible)
 {
 	setAllChildrenVisible(this, !visible);
@@ -737,26 +716,50 @@ void LLPanelPlaces::togglePickPanel(BOOL visible)
 
 void LLPanelPlaces::togglePlaceInfoPanel(BOOL visible)
 {
-	if (!mPlaceInfo)
+	if (!mPlaceProfile || !mLandmarkInfo)
 		return;
 
-	mPlaceInfo->setVisible(visible);
 	mFilterEditor->setVisible(!visible);
 	mTabContainer->setVisible(!visible);
 
-	if (visible)
+	if (mPlaceInfoType == AGENT_INFO_TYPE ||
+		mPlaceInfoType == REMOTE_PLACE_INFO_TYPE ||
+		mPlaceInfoType == TELEPORT_HISTORY_INFO_TYPE)
 	{
-		mPlaceInfo->resetLocation();
+		mPlaceProfile->setVisible(visible);
 
-		LLRect rect = getRect();
-		LLRect new_rect = LLRect(rect.mLeft, rect.mTop, rect.mRight, mTabContainer->getRect().mBottom);
-		mPlaceInfo->reshape(new_rect.getWidth(),new_rect.getHeight());
+		if (visible)
+		{
+			mPlaceProfile->resetLocation();
+
+			LLRect rect = getRect();
+			LLRect new_rect = LLRect(rect.mLeft, rect.mTop, rect.mRight, mTabContainer->getRect().mBottom);
+			mPlaceProfile->reshape(new_rect.getWidth(), new_rect.getHeight());
+
+			mLandmarkInfo->setVisible(FALSE);
+		}
+	}
+	else if (mPlaceInfoType == CREATE_LANDMARK_INFO_TYPE ||
+			 mPlaceInfoType == LANDMARK_INFO_TYPE)
+	{
+		mLandmarkInfo->setVisible(visible);
+
+		if (visible)
+		{
+			mLandmarkInfo->resetLocation();
+
+			LLRect rect = getRect();
+			LLRect new_rect = LLRect(rect.mLeft, rect.mTop, rect.mRight, mTabContainer->getRect().mBottom);
+			mLandmarkInfo->reshape(new_rect.getWidth(), new_rect.getHeight());
+
+			mPlaceProfile->setVisible(FALSE);
+		}
 	}
 }
 
 void LLPanelPlaces::changedParcelSelection()
 {
-	if (!mPlaceInfo)
+	if (!mPlaceProfile)
 		return;
 
 	LLViewerParcelMgr* parcel_mgr = LLViewerParcelMgr::getInstance();
@@ -782,8 +785,8 @@ void LLPanelPlaces::changedParcelSelection()
 		}
 	}
 
-	mPlaceInfo->resetLocation();
-	mPlaceInfo->displaySelectedParcelInfo(parcel, region, mPosGlobal, is_current_parcel);
+	mPlaceProfile->resetLocation();
+	mPlaceProfile->displaySelectedParcelInfo(parcel, region, mPosGlobal, is_current_parcel);
 
 	updateVerbs();
 }
@@ -830,30 +833,22 @@ void LLPanelPlaces::changedInventory(U32 mask)
 	gInventory.removeObserver(mInventoryObserver);
 }
 
-void LLPanelPlaces::onAgentParcelChange()
+void LLPanelPlaces::updateVerbs()
 {
-	if (!mPlaceInfo)
-		return;
+	bool is_place_info_visible;
 
-	if (mPlaceInfo->isMediaPanelVisible())
+	LLPanelPlaceInfo* panel = getCurrentInfoPanel();
+	if (panel)
 	{
-		onOpen(LLSD().insert("type", AGENT_INFO_TYPE));
+		is_place_info_visible = panel->getVisible();
 	}
 	else
 	{
-		updateVerbs();
+		is_place_info_visible = false;
 	}
-}
 
-void LLPanelPlaces::updateVerbs()
-{
-	if (!mPlaceInfo)
-		return;
-
-	bool is_place_info_visible = mPlaceInfo->getVisible();
 	bool is_agent_place_info_visible = mPlaceInfoType == AGENT_INFO_TYPE;
 	bool is_create_landmark_visible = mPlaceInfoType == CREATE_LANDMARK_INFO_TYPE;
-	bool is_media_panel_visible = mPlaceInfo->isMediaPanelVisible();
 
 	mTeleportBtn->setVisible(!is_create_landmark_visible && !isLandmarkEditModeOn);
 	mShowOnMapBtn->setVisible(!is_create_landmark_visible && !isLandmarkEditModeOn);
@@ -864,7 +859,7 @@ void LLPanelPlaces::updateVerbs()
 	mCancelBtn->setVisible(isLandmarkEditModeOn);
 	mCloseBtn->setVisible(is_create_landmark_visible && !isLandmarkEditModeOn);
 
-	mOverflowBtn->setEnabled(is_place_info_visible && !is_media_panel_visible && !is_create_landmark_visible);
+	mOverflowBtn->setEnabled(is_place_info_visible && !is_create_landmark_visible);
 
 	if (is_place_info_visible)
 	{
@@ -872,16 +867,13 @@ void LLPanelPlaces::updateVerbs()
 		{
 			// We don't need to teleport to the current location
 			// so check if the location is not within the current parcel.
-			mTeleportBtn->setEnabled(!is_media_panel_visible &&
-									 !mPosGlobal.isExactlyZero() &&
+			mTeleportBtn->setEnabled(!mPosGlobal.isExactlyZero() &&
 									 !LLViewerParcelMgr::getInstance()->inAgentParcel(mPosGlobal));
 		}
 		else if (mPlaceInfoType == LANDMARK_INFO_TYPE || mPlaceInfoType == REMOTE_PLACE_INFO_TYPE)
 		{
 			mTeleportBtn->setEnabled(TRUE);
 		}
-
-		mShowOnMapBtn->setEnabled(!is_media_panel_visible);
 	}
 	else
 	{
@@ -890,6 +882,23 @@ void LLPanelPlaces::updateVerbs()
 	}
 }
 
+LLPanelPlaceInfo* LLPanelPlaces::getCurrentInfoPanel()
+{
+	if (mPlaceInfoType == AGENT_INFO_TYPE ||
+		mPlaceInfoType == REMOTE_PLACE_INFO_TYPE ||
+		mPlaceInfoType == TELEPORT_HISTORY_INFO_TYPE)
+	{
+		return mPlaceProfile;
+	}
+	else if (mPlaceInfoType == CREATE_LANDMARK_INFO_TYPE ||
+			 mPlaceInfoType == LANDMARK_INFO_TYPE)
+	{
+		return mLandmarkInfo;
+	}
+
+	return NULL;
+}
+
 static bool is_agent_in_selected_parcel(LLParcel* parcel)
 {
 	LLViewerParcelMgr* parcel_mgr = LLViewerParcelMgr::getInstance();
diff --git a/indra/newview/llpanelplaces.h b/indra/newview/llpanelplaces.h
index e2d281dd84..39eb5261db 100644
--- a/indra/newview/llpanelplaces.h
+++ b/indra/newview/llpanelplaces.h
@@ -37,6 +37,10 @@
 class LLInventoryItem;
 class LLFilterEditor;
 class LLLandmark;
+
+class LLPanelLandmarkInfo;
+class LLPanelPlaceProfile;
+
 class LLPanelPickEdit;
 class LLPanelPlaceInfo;
 class LLPanelPlacesTab;
@@ -85,13 +89,16 @@ private:
 	void togglePickPanel(BOOL visible);
 	void togglePlaceInfoPanel(BOOL visible);
 
-	void onAgentParcelChange();
 	void updateVerbs();
 
+	LLPanelPlaceInfo* getCurrentInfoPanel();
+
 	LLFilterEditor*				mFilterEditor;
 	LLPanelPlacesTab*			mActivePanel;
 	LLTabContainer*				mTabContainer;
-	LLPanelPlaceInfo*			mPlaceInfo;
+	LLPanelPlaceProfile*		mPlaceProfile;
+	LLPanelLandmarkInfo*		mLandmarkInfo;
+
 	LLPanelPickEdit*			mPickPanel;
 	LLToggleableMenu*			mPlaceMenu;
 	LLToggleableMenu*			mLandmarkMenu;
diff --git a/indra/newview/llpanelprofileview.h b/indra/newview/llpanelprofileview.h
index b59d1d42f3..45c2fc116e 100644
--- a/indra/newview/llpanelprofileview.h
+++ b/indra/newview/llpanelprofileview.h
@@ -36,6 +36,8 @@
 #include "llpanel.h"
 #include "llpanelprofile.h"
 #include "llavatarpropertiesprocessor.h"
+#include "llagent.h"
+#include "lltooldraganddrop.h"
 
 class LLPanelProfile;
 class LLPanelProfileTab;
@@ -64,6 +66,18 @@ public:
 
 	/*virtual*/ void togglePanel(LLPanel* panel);
 
+	BOOL handleDragAndDrop(S32 x, S32 y, MASK mask,
+						   BOOL drop, EDragAndDropType cargo_type,
+						   void *cargo_data, EAcceptance *accept,
+						   std::string& tooltip_msg)
+	{
+		LLToolDragAndDrop::handleGiveDragAndDrop(getAvatarId(), gAgent.getSessionID(), drop,
+				 cargo_type, cargo_data, accept);
+
+		return TRUE;
+	}
+
+
 protected:
 
 	void onBackBtnClick();
diff --git a/indra/newview/llparticipantlist.cpp b/indra/newview/llparticipantlist.cpp
index e97eb1df2b..9450bee315 100644
--- a/indra/newview/llparticipantlist.cpp
+++ b/indra/newview/llparticipantlist.cpp
@@ -32,6 +32,11 @@
 
 #include "llviewerprecompiledheaders.h"
 
+// common includes
+#include "lltrans.h"
+#include "llavataractions.h"
+#include "llagent.h"
+
 #include "llparticipantlist.h"
 #include "llavatarlist.h"
 #include "llspeakers.h"
@@ -39,15 +44,18 @@
 //LLParticipantList retrieves add, clear and remove events and updates view accordingly 
 LLParticipantList::LLParticipantList(LLSpeakerMgr* data_source, LLAvatarList* avatar_list):
 	mSpeakerMgr(data_source),
-	mAvatarList(avatar_list)
+	mAvatarList(avatar_list),
+	mSpeakerAddListener(*this),
+	mSpeakerRemoveListener(*this),
+	mSpeakerClearListener(*this),
+	mSortOrder(E_SORT_BY_NAME)
 {
-	mSpeakerAddListener = new SpeakerAddListener(mAvatarList);
-	mSpeakerRemoveListener = new SpeakerRemoveListener(mAvatarList);
-	mSpeakerClearListener = new SpeakerClearListener(mAvatarList);
+	mSpeakerMgr->addListener(&mSpeakerAddListener, "add");
+	mSpeakerMgr->addListener(&mSpeakerRemoveListener, "remove");
+	mSpeakerMgr->addListener(&mSpeakerClearListener, "clear");
 
-	mSpeakerMgr->addListener(mSpeakerAddListener, "add");
-	mSpeakerMgr->addListener(mSpeakerRemoveListener, "remove");
-	mSpeakerMgr->addListener(mSpeakerClearListener, "clear");
+	mAvatarList->setNoItemsCommentText(LLTrans::getString("LoadingData"));
+	mAvatarList->setDoubleClickCallback(boost::bind(&LLParticipantList::onAvatarListDoubleClicked, this, mAvatarList));
 
 	//Lets fill avatarList with existing speakers
 	LLAvatarList::uuid_vector_t& group_members = mAvatarList->getIDs();
@@ -58,24 +66,33 @@ LLParticipantList::LLParticipantList(LLSpeakerMgr* data_source, LLAvatarList* av
 	{
 		group_members.push_back((*it)->mID);
 	}
-	mAvatarList->setDirty();
-	mAvatarList->sortByName();
+	sort();
 }
 
 LLParticipantList::~LLParticipantList()
 {
-	delete mSpeakerAddListener;
-	delete mSpeakerRemoveListener;
-	delete mSpeakerClearListener;
-	mSpeakerAddListener = NULL;
-	mSpeakerRemoveListener = NULL;
-	mSpeakerClearListener = NULL;
 }
 
-//
-// LLParticipantList::SpeakerAddListener
-//
-bool LLParticipantList::SpeakerAddListener::handleEvent(LLPointer<LLOldEvents::LLEvent> event, const LLSD& userdata)
+void LLParticipantList::onAvatarListDoubleClicked(LLAvatarList* list)
+{
+	LLUUID clicked_id = list->getSelectedUUID();
+
+	if (clicked_id.isNull() || clicked_id == gAgent.getID())
+		return;
+	
+	LLAvatarActions::startIM(clicked_id);
+}
+
+void LLParticipantList::setSortOrder(EParticipantSortOrder order)
+{
+	if ( mSortOrder != order )
+	{
+		mSortOrder = order;
+		sort();
+	}
+}
+
+bool LLParticipantList::onAddItemEvent(LLPointer<LLOldEvents::LLEvent> event, const LLSD& userdata)
 {
 	LLAvatarList::uuid_vector_t& group_members = mAvatarList->getIDs();
 	LLUUID uu_id = event->getValue().asUUID();
@@ -88,15 +105,11 @@ bool LLParticipantList::SpeakerAddListener::handleEvent(LLPointer<LLOldEvents::L
 	}
 
 	group_members.push_back(uu_id);
-	mAvatarList->setDirty();
-	mAvatarList->sortByName();
+	sort();
 	return true;
 }
 
-//
-// LLParticipantList::SpeakerRemoveListener
-//
-bool LLParticipantList::SpeakerRemoveListener::handleEvent(LLPointer<LLOldEvents::LLEvent> event, const LLSD& userdata)
+bool LLParticipantList::onRemoveItemEvent(LLPointer<LLOldEvents::LLEvent> event, const LLSD& userdata)
 {
 	LLAvatarList::uuid_vector_t& group_members = mAvatarList->getIDs();
 	LLAvatarList::uuid_vector_t::iterator pos = std::find(group_members.begin(), group_members.end(), event->getValue().asUUID());
@@ -108,10 +121,7 @@ bool LLParticipantList::SpeakerRemoveListener::handleEvent(LLPointer<LLOldEvents
 	return true;
 }
 
-//
-// LLParticipantList::SpeakerClearListener
-//
-bool LLParticipantList::SpeakerClearListener::handleEvent(LLPointer<LLOldEvents::LLEvent> event, const LLSD& userdata)
+bool LLParticipantList::onClearListEvent(LLPointer<LLOldEvents::LLEvent> event, const LLSD& userdata)
 {
 	LLAvatarList::uuid_vector_t& group_members = mAvatarList->getIDs();
 	group_members.clear();
@@ -119,3 +129,45 @@ bool LLParticipantList::SpeakerClearListener::handleEvent(LLPointer<LLOldEvents:
 	return true;
 }
 
+void LLParticipantList::sort()
+{
+	if ( !mAvatarList )
+		return;
+
+	// Mark AvatarList as dirty one
+	mAvatarList->setDirty();
+
+	// TODO: Implement more sorting orders after specs updating (EM)
+	switch ( mSortOrder ) {
+	case E_SORT_BY_NAME :
+		mAvatarList->sortByName();
+		break;
+	default :
+		llwarns << "Unrecognized sort order for " << mAvatarList->getName() << llendl;
+		return;
+	}
+}
+
+//
+// LLParticipantList::SpeakerAddListener
+//
+bool LLParticipantList::SpeakerAddListener::handleEvent(LLPointer<LLOldEvents::LLEvent> event, const LLSD& userdata)
+{
+	return mParent.onAddItemEvent(event, userdata);
+}
+
+//
+// LLParticipantList::SpeakerRemoveListener
+//
+bool LLParticipantList::SpeakerRemoveListener::handleEvent(LLPointer<LLOldEvents::LLEvent> event, const LLSD& userdata)
+{
+	return mParent.onRemoveItemEvent(event, userdata);
+}
+
+//
+// LLParticipantList::SpeakerClearListener
+//
+bool LLParticipantList::SpeakerClearListener::handleEvent(LLPointer<LLOldEvents::LLEvent> event, const LLSD& userdata)
+{
+	return mParent.onClearListEvent(event, userdata);
+}
diff --git a/indra/newview/llparticipantlist.h b/indra/newview/llparticipantlist.h
index 68aae0aee5..04d9e29256 100644
--- a/indra/newview/llparticipantlist.h
+++ b/indra/newview/llparticipantlist.h
@@ -38,46 +38,74 @@ class LLAvatarList;
 
 class LLParticipantList
 {
+	LOG_CLASS(LLParticipantList);
 	public:
 		LLParticipantList(LLSpeakerMgr* data_source, LLAvatarList* avatar_list);
 		~LLParticipantList();
 
+		typedef enum e_participant_sort_oder {
+			E_SORT_BY_NAME = 0,
+		} EParticipantSortOrder;
+
+		/**
+		  * Set and sort Avatarlist by given order
+		  */
+		void setSortOrder(EParticipantSortOrder order = E_SORT_BY_NAME);
+
 	protected:
+		/**
+		 * LLSpeakerMgr event handlers
+		 */
+		bool onAddItemEvent(LLPointer<LLOldEvents::LLEvent> event, const LLSD& userdata);
+		bool onRemoveItemEvent(LLPointer<LLOldEvents::LLEvent> event, const LLSD& userdata);
+		bool onClearListEvent(LLPointer<LLOldEvents::LLEvent> event, const LLSD& userdata);
+
+		/**
+		 * Sorts the Avatarlist by stored order
+		 */
+		void sort();
 
 		//List of listeners implementing LLOldEvents::LLSimpleListener.
 		//There is no way to handle all the events in one listener as LLSpeakerMgr registers listeners in such a way
 		//that one listener can handle only one type of event
-		class SpeakerAddListener : public LLOldEvents::LLSimpleListener
+		class BaseSpeakerListner : public LLOldEvents::LLSimpleListener
 		{
 		public:
-			SpeakerAddListener(LLAvatarList* avatar_list) : mAvatarList(avatar_list) {}
+			BaseSpeakerListner(LLParticipantList& parent) : mParent(parent) {}
+		protected:
+			LLParticipantList& mParent;
+		};
 
+		class SpeakerAddListener : public BaseSpeakerListner
+		{
+		public:
+			SpeakerAddListener(LLParticipantList& parent) : BaseSpeakerListner(parent) {}
 			/*virtual*/ bool handleEvent(LLPointer<LLOldEvents::LLEvent> event, const LLSD& userdata);
-			LLAvatarList* mAvatarList;
 		};
 
-		class SpeakerRemoveListener : public LLOldEvents::LLSimpleListener
+		class SpeakerRemoveListener : public BaseSpeakerListner
 		{
 		public:
-			SpeakerRemoveListener(LLAvatarList* avatar_list) : mAvatarList(avatar_list) {}
-
+			SpeakerRemoveListener(LLParticipantList& parent) : BaseSpeakerListner(parent) {}
 			/*virtual*/ bool handleEvent(LLPointer<LLOldEvents::LLEvent> event, const LLSD& userdata);
-			LLAvatarList* mAvatarList;
 		};
 
-		class SpeakerClearListener : public LLOldEvents::LLSimpleListener
+		class SpeakerClearListener : public BaseSpeakerListner
 		{
 		public:
-			SpeakerClearListener(LLAvatarList* avatar_list) : mAvatarList(avatar_list) {}
-
+			SpeakerClearListener(LLParticipantList& parent) : BaseSpeakerListner(parent) {}
 			/*virtual*/ bool handleEvent(LLPointer<LLOldEvents::LLEvent> event, const LLSD& userdata);
-			LLAvatarList* mAvatarList;
 		};
+
 	private:
+		void onAvatarListDoubleClicked(LLAvatarList* list);
+
 		LLSpeakerMgr*		mSpeakerMgr;
-		LLAvatarList* 		mAvatarList;
+		LLAvatarList*		mAvatarList;
+
+		SpeakerAddListener		mSpeakerAddListener;
+		SpeakerRemoveListener	mSpeakerRemoveListener;
+		SpeakerClearListener	mSpeakerClearListener;
 
-		SpeakerAddListener* mSpeakerAddListener;
-		SpeakerRemoveListener* mSpeakerRemoveListener;
-		SpeakerClearListener* mSpeakerClearListener;
+		EParticipantSortOrder	mSortOrder;
 };
diff --git a/indra/newview/llpreview.cpp b/indra/newview/llpreview.cpp
index b06e70c00a..34e78b5c46 100644
--- a/indra/newview/llpreview.cpp
+++ b/indra/newview/llpreview.cpp
@@ -45,6 +45,7 @@
 #include "lltooldraganddrop.h"
 #include "llradiogroup.h"
 #include "llassetstorage.h"
+#include "llviewerassettype.h"
 #include "llviewerobject.h"
 #include "llviewerobjectlist.h"
 #include "lldbstrings.h"
@@ -317,7 +318,7 @@ BOOL LLPreview::handleHover(S32 x, S32 y, MASK mask)
 		   && LLToolDragAndDrop::getInstance()->isOverThreshold(screen_x, screen_y))
 		{
 			EDragAndDropType type;
-			type = LLAssetType::lookupDragAndDropType(item->getType());
+			type = LLViewerAssetType::lookupDragAndDropType(item->getType());
 			LLToolDragAndDrop::ESource src = LLToolDragAndDrop::SOURCE_LIBRARY;
 			if(!mObjectUUID.isNull())
 			{
@@ -406,7 +407,7 @@ void LLPreview::onDiscardBtn(void* data)
 	*/
 
 	// Move the item to the trash
-	LLUUID trash_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_TRASH);
+	const LLUUID trash_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_TRASH);
 	if (item->getParentUUID() != trash_id)
 	{
 		LLInventoryModel::update_list_t update;
diff --git a/indra/newview/llpreviewgesture.cpp b/indra/newview/llpreviewgesture.cpp
index ab2afb8056..7b3a20d102 100644
--- a/indra/newview/llpreviewgesture.cpp
+++ b/indra/newview/llpreviewgesture.cpp
@@ -130,10 +130,10 @@ LLPreviewGesture* LLPreviewGesture::show(const LLUUID& item_id, const LLUUID& ob
 	preview->setObjectID(object_id);
 	
 	// Start speculative download of sounds and animations
-	LLUUID animation_folder_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_ANIMATION);
+	const LLUUID animation_folder_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_ANIMATION);
 	gInventory.startBackgroundFetch(animation_folder_id);
 
-	LLUUID sound_folder_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_SOUND);
+	const LLUUID sound_folder_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_SOUND);
 	gInventory.startBackgroundFetch(sound_folder_id);
 
 	// this will call refresh when we have everything.
diff --git a/indra/newview/llresourcedata.h b/indra/newview/llresourcedata.h
index 46b79150bb..b4b9042689 100644
--- a/indra/newview/llresourcedata.h
+++ b/indra/newview/llresourcedata.h
@@ -39,11 +39,12 @@
 struct LLResourceData
 {
 	LLAssetInfo mAssetInfo;
-	LLAssetType::EType mPreferredLocation;
+	LLFolderType::EType mPreferredLocation;
 	LLInventoryType::EType mInventoryType;
 	U32 mNextOwnerPerm;
 	S32 mExpectedUploadCost;
 	void *mUserData;
+	static const S8 INVALID_LOCATION = -2;
 };
 
 #endif
diff --git a/indra/newview/llselectmgr.cpp b/indra/newview/llselectmgr.cpp
index b8ceef0899..26e668adb5 100644
--- a/indra/newview/llselectmgr.cpp
+++ b/indra/newview/llselectmgr.cpp
@@ -2827,7 +2827,7 @@ bool LLSelectMgr::confirmDelete(const LLSD& notification, const LLSD& response,
 	case 0:
 		{
 			// TODO: Make sure you have delete permissions on all of them.
-			LLUUID trash_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_TRASH);
+			const LLUUID trash_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_TRASH);
 			// attempt to derez into the trash.
 			LLDeRezInfo* info = new LLDeRezInfo(DRD_TRASH, trash_id);
 			LLSelectMgr::getInstance()->sendListToRegions("DeRezObject",
diff --git a/indra/newview/llstartup.cpp b/indra/newview/llstartup.cpp
index 9bdea57491..b23e7feda2 100644
--- a/indra/newview/llstartup.cpp
+++ b/indra/newview/llstartup.cpp
@@ -334,7 +334,7 @@ void populate_favorites_bar()
 	S32 count = lib_cats->count();
 	for(S32 i = 0; i < count; ++i)
 	{
-		if(lib_cats->get(i)->getPreferredType() == LLAssetType::AT_LANDMARK)
+		if(lib_cats->get(i)->getPreferredType() == LLFolderType::FT_LANDMARK)
 		{
 			lib_landmarks = lib_cats->get(i)->getUUID();
 			break;
@@ -351,7 +351,7 @@ void populate_favorites_bar()
 	gInventory.getDirectDescendentsOf(lib_landmarks, lm_cats, lm_items);
 	if (!lm_items) return;
 
-	LLUUID favorites_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_FAVORITE);
+	const LLUUID favorites_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_FAVORITE);
 	if (favorites_id.isNull())
 	{
 		llerror("My Inventory is missing My Favorites", 0);
@@ -1673,7 +1673,7 @@ bool idle_startup()
 		gInventory.buildParentChildMap();
 
 		//all categories loaded. lets create "My Favorites" category
-		gInventory.findCategoryUUIDForType(LLAssetType::AT_FAVORITE,true);
+		gInventory.findCategoryUUIDForType(LLFolderType::FT_FAVORITE,true);
 
 		// lets create "Friends" and "Friends/All" in the Inventory "Calling Cards" and fill it with buddies
 		LLFriendCardsManager::instance().syncFriendsFolder();
diff --git a/indra/newview/lltexturectrl.cpp b/indra/newview/lltexturectrl.cpp
index efe8804742..de00ca8420 100644
--- a/indra/newview/lltexturectrl.cpp
+++ b/indra/newview/lltexturectrl.cpp
@@ -426,7 +426,7 @@ BOOL LLFloaterTexturePicker::postBuild()
 		mInventoryPanel->getRootFolder()->getFilter()->markDefault();
 
 		// Commented out to stop opening all folders with textures
-		// mInventoryPanel->openDefaultFolderForType(LLAssetType::AT_TEXTURE);
+		// mInventoryPanel->openDefaultFolderForType(LLFolderType::FT_TEXTURE);
 
 		// don't put keyboard focus on selected item, because the selection callback
 		// will assume that this was user input
@@ -1073,7 +1073,7 @@ BOOL LLTextureCtrl::handleMouseDown(S32 x, S32 y, MASK mask)
 	{
 		showPicker(FALSE);
 		//grab textures first...
-		gInventory.startBackgroundFetch(gInventory.findCategoryUUIDForType(LLAssetType::AT_TEXTURE));
+		gInventory.startBackgroundFetch(gInventory.findCategoryUUIDForType(LLFolderType::FT_TEXTURE));
 		//...then start full inventory fetch.
 		gInventory.startBackgroundFetch();
 		handled = TRUE;
diff --git a/indra/newview/lltoastgroupnotifypanel.cpp b/indra/newview/lltoastgroupnotifypanel.cpp
index e78737fe0d..f82573f46c 100644
--- a/indra/newview/lltoastgroupnotifypanel.cpp
+++ b/indra/newview/lltoastgroupnotifypanel.cpp
@@ -220,7 +220,6 @@ bool LLToastGroupNotifyPanel::isAttachmentOpenable(LLAssetType::EType type)
 	switch(type)
 	{
 	case LLAssetType::AT_LANDMARK:
-	case LLAssetType::AT_FAVORITE:
 	case LLAssetType::AT_NOTECARD:
 	case LLAssetType::AT_IMAGE_JPEG:
 	case LLAssetType::AT_IMAGE_TGA:
diff --git a/indra/newview/lltooldraganddrop.cpp b/indra/newview/lltooldraganddrop.cpp
index 9a63f07a7e..959cb3f182 100644
--- a/indra/newview/lltooldraganddrop.cpp
+++ b/indra/newview/lltooldraganddrop.cpp
@@ -92,7 +92,7 @@ public:
 	virtual bool operator()(LLInventoryCategory* cat,
 							LLInventoryItem* item)
 	{
-		if(cat && (cat->getPreferredType() == LLAssetType::AT_NONE))
+		if(cat && (cat->getPreferredType() == LLFolderType::FT_NONE))
 		{
 			return true;
 		}
@@ -109,7 +109,7 @@ public:
 							LLInventoryItem* item)
 	{
 		if(item) return true;
-		if(cat && (cat->getPreferredType() == LLAssetType::AT_NONE))
+		if(cat && (cat->getPreferredType() == LLFolderType::FT_NONE))
 		{
 			return true;
 		}
@@ -1317,8 +1317,7 @@ void LLToolDragAndDrop::dropObject(LLViewerObject* raycast_target,
 
 	// Check if it's in the trash.
 	bool is_in_trash = false;
-	LLUUID trash_id;
-	trash_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_TRASH);
+	const LLUUID trash_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_TRASH);
 	if(gInventory.isObjectDescendentOf(item->getUUID(), trash_id))
 	{
 		is_in_trash = true;
@@ -2088,7 +2087,7 @@ EAcceptance LLToolDragAndDrop::dad3dRezAttachmentFromInv(
 	if(!item || !item->isComplete()) return ACCEPT_NO;
 
 	// must not be in the trash
-	LLUUID trash_id(gInventory.findCategoryUUIDForType(LLAssetType::AT_TRASH));
+	const LLUUID trash_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_TRASH);
 	if( gInventory.isObjectDescendentOf( item->getUUID(), trash_id ) )
 	{
 		return ACCEPT_NO;
@@ -2170,8 +2169,7 @@ EAcceptance LLToolDragAndDrop::dad3dRezObjectOnLand(
 	}
 
 	// Check if it's in the trash.
-	LLUUID trash_id;
-	trash_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_TRASH);
+	const LLUUID trash_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_TRASH);
 	if(gInventory.isObjectDescendentOf(item->getUUID(), trash_id))
 	{
 		accept = ACCEPT_YES_SINGLE;
@@ -2249,8 +2247,7 @@ EAcceptance LLToolDragAndDrop::dad3dRezObjectOnObject(
 	}
 
 	// Check if it's in the trash.
-	LLUUID trash_id;
-	trash_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_TRASH);
+	const LLUUID trash_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_TRASH);
 	if(gInventory.isObjectDescendentOf(item->getUUID(), trash_id))
 	{
 		accept = ACCEPT_YES_SINGLE;
@@ -2388,7 +2385,7 @@ EAcceptance LLToolDragAndDrop::dad3dWearItem(
 	if(mSource == SOURCE_AGENT || mSource == SOURCE_LIBRARY)
 	{
 		// it's in the agent inventory
-		LLUUID trash_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_TRASH);
+		const LLUUID trash_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_TRASH);
 		if( gInventory.isObjectDescendentOf( item->getUUID(), trash_id ) )
 		{
 			return ACCEPT_NO;
@@ -2443,7 +2440,7 @@ EAcceptance LLToolDragAndDrop::dad3dActivateGesture(
 	if(mSource == SOURCE_AGENT || mSource == SOURCE_LIBRARY)
 	{
 		// it's in the agent inventory
-		LLUUID trash_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_TRASH);
+		const LLUUID trash_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_TRASH);
 		if( gInventory.isObjectDescendentOf( item->getUUID(), trash_id ) )
 		{
 			return ACCEPT_NO;
@@ -2502,7 +2499,7 @@ EAcceptance LLToolDragAndDrop::dad3dWearCategory(
 
 	if(mSource == SOURCE_AGENT)
 	{
-		LLUUID trash_id(gInventory.findCategoryUUIDForType(LLAssetType::AT_TRASH));
+		const LLUUID trash_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_TRASH);
 		if( gInventory.isObjectDescendentOf( category->getUUID(), trash_id ) )
 		{
 			return ACCEPT_NO;
diff --git a/indra/newview/llviewerassettype.cpp b/indra/newview/llviewerassettype.cpp
new file mode 100644
index 0000000000..c974171c2c
--- /dev/null
+++ b/indra/newview/llviewerassettype.cpp
@@ -0,0 +1,114 @@
+/** 
+ * @file llassettype.cpp
+ * @brief Implementatino of LLViewerAssetType functionality.
+ *
+ * $LicenseInfo:firstyear=2001&license=viewergpl$
+ * 
+ * Copyright (c) 2001-2009, Linden Research, Inc.
+ * 
+ * Second Life Viewer Source Code
+ * The source code in this file ("Source Code") is provided by Linden Lab
+ * to you under the terms of the GNU General Public License, version 2.0
+ * ("GPL"), unless you have obtained a separate licensing agreement
+ * ("Other License"), formally executed by you and Linden Lab.  Terms of
+ * the GPL can be found in doc/GPL-license.txt in this distribution, or
+ * online at http://secondlifegrid.net/programs/open_source/licensing/gplv2
+ * 
+ * There are special exceptions to the terms and conditions of the GPL as
+ * it is applied to this Source Code. View the full text of the exception
+ * in the file doc/FLOSS-exception.txt in this software distribution, or
+ * online at
+ * http://secondlifegrid.net/programs/open_source/licensing/flossexception
+ * 
+ * By copying, modifying or distributing this software, you acknowledge
+ * that you have read and understood your obligations described above,
+ * and agree to abide by those obligations.
+ * 
+ * ALL LINDEN LAB SOURCE CODE IS PROVIDED "AS IS." LINDEN LAB MAKES NO
+ * WARRANTIES, EXPRESS, IMPLIED OR OTHERWISE, REGARDING ITS ACCURACY,
+ * COMPLETENESS OR PERFORMANCE.
+ * $/LicenseInfo$
+ */
+
+#include "llviewerprecompiledheaders.h"
+
+#include "llviewerassettype.h"
+#include "lldictionary.h"
+#include "llmemory.h"
+#include "llsingleton.h"
+
+static const std::string empty_string;
+
+struct ViewerAssetEntry : public LLDictionaryEntry
+{
+	ViewerAssetEntry(EDragAndDropType dad_type // drag and drop type
+		)
+		:
+		LLDictionaryEntry(empty_string), // no reverse lookup needed for now, so just leave this blank
+		mDadType(dad_type)
+	{
+	}
+	EDragAndDropType mDadType;
+};
+
+class LLViewerAssetDictionary : public LLSingleton<LLViewerAssetDictionary>,
+						  public LLDictionary<LLViewerAssetType::EType, ViewerAssetEntry>
+{
+public:
+	LLViewerAssetDictionary();
+};
+
+LLViewerAssetDictionary::LLViewerAssetDictionary()
+{
+	//       												      	   	   	 DRAG&DROP TYPE		    
+	//   	   	   	   	   	   	   	   	   	   	   	   	   	   	   	   	   	|--------------------|
+	addEntry(LLViewerAssetType::AT_TEXTURE, 			new ViewerAssetEntry(DAD_TEXTURE));
+	addEntry(LLViewerAssetType::AT_SOUND, 				new ViewerAssetEntry(DAD_SOUND));
+	addEntry(LLViewerAssetType::AT_CALLINGCARD, 		new ViewerAssetEntry(DAD_CALLINGCARD));
+	addEntry(LLViewerAssetType::AT_LANDMARK, 			new ViewerAssetEntry(DAD_LANDMARK));
+	addEntry(LLViewerAssetType::AT_SCRIPT, 				new ViewerAssetEntry(DAD_NONE));
+	addEntry(LLViewerAssetType::AT_CLOTHING, 			new ViewerAssetEntry(DAD_CLOTHING));
+	addEntry(LLViewerAssetType::AT_OBJECT, 				new ViewerAssetEntry(DAD_OBJECT));
+	addEntry(LLViewerAssetType::AT_NOTECARD, 			new ViewerAssetEntry(DAD_NOTECARD));
+	addEntry(LLViewerAssetType::AT_CATEGORY, 			new ViewerAssetEntry(DAD_CATEGORY));
+	addEntry(LLViewerAssetType::AT_ROOT_CATEGORY, 		new ViewerAssetEntry(DAD_ROOT_CATEGORY));
+	addEntry(LLViewerAssetType::AT_LSL_TEXT, 			new ViewerAssetEntry(DAD_SCRIPT));
+	addEntry(LLViewerAssetType::AT_LSL_BYTECODE, 		new ViewerAssetEntry(DAD_NONE));
+	addEntry(LLViewerAssetType::AT_TEXTURE_TGA, 		new ViewerAssetEntry(DAD_NONE));
+	addEntry(LLViewerAssetType::AT_BODYPART, 			new ViewerAssetEntry(DAD_BODYPART));
+	addEntry(LLViewerAssetType::AT_SOUND_WAV, 			new ViewerAssetEntry(DAD_NONE));
+	addEntry(LLViewerAssetType::AT_IMAGE_TGA, 			new ViewerAssetEntry(DAD_NONE));
+	addEntry(LLViewerAssetType::AT_IMAGE_JPEG, 			new ViewerAssetEntry(DAD_NONE));
+	addEntry(LLViewerAssetType::AT_ANIMATION, 			new ViewerAssetEntry(DAD_ANIMATION));
+	addEntry(LLViewerAssetType::AT_GESTURE, 			new ViewerAssetEntry(DAD_GESTURE));
+	addEntry(LLViewerAssetType::AT_SIMSTATE, 			new ViewerAssetEntry(DAD_NONE));
+
+	addEntry(LLViewerAssetType::AT_LINK, 				new ViewerAssetEntry(DAD_LINK));
+	addEntry(LLViewerAssetType::AT_LINK_FOLDER, 		new ViewerAssetEntry(DAD_LINK));
+
+	addEntry(LLViewerAssetType::AT_NONE, 				new ViewerAssetEntry(DAD_NONE));
+};
+
+EDragAndDropType LLViewerAssetType::lookupDragAndDropType(EType asset_type)
+{
+	const LLViewerAssetDictionary *dict = LLViewerAssetDictionary::getInstance();
+	const ViewerAssetEntry *entry = dict->lookup(asset_type);
+	if (entry)
+		return entry->mDadType;
+	else
+		return DAD_NONE;
+}
+
+// Generate a good default description
+void LLViewerAssetType::generateDescriptionFor(LLViewerAssetType::EType asset_type,
+											   std::string& description)
+{
+	const S32 BUF_SIZE = 30;
+	char time_str[BUF_SIZE];	/* Flawfinder: ignore */
+	time_t now;
+	time(&now);
+	memset(time_str, '\0', BUF_SIZE);
+	strftime(time_str, BUF_SIZE - 1, "%Y-%m-%d %H:%M:%S ", localtime(&now));
+	description.assign(time_str);
+	description.append(LLAssetType::lookupHumanReadable(asset_type));
+}
diff --git a/indra/newview/llviewerassettype.h b/indra/newview/llviewerassettype.h
new file mode 100644
index 0000000000..01158885ce
--- /dev/null
+++ b/indra/newview/llviewerassettype.h
@@ -0,0 +1,54 @@
+/** 
+ * @file llviewerassettype.h
+ * @brief Declaration of LLViewerViewerAssetType.
+ *
+ * $LicenseInfo:firstyear=2001&license=viewergpl$
+ * 
+ * Copyright (c) 2001-2009, Linden Research, Inc.
+ * 
+ * Second Life Viewer Source Code
+ * The source code in this file ("Source Code") is provided by Linden Lab
+ * to you under the terms of the GNU General Public License, version 2.0
+ * ("GPL"), unless you have obtained a separate licensing agreement
+ * ("Other License"), formally executed by you and Linden Lab.  Terms of
+ * the GPL can be found in doc/GPL-license.txt in this distribution, or
+ * online at http://secondlifegrid.net/programs/open_source/licensing/gplv2
+ * 
+ * There are special exceptions to the terms and conditions of the GPL as
+ * it is applied to this Source Code. View the full text of the exception
+ * in the file doc/FLOSS-exception.txt in this software distribution, or
+ * online at
+ * http://secondlifegrid.net/programs/open_source/licensing/flossexception
+ * 
+ * By copying, modifying or distributing this software, you acknowledge
+ * that you have read and understood your obligations described above,
+ * and agree to abide by those obligations.
+ * 
+ * ALL LINDEN LAB SOURCE CODE IS PROVIDED "AS IS." LINDEN LAB MAKES NO
+ * WARRANTIES, EXPRESS, IMPLIED OR OTHERWISE, REGARDING ITS ACCURACY,
+ * COMPLETENESS OR PERFORMANCE.
+ * $/LicenseInfo$
+ */
+
+#ifndef LL_LLVIEWERASSETTYPE_H
+#define LL_LLVIEWERASSETTYPE_H
+
+#include <string>
+#include "llassettype.h"
+
+// This class is similar to llassettype, but contains methods
+// only used by the viewer.
+class LLViewerAssetType : public LLAssetType
+{
+public:
+	// Generate a good default description. You may want to add a verb
+	// or agent name after this depending on your application.
+	static void 				generateDescriptionFor(LLViewerAssetType::EType asset_type,
+													   std::string& description);
+	static EDragAndDropType   	lookupDragAndDropType(EType asset_type);
+protected:
+	LLViewerAssetType() {}
+	~LLViewerAssetType() {}
+};
+
+#endif // LL_LLVIEWERASSETTYPE_H
diff --git a/indra/newview/llviewerfoldertype.cpp b/indra/newview/llviewerfoldertype.cpp
new file mode 100644
index 0000000000..384538364f
--- /dev/null
+++ b/indra/newview/llviewerfoldertype.cpp
@@ -0,0 +1,263 @@
+/** 
+ * @file llfoldertype.cpp
+ * @brief Implementation of LLViewerFolderType functionality.
+ *
+ * $LicenseInfo:firstyear=2001&license=viewergpl$
+ * 
+ * Copyright (c) 2001-2009, Linden Research, Inc.
+ * 
+ * Second Life Viewer Source Code
+ * The source code in this file ("Source Code") is provided by Linden Lab
+ * to you under the terms of the GNU General Public License, version 2.0
+ * ("GPL"), unless you have obtained a separate licensing agreement
+ * ("Other License"), formally executed by you and Linden Lab.  Terms of
+ * the GPL can be found in doc/GPL-license.txt in this distribution, or
+ * online at http://secondlifegrid.net/programs/open_source/licensing/gplv2
+ * 
+ * There are special exceptions to the terms and conditions of the GPL as
+ * it is applied to this Source Code. View the full text of the exception
+ * in the file doc/FLOSS-exception.txt in this software distribution, or
+ * online at
+ * http://secondlifegrid.net/programs/open_source/licensing/flossexception
+ * 
+ * By copying, modifying or distributing this software, you acknowledge
+ * that you have read and understood your obligations described above,
+ * and agree to abide by those obligations.
+ * 
+ * ALL LINDEN LAB SOURCE CODE IS PROVIDED "AS IS." LINDEN LAB MAKES NO
+ * WARRANTIES, EXPRESS, IMPLIED OR OTHERWISE, REGARDING ITS ACCURACY,
+ * COMPLETENESS OR PERFORMANCE.
+ * $/LicenseInfo$
+ */
+
+#include "llviewerprecompiledheaders.h"
+
+#include "llviewerfoldertype.h"
+#include "lldictionary.h"
+#include "llmemory.h"
+#include "llvisualparam.h"
+
+static const std::string empty_string;
+
+struct ViewerFolderEntry : public LLDictionaryEntry
+{
+	// Constructor for non-ensembles
+	ViewerFolderEntry(const std::string &new_category_name, // default name when creating a new category of this type
+					  const std::string &icon_name 			// name of the folder icon
+		) 
+		:
+		LLDictionaryEntry(empty_string), // no reverse lookup needed on non-ensembles, so just leave this blank
+		mIconName(icon_name),
+		mNewCategoryName(new_category_name)
+	{
+		mAllowedNames.clear();
+	}
+
+	// Constructor for ensembles
+	ViewerFolderEntry(const std::string &xui_name, 			// name of the xui menu item
+					  const std::string &new_category_name, // default name when creating a new category of this type
+					  const std::string &icon_name, 		// name of the folder icon
+					  const std::string allowed_names 		// allowed item typenames for this folder type
+		) 
+		:
+		LLDictionaryEntry(xui_name),
+		mIconName(icon_name),
+		mNewCategoryName(new_category_name)
+	{
+		const std::string delims (",");
+		LLStringUtilBase<char>::getTokens(allowed_names, mAllowedNames, delims);
+	}
+
+	bool getIsAllowedName(const std::string &name) const
+	{
+		if (mAllowedNames.empty())
+			return false;
+		for (name_vec_t::const_iterator iter = mAllowedNames.begin();
+			 iter != mAllowedNames.end();
+			 iter++)
+		{
+			if (name == (*iter))
+				return true;
+		}
+		return false;
+	}
+	const std::string mIconName;
+	const std::string mNewCategoryName;
+	typedef std::vector<std::string> name_vec_t;
+	name_vec_t mAllowedNames;
+};
+
+class LLViewerFolderDictionary : public LLSingleton<LLViewerFolderDictionary>,
+								 public LLDictionary<LLFolderType::EType, ViewerFolderEntry>
+{
+public:
+	LLViewerFolderDictionary();
+protected:
+	bool initEnsemblesFromFile(); // Reads in ensemble information from foldertypes.xml
+};
+
+LLViewerFolderDictionary::LLViewerFolderDictionary()
+{
+	initEnsemblesFromFile();
+
+	//       													    	  NEW CATEGORY NAME         FOLDER ICON NAME
+	//      												  		     |-------------------------|---------------------------|
+	addEntry(LLFolderType::FT_TEXTURE, 				new ViewerFolderEntry("Textures",				"inv_folder_texture.tga"));
+	addEntry(LLFolderType::FT_SOUND, 				new ViewerFolderEntry("Sounds",					"inv_folder_sound.tga"));
+	addEntry(LLFolderType::FT_CALLINGCARD, 			new ViewerFolderEntry("Calling Cards",			"inv_folder_callingcard.tga"));
+	addEntry(LLFolderType::FT_LANDMARK, 			new ViewerFolderEntry("Landmarks",				"inv_folder_landmark.tga"));
+	addEntry(LLFolderType::FT_CLOTHING, 			new ViewerFolderEntry("Clothing",				"inv_folder_clothing.tga"));
+	addEntry(LLFolderType::FT_OBJECT, 				new ViewerFolderEntry("Objects",				"inv_folder_object.tga"));
+	addEntry(LLFolderType::FT_NOTECARD, 			new ViewerFolderEntry("Notecards",				"inv_folder_notecard.tga"));
+	addEntry(LLFolderType::FT_CATEGORY, 			new ViewerFolderEntry("New Folder",				"inv_folder_plain_closed.tga"));
+	addEntry(LLFolderType::FT_ROOT_CATEGORY, 		new ViewerFolderEntry("Inventory",				""));
+	addEntry(LLFolderType::FT_LSL_TEXT, 			new ViewerFolderEntry("Scripts",				"inv_folder_script.tga"));
+	addEntry(LLFolderType::FT_BODYPART, 			new ViewerFolderEntry("Body Parts",				"inv_folder_bodypart.tga"));
+	addEntry(LLFolderType::FT_TRASH, 				new ViewerFolderEntry("Trash",					"inv_folder_trash.tga"));
+	addEntry(LLFolderType::FT_SNAPSHOT_CATEGORY, 	new ViewerFolderEntry("Photo Album",			"inv_folder_snapshot.tga"));
+	addEntry(LLFolderType::FT_LOST_AND_FOUND, 		new ViewerFolderEntry("Lost And Found",	   		"inv_folder_lostandfound.tga"));
+	addEntry(LLFolderType::FT_ANIMATION, 			new ViewerFolderEntry("Animations",				"inv_folder_animation.tga"));
+	addEntry(LLFolderType::FT_GESTURE, 				new ViewerFolderEntry("Gestures",				"inv_folder_gesture.tga"));
+	addEntry(LLFolderType::FT_FAVORITE, 			new ViewerFolderEntry("Favorite",				"inv_folder_plain_closed.tga"));
+
+	addEntry(LLFolderType::FT_CURRENT_OUTFIT, 		new ViewerFolderEntry("Current Outfit",			"inv_folder_current_outfit.tga"));
+	addEntry(LLFolderType::FT_OUTFIT, 				new ViewerFolderEntry("New Outfit",				"inv_folder_outfit.tga"));
+	addEntry(LLFolderType::FT_MY_OUTFITS, 			new ViewerFolderEntry("My Outfits",				"inv_folder_my_outfits.tga"));
+	addEntry(LLFolderType::FT_INBOX, 				new ViewerFolderEntry("Inbox",					"inv_folder_inbox.tga"));
+		 
+	addEntry(LLFolderType::FT_NONE, 				new ViewerFolderEntry("New Folder",				"inv_folder_plain_closed.tga"));
+}
+
+bool LLViewerFolderDictionary::initEnsemblesFromFile()
+{
+	std::string xml_filename = gDirUtilp->getExpandedFilename(LL_PATH_APP_SETTINGS,"foldertypes.xml");
+	LLXmlTree folder_def;
+	if (!folder_def.parseFile(xml_filename))
+	{
+		llerrs << "Failed to parse folders file " << xml_filename << llendl;
+		return false;
+	}
+
+	LLXmlTreeNode* rootp = folder_def.getRoot();
+	for (LLXmlTreeNode* ensemble = rootp->getFirstChild();
+		 ensemble;
+		 ensemble = rootp->getNextChild())
+	{
+		if (!ensemble->hasName("ensemble"))
+		{
+			llwarns << "Invalid ensemble definition node " << ensemble->getName() << llendl;
+			continue;
+		}
+
+		S32 ensemble_type;
+		static LLStdStringHandle ensemble_num_string = LLXmlTree::addAttributeString("foldertype_num");
+		if (!ensemble->getFastAttributeS32(ensemble_num_string, ensemble_type))
+		{
+			llwarns << "No ensemble type defined" << llendl;
+			continue;
+		}
+
+
+		if (ensemble_type < S32(LLFolderType::FT_ENSEMBLE_START) || ensemble_type > S32(LLFolderType::FT_ENSEMBLE_END))
+		{
+			llwarns << "Exceeded maximum ensemble index" << LLFolderType::FT_ENSEMBLE_END << llendl;
+			break;
+		}
+
+		std::string xui_name;
+		static LLStdStringHandle xui_name_string = LLXmlTree::addAttributeString("xui_name");
+		if (!ensemble->getFastAttributeString(xui_name_string, xui_name))
+		{
+			llwarns << "No xui name defined" << llendl;
+			continue;
+		}
+
+		std::string icon_name;
+		static LLStdStringHandle icon_name_string = LLXmlTree::addAttributeString("icon_name");
+		if (!ensemble->getFastAttributeString(icon_name_string, icon_name))
+		{
+			llwarns << "No ensemble icon name defined" << llendl;
+			continue;
+		}
+
+		std::string allowed_names;
+		static LLStdStringHandle allowed_names_string = LLXmlTree::addAttributeString("allowed");
+		if (!ensemble->getFastAttributeString(allowed_names_string, allowed_names))
+		{
+		}
+
+		// Add the entry and increment the asset number.
+		const static std::string new_ensemble_name = "New Ensemble";
+		addEntry(LLFolderType::EType(ensemble_type), new ViewerFolderEntry(xui_name, new_ensemble_name, icon_name, allowed_names));
+	}
+
+	return true;
+}
+
+
+const std::string &LLViewerFolderType::lookupXUIName(LLFolderType::EType folder_type)
+{
+	const ViewerFolderEntry *entry = LLViewerFolderDictionary::getInstance()->lookup(folder_type);
+	if (entry)
+	{
+		return entry->mName;
+	}
+	return badLookup();
+}
+
+LLFolderType::EType LLViewerFolderType::lookupTypeFromXUIName(const std::string &name)
+{
+	return LLViewerFolderDictionary::getInstance()->lookup(name);
+}
+
+const std::string &LLViewerFolderType::lookupIconName(LLFolderType::EType folder_type)
+{
+	const ViewerFolderEntry *entry = LLViewerFolderDictionary::getInstance()->lookup(folder_type);
+	if (entry)
+	{
+		return entry->mIconName;
+	}
+	return badLookup();
+}
+
+const std::string &LLViewerFolderType::lookupNewCategoryName(LLFolderType::EType folder_type)
+{
+	const ViewerFolderEntry *entry = LLViewerFolderDictionary::getInstance()->lookup(folder_type);
+	if (entry)
+	{
+		return entry->mNewCategoryName;
+	}
+	return badLookup();
+}
+
+LLFolderType::EType LLViewerFolderType::lookupTypeFromNewCategoryName(const std::string& name)
+{
+	for (LLViewerFolderDictionary::const_iterator iter = LLViewerFolderDictionary::getInstance()->begin();
+		 iter != LLViewerFolderDictionary::getInstance()->end();
+		 iter++)
+	{
+		const ViewerFolderEntry *entry = iter->second;
+		if (entry->mNewCategoryName == name)
+		{
+			return iter->first;
+		}
+	}
+	return FT_NONE;
+}
+
+
+U64 LLViewerFolderType::lookupValidFolderTypes(const std::string& item_name)
+{
+	U64 matching_folders = 0;
+	for (LLViewerFolderDictionary::const_iterator iter = LLViewerFolderDictionary::getInstance()->begin();
+		 iter != LLViewerFolderDictionary::getInstance()->end();
+		 iter++)
+	{
+		const ViewerFolderEntry *entry = iter->second;
+		if (entry->getIsAllowedName(item_name))
+		{
+			matching_folders |= 1LL << iter->first;
+		}
+	}
+	return matching_folders;
+}
diff --git a/indra/newview/llviewerfoldertype.h b/indra/newview/llviewerfoldertype.h
new file mode 100644
index 0000000000..a6aea62b2a
--- /dev/null
+++ b/indra/newview/llviewerfoldertype.h
@@ -0,0 +1,57 @@
+/** 
+ * @file llviewerfoldertype.h
+ * @brief Declaration of LLAssetType.
+ *
+ * $LicenseInfo:firstyear=2001&license=viewergpl$
+ * 
+ * Copyright (c) 2001-2009, Linden Research, Inc.
+ * 
+ * Second Life Viewer Source Code
+ * The source code in this file ("Source Code") is provided by Linden Lab
+ * to you under the terms of the GNU General Public License, version 2.0
+ * ("GPL"), unless you have obtained a separate licensing agreement
+ * ("Other License"), formally executed by you and Linden Lab.  Terms of
+ * the GPL can be found in doc/GPL-license.txt in this distribution, or
+ * online at http://secondlifegrid.net/programs/open_source/licensing/gplv2
+ * 
+ * There are special exceptions to the terms and conditions of the GPL as
+ * it is applied to this Source Code. View the full text of the exception
+ * in the file doc/FLOSS-exception.txt in this software distribution, or
+ * online at
+ * http://secondlifegrid.net/programs/open_source/licensing/flossexception
+ * 
+ * By copying, modifying or distributing this software, you acknowledge
+ * that you have read and understood your obligations described above,
+ * and agree to abide by those obligations.
+ * 
+ * ALL LINDEN LAB SOURCE CODE IS PROVIDED "AS IS." LINDEN LAB MAKES NO
+ * WARRANTIES, EXPRESS, IMPLIED OR OTHERWISE, REGARDING ITS ACCURACY,
+ * COMPLETENESS OR PERFORMANCE.
+ * $/LicenseInfo$
+ */
+
+#ifndef LL_LLVIEWERFOLDERTYPE_H
+#define LL_LLVIEWERFOLDERTYPE_H
+
+#include <string>
+#include "llfoldertype.h"
+
+// This class is similar to llfoldertype, but contains methods
+// only used by the viewer.  This also handles ensembles.
+class LLViewerFolderType : public LLFolderType
+{
+public:
+	static const std::string&   lookupXUIName(EType folder_type); // name used by the UI
+	static LLFolderType::EType 	lookupTypeFromXUIName(const std::string& name);
+
+	static const std::string&   lookupIconName(EType asset_type); // folder icon name
+	static const std::string&	lookupNewCategoryName(EType folder_type); // default name when creating new category
+	static LLFolderType::EType	lookupTypeFromNewCategoryName(const std::string& name); // default name when creating new category
+
+	static U64					lookupValidFolderTypes(const std::string& item_name); // which folders allow an item of this type?
+protected:
+	LLViewerFolderType() {}
+	~LLViewerFolderType() {}
+};
+
+#endif // LL_LLVIEWERFOLDERTYPE_H
diff --git a/indra/newview/llviewerinventory.cpp b/indra/newview/llviewerinventory.cpp
index 470739baa9..1d62ead843 100644
--- a/indra/newview/llviewerinventory.cpp
+++ b/indra/newview/llviewerinventory.cpp
@@ -37,7 +37,7 @@
 #include "indra_constants.h"
 
 #include "llagent.h"
-#include "llfoldertype.h"
+#include "llviewerfoldertype.h"
 #include "llfolderview.h"
 #include "llviewercontrol.h"
 #include "llconsole.h"
@@ -48,6 +48,7 @@
 #include "llinventorybridge.h"
 #include "llfloaterinventory.h"
 
+#include "llviewerassettype.h"
 #include "llviewerregion.h"
 #include "llviewerobjectlist.h"
 #include "llpreviewgesture.h"
@@ -359,7 +360,7 @@ void LLViewerInventoryItem::updateParentOnServer(BOOL restamp) const
 
 LLViewerInventoryCategory::LLViewerInventoryCategory(const LLUUID& uuid,
 													 const LLUUID& parent_uuid,
-													 LLAssetType::EType pref,
+													 LLFolderType::EType pref,
 													 const std::string& name,
 													 const LLUUID& owner_id) :
 	LLInventoryCategory(uuid, parent_uuid, pref, name),
@@ -416,7 +417,7 @@ void LLViewerInventoryCategory::updateServer(BOOL is_new) const
 {
 	// communicate that change with the server.
 
-	if (LLAssetType::lookupIsProtectedCategoryType(mPreferredType))
+	if (LLFolderType::lookupIsProtectedType(mPreferredType))
 	{
 		LLNotifications::instance().add("CannotModifyProtectedCategories");
 		return;
@@ -440,7 +441,7 @@ void LLViewerInventoryCategory::removeFromServer( void )
 	llinfos << "Removing inventory category " << mUUID << " from server."
 			<< llendl;
 	// communicate that change with the server.
-	if(LLAssetType::lookupIsProtectedCategoryType(mPreferredType))
+	if(LLFolderType::lookupIsProtectedType(mPreferredType))
 	{
 		LLNotifications::instance().add("CannotRemoveProtectedCategories");
 		return;
@@ -543,7 +544,7 @@ bool LLViewerInventoryCategory::importFileLocal(LLFILE* fp)
 		}
 		else if(0 == strcmp("pref_type", keyword))
 		{
-			mPreferredType = LLAssetType::lookup(valuestr);
+			mPreferredType = LLFolderType::lookup(valuestr);
 		}
 		else if(0 == strcmp("name", keyword))
 		{
@@ -581,7 +582,7 @@ bool LLViewerInventoryCategory::exportFileLocal(LLFILE* fp) const
 	mParentUUID.toString(uuid_str);
 	fprintf(fp, "\t\tparent_id\t%s\n", uuid_str.c_str());
 	fprintf(fp, "\t\ttype\t%s\n", LLAssetType::lookup(mType));
-	fprintf(fp, "\t\tpref_type\t%s\n", LLAssetType::lookup(mPreferredType));
+	fprintf(fp, "\t\tpref_type\t%s\n", LLFolderType::lookup(mPreferredType).c_str());
 	fprintf(fp, "\t\tname\t%s|\n", mName.c_str());
 	mOwnerID.toString(uuid_str);
 	fprintf(fp, "\t\towner_id\t%s\n", uuid_str.c_str());
@@ -592,8 +593,8 @@ bool LLViewerInventoryCategory::exportFileLocal(LLFILE* fp) const
 
 void LLViewerInventoryCategory::determineFolderType()
 {
-	LLAssetType::EType original_type = getPreferredType();
-	if (LLAssetType::lookupIsProtectedCategoryType(original_type))
+	LLFolderType::EType original_type = getPreferredType();
+	if (LLFolderType::lookupIsProtectedType(original_type))
 		return;
 
 	U64 folder_valid = 0;
@@ -616,28 +617,28 @@ void LLViewerInventoryCategory::determineFolderType()
 			{
 				const EWearableType wearable_type = item->getWearableType();
 				const std::string& wearable_name = LLWearableDictionary::getTypeName(wearable_type);
-				U64 valid_folder_types = LLFolderType::lookupValidFolderTypes(wearable_name);
+				U64 valid_folder_types = LLViewerFolderType::lookupValidFolderTypes(wearable_name);
 				folder_valid |= valid_folder_types;
 				folder_invalid |= ~valid_folder_types;
 			}
 		}
-		for (U8 i = LLAssetType::AT_FOLDER_ENSEMBLE_START; i <= LLAssetType::AT_FOLDER_ENSEMBLE_END; i++)
+		for (U8 i = LLFolderType::FT_ENSEMBLE_START; i <= LLFolderType::FT_ENSEMBLE_END; i++)
 		{
 			if ((folder_valid & (1LL << i)) &&
 				!(folder_invalid & (1LL << i)))
 			{
-				changeType((LLAssetType::EType)i);
+				changeType((LLFolderType::EType)i);
 				return;
 			}
 		}
 	}
-	if (LLAssetType::lookupIsEnsembleCategoryType(original_type))
+	if (LLFolderType::lookupIsEnsembleType(original_type))
 	{
-		changeType(LLAssetType::AT_NONE);
+		changeType(LLFolderType::FT_NONE);
 	}
 }
 
-void LLViewerInventoryCategory::changeType(LLAssetType::EType new_folder_type)
+void LLViewerInventoryCategory::changeType(LLFolderType::EType new_folder_type)
 {
 	const LLUUID &folder_id = getUUID();
 	const LLUUID &parent_id = getParentUUID();
@@ -948,7 +949,7 @@ void copy_inventory_from_notecard(const LLUUID& object_id, const LLUUID& notecar
     body["notecard-id"] = notecard_inv_id;
     body["object-id"] = object_id;
     body["item-id"] = src->getUUID();
-    body["folder-id"] = gInventory.findCategoryUUIDForType(src->getType());
+	body["folder-id"] = gInventory.findCategoryUUIDForType(LLFolderType::assetTypeToFolderType(src->getType()));
     body["callback-id"] = (LLSD::Integer)callback_id;
 
     request["message"] = "CopyInventoryFromNotecard";
@@ -964,7 +965,7 @@ void create_new_item(const std::string& name,
 				   U32 next_owner_perm)
 {
 	std::string desc;
-	LLAssetType::generateDescriptionFor(asset_type, desc);
+	LLViewerAssetType::generateDescriptionFor(asset_type, desc);
 	next_owner_perm = (next_owner_perm) ? next_owner_perm : PERM_MOVE | PERM_TRANSFER;
 
 	
@@ -989,19 +990,14 @@ const std::string NEW_LSL_NAME = "New Script"; // *TODO:Translate? (probably not
 const std::string NEW_NOTECARD_NAME = "New Note"; // *TODO:Translate? (probably not)
 const std::string NEW_GESTURE_NAME = "New Gesture"; // *TODO:Translate? (probably not)
 
+// ! REFACTOR ! Really need to refactor this so that it's not a bunch of if-then statements...
 void menu_create_inventory_item(LLFolderView* folder, LLFolderBridge *bridge, const LLSD& userdata, const LLUUID& default_parent_uuid)
 {
-	std::string type = userdata.asString();
+	std::string type_name = userdata.asString();
 	
-	if (("category" == type) || ("current" == type) || ("outfit" == type) || ("my_otfts" == type) )
+	if (("category" == type_name) || ("current" == type_name) || ("outfit" == type_name) || ("my_otfts" == type_name))
 	{
-		LLAssetType::EType a_type = LLAssetType::AT_NONE;
-		if ("current" == type)
-			a_type = LLAssetType::AT_CURRENT_OUTFIT;
-		if ("outfit" == type)
-			a_type = LLAssetType::AT_OUTFIT;
-		if ("my_otfts" == type)
-			a_type = LLAssetType::AT_MY_OUTFITS;
+		LLFolderType::EType preferred_type = LLFolderType::lookup(type_name);
 
 		LLUUID parent_id;
 		if (bridge)
@@ -1017,100 +1013,100 @@ void menu_create_inventory_item(LLFolderView* folder, LLFolderBridge *bridge, co
 			parent_id = gInventory.getRootFolderID();
 		}
 
-		LLUUID category = gInventory.createNewCategory(parent_id, a_type, LLStringUtil::null);
+		LLUUID category = gInventory.createNewCategory(parent_id, preferred_type, LLStringUtil::null);
 		gInventory.notifyObservers();
 		folder->setSelectionByID(category, TRUE);
 	}
-	else if ("lsl" == type)
+	else if ("lsl" == type_name)
 	{
-		LLUUID parent_id = bridge ? bridge->getUUID() : gInventory.findCategoryUUIDForType(LLAssetType::AT_LSL_TEXT);
+		const LLUUID parent_id = bridge ? bridge->getUUID() : gInventory.findCategoryUUIDForType(LLFolderType::FT_LSL_TEXT);
 		create_new_item(NEW_LSL_NAME,
 					  parent_id,
 					  LLAssetType::AT_LSL_TEXT,
 					  LLInventoryType::IT_LSL,
 					  PERM_MOVE | PERM_TRANSFER);
 	}
-	else if ("notecard" == type)
+	else if ("notecard" == type_name)
 	{
-		LLUUID parent_id = bridge ? bridge->getUUID() : gInventory.findCategoryUUIDForType(LLAssetType::AT_NOTECARD);
+		const LLUUID parent_id = bridge ? bridge->getUUID() : gInventory.findCategoryUUIDForType(LLFolderType::FT_NOTECARD);
 		create_new_item(NEW_NOTECARD_NAME,
 					  parent_id,
 					  LLAssetType::AT_NOTECARD,
 					  LLInventoryType::IT_NOTECARD,
 					  PERM_ALL);
 	}
-	else if ("gesture" == type)
+	else if ("gesture" == type_name)
 	{
-		LLUUID parent_id = bridge ? bridge->getUUID() : gInventory.findCategoryUUIDForType(LLAssetType::AT_GESTURE);
+		const LLUUID parent_id = bridge ? bridge->getUUID() : gInventory.findCategoryUUIDForType(LLFolderType::FT_GESTURE);
 		create_new_item(NEW_GESTURE_NAME,
 					  parent_id,
 					  LLAssetType::AT_GESTURE,
 					  LLInventoryType::IT_GESTURE,
 					  PERM_ALL);
 	}
-	else if ("shirt" == type)
+	else if ("shirt" == type_name)
 	{
-		LLUUID parent_id = bridge ? bridge->getUUID() : gInventory.findCategoryUUIDForType(LLAssetType::AT_CLOTHING);
+		const LLUUID parent_id = bridge ? bridge->getUUID() : gInventory.findCategoryUUIDForType(LLFolderType::FT_CLOTHING);
 		LLFolderBridge::createWearable(parent_id, WT_SHIRT);
 	}
-	else if ("pants" == type)
+	else if ("pants" == type_name)
 	{
-		LLUUID parent_id = bridge ? bridge->getUUID() : gInventory.findCategoryUUIDForType(LLAssetType::AT_CLOTHING);
+		const LLUUID parent_id = bridge ? bridge->getUUID() : gInventory.findCategoryUUIDForType(LLFolderType::FT_CLOTHING);
 		LLFolderBridge::createWearable(parent_id, WT_PANTS);
 	}
-	else if ("shoes" == type)
+	else if ("shoes" == type_name)
 	{
-		LLUUID parent_id = bridge ? bridge->getUUID() : gInventory.findCategoryUUIDForType(LLAssetType::AT_CLOTHING);
+		const LLUUID parent_id = bridge ? bridge->getUUID() : gInventory.findCategoryUUIDForType(LLFolderType::FT_CLOTHING);
 		LLFolderBridge::createWearable(parent_id, WT_SHOES);
 	}
-	else if ("socks" == type)
+	else if ("socks" == type_name)
 	{
-		LLUUID parent_id = bridge ? bridge->getUUID() : gInventory.findCategoryUUIDForType(LLAssetType::AT_CLOTHING);
+		const LLUUID parent_id = bridge ? bridge->getUUID() : gInventory.findCategoryUUIDForType(LLFolderType::FT_CLOTHING);
 		LLFolderBridge::createWearable(parent_id, WT_SOCKS);
 	}
-	else if ("jacket" == type)
+	else if ("jacket" == type_name)
 	{
-		LLUUID parent_id = bridge ? bridge->getUUID() : gInventory.findCategoryUUIDForType(LLAssetType::AT_CLOTHING);
+		const LLUUID parent_id = bridge ? bridge->getUUID() : gInventory.findCategoryUUIDForType(LLFolderType::FT_CLOTHING);
 		LLFolderBridge::createWearable(parent_id, WT_JACKET);
 	}
-	else if ("skirt" == type)
+	else if ("skirt" == type_name)
 	{
-		LLUUID parent_id = bridge ? bridge->getUUID() : gInventory.findCategoryUUIDForType(LLAssetType::AT_CLOTHING);
+		const LLUUID parent_id = bridge ? bridge->getUUID() : gInventory.findCategoryUUIDForType(LLFolderType::FT_CLOTHING);
 		LLFolderBridge::createWearable(parent_id, WT_SKIRT);
 	}
-	else if ("gloves" == type)
+	else if ("gloves" == type_name)
 	{
-		LLUUID parent_id = bridge ? bridge->getUUID() : gInventory.findCategoryUUIDForType(LLAssetType::AT_CLOTHING);
+		const LLUUID parent_id = bridge ? bridge->getUUID() : gInventory.findCategoryUUIDForType(LLFolderType::FT_CLOTHING);
 		LLFolderBridge::createWearable(parent_id, WT_GLOVES);
 	}
-	else if ("undershirt" == type)
+	else if ("undershirt" == type_name)
 	{
-		LLUUID parent_id = bridge ? bridge->getUUID() : gInventory.findCategoryUUIDForType(LLAssetType::AT_CLOTHING);
+		const LLUUID parent_id = bridge ? bridge->getUUID() : gInventory.findCategoryUUIDForType(LLFolderType::FT_CLOTHING);
 		LLFolderBridge::createWearable(parent_id, WT_UNDERSHIRT);
 	}
-	else if ("underpants" == type)
+	else if ("underpants" == type_name)
 	{
-		LLUUID parent_id = bridge ? bridge->getUUID() : gInventory.findCategoryUUIDForType(LLAssetType::AT_CLOTHING);
+		const LLUUID parent_id = bridge ? bridge->getUUID() : gInventory.findCategoryUUIDForType(LLFolderType::FT_CLOTHING);
 		LLFolderBridge::createWearable(parent_id, WT_UNDERPANTS);
 	}
-	else if ("shape" == type)
+	else if ("shape" == type_name)
 	{
-		LLUUID parent_id = bridge ? bridge->getUUID() : gInventory.findCategoryUUIDForType(LLAssetType::AT_BODYPART);
+		const LLUUID parent_id = bridge ? bridge->getUUID() : gInventory.findCategoryUUIDForType(LLFolderType::FT_BODYPART);
 		LLFolderBridge::createWearable(parent_id, WT_SHAPE);
 	}
-	else if ("skin" == type)
+	else if ("skin" == type_name)
 	{
-		LLUUID parent_id = bridge ? bridge->getUUID() : gInventory.findCategoryUUIDForType(LLAssetType::AT_BODYPART);
+		const LLUUID parent_id = bridge ? bridge->getUUID() : gInventory.findCategoryUUIDForType(LLFolderType::FT_BODYPART);
 		LLFolderBridge::createWearable(parent_id, WT_SKIN);
 	}
-	else if ("hair" == type)
+	else if ("hair" == type_name)
 	{
-		LLUUID parent_id = bridge ? bridge->getUUID() : gInventory.findCategoryUUIDForType(LLAssetType::AT_BODYPART);
+		const LLUUID parent_id = bridge ? bridge->getUUID() : gInventory.findCategoryUUIDForType(LLFolderType::FT_BODYPART);
 		LLFolderBridge::createWearable(parent_id, WT_HAIR);
 	}
-	else if ("eyes" == type)
+	else if ("eyes" == type_name)
 	{
-		LLUUID parent_id = bridge ? bridge->getUUID() : gInventory.findCategoryUUIDForType(LLAssetType::AT_BODYPART);
+		const LLUUID parent_id = bridge ? bridge->getUUID() : gInventory.findCategoryUUIDForType(LLFolderType::FT_BODYPART);
 		LLFolderBridge::createWearable(parent_id, WT_EYES);
 	}
 	
diff --git a/indra/newview/llviewerinventory.h b/indra/newview/llviewerinventory.h
index d523bf2859..529425aa25 100644
--- a/indra/newview/llviewerinventory.h
+++ b/indra/newview/llviewerinventory.h
@@ -185,7 +185,7 @@ protected:
 	
 public:
 	LLViewerInventoryCategory(const LLUUID& uuid, const LLUUID& parent_uuid,
-							  LLAssetType::EType preferred_type,
+							  LLFolderType::EType preferred_type,
 							  const std::string& name,
 							  const LLUUID& owner_id);
 	LLViewerInventoryCategory(const LLUUID& owner_id);
@@ -221,7 +221,7 @@ public:
 	bool exportFileLocal(LLFILE* fp) const;
 	bool importFileLocal(LLFILE* fp);
 	void determineFolderType();
-	void changeType(LLAssetType::EType new_folder_type);
+	void changeType(LLFolderType::EType new_folder_type);
 protected:
 	LLUUID mOwnerID;
 	S32 mVersion;
diff --git a/indra/newview/llviewermenu.cpp b/indra/newview/llviewermenu.cpp
index 23ceb1e72d..9a98264847 100644
--- a/indra/newview/llviewermenu.cpp
+++ b/indra/newview/llviewermenu.cpp
@@ -4176,12 +4176,10 @@ void handle_take_copy()
 {
 	if (LLSelectMgr::getInstance()->getSelection()->isEmpty()) return;
 
-	LLUUID category_id =
-		gInventory.findCategoryUUIDForType(LLAssetType::AT_OBJECT);
+	const LLUUID category_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_OBJECT);
 	derez_objects(DRD_ACQUIRE_TO_AGENT_INVENTORY, category_id);
 }
 
-
 // You can return an object to its owner if it is on your land.
 class LLObjectReturn : public view_listener_t
 {
@@ -4262,7 +4260,7 @@ class LLObjectEnableReturn : public view_listener_t
 void force_take_copy(void*)
 {
 	if (LLSelectMgr::getInstance()->getSelection()->isEmpty()) return;
-	const LLUUID& category_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_OBJECT);
+	const LLUUID category_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_OBJECT);
 	derez_objects(DRD_FORCE_TO_GOD_INVENTORY, category_id);
 }
 
@@ -4323,8 +4321,7 @@ void handle_take()
 		if(category_id.notNull())
 		{
 		        // check trash
-			LLUUID trash;
-			trash = gInventory.findCategoryUUIDForType(LLAssetType::AT_TRASH);
+			const LLUUID trash = gInventory.findCategoryUUIDForType(LLFolderType::FT_TRASH);
 			if(category_id == trash || gInventory.isObjectDescendentOf(category_id, trash))
 			{
 				category_id.setNull();
@@ -4340,7 +4337,7 @@ void handle_take()
 	}
 	if(category_id.isNull())
 	{
-		category_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_OBJECT);
+		category_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_OBJECT);
 	}
 	LLSD payload;
 	payload["folder_id"] = category_id;
@@ -6919,7 +6916,7 @@ void handle_grab_texture(void* data)
 		LL_INFOS("texture") << "Adding baked texture " << asset_id << " to inventory." << llendl;
 		LLAssetType::EType asset_type = LLAssetType::AT_TEXTURE;
 		LLInventoryType::EType inv_type = LLInventoryType::IT_TEXTURE;
-		LLUUID folder_id(gInventory.findCategoryUUIDForType(asset_type));
+		const LLUUID folder_id = gInventory.findCategoryUUIDForType(LLFolderType::assetTypeToFolderType(asset_type));
 		if(folder_id.notNull())
 		{
 			std::string name = "Unknown";
diff --git a/indra/newview/llviewermenufile.cpp b/indra/newview/llviewermenufile.cpp
index d3a9e1cef8..d17c7e486f 100644
--- a/indra/newview/llviewermenufile.cpp
+++ b/indra/newview/llviewermenufile.cpp
@@ -319,7 +319,7 @@ class LLFileUploadBulk : public view_listener_t
 			LLAssetStorage::LLStoreAssetCallback callback = NULL;
 			S32 expected_upload_cost = LLGlobalEconomy::Singleton::getInstance()->getPriceUpload();
 			void *userdata = NULL;
-			upload_new_resource(filename, asset_name, asset_name, 0, LLAssetType::AT_NONE, LLInventoryType::IT_NONE,
+			upload_new_resource(filename, asset_name, asset_name, 0, LLFolderType::FT_NONE, LLInventoryType::IT_NONE,
 				LLFloaterPerms::getNextOwnerPerms(), LLFloaterPerms::getGroupPerms(), LLFloaterPerms::getEveryonePerms(),
 					    display_name,
 					    callback, expected_upload_cost, userdata);
@@ -493,7 +493,7 @@ void handle_compress_image(void*)
 
 void upload_new_resource(const std::string& src_filename, std::string name,
 			 std::string desc, S32 compression_info,
-			 LLAssetType::EType destination_folder_type,
+			 LLFolderType::EType destination_folder_type,
 			 LLInventoryType::EType inv_type,
 			 U32 next_owner_perms,
 			 U32 group_perms,
@@ -810,7 +810,7 @@ void upload_done_callback(const LLUUID& uuid, void* user_data, S32 result, LLExt
 
 	if(result >= 0)
 	{
-		LLAssetType::EType dest_loc = (data->mPreferredLocation == LLAssetType::AT_NONE) ? data->mAssetInfo.mType : data->mPreferredLocation;
+		LLFolderType::EType dest_loc = (data->mPreferredLocation == LLFolderType::FT_NONE) ? LLFolderType::assetTypeToFolderType(data->mAssetInfo.mType) : data->mPreferredLocation;
 
 		if (LLAssetType::AT_SOUND == data->mAssetInfo.mType ||
 			LLAssetType::AT_TEXTURE == data->mAssetInfo.mType ||
@@ -856,7 +856,7 @@ void upload_done_callback(const LLUUID& uuid, void* user_data, S32 result, LLExt
 		{
 			// Actually add the upload to inventory
 			llinfos << "Adding " << uuid << " to inventory." << llendl;
-			LLUUID folder_id(gInventory.findCategoryUUIDForType(dest_loc));
+			const LLUUID folder_id = gInventory.findCategoryUUIDForType(dest_loc);
 			if(folder_id.notNull())
 			{
 				U32 next_owner_perms = data->mNextOwnerPerm;
@@ -903,7 +903,7 @@ void upload_done_callback(const LLUUID& uuid, void* user_data, S32 result, LLExt
 		LLAssetStorage::LLStoreAssetCallback callback = NULL;
 		void *userdata = NULL;
 		upload_new_resource(next_file, asset_name, asset_name,	// file
-				    0, LLAssetType::AT_NONE, LLInventoryType::IT_NONE,
+				    0, LLFolderType::FT_NONE, LLInventoryType::IT_NONE,
 				    PERM_NONE, PERM_NONE, PERM_NONE,
 				    display_name,
 				    callback,
@@ -915,7 +915,7 @@ void upload_done_callback(const LLUUID& uuid, void* user_data, S32 result, LLExt
 void upload_new_resource(const LLTransactionID &tid, LLAssetType::EType asset_type,
 			 std::string name,
 			 std::string desc, S32 compression_info,
-			 LLAssetType::EType destination_folder_type,
+			 LLFolderType::EType destination_folder_type,
 			 LLInventoryType::EType inv_type,
 			 U32 next_owner_perms,
 			 U32 group_perms,
@@ -973,14 +973,14 @@ void upload_new_resource(const LLTransactionID &tid, LLAssetType::EType asset_ty
 	llinfos << "Name: " << name << llendl;
 	llinfos << "Desc: " << desc << llendl;
 	llinfos << "Expected Upload Cost: " << expected_upload_cost << llendl;
-	lldebugs << "Folder: " << gInventory.findCategoryUUIDForType((destination_folder_type == LLAssetType::AT_NONE) ? asset_type : destination_folder_type) << llendl;
+	lldebugs << "Folder: " << gInventory.findCategoryUUIDForType((destination_folder_type == LLFolderType::FT_NONE) ? LLFolderType::assetTypeToFolderType(asset_type) : destination_folder_type) << llendl;
 	lldebugs << "Asset Type: " << LLAssetType::lookup(asset_type) << llendl;
 	std::string url = gAgent.getRegion()->getCapability("NewFileAgentInventory");
 	if (!url.empty())
 	{
 		llinfos << "New Agent Inventory via capability" << llendl;
 		LLSD body;
-		body["folder_id"] = gInventory.findCategoryUUIDForType((destination_folder_type == LLAssetType::AT_NONE) ? asset_type : destination_folder_type);
+		body["folder_id"] = gInventory.findCategoryUUIDForType((destination_folder_type == LLFolderType::FT_NONE) ? LLFolderType::assetTypeToFolderType(asset_type) : destination_folder_type);
 		body["asset_type"] = LLAssetType::lookup(asset_type);
 		body["inventory_type"] = LLInventoryType::lookup(inv_type);
 		body["name"] = name;
diff --git a/indra/newview/llviewermenufile.h b/indra/newview/llviewermenufile.h
index bf21292082..da78537a29 100644
--- a/indra/newview/llviewermenufile.h
+++ b/indra/newview/llviewermenufile.h
@@ -33,7 +33,7 @@
 #ifndef LLVIEWERMENUFILE_H
 #define LLVIEWERMENUFILE_H
 
-#include "llassettype.h"
+#include "llfoldertype.h"
 #include "llinventorytype.h"
 
 class LLTransactionID;
@@ -45,7 +45,7 @@ void upload_new_resource(const std::string& src_filename,
 			 std::string name,
 			 std::string desc, 
 			 S32 compression_info,
-			 LLAssetType::EType destination_folder_type,
+			 LLFolderType::EType destination_folder_type,
 			 LLInventoryType::EType inv_type,
 			 U32 next_owner_perms,
 			 U32 group_perms,
@@ -60,7 +60,7 @@ void upload_new_resource(const LLTransactionID &tid,
 			 std::string name,
 			 std::string desc, 
 			 S32 compression_info,
-			 LLAssetType::EType destination_folder_type,
+			 LLFolderType::EType destination_folder_type,
 			 LLInventoryType::EType inv_type,
 			 U32 next_owner_perms,
 			 U32 group_perms,
diff --git a/indra/newview/llviewermessage.cpp b/indra/newview/llviewermessage.cpp
index ff1c7b526f..d8e6c52c8c 100644
--- a/indra/newview/llviewermessage.cpp
+++ b/indra/newview/llviewermessage.cpp
@@ -140,7 +140,7 @@
 #include "llgroupactions.h"
 #include "llagentui.h"
 #include "llpanelblockedlist.h"
-#include "llpanelplaceinfo.h"
+#include "llpanelplaceprofile.h"
 
 #include <boost/tokenizer.hpp>
 #include <boost/algorithm/string/split.hpp>
@@ -209,7 +209,6 @@ const BOOL SCRIPT_QUESTION_IS_CAUTION[SCRIPT_PERMISSION_EOF] =
 bool friendship_offer_callback(const LLSD& notification, const LLSD& response)
 {
 	S32 option = LLNotification::getSelectedOption(notification, response);
-	LLUUID fid;
 	LLMessageSystem* msg = gMessageSystem;
 	const LLSD& payload = notification["payload"];
 
@@ -219,10 +218,11 @@ bool friendship_offer_callback(const LLSD& notification, const LLSD& response)
 	switch(option)
 	{
 	case 0:
+	{
 		// accept
 		LLAvatarTracker::formFriendship(payload["from_id"]);
 
-		fid = gInventory.findCategoryUUIDForType(LLAssetType::AT_CALLINGCARD);
+		const LLUUID fid = gInventory.findCategoryUUIDForType(LLFolderType::FT_CALLINGCARD);
 
 		// This will also trigger an onlinenotification if the user is online
 		msg->newMessageFast(_PREHASH_AcceptFriendship);
@@ -235,7 +235,9 @@ bool friendship_offer_callback(const LLSD& notification, const LLSD& response)
 		msg->addUUIDFast(_PREHASH_FolderID, fid);
 		msg->sendReliable(LLHost(payload["sender"].asString()));
 		break;
+	}
 	case 1:
+	{
 		// decline
 		// We no longer notify other viewers, but we DO still send
 		// the rejection to the simulator to delete the pending userop.
@@ -247,6 +249,7 @@ bool friendship_offer_callback(const LLSD& notification, const LLSD& response)
 		msg->addUUIDFast(_PREHASH_TransactionID, payload["session_id"]);
 		msg->sendReliable(LLHost(payload["sender"].asString()));
 		break;
+	}
 	default:
 		// close button probably, possibly timed out
 		break;
@@ -767,8 +770,7 @@ public:
 	virtual void done()
 	{
 		LL_DEBUGS("Messaging") << "LLDiscardAgentOffer::done()" << LL_ENDL;
-		LLUUID trash_id;
-		trash_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_TRASH);
+		const LLUUID trash_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_TRASH);
 		bool notify = false;
 		if(trash_id.notNull() && mObjectID.notNull())
 		{
@@ -875,7 +877,7 @@ void open_offer(const std::vector<LLUUID>& items, const std::string& from_name)
 {
 	std::vector<LLUUID>::const_iterator it = items.begin();
 	std::vector<LLUUID>::const_iterator end = items.end();
-	LLUUID trash_id(gInventory.findCategoryUUIDForType(LLAssetType::AT_TRASH));
+	const LLUUID trash_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_TRASH);
 	LLInventoryItem* item;
 	for(; it != end; ++it)
 	{
@@ -946,13 +948,12 @@ void open_offer(const std::vector<LLUUID>& items, const std::string& from_name)
 		}
 
 		//Trash Check
-		LLUUID trash_id;
-		trash_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_TRASH);
+		const LLUUID trash_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_TRASH);
 		if(gInventory.isObjectDescendentOf(item->getUUID(), trash_id))
 		{
 			return;
 		}
-		LLUUID lost_and_found_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_LOST_AND_FOUND);
+		const LLUUID lost_and_found_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_LOST_AND_FOUND);
 		//BOOL inventory_has_focus = gFocusMgr.childHasKeyboardFocus(view);
 		BOOL user_is_away = gAwayTimer.getStarted();
 
@@ -1716,7 +1717,7 @@ void process_improved_im(LLMessageSystem *msg, void **user_data)
 				info->mFromGroup = from_group;
 				info->mTransactionID = session_id;
 				info->mType = (LLAssetType::EType) asset_type;
-				info->mFolderID = gInventory.findCategoryUUIDForType(info->mType);
+				info->mFolderID = gInventory.findCategoryUUIDForType(LLFolderType::assetTypeToFolderType(info->mType));
 				std::string from_name;
 
 				from_name += "A group member named ";
@@ -1850,7 +1851,7 @@ void process_improved_im(LLMessageSystem *msg, void **user_data)
 			info->mFromID = from_id;
 			info->mFromGroup = from_group;
 			info->mTransactionID = session_id;
-			info->mFolderID = gInventory.findCategoryUUIDForType(info->mType);
+			info->mFolderID = gInventory.findCategoryUUIDForType(LLFolderType::assetTypeToFolderType(info->mType));
 
 			if (dialog == IM_TASK_INVENTORY_OFFERED)
 			{
@@ -2144,7 +2145,7 @@ bool callingcard_offer_callback(const LLSD& notification, const LLSD& response)
 		msg->addUUIDFast(_PREHASH_SessionID, gAgent.getSessionID());
 		msg->nextBlockFast(_PREHASH_TransactionBlock);
 		msg->addUUIDFast(_PREHASH_TransactionID, notification["payload"]["transaction_id"].asUUID());
-		fid = gInventory.findCategoryUUIDForType(LLAssetType::AT_CALLINGCARD);
+		fid = gInventory.findCategoryUUIDForType(LLFolderType::FT_CALLINGCARD);
 		msg->nextBlockFast(_PREHASH_FolderData);
 		msg->addUUIDFast(_PREHASH_FolderID, fid);
 		msg->sendReliable(LLHost(notification["payload"]["sender"].asString()));
@@ -2597,11 +2598,10 @@ BOOL LLPostTeleportNotifiers::tick()
 	{
 		// get callingcards and landmarks available to the user arriving.
 		LLInventoryFetchDescendentsObserver::folder_ref_t folders;
-		LLUUID folder_id;
-		folder_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_CALLINGCARD);
-		if(folder_id.notNull()) 
-			folders.push_back(folder_id);
-		folder_id = gInventory.findCategoryUUIDForType(LLAssetType::AT_LANDMARK);
+		const LLUUID callingcard_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_CALLINGCARD);
+		if(callingcard_id.notNull()) 
+			folders.push_back(callingcard_id);
+		const LLUUID folder_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_LANDMARK);
 		if(folder_id.notNull()) 
 			folders.push_back(folder_id);
 		if(!folders.empty())
@@ -4819,7 +4819,7 @@ void container_inventory_arrived(LLViewerObject* object,
 		// create a new inventory category to put this in
 		LLUUID cat_id;
 		cat_id = gInventory.createNewCategory(gInventory.getRootFolderID(),
-											  LLAssetType::AT_NONE,
+											  LLFolderType::FT_NONE,
 											  LLTrans::getString("AcquiredItems"));
 
 		InventoryObjectList::const_iterator it = inventory->begin();
@@ -4869,7 +4869,7 @@ void container_inventory_arrived(LLViewerObject* object,
 		}
 
 		LLInventoryItem* item = (LLInventoryItem*)((LLInventoryObject*)(*it));
-		LLUUID category = gInventory.findCategoryUUIDForType(item->getType());
+		const LLUUID category = gInventory.findCategoryUUIDForType(LLFolderType::assetTypeToFolderType(item->getType()));
 
 		LLUUID item_id;
 		item_id.generate();
@@ -5549,7 +5549,7 @@ void process_covenant_reply(LLMessageSystem* msg, void**)
 	LLPanelLandCovenant::updateEstateOwnerName(owner_name);
 	LLFloaterBuyLand::updateEstateOwnerName(owner_name);
 
-	LLPanelPlaceInfo* panel = LLSideTray::getInstance()->findChild<LLPanelPlaceInfo>("panel_place_info");
+	LLPanelPlaceProfile* panel = LLSideTray::getInstance()->findChild<LLPanelPlaceProfile>("panel_place_profile");
 	if (panel)
 	{
 		panel->updateEstateName(estate_name);
@@ -5683,7 +5683,7 @@ void onCovenantLoadComplete(LLVFS *vfs,
 	LLPanelLandCovenant::updateCovenantText(covenant_text);
 	LLFloaterBuyLand::updateCovenantText(covenant_text, asset_uuid);
 
-	LLPanelPlaceInfo* panel = LLSideTray::getInstance()->findChild<LLPanelPlaceInfo>("panel_place_info");
+	LLPanelPlaceProfile* panel = LLSideTray::getInstance()->findChild<LLPanelPlaceProfile>("panel_place_profile");
 	if (panel)
 	{
 		panel->updateCovenantText(covenant_text);
diff --git a/indra/newview/llviewertexteditor.cpp b/indra/newview/llviewertexteditor.cpp
index 5c40f2a540..90dff465c9 100644
--- a/indra/newview/llviewertexteditor.cpp
+++ b/indra/newview/llviewertexteditor.cpp
@@ -62,6 +62,7 @@
 #include "lltooltip.h"
 #include "lltrans.h"
 #include "lluictrlfactory.h"
+#include "llviewerassettype.h"
 #include "llviewercontrol.h"
 #include "llviewerinventory.h"
 #include "llviewertexturelist.h"
@@ -505,19 +506,17 @@ LLUIImagePtr LLEmbeddedItems::getItemImage(llwchar ext_char) const
 				}
 
 				break;
-			case LLAssetType::AT_SOUND:			img_name = "Inv_Sound";	break;
+			case LLAssetType::AT_SOUND:			img_name = "Inv_Sound";		break;
 			case LLAssetType::AT_CLOTHING:		img_name = "Inv_Clothing";	break;
-			case LLAssetType::AT_OBJECT:		img_name = "Inv_Object"; break;
+			case LLAssetType::AT_OBJECT:		img_name = "Inv_Object"; 	break;
 			case LLAssetType::AT_CALLINGCARD:	img_name = "Inv_CallingCard"; break;
-			case LLAssetType::AT_LANDMARK:		img_name = "Inv_Landmark"; break;
+			case LLAssetType::AT_LANDMARK:		img_name = "Inv_Landmark"; 	break;
 			case LLAssetType::AT_NOTECARD:		img_name = "Inv_Notecard";	break;
 			case LLAssetType::AT_LSL_TEXT:		img_name = "Inv_Script";	break;
-			case LLAssetType::AT_BODYPART:		img_name = "Inv_Skin";	break;
-			case LLAssetType::AT_ANIMATION:		img_name = "Inv_Animation";break;
-			case LLAssetType::AT_GESTURE:			img_name = "Inv_Gesture";	break;
-				//TODO need img_name
-			case LLAssetType::AT_FAVORITE:		img_name = "Inv_Landmark";	 break;
-			default: llassert(0); 
+			case LLAssetType::AT_BODYPART:		img_name = "Inv_Skin";		break;
+			case LLAssetType::AT_ANIMATION:		img_name = "Inv_Animation";	break;
+			case LLAssetType::AT_GESTURE:		img_name = "Inv_Gesture";	break;
+			default: llassert(0);
 		}
 
 		return LLUI::getUIImage(img_name);
@@ -732,11 +731,10 @@ BOOL LLViewerTextEditor::handleHover(S32 x, S32 y, MASK mask)
 		if( LLToolDragAndDrop::getInstance()->isOverThreshold( screen_x, screen_y ) )
 		{
 			LLToolDragAndDrop::getInstance()->beginDrag(
-				LLAssetType::lookupDragAndDropType( mDragItem->getType() ),
+				LLViewerAssetType::lookupDragAndDropType( mDragItem->getType() ),
 				mDragItem->getUUID(),
 				LLToolDragAndDrop::SOURCE_NOTECARD,
 				mPreviewID, mObjectID);
-
 			return LLToolDragAndDrop::getInstance()->handleHover( x, y, mask );
 		}
 		getWindow()->setCursor(UI_CURSOR_HAND);
diff --git a/indra/newview/llvoavatarself.cpp b/indra/newview/llvoavatarself.cpp
index a964f43171..e7a43924db 100644
--- a/indra/newview/llvoavatarself.cpp
+++ b/indra/newview/llvoavatarself.cpp
@@ -41,53 +41,22 @@
 #include "llvoavatarself.h"
 #include "llvoavatar.h"
 
-#include <stdio.h>
-#include <ctype.h>
-
-#include "llaudioengine.h"
-#include "noise.h"
+#include "pipeline.h"
 
-// TODO: Seraph - Remove unnecessary headers.  These are copied from llvoavatar.h.
 #include "llagent.h" //  Get state values from here
 #include "llagentwearables.h"
-#include "llviewercontrol.h"
-#include "lldrawpoolavatar.h"
-#include "lldriverparam.h"
-#include "lleditingmotion.h"
-#include "llemote.h"
-#include "llface.h"
-#include "llfirstuse.h"
-#include "llheadrotmotion.h"
 #include "llhudeffecttrail.h"
 #include "llhudmanager.h"
-#include "llkeyframefallmotion.h"
-#include "llkeyframestandmotion.h"
-#include "llkeyframewalkmotion.h"
-#include "llmutelist.h"
 #include "llselectmgr.h"
-#include "llsprite.h"
-#include "lltargetingmotion.h"
-#include "lltexlayer.h"
-#include "lltexglobalcolor.h"
 #include "lltoolgrab.h"	// for needsRenderBeam
 #include "lltoolmgr.h" // for needsRenderBeam
 #include "lltoolmorph.h"
 #include "lltrans.h"
 #include "llviewercamera.h"
-#include "llviewertexturelist.h"
 #include "llviewermenu.h"
 #include "llviewerobjectlist.h"
-#include "llviewerparcelmgr.h"
 #include "llviewerstats.h"
-#include "llvovolume.h"
-#include "llworld.h"
-#include "pipeline.h"
-#include "llviewershadermgr.h"
-#include "llsky.h"
-#include "llanimstatelabels.h"
-#include "llgesturemgr.h" //needed to trigger the voice gesticulations
-#include "llvoiceclient.h"
-#include "llvoicevisualizer.h" // Ventrella
+#include "llviewerregion.h"
 #include "llappearancemgr.h"
 
 #if LL_MSVC
diff --git a/indra/newview/llwearable.cpp b/indra/newview/llwearable.cpp
index f2cf84c228..4288e4e6fd 100644
--- a/indra/newview/llwearable.cpp
+++ b/indra/newview/llwearable.cpp
@@ -1123,7 +1123,7 @@ void LLWearable::saveNewAsset() const
 		{
 			llinfos << "Update Agent Inventory via capability" << llendl;
 			LLSD body;
-			body["folder_id"] = gInventory.findCategoryUUIDForType(getAssetType());
+			body["folder_id"] = gInventory.findCategoryUUIDForType(LLFolderType::assetToFolderType(getAssetType()));
 			body["asset_type"] = LLAssetType::lookup(getAssetType());
 			body["inventory_type"] = LLInventoryType::lookup(LLInventoryType::IT_WEARABLE);
 			body["name"] = getName();
diff --git a/indra/newview/skins/default/textures/inv_folder_inbox.tga b/indra/newview/skins/default/textures/inv_folder_inbox.tga
new file mode 100644
index 0000000000..04539c2cc4
Binary files /dev/null and b/indra/newview/skins/default/textures/inv_folder_inbox.tga differ
diff --git a/indra/newview/skins/default/xui/en/floater_im_session.xml b/indra/newview/skins/default/xui/en/floater_im_session.xml
index 26d2f4e497..88aca005cf 100644
--- a/indra/newview/skins/default/xui/en/floater_im_session.xml
+++ b/indra/newview/skins/default/xui/en/floater_im_session.xml
@@ -3,7 +3,7 @@
  legacy_header_height="18"
  background_visible="true"
  follows="left|top|right|bottom"
- height="270"
+ height="359"
  layout="topleft"
  left="0"
  name="panel_im"
@@ -12,13 +12,13 @@
  can_dock="true"
  can_minimize="true"
  visible="true" 
- width="365"
+ width="400"
  can_resize="true"
  min_width="200"
  min_height="150">
   <layout_stack follows="left|top|right|bottom"
-                height="255"
-                width="365"
+                height="344"
+                width="400"
                 layout="topleft"
                 orientation="horizontal"
                 name="im_panels"
@@ -28,13 +28,13 @@
       name="panel_im_control_panel"
       layout="topleft"
       top_delta="-3"
-      width="146"
-      height="255"
+      height="344"
       follows="left"
       label="IM Control Panel"
+      auto_resize="false"
       user_resize="false" />
-    <layout_panel height="255"
-                  width="200"
+    <layout_panel height="344"
+                  width="235"
                   left_delta="146" 
                   top="0"
                   user_resize="false">
@@ -56,14 +56,14 @@
        length="1"
        follows="left|top|right|bottom"
        font="SansSerif"
-       height="205"
+       height="290"
        layout="topleft"
        name="chat_history"
        parse_highlights="true"
        allow_html="true" 
-       width="195">
+       width="230">
       </chat_history>
-      <line_editor follows="left|right" name="chat_editor" height="20" layout="topleft" width="190">
+      <line_editor follows="left|right" name="chat_editor" height="20" layout="topleft" width="225">
       </line_editor>
     </layout_panel>
   </layout_stack>
diff --git a/indra/newview/skins/default/xui/en/inspect_avatar.xml b/indra/newview/skins/default/xui/en/inspect_avatar.xml
index 6b13e2f1c7..e2ae81e0b9 100644
--- a/indra/newview/skins/default/xui/en/inspect_avatar.xml
+++ b/indra/newview/skins/default/xui/en/inspect_avatar.xml
@@ -128,6 +128,8 @@
      left_delta="110"
      tab_stop="false"
      width="18" />
+  <!-- Overlapping buttons for default actions
+    llinspectavatar.cpp makes visible the most likely default action -->
     <button
      follows="bottom|left"
      height="23"
@@ -136,6 +138,16 @@
      top="246"
      name="add_friend_btn"
      width="100" />
+    <button
+     follows="bottom|left"
+     height="23"
+     label="IM"
+     left_delta="0"
+     top_delta="0"
+     name="im_btn"
+     width="100"
+     commit_callback.function="InspectAvatar.IM"
+     />
     <menu_button
      follows="top|left"
      height="18"
diff --git a/indra/newview/skins/default/xui/en/menu_inspect_avatar_gear.xml b/indra/newview/skins/default/xui/en/menu_inspect_avatar_gear.xml
index 6049476a43..8ee67b9a02 100644
--- a/indra/newview/skins/default/xui/en/menu_inspect_avatar_gear.xml
+++ b/indra/newview/skins/default/xui/en/menu_inspect_avatar_gear.xml
@@ -7,7 +7,6 @@
          name="Gear Menu">
   <menu_item_call
    label="View Profile"
-   layout="topleft"
    enabled="true" 
    name="view_profile">
     <menu_item_call.on_click
@@ -15,49 +14,42 @@
   </menu_item_call>
   <menu_item_call
    label="Add Friend"
-   layout="topleft"
    name="add_friend">
     <menu_item_call.on_click
      function="InspectAvatar.AddFriend"/>
   </menu_item_call>
   <menu_item_call
    label="IM"
-   layout="topleft"
    name="im">
     <menu_item_call.on_click
      function="InspectAvatar.IM"/>
   </menu_item_call>
   <menu_item_call
    label="Call"
-   layout="topleft"
    enabled="true"
    name="call">
   </menu_item_call>
   <menu_item_call
    label="Teleport"
-   layout="topleft"
    name="teleport">
     <menu_item_call.on_click
      function="InspectAvatar.Teleport"/>
   </menu_item_call>
   <menu_item_call
    label="Invite to Group"
-   layout="topleft"
    name="invite_to_group">
     <menu_item_call.on_click
      function="InspectAvatar.InviteToGroup"/>
   </menu_item_call>
-  <menu_item_separator layout="topleft" />
+  <menu_item_separator />
   <menu_item_call
    label="Block"
-   layout="topleft"
    name="block">
     <menu_item_call.on_click
      function="InspectAvatar.Block"/>
   </menu_item_call>
   <menu_item_call
    label="Report"
-   layout="topleft"
    name="report">
     <menu_item_call.on_click
      function="InspectAvatar.Report"/>
@@ -88,7 +80,6 @@
   </menu_item_call>
   <menu_item_call
    label="Find On Map"
-   layout="topleft"
    name="find_on_map">
     <menu_item_call.on_click
      function="InspectAvatar.FindOnMap"/>
@@ -97,16 +88,14 @@
   </menu_item_call>
   <menu_item_call
    label="Zoom In"
-   layout="topleft"
    name="zoom_in">
     <menu_item_call.on_click
      function="InspectAvatar.ZoomIn"/>
   </menu_item_call>  
   <menu_item_call
    label="Pay"
-   layout="topleft"
    name="pay">
     <menu_item_call.on_click
      function="InspectAvatar.Pay"/>
   </menu_item_call>
-</menu>
\ No newline at end of file
+</menu>
diff --git a/indra/newview/skins/default/xui/en/menu_inspect_self_gear.xml b/indra/newview/skins/default/xui/en/menu_inspect_self_gear.xml
index 19c2bf3496..ce5ee83f55 100644
--- a/indra/newview/skins/default/xui/en/menu_inspect_self_gear.xml
+++ b/indra/newview/skins/default/xui/en/menu_inspect_self_gear.xml
@@ -7,7 +7,6 @@
          name="Gear Menu">
   <menu_item_call
    label="Stand Up"
-   layout="topleft"
    enabled="true"
    name="stand_up">
     <menu_item_call.on_click
@@ -18,7 +17,6 @@
   </menu_item_call>
   <menu_item_call
    label="My Appearance"
-   layout="topleft"
    name="my_appearance">
     <menu_item_call.on_click
      function="ShowFloater"
@@ -28,7 +26,6 @@
   </menu_item_call>
   <menu_item_call
    label="My Profile"
-   layout="topleft"
    enabled="true" 
    name="my_profile">
     <menu_item_call.on_click
@@ -37,7 +34,6 @@
   </menu_item_call>
   <menu_item_call
    label="My Friends"
-   layout="topleft"
    name="my_friends">
     <menu_item_call.on_click
      function="Self.Friends"
@@ -45,9 +41,8 @@
   </menu_item_call>
   <menu_item_call
    label="My Groups"
-   layout="topleft"
    name="my_groups">
     <menu_item_call.on_click
      function="Self.Groups" />
   </menu_item_call>
-</menu>
\ No newline at end of file
+</menu>
diff --git a/indra/newview/skins/default/xui/en/panel_adhoc_control_panel.xml b/indra/newview/skins/default/xui/en/panel_adhoc_control_panel.xml
index f50acc224f..87c4e2787f 100644
--- a/indra/newview/skins/default/xui/en/panel_adhoc_control_panel.xml
+++ b/indra/newview/skins/default/xui/en/panel_adhoc_control_panel.xml
@@ -1,7 +1,7 @@
 <?xml version="1.0" encoding="utf-8" standalone="yes" ?>
 <panel
  name="panel_im_control_panel"
- width="146"
+ width="180"
  height="215"
  border="false">
     <avatar_list
@@ -16,10 +16,11 @@
      show_info_btn="false"
      show_profile_btn="false"
      top="10"
-     width="140" />
+     width="180" />
     <button
      name="call_btn"
      label="Call"
+     left_delta="27"
      width="125"
      height="20" />
     <button
diff --git a/indra/newview/skins/default/xui/en/panel_bottomtray.xml b/indra/newview/skins/default/xui/en/panel_bottomtray.xml
index 61bd1d186e..b5051523e5 100644
--- a/indra/newview/skins/default/xui/en/panel_bottomtray.xml
+++ b/indra/newview/skins/default/xui/en/panel_bottomtray.xml
@@ -60,7 +60,7 @@
          min_width="96"
          name="speak_panel"
          user_resize="false">
-         <chiclet_talk
+         <talk_button
           follows="right"
           height="23"
           speak_button.tab_stop="true"
@@ -93,7 +93,7 @@
          min_width="76"
          name="gesture_panel"
          user_resize="false">
-         <button
+         <gesture_combo_box
            follows="right"
           height="23"
           label="Gesture"
diff --git a/indra/newview/skins/default/xui/en/panel_group_control_panel.xml b/indra/newview/skins/default/xui/en/panel_group_control_panel.xml
index 9ed510dff3..3358015335 100644
--- a/indra/newview/skins/default/xui/en/panel_group_control_panel.xml
+++ b/indra/newview/skins/default/xui/en/panel_group_control_panel.xml
@@ -1,7 +1,7 @@
 <?xml version="1.0" encoding="utf-8" standalone="yes" ?>
 <panel
  name="panel_im_control_panel"
- width="146"
+ width="180"
  height="238"
  border="false">
     <avatar_list
@@ -16,11 +16,11 @@
      show_info_btn="false"
      show_profile_btn="false"
      top="10"
-     width="140" />
+     width="180" />
     <button
      name="group_info_btn"
      label="Group Info"
-     left_delta="3"
+     left_delta="27"
      width="125"
      height="20" />
     <button
diff --git a/indra/newview/skins/default/xui/en/panel_group_general.xml b/indra/newview/skins/default/xui/en/panel_group_general.xml
index a85c55f9b2..4f24c7a745 100644
--- a/indra/newview/skins/default/xui/en/panel_group_general.xml
+++ b/indra/newview/skins/default/xui/en/panel_group_general.xml
@@ -1,14 +1,14 @@
 <?xml version="1.0" encoding="utf-8" standalone="yes" ?>
 <panel
  follows="all"
- height="412"
+     height="380"
  label="General"
  class="panel_group_general"
  layout="topleft"
  left="0"
  top="0"
  name="general_tab"
- width="313">
+ width="303">
     <panel.string
      name="help_text">
         The General tab contains general information about this group, a list of members, general Group Preferences and member options.
@@ -41,7 +41,7 @@ Hover your mouse over the options for more help.
      draw_heading="true"
      follows="left|top"
      heading_height="16"
-     height="160"
+     height="130"
      layout="topleft"
      left_delta="0"
      name="visible_members"
diff --git a/indra/newview/skins/default/xui/en/panel_group_info_sidetray.xml b/indra/newview/skins/default/xui/en/panel_group_info_sidetray.xml
index d8d47c4008..ab0f956da0 100644
--- a/indra/newview/skins/default/xui/en/panel_group_info_sidetray.xml
+++ b/indra/newview/skins/default/xui/en/panel_group_info_sidetray.xml
@@ -5,7 +5,7 @@ background_visible="true"
  height="570"
  label="Group Info"
  layout="topleft"
- min_height="350"
+ min_height="425"
  left="0"
  top="20"
  name="GroupInfo"
@@ -47,7 +47,7 @@ background_visible="true"
      text_color="white"
      top="0"
      value="(Loading...)"
-     use_elipsis="true"
+     use_ellipses="true"
      width="300" />
     <line_editor
      follows="left|top"
@@ -60,7 +60,7 @@ background_visible="true"
      top_delta="5"
      width="250"
      height="20"
-     visible="true" />
+     visible="false" />
     <texture_picker
      follows="left|top"
      height="113"
@@ -112,33 +112,46 @@ background_visible="true"
      left_delta="0"
      top_pad="6"
      height="23"
-     label="Join now!"
-     label_selected="Join now!"
+     label="JOIN NOW!"
      name="btn_join"
      visible="true"
      width="120" />
    <accordion
              follows="all"
-             height="405"
+             height="425"
              layout="topleft"
              left="0"
+             multiple_expansion="false"
              name="groups_accordion"
-             top_pad="20"
-             width="333">
+             top_pad="15"
+             width="336">
              <accordion_tab
                  can_resize="false"
+                 expanded="true"
                  layout="topleft"
                  name="tab_general"
                  title="General">
-        <panel
-        border="false"
-         filename="panel_group_general.xml"
+         <scroll_container
+         color="DkGray2"
+         opaque="true"
+         height="323"
+         follows="all"
          layout="topleft"
          left="0"
-         help_topic="group_general_tab"
-         name="general_tab"
          top="0"
-         width="333" />
+         name="general_scroll"
+         reserve_scroll_corner="false"
+         width="333">
+            <panel
+            border="false"
+             filename="panel_group_general.xml"
+             layout="topleft"
+             left="0"
+             help_topic="group_general_tab"
+             name="general_tab"
+             top="0"
+             width="303" />
+         </scroll_container>
          </accordion_tab>
          <accordion_tab
                  can_resize="false"
@@ -146,15 +159,27 @@ background_visible="true"
                  layout="topleft"
                  name="tab_roles"
                  title="Roles">
-        <panel
-        border="false"
-         filename="panel_group_roles.xml"
-         layout="topleft"
-         left="0"
-         help_topic="group_roles_tab"
-         name="roles_tab"
-         top="0"
-         width="333" />
+               <scroll_container
+                  color="DkGray2"
+                  opaque="true"
+                  height="323"
+                  follows="all"
+                  layout="topleft"
+                  left="0"
+                  top="0"
+                  name="roles_scroll"
+                  reserve_scroll_corner="false"
+                  width="333">
+                 <panel
+                 border="false"
+                  filename="panel_group_roles.xml"
+                  layout="topleft"
+                  left="0"
+                  help_topic="group_roles_tab"
+                  name="roles_tab"
+                  top="0"
+             width="303" />
+         </scroll_container>
          </accordion_tab>
          <accordion_tab
                  can_resize="false"
@@ -162,21 +187,45 @@ background_visible="true"
                  layout="topleft"
                  name="tab_notices"
                  title="Notices">
+            <scroll_container
+                  color="DkGray2"
+                  opaque="true"
+                  height="323"
+                  follows="all"
+                  layout="topleft"
+                  left="0"
+                  top="0"
+                  name="notices_scroll"
+                  reserve_scroll_corner="false"
+                  width="333">
         <panel
+        border="false"
          filename="panel_group_notices.xml"
          layout="topleft"
          left="0"
          help_topic="group_notices_tab"
          name="notices_tab"
          top="0"
-         width="333" />
+         width="303" />
+         </scroll_container>
          </accordion_tab>
-                  <accordion_tab
+        <accordion_tab
                  can_resize="false"
                  expanded="false"
                  layout="topleft"
                  name="tab_notices"
                  title="Land/Assets">
+           <scroll_container
+                  color="DkGray2"
+                  opaque="true"
+                  height="323"
+                  follows="all"
+                  layout="topleft"
+                  left="0"
+                  top="0"
+                  name="land_scroll"
+                  reserve_scroll_corner="false"
+                  width="333">
         <panel
         border="false"
          filename="panel_group_land_money.xml"
@@ -185,41 +234,43 @@ background_visible="true"
          help_topic="group_land_money_tab"
          name="land_money_tab"
          top="0"
-         width="333" />
+         width="313" />
+         </scroll_container>
          </accordion_tab>
          </accordion>
-    <button
+   <button
      follows="top|left"
-     height="20"
+     height="22"
      image_overlay="Refresh_Off"
      layout="topleft"
+     left="5"
      name="btn_refresh"
      picture_style="true"
-     left="5"
-     width="20" />
-     <button
-     height="20"
-     font="SansSerifSmall"
-     label="Save"
-     label_selected="Save"
-     name="btn_apply"
-     left_pad="5"
-     width="65" />
-    <button
+     top_pad="-15"
+     width="23" />
+         <button
      height="20"
      label="Create"
-     label_selected="Create"
+     label_selected="New group"
      name="btn_create"
-     left_pad="5"
+     left_pad="10"
      visible="false"
-     width="65" />
-    <button
-     left_pad="5"
+     width="100" />
+   <!-- <button
+     left_pad="10"
      height="20"
      label="Cancel"
      label_selected="Cancel"
      name="btn_cancel"
      visible="false"
+     width="65" />-->
+     <button
+     height="20"
+     font="SansSerifSmall"
+     label="Save"
+     label_selected="Save"
+     name="btn_apply"
+     left_pad="10"
+     right="-10"
      width="65" />
-
 </panel>
\ No newline at end of file
diff --git a/indra/newview/skins/default/xui/en/panel_group_land_money.xml b/indra/newview/skins/default/xui/en/panel_group_land_money.xml
index c81c7113ae..99fc39c466 100644
--- a/indra/newview/skins/default/xui/en/panel_group_land_money.xml
+++ b/indra/newview/skins/default/xui/en/panel_group_land_money.xml
@@ -1,25 +1,25 @@
 <?xml version="1.0" encoding="utf-8" standalone="yes" ?>
 <panel
- border="true"
+ border="false"
  follows="all"
  height="510"
  label="Land &amp; L$"
  layout="topleft"
  left="1"
  name="land_money_tab"
- top="490"
- width="280">
+ top="0"
+ width="313">
     <panel.string
      name="help_text">
-        Parcels owned by the group are listed along with contribution details. A warning appears until the Total Land in Use is less than or equal to the Total Contribution. The Planning, Details, and Sales tabs provide information about the group&apos;s finances.
+        Parcels owned by a group are listed along with contribution details. A warning appears until the Total Land in Use is less than or = to the Total Contribution.
     </panel.string>
     <panel.string
      name="cant_view_group_land_text">
-        You do not have permission to view group owned land.
+        You don&apos;t have permission to view group owned land
     </panel.string>
     <panel.string
      name="cant_view_group_accounting_text">
-        You do not have permission to view the group&apos;s accounting information.
+        You don&apos;t have permission to view the group&apos;s accounting information.
     </panel.string>
     <panel.string
      name="loading_txt">
@@ -27,7 +27,7 @@
     </panel.string>
     <panel.string
      name="land_contrib_error">
-        Unable to set your land contribution.
+        Unable to set your land contribution
     </panel.string>
    <!-- <text
      type="string"
@@ -44,29 +44,29 @@
     <scroll_list
      draw_heading="true"
      follows="top"
-     heading_height="14"
-     height="100"
+     heading_height="20"
+     height="150"
      layout="topleft"
-     left="5"
+     left="0"
      name="group_parcel_list"
-     top_pad="10"
-     width="265">
+     top_pad="0"
+     width="313">
         <scroll_list.columns
          label="Parcel"
          name="name"
-         width="67" />
+         width="78" />
         <scroll_list.columns
          label="Region"
          name="location"
-         width="72" />
+         width="78" />
         <scroll_list.columns
          label="Type"
          name="type"
-         width="60" />
+         width="70" />
         <scroll_list.columns
          label="Area"
          name="area"
-         width="20" />
+         width="50" />
         <scroll_list.columns
          label=""
          name="hidden"
@@ -74,14 +74,14 @@
     </scroll_list>
     <button
      follows="top"
-     height="20"
+     height="23"
      label="Map"
      label_selected="Map"
      layout="topleft"
-     left="150"
      name="map_button"
-     top_pad="10"
-     width="125"
+     right="-10"
+     top_pad="5"
+     width="95"
      enabled="false" />
     <text
      type="string"
@@ -91,11 +91,12 @@
      layout="topleft"
      left="5"
      name="total_contributed_land_label"
-     top_pad="10"
+     top_pad="0"
      width="130">
         Total Contribution:
     </text>
     <text
+    text_color="EmphasisColor"
      type="string"
      follows="left|top"
      height="16"
@@ -119,6 +120,7 @@
         Total Land In Use:
     </text>
     <text
+    text_color="EmphasisColor"
      type="string"
      follows="left|top"
      height="16"
@@ -142,6 +144,7 @@
         Land Available:
     </text>
     <text
+    text_color="EmphasisColor"
      type="string"
      follows="left|top"
      height="16"
@@ -168,19 +171,19 @@
      border_style="line"
      border_thickness="1"
      follows="left|top"
-     height="16"
+     height="19"
      layout="topleft"
      left_pad="5"
      max_length="10"
      name="your_contribution_line_editor"
-     top_delta="-2"
+     top_delta="0"
      width="95" />
     <text
      type="string"
      follows="left|top"
      height="16"
      layout="topleft"
-     left_pad="5"
+     left_pad="3"
      name="your_contribution_units"
      top_delta="2">
         m²
@@ -193,13 +196,13 @@
      layout="topleft"
      left="140"
      name="your_contribution_max_value"
-     top_pad="0"
+     top_pad="2"
      width="95">
         ([AMOUNT] max)
     </text>
     <icon
      height="16"
-     image_name="smicon_warn.tga"
+     image_name="notify_next"
      layout="topleft"
      left="9"
      name="group_over_limit_icon"
@@ -211,14 +214,14 @@
      type="string"
      word_wrap="true"
      font="SansSerifSmall"
-     height="40"
+     height="35"
      layout="topleft"
-     left_pad="5"
+     left_pad="0"
      name="group_over_limit_text"
-     text_color="GroupOverTierColor"
+     text_color="EmphasisColor"
      top_delta="0"
-     width="250">
-        Group members must contribute more land credits to support land in use.
+     width="290">
+        Group members must contribute more land credits to support land in use
     </text>
     <text
      type="string"
@@ -242,128 +245,126 @@
      name="group_money_tab_container"
      tab_position="top"
      tab_height="20"
-     top_pad="10"
-     width="265">
+     top_pad="2"
+     tab_min_width="70"
+     width="300">
         <panel
-         border="true"
+         border="false"
          follows="all"
          height="180"
-         label="Planning"
+         label="PLANNING"
          layout="topleft"
-         left="1"
+         left="0"
          help_topic="group_money_planning_tab"
          name="group_money_planning_tab"
          top="5"
-         width="265">
+         width="300">
             <text_editor
              type="string"
-             bg_readonly_color="0.784314 0.819608 0.8 1"
              follows="all"
-             font="Monospace"
-             height="168"
+             font="SansSerif"
+             height="140"
              layout="topleft"
-             left="8"
+             left="0"
              max_length="4096"
              name="group_money_planning_text"
-             top="5"
-             width="250"
+             top="0"
+             width="300"
              word_wrap="true">
-                Computing...
+                Loading...
             </text_editor>
         </panel>
       <panel
-         border="true"
-         follows="left|top|right|bottom"
+         border="false"
+         follows="all"
          height="180"
-         label="Details"
+         label="DETAILS"
          layout="topleft"
-         left_delta="0"
+         left="0"
          help_topic="group_money_details_tab"
          name="group_money_details_tab"
-         top_delta="0"
-         width="265">
+         top="5"
+         width="300">
           <text_editor
              type="string"
-             bg_readonly_color="0.784314 0.819608 0.8 1"
              follows="all"
-             font="Monospace"
              height="140"
              layout="topleft"
-             left="8"
+             left="0"
              max_length="4096"
              name="group_money_details_text"
-             top="7"
-             width="250"
+             top="0"
+             width="300"
              word_wrap="true">
-                Computing...
+                Loading...
             </text_editor>
-          <button
-             height="20"
-             label="&lt; Earlier"
-             label_selected="&lt; Earlier"
-             layout="topleft"
-             left="5"
-             name="earlier_details_button"
-             tool_tip="Go back in time"
-             top_pad="10"
-             width="125" />
             <button
-             height="20"
-             label="Later &gt;"
-             label_selected="Later &gt;"
-             layout="topleft"
-             left_pad="5"
+	     follows="left|top"
+	     height="23"
+	     image_overlay="Arrow_Left_Off"
+	     layout="topleft"
+	     name="earlier_details_button"
+	     picture_style="true"
+	     tool_tip="Back"
+	     top_pad="3"
+             right="-35"
+	     width="31" />
+             <button
+	     follows="left|top"
+	     height="23"
+	     image_overlay="Arrow_Right_Off"
+	     layout="topleft"
+	     left_pad="10"
              name="later_details_button"
-             tool_tip="Go forward in time"
-             top_delta="0"
-             width="125" />
+	     picture_style="true"
+	     tool_tip="Next"
+	     width="31" />
         </panel>
       <panel
-         border="true"
-         follows="left|top|right|bottom"
+         border="false"
+         follows="all"
          height="180"
-         label="Sales"
+         label="SALES"
          layout="topleft"
          left_delta="0"
          help_topic="group_money_sales_tab"
          name="group_money_sales_tab"
          top_delta="-1"
-         width="265">
+         width="300">
             <text_editor
              type="string"
-             bg_readonly_color="0.784314 0.819608 0.8 1"
              follows="all"
-             font="Monospace"
              height="140"
              layout="topleft"
-             left="8"
+             left="0"
              max_length="4096"
              name="group_money_sales_text"
-             top="7"
-             width="250"
+             top="0"
+             width="300"
              word_wrap="true">
-                Computing...
+                Loading...
             </text_editor>
-            <button
-             height="20"
-             label="&lt; Earlier"
-             label_selected="&lt; Earlier"
-             layout="topleft"
-             left="5"
-             name="earlier_sales_button"
-             tool_tip="Go back in time"
-             top_pad="10"
-             width="125" />
-            <button
-             height="20"
-             label="Later &gt;"
-             label_selected="Later &gt;"
-             layout="topleft"
-             left_pad="5"
+                         <button
+	     follows="left|top"
+	     height="23"
+	     image_overlay="Arrow_Left_Off"
+	     layout="topleft"
+	     name="earlier_sales_button"
+	     picture_style="true"
+	     tool_tip="Back"
+	     top_pad="3"
+             right="-35"
+	     width="31" />
+             <button
+	     follows="left|top"
+	     height="23"
+	     image_overlay="Arrow_Right_Off"
+	     layout="topleft"
+	     left_pad="10"
              name="later_sales_button"
-             tool_tip="Go forward in time"
-             top_delta="0"
-             width="125" />
+	     picture_style="true"
+	     tool_tip="Next"
+	     width="31" />
         </panel>
     </tab_container>
 </panel>
diff --git a/indra/newview/skins/default/xui/en/panel_group_notices.xml b/indra/newview/skins/default/xui/en/panel_group_notices.xml
index 0e4d490369..bfb49a60c2 100644
--- a/indra/newview/skins/default/xui/en/panel_group_notices.xml
+++ b/indra/newview/skins/default/xui/en/panel_group_notices.xml
@@ -1,14 +1,13 @@
 <?xml version="1.0" encoding="utf-8" standalone="yes" ?>
 <panel
- border="true"
  follows="all"
  height="485"
  label="Notices"
  layout="topleft"
- left="1"
+ left="0"
  name="notices_tab"
- top="485"
- width="280">
+ top="0"
+ width="313">
     <panel.string
      name="help_text">
         Notices are a quick way to communicate across a 
@@ -20,60 +19,48 @@ the General tab.
     </panel.string>
     <panel.string
      name="no_notices_text">
-        There are no past notices.
+        There are no past notices
     </panel.string>
-     <!--<text
-      follows="left|top"
-     type="string"
-     font="SansSerifBig"
-     height="16"
-     layout="topleft"
-     left="10"
-     name="lbl"
-     top_pad="10"
-     width="269">
-        Group Notices Archive
-    </text> -->
     <text
       follows="left|top"
      type="string"
      word_wrap="true"
-     height="40"
+     height="30"
      layout="topleft"
-     left_delta="10"
+     left="10"
      name="lbl2"
-     text_color="EmphasisColor"
-     top_pad="10"
-     width="270">
-        Notices are kept for 14 days. Notice lists are limited to 200 notices per group on a daily basis.
+     top="5"
+     width="300">
+     Notices are kept for 14 days
+Groups are limited to 200 notices/group daily
     </text>
     <scroll_list
       follows="left|top"
      column_padding="0"
      draw_heading="true"
-     heading_height="14"
-     height="109"
+     heading_height="16"
+     height="125"
      layout="topleft"
-     left_delta="0"
+     left="0"
      name="notice_list"
      top_pad="0"
-     width="265">
+     width="303">
         <scroll_list.columns
          label=""
          name="icon"
-         width="16" />
+         width="20" />
         <scroll_list.columns
          label="Subject"
          name="subject"
-         width="100" />
+         width="125" />
         <scroll_list.columns
          label="From"
          name="from"
-         width="83" />
+         width="90" />
         <scroll_list.columns
          label="Date"
          name="date"
-         width="50" />
+         width="30" />
         <scroll_list.columns
          name="sort"
          width="-1" />
@@ -84,39 +71,42 @@ the General tab.
      layout="topleft"
      name="notice_list_none_found"
      visible="false">
-        None found.
+        None found
     </text>
-    <button
-      follows="left|top"
-     height="20"
-     font="SansSerifSmall"
-     label="New Notice"
-     label_selected="Create New Notice"
-     layout="topleft"
-     left_delta="0"
-     name="create_new_notice"
-     top_delta="4"
-     width="125" />
-    <button
-      follows="left|top"
-     height="20"
-     font="SansSerifSmall"
-     label="Refresh"
-     label_selected="Refresh List"
+         <button
+       follows="bottom|left"
+       height="18"
+       image_selected="AddItem_Press"
+       image_unselected="AddItem_Off"
+       image_disabled="AddItem_Disabled"
+       layout="topleft"
+       label="Create a new notice"
+       left="15"
+       name="create_new_notice"
+       picture_style="true"
+       tool_tip="Create a new notice"
+     top_delta="-5"
+       width="18" />
+     <button
+     follows="top|left"
+     height="22"
+     image_overlay="Refresh_Off"
      layout="topleft"
-     left_pad="12"
      name="refresh_notices"
-     top_delta="0"
-     width="125" />
+     picture_style="true"
+     right="-5"
+     top_delta="5"
+     width="23" />
     <panel
      follows="left|top"
-     height="268"
+     height="300"
      label="Create New Notice"
      layout="topleft"
      left="0"
-     name="panel_create_new_notice"
      top_pad="10"
-     width="265">
+     visible="false"
+     name="panel_create_new_notice"
+     width="303">
         <text
          follows="left|top"
          type="string"
@@ -127,30 +117,16 @@ the General tab.
          mouse_opaque="false"
          name="lbl"
          text_color="EmphasisColor"
-         top_pad="0"
-         width="265">
+         top="0"
+         width="200">
             Create a Notice
         </text>
-        <text
-         follows="left|top"
-         type="string"
-         word_wrap="true"
-         height="90"
-         layout="topleft"
-         left_delta="0"
-         name="lbl2"
-         text_color="EmphasisColor"
-         top_pad="4"
-         width="195">
-            You can add a single item to a notice by dragging it from your inventory to this panel. Attached items must be copiable and transferrable, and you can&apos;t send a folder.
-        </text>
         <text
          follows="left|top"
          type="string"
          halign="left"
          height="16"
          layout="topleft"
-         left_delta="0"
          name="lbl3"
          top_pad="10"
          width="60">
@@ -164,8 +140,7 @@ the General tab.
          left_pad="3"
          max_length="63"
          name="create_subject"
-         top_delta="-1"
-         width="200" />
+         width="220" />
         <text
          follows="left|top"
          type="string"
@@ -174,106 +149,100 @@ the General tab.
          layout="topleft"
          left="10"
          name="lbl4"
-         top_pad="10"
+         top_pad="5"
          width="60">
             Message:
         </text>
         <text_editor
-         height="75"
+         height="90"
          layout="topleft"
          left_pad="3"
          max_length="511"
          name="create_message"
          top_delta="0"
-         width="200"
+         width="220"
          word_wrap="true" />
         <text
          follows="left|top"
          type="string"
          halign="left"
-         height="16"
+         height="14"
          layout="topleft"
          left="10"
          name="lbl5"
-         top_pad="10"
-         width="60">
+         width="200">
             Attach:
         </text>
         <line_editor
          enabled="false"
-         height="16"
+         height="19"
          layout="topleft"
-         left_pad="3"
-         max_length="63"
+         max_length="90"
          mouse_opaque="false"
          name="create_inventory_name"
-         top_delta="0"
-         width="200" />
+         top_pad="2"
+         width="285" />
+        <text
+        text_color="EmphasisColor"
+         follows="left|top"
+         type="string"
+         halign="right"
+         height="34"
+         layout="topleft"
+         left="10"
+         name="string"
+         top_pad="15"
+         word_wrap="true"
+         width="150">
+            Drag here to attach something -- >
+        </text>
         <icon
-         height="16"
+         height="72"
+         image_name="DropTarget"
          layout="topleft"
-         left_delta="0"
-         name="create_inv_icon"
-         top_delta="0"
-         width="16" />
+         left_pad="10"
+         mouse_opaque="true"
+         name="drop_icon"
+         top_delta="-10"
+         width="72" />
         <button
          follows="left|top"
-         height="20"
-         font="SansSerifSmall"
-         label="Remove Attachment"
-         label_selected="Remove Attachment"
+         height="23"
+         label="Remove"
          layout="topleft"
-         left="10"
+         left="70"
          name="remove_attachment"
-         top_pad="10"
-         width="135" />
+         top_delta="45"
+         width="90" />
         <button
          follows="left|top"
-         height="20"
-         font="SansSerifSmall"
+         height="23"
          label="Send"
          label_selected="Send Notice"
          layout="topleft"
-         left_delta="138"
+         right="-10"
+         top_pad="20"
          name="send_notice"
-         top_delta="0"
-         width="125" />
-        <panel
-         bevel_style="in"
-         border="true"
-         height="71"
-         layout="topleft"
-         left="200"
-         name="drop_target2"
-         top="20"
-         width="71" />
-        <icon
-         height="59"
-         image_name="icon_groupnoticeinventory.tga"
-         layout="topleft"
-         left_delta="6"
-         mouse_opaque="true"
-         name="drop_icon"
-         top="26"
-         width="59" />
-        <group_drop_target
+         width="100" />
+      <group_drop_target
          height="466"
-         layout="topleft"
+         top="0"
          left="0"
+         layout="topleft"
          name="drop_target"
          tool_tip="Drag an inventory item onto the message box to send it with the notice. You must have permission to copy and transfer the object to send it with the notice."
-         top="-198"
-         width="280" />
+         width="295" />
    </panel> 
     <panel
      follows="left|top"
-     height="268"
+     height="300"
      label="View Past Notice"
      layout="topleft"
      left="0"
+     visible="true"
      name="panel_view_past_notice"
-     top="197"
-     width="265">
+     top="180"
+     width="303">
         <text
          type="string"
          font="SansSerifBig"
@@ -294,9 +263,9 @@ the General tab.
          layout="topleft"
          left_delta="0"
          name="lbl2"
-         top_pad="4"
+         top_pad="2"
          width="265">
-            To send a new notice, click the &apos;New Notice&apos; button above.
+            To send a new notice, click the + button
         </text>
         <text
          type="string"
@@ -305,7 +274,7 @@ the General tab.
          layout="topleft"
          left_delta="0"
          name="lbl3"
-         top_pad="24"
+         top_pad="15"
          visible="false"
          width="60">
             Subject:
@@ -336,13 +305,13 @@ the General tab.
         </text>
         <text_editor
          enabled="false"
-         height="150"
+         height="205"
          layout="topleft"
          left="10"
          max_length="511"
          name="view_message"
          top_delta="-35"
-         width="260"
+         width="285"
          word_wrap="true" />
         <line_editor
          enabled="false"
@@ -353,7 +322,7 @@ the General tab.
          mouse_opaque="false"
          name="view_inventory_name"
          top_pad="10"
-         width="260" />
+         width="285" />
         <icon
          height="16"
          layout="topleft"
@@ -363,14 +332,12 @@ the General tab.
          width="16" />
         <button
          follows="left|top"
-         height="20"
-         font="SansSerifSmall"
-         label="Open Attachment"
-         label_selected="Open Attachment"
+         height="23"
+         label="Open attachment"
          layout="topleft"
-         left_delta="0"
+         right="-10"
          name="open_attachment"
-         top_pad="10"
+         top_pad="5"
          width="135" />
         </panel>
 </panel>
diff --git a/indra/newview/skins/default/xui/en/panel_group_roles.xml b/indra/newview/skins/default/xui/en/panel_group_roles.xml
index e87859f788..5ed464bcec 100644
--- a/indra/newview/skins/default/xui/en/panel_group_roles.xml
+++ b/indra/newview/skins/default/xui/en/panel_group_roles.xml
@@ -1,7 +1,7 @@
 <?xml version="1.0" encoding="utf-8" standalone="yes" ?>
 <panel
  border="false"
- height="412"
+ height="552"
  label="Members &amp; Roles"
  layout="topleft"
  left="0"
@@ -18,158 +18,28 @@
     </panel.string>
     <panel.string
      name="help_text" />
-    <!--<panel
-     follows="left|top"
-     height="80"
-     layout="topleft"
-     left="10"
-     name="members_header"
-     top_pad="10"
-     width="270">
-        <text
-         type="string"
-         font="SansSerifBig"
-         height="16"
-         layout="topleft"
-         left="0"
-         name="static"
-         top="0"
-         width="270">
-            Members &amp; Roles
-        </text>
-        <text
-         type="string"
-         word_wrap="true"
-         height="40"
-         layout="topleft"
-         left_delta="0"
-         name="static2"
-         top_pad="4"
-         width="270">
-            Group Members are assigned Roles with Abilities. These settings can easily be customized, allowing for greater organization and flexibility.
-        </text>
-    </panel>
-    <panel
-     follows="left|top"
-     height="24"
-     layout="topleft"
-     left_delta="0"
-     name="roles_header"
-     top_delta="0"
-     visible="false"
-     width="270">
-        <text
-         type="string"
-         font="SansSerifBig"
-         height="16"
-         layout="topleft"
-         left="0"
-         name="static"
-         top="0"
-         width="270">
-            Roles
-        </text>
-        <text
-         type="string"
-         word_wrap="true"
-         height="40"
-         layout="topleft"
-         left_delta="0"
-         name="role_properties_modifiable"
-         top_pad="4"
-         visible="false"
-         width="270">
-            Select a Role below.  You can modify its Name, Description and Member Title.
-        </text>
-        <text
-         type="string"
-         word_wrap="true"
-         height="40"
-         layout="topleft"
-         left_delta="0"
-         name="role_properties_not_modifiable"
-         top_delta="0"
-         width="270">
-            Select a Role below to see its properties, Members and allowed Abilities.
-        </text>
-        <text
-         type="string"
-         word_wrap="true"
-         height="16"
-         layout="topleft"
-         left_delta="0"
-         name="role_actions_modifiable"
-         top_delta="24"
-         visible="false"
-         width="270">
-            You can also assign Abilities to the Role.
-        </text>
-        <text
-         type="string"
-         word_wrap="true"
-         height="16"
-         layout="topleft"
-         left_delta="0"
-         name="role_actions_not_modifiable"
-         top_delta="0"
-         width="270">
-            You may view, but not modify, assigned Abilities.
-        </text>
-    </panel>
-    <panel
-     follows="left|top"
-     height="24"
-     layout="topleft"
-     left_delta="0"
-     name="actions_header"
-     top_delta="0"
-     visible="false"
-     width="270">
-        <text
-         type="string"
-         font="SansSerifBig"
-         height="16"
-         layout="topleft"
-         left="0"
-         name="static"
-         top="0"
-         width="270">
-            Abilities
-        </text>
-        <text
-         type="string"
-         word_wrap="true"
-         height="40"
-         layout="topleft"
-         left_delta="0"
-         name="static2"
-         top_pad="4"
-         width="270">
-            You can view an Ability&apos;s Description and which Roles and Members can execute the Ability.
-        </text>
-    </panel> -->
     <tab_container
-    border="true"
+    border="false"
      follows="left|top"
-     height="260"
+     height="245"
      halign="center"
      layout="topleft"
      left="5"
      name="roles_tab_container"
      tab_position="top"
      tab_height="20"
-     top="0"
+     tab_min_width="96"
+     top="3"
      width="303">
         <panel
          border="false"
-         height="260"
-         label="Members"
+         height="220"
+         label="MEMBERS"
          layout="topleft"
-         left="1"
+         left="0"
          help_topic="roles_members_tab"
          name="members_sub_tab"
          tool_tip="Members"
-         top="17"
          class="panel_group_members_subtab"
          width="300">
             <panel.string
@@ -187,8 +57,7 @@ clicking on their names.
          follows="left|top|right"
          max_length="250"
          label="Filter Members"
-         name="filter_input"
-         font="SansSerif" />
+         name="filter_input" />
           <!--  <button
              enabled="false"
              font="SansSerifSmall"
@@ -229,6 +98,7 @@ clicking on their names.
              font="SansSerifSmall"
              label="Invite"
              layout="topleft"
+             left="5"
              name="member_invite"
              top_pad="3"
              width="100" />
@@ -238,8 +108,10 @@ clicking on their names.
              label="Eject"
              layout="topleft"
              left_pad="5"
+             right="-5"
              name="member_eject"
              width="100" />
+             <!--What is this?-->
             <icon
              height="16"
              image_name="Inv_FolderClosed"
@@ -250,15 +122,14 @@ clicking on their names.
         </panel>
         <panel
          border="false"
-         height="164"
-         label="Roles"
+         height="220"
+         label="ROLES"
          layout="topleft"
-         left_delta="0"
+         left="0"
          help_topic="roles_roles_tab"
          name="roles_sub_tab"
          class="panel_group_roles_subtab"
-         top="17"
-         width="265">
+         width="300">
             <panel.string
              name="help_text">
                 Roles have a title and an allowed list of Abilities
@@ -282,40 +153,19 @@ including the Everyone and Owner Roles.
              name="power_partial_icon">
                 checkbox_enabled_false.tga
             </panel.string>
-            <filter_editor
-            layout="topleft"
-            top="10"
-            left="4"
-            width="260"
-            height="20"
-            follows="left|top|right"
-            max_length="250"
-            label="Filter Roles"
-            name="filter_input"
-            font="SansSerif" />
-            <!--<line_editor
-             border_style="line"
-             border_thickness="1"
-             follows="left|top"
-             height="16"
-             layout="topleft"
-             left="4"
-             max_length="63"
-             name="search_text"
-             top="10"
-             width="90" />
-            <button
-             font="SansSerifSmall"
-             height="20"
-             label="Search"
-             layout="topleft"
-             left_pad="5"
-             name="search_button"
-             top_delta="-2"
-             width="80" />
+         <filter_editor
+         layout="topleft"
+         top="10"
+         left="4"
+         width="280"
+         height="20"
+         follows="left|top|right"
+         max_length="250"
+         label="Filter Roles"
+         name="filter_input" />
+            <!--
             <button
              enabled="false"
-             font="SansSerifSmall"
              height="20"
              label="Show All"
              layout="topleft"
@@ -326,11 +176,13 @@ including the Everyone and Owner Roles.
             <scroll_list
              column_padding="0"
              draw_heading="true"
+             draw_stripes="false"
              follows="left|top"
              heading_height="20"
              height="150"
              layout="topleft"
-             left="4"
+             search_column="1"
+             left="0"
              name="role_list"
              top_pad="4"
              width="300">
@@ -352,7 +204,7 @@ including the Everyone and Owner Roles.
              font="SansSerifSmall"
              label="Add Role"
              layout="topleft"
-             left_delta="0"
+             left="5"
              name="role_create"
              top_pad="6"
              width="125" />
@@ -362,20 +214,20 @@ including the Everyone and Owner Roles.
              label="Delete Role"
              layout="topleft"
              left_pad="5"
+             right="-5"
              name="role_delete"
              top_delta="0"
              width="125" />
         </panel>
         <panel
          border="false"
-         height="164"
-         label="Abilities"
+         height="220"
+         label="ABILITIES"
          layout="topleft"
-         left_delta="0"
+         left="0"
          help_topic="roles_actions_tab"
          name="actions_sub_tab"
          class="panel_group_actions_subtab"
-         top="17"
          tool_tip="You can view an Ability&apos;s Description and which Roles and Members can execute the Ability."
          width="300">
             <panel.string
@@ -383,37 +235,17 @@ including the Everyone and Owner Roles.
                 Abilities allow Members in Roles to do specific
 things in this group. There&apos;s a broad variety of Abilities.
             </panel.string>
-            <filter_editor
-            layout="topleft"
-            top="10"
-            left="4"
-            width="255"
-            height="20"
-            follows="left|top|right"
-            max_length="250"
-            label="Filter Abilities"
-            name="filter_input"
-            font="SansSerif" />
-            <!--<line_editor
-             border_style="line"
-             border_thickness="1"
-             follows="left|top"
-             height="16"
-             layout="topleft"
-             left="4"
-             max_length="63"
-             name="search_text"
-             top="10"
-             width="90" />
-            <button
-             font="SansSerifSmall"
-             height="20"
-             label="Search"
-             layout="topleft"
-             left_pad="5"
-             name="search_button"
-             top_delta="-2"
-             width="80" />
+         <filter_editor
+         layout="topleft"
+         top="10"
+         left="4"
+         width="280"
+         height="20"
+         follows="left|top|right"
+         max_length="250"
+         label="Filter Abilities"
+         name="filter_input" />
+            <!--
             <button
              enabled="false"
              font="SansSerifSmall"
@@ -428,19 +260,19 @@ things in this group. There&apos;s a broad variety of Abilities.
              column_padding="0"
              draw_stripes="false"
              follows="left|top"
-             height="100"
+             height="160"
              layout="topleft"
-             left="6"
+             left="0"
              multi_select="true"
              name="action_list"
              search_column="1"
              tool_tip="Select an Ability to view more details"
              top_pad="6"
-             width="255">
+             width="300">
                 <scroll_list.columns
                  label=""
                  name="icon"
-                 width="18" />
+                 width="16" />
                 <scroll_list.columns
                  label=""
                  name="action"
@@ -448,7 +280,7 @@ things in this group. There&apos;s a broad variety of Abilities.
             </scroll_list>
             <icon
              height="16"
-             image_name="inv_folder_plain_closed.tga"
+             image_name="Inv_FolderClosed"
              layout="topleft"
              name="power_folder_icon"
              visible="false"
@@ -456,105 +288,93 @@ things in this group. There&apos;s a broad variety of Abilities.
         </panel>
     </tab_container>
     <panel
-     height="150"
+     height="252"
      layout="topleft"
      follows="left|top"
      left="10"
      name="members_footer"
-     top_pad="2"
+     top_pad="10"
+     top_delta="0"
      width="300">
         <text
          type="string"
-         font="SansSerif"
          height="16"
          layout="topleft"
          follows="left|top"
          left="0"
          name="static"
-         top_pad="0"
-         width="100">
+         top_pad="5"
+         width="295">
             Assigned Roles
         </text>
-        <text
-         type="string"
-         font="SansSerif"
-         height="16"
-         layout="topleft"
-         follows="left|top"
-         left_pad="35"
-         name="static2"
-         top_delta="0"
-         width="100">
-            Allowed Abilities
-        </text>
         <scroll_list
          draw_stripes="false"
          follows="left|top"
-         height="150"
+         height="80"
          layout="topleft"
          left="0"
          name="member_assigned_roles"
-         top_pad="5"
-         width="130">
+         top_pad="0"
+         width="295">
             <scroll_list.columns
              label=""
              name="checkbox"
-             width="18" />
+             width="30" />
             <scroll_list.columns
              label=""
              name="role"
-             width="107" />
+             width="265" />
         </scroll_list>
-        <scroll_list
-         draw_stripes="false"
-         height="150"
+                 <text
+         type="string"
+         height="16"
          layout="topleft"
          follows="left|top"
-         left_pad="5"
+         left="0"
+         name="static2"
+         top_pad="5"
+         width="295">
+            Allowed Abilities
+        </text>
+         <scroll_list
+         draw_stripes="false"
+         height="80"
+         layout="topleft"
+         left="0"
          name="member_allowed_actions"
+         search_column="2"
          tool_tip="For details of each allowed ability see the abilities tab"
-         top_delta="0"
-         width="130">
+         top_pad="0"
+         width="295">
             <scroll_list.columns
              label=""
              name="icon"
-             width="14" />
+             width="20" />
             <scroll_list.columns
              label=""
              name="action"
-             width="126" />
+             width="275" />
         </scroll_list>
     </panel>
     <panel
-     height="252"
+     height="297"
      layout="topleft"
-     left_delta="0"
+     left="10"
      name="roles_footer"
      top_delta="0"
+     top="245"
      visible="false"
-     width="270">
+     width="300">
         <text
          type="string"
-         font="SansSerif"
          height="16"
          layout="topleft"
          left="0"
          name="static"
          top="0"
-         width="100">
+         width="140">
             Name
         </text>
-        <text
-         type="string"
-         font="SansSerif"
-         height="16"
-         layout="topleft"
-         left_pad="35"
-         name="static2"
-         top_delta="0"
-         width="100">
-            Description
-        </text>
         <line_editor
          type="string"
          border_style="line"
@@ -563,21 +383,19 @@ things in this group. There&apos;s a broad variety of Abilities.
          height="20"
          layout="topleft"
          left="0"
-         max_length="20"
+         max_length="295"
          name="role_name"
          top_pad="0"
-         width="130">
+         width="295">
             Employees
         </line_editor>
         <text
          type="string"
-         font="SansSerif"
          height="16"
          layout="topleft"
-         left_delta="0"
          name="static3"
-         top_pad="10"
-         width="100">
+         top_pad="5"
+         width="295">
             Title
         </text>
         <line_editor
@@ -587,158 +405,159 @@ things in this group. There&apos;s a broad variety of Abilities.
          follows="left|top"
          height="20"
          layout="topleft"
-         left_delta="0"
-         max_length="20"
+         max_length="295"
          name="role_title"
          top_pad="0"
-         width="130">
-            (waiting)
+         width="295">
+          (waiting)
         </line_editor>
+                <text
+         type="string"
+         height="16"
+         layout="topleft"
+         left="0"
+         name="static2"
+         top_pad="5"
+         width="100">
+            Description
+        </text>
         <text_editor
          type="string"
          halign="left"
-         height="48"
+         height="35"
          layout="topleft"
-         left="135"
-         max_length="254"
+         left="0"
+         max_length="295"
          name="role_description"
-         top="16"
-         width="130"
+         top_pad="0"
+         width="295"
          word_wrap="true">
-            (waiting)
+          (waiting)
         </text_editor>
         <text
          type="string"
-         font="SansSerif"
          height="16"
          layout="topleft"
+         follows="left|top"
          left="0"
-         name="static4"
-         top="85"
-         width="120">
-            Assigned Members
-        </text>
-        <text
-         type="string"
-         font="SansSerif"
-         height="16"
-         layout="topleft"
-         left_pad="15"
-         name="static5"
-         tool_tip="A list of abilities the currently selected role can perform"
-         top_delta="0"
-         width="100">
-            Allowed Abilities
+         name="static"
+         top_pad="5"
+         width="295">
+            Assigned Roles
         </text>
         <name_list
          draw_stripes="false"
-         height="150"
+         height="50"
          layout="topleft"
          left="0"
          name="role_assigned_members"
          top_pad="0"
-         width="130" />
+         width="295" />
         <check_box
-         height="16"
-         label="Members are visible"
+         height="15"
+         label="Reveal members"
          layout="topleft"
-         left_delta="0"
          name="role_visible_in_list"
          tool_tip="Sets whether members of this role are visible in the General tab to people outside of the group."
-         top_pad="10"
-         width="130" />
+         top_pad="3"
+         width="290" />
+         <text
+         type="string"
+         height="16"
+         layout="topleft"
+         follows="left|top"
+         left="0"
+         name="static2"
+         top_pad="5"
+         width="295">
+            Allowed Abilities
+        </text>
         <scroll_list
          draw_stripes="false"
-         height="150"
+         height="50"
          layout="topleft"
-         left="135"
+         left="0"
          name="role_allowed_actions"
          search_column="2"
          tool_tip="For details of each allowed ability see the abilities tab"
-         top="101"
-         width="130">
+         top_pad="0"
+         width="295">
             <scroll_list.columns
              label=""
              name="icon"
-             width="2" />
+             width="20" />
             <scroll_list.columns
              label=""
              name="checkbox"
-             width="16" />
+             width="20" />
             <scroll_list.columns
              label=""
              name="action"
-             width="220" />
+             width="250" />
         </scroll_list>
     </panel>
    <panel
-     height="215"
+     height="303"
      layout="topleft"
-     left_delta="0"
+     left="10"
      name="actions_footer"
      top_delta="0"
+     top="245"
      visible="false"
-     width="265">
+     width="300">
         <text
          type="string"
-         font="SansSerif"
          height="16"
          layout="topleft"
-         left="0"
          name="static"
-         top="0"
          width="200">
-            Description
+            Ability description
         </text>
         <text_editor
          type="string"
          enabled="false"
          halign="left"
-         height="48"
+         height="80"
          layout="topleft"
          left_delta="0"
          max_length="512"
          name="action_description"
          top_pad="0"
-         width="265"
+         width="295"
          word_wrap="true">
             This Ability is &apos;Eject Members from this Group&apos;. Only an Owner can eject another Owner.
         </text_editor>
         <text
          type="string"
-         font="SansSerif"
          height="16"
          layout="topleft"
          left_delta="0"
          name="static2"
-         top_pad="10"
-         width="125">
-            Roles with Ability
+         top_pad="5"
+         width="295">
+            Roles with this ability
         </text>
-        <text
+        <scroll_list
+         height="60"
+         layout="topleft"
+         left="0"
+         name="action_roles"
+         top_pad="0"
+         width="295" />
+                 <text
          type="string"
-         font="SansSerif"
          height="16"
          layout="topleft"
-         left_pad="10"
          name="static3"
-         top_delta="0"
-         width="125">
-            Members with Ability
+         top_pad="5"
+         width="295">
+            Members with this ability
         </text>
-        <scroll_list
-         height="150"
-         layout="topleft"
-         left="0"
-         name="action_roles"
-         top="90"
-         width="130" />
         <name_list
-         height="150"
+         height="100"
          layout="topleft"
-         left_pad="5"
          name="action_members"
-         top_delta="0"
-         width="130" />
+         top_pad="0"
+         width="295" />
     </panel>
 </panel>
diff --git a/indra/newview/skins/default/xui/en/panel_im_control_panel.xml b/indra/newview/skins/default/xui/en/panel_im_control_panel.xml
index c4cdaa41f9..0dd3878426 100644
--- a/indra/newview/skins/default/xui/en/panel_im_control_panel.xml
+++ b/indra/newview/skins/default/xui/en/panel_im_control_panel.xml
@@ -1,30 +1,35 @@
 <?xml version="1.0" encoding="utf-8" standalone="yes" ?>
 <panel name="panel_im_control_panel"
-       width="125"
-       height="248"
+       width="128"
+       height="327"
        border="false">
 
   <avatar_icon name="avatar_icon"
-               width="96"
-               height="96" />
+               follows="left|top"
+               left_delta="3"
+               width="125"
+               height="125" />
 
   <button name="view_profile_btn"
+          follows="left|bottom"
           label="View Profile"
-          left_delta="3"
           width="125"
 		  height="20" />
 
   <button name="add_friend_btn"
+          follows="left|bottom"
           label="Add Friend"
           width="125"
           height="20" />
 
   <button name="call_btn"
+          follows="left|bottom"
           label="Call"
           width="125"
           height="20" />
 
     <button
+     follows="left|bottom"
      height="20"
      label="End Call"
      name="end_call_btn"
@@ -33,15 +38,27 @@
 
   <button
 	 enabled="false"
+     follows="left|bottom"
      name="voice_ctrls_btn"
      label="Open Voice Controls"
      width="125"
      height="20"
      visible="false"/>
 
+  <button name="teleport_btn"
+          follows="left|bottom"
+          label="Teleport"
+          width="125"
+          height="20" />
   <button name="share_btn"
+          follows="left|bottom"
           label="Share"
           width="125"
           height="20" />
+  <button name="pay_btn"
+          follows="left|bottom"
+          label="Pay"
+          width="125"
+          height="20" />
 
 </panel>
diff --git a/indra/newview/skins/default/xui/en/panel_landmark_info.xml b/indra/newview/skins/default/xui/en/panel_landmark_info.xml
new file mode 100644
index 0000000000..03ba7f7c81
--- /dev/null
+++ b/indra/newview/skins/default/xui/en/panel_landmark_info.xml
@@ -0,0 +1,257 @@
+<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
+<panel
+ background_visible="true"
+ follows="all"
+ height="570"
+ layout="topleft"
+ left="0"
+ min_height="350"
+ name="landmark_info"
+ top="20"
+ width="330">
+    <string
+     name="title_create_landmark"
+     value="Create Landmark" />
+    <string
+     name="title_edit_landmark"
+     value="Edit Landmark" />
+    <string
+     name="title_landmark"
+     value="Landmark" />
+    <string
+     name="not_available"
+     value="(N\A)" />
+    <string
+     name="unknown"
+     value="(unknown)" />
+    <string
+     name="public"
+     value="(public)" />
+    <string
+     name="server_update_text">
+        Place information not available without server update.
+    </string>
+    <string
+     name="server_error_text">
+        Information about this location is unavailable at this time, please try again later.
+    </string>
+    <string
+     name="server_forbidden_text">
+        Information about this location is unavailable due to access restrictions.  Please check your permissions with the parcel owner.
+    </string>
+    <string
+     name="acquired_date">
+        [wkday,datetime,local] [mth,datetime,local] [day,datetime,local] [hour,datetime,local]:[min,datetime,local]:[second,datetime,local] [year,datetime,local]
+    </string>
+    <button
+     follows="top|right"
+     height="23"
+     image_overlay="BackArrow_Off"
+     layout="topleft"
+     left="10"
+     name="back_btn"
+     picture_style="true"
+     tab_stop="false"
+     top="0"
+     width="23" />
+    <text
+     follows="top|left|right"
+     font="SansSerifHugeBold"
+     height="26"
+     layout="topleft"
+     left_pad="10"
+     name="title"
+     text_color="white"
+     top="0"
+     use_ellipses="true"
+     value="Place Profile"
+     width="275" />
+    <scroll_container
+     color="DkGray2"
+     follows="all"
+     height="533"
+     layout="topleft"
+     left="10"
+     name="place_scroll"
+     opaque="true"
+     top_pad="5"
+     width="313">
+        <panel
+         bg_alpha_color="DkGray2"
+         follows="all"
+         height="533"
+         layout="topleft"
+         left="0"
+         min_height="300"
+         name="scrolling_panel"
+         top="0"
+         width="313">
+            <texture_picker
+             enabled="false"
+             follows="top|left"
+             height="190"
+             layout="topleft"
+             left="10"
+             name="logo"
+             top="10"
+             width="290" />
+            <text
+             follows="left|top|right"
+             font="SansSerifLarge"
+             height="14"
+             layout="topleft"
+             left="10"
+             name="region_title"
+             text_color="white"
+             top_pad="5"
+             use_ellipses="true"
+             value="SampleRegion"
+             width="290" />
+            <text
+             follows="left|top|right"
+             height="14"
+             layout="topleft"
+             left="10"
+             name="parcel_title"
+             top_pad="4"
+             use_ellipses="true"
+             value="SampleParcel, Name Long (145, 228, 26)"
+             width="285" />
+            <expandable_text
+             follows="left|top|right"
+             height="50"
+             layout="topleft"
+             left="5"
+             name="description"
+             top_pad="10"
+             value="Du waltz die spritz"
+             width="300" />
+            <panel
+             follows="left|top|right"
+             height="55"
+             layout="topleft"
+             left="10"
+             name="landmark_info_panel"
+             top_pad="10"
+             width="290">
+                <text
+                 follows="left|top"
+                 height="15"
+                 layout="topleft"
+                 left="0"
+                 name="owner_label"
+                 top_pad="10"
+                 value="Owner:"
+                 width="90" />
+                <text
+                 follows="left|top|right"
+                 height="15"
+                 layout="topleft"
+                 left="70"
+                 name="owner"
+                 top_delta="0"
+                 width="200" />
+                <text
+                 follows="left|top"
+                 height="15"
+                 layout="topleft"
+                 left="0"
+                 name="creator_label"
+                 value="Creator:"
+                 width="90" />
+                <text
+                 follows="left|top|right"
+                 height="15"
+                 layout="topleft"
+                 left="70"
+                 name="creator"
+                 top_delta="0"
+                 width="200" />
+                <text
+                 follows="left|top"
+                 height="15"
+                 layout="topleft"
+                 left="0"
+                 name="created_label"
+                 value="Created:"
+                 width="50" />
+                <text
+                 follows="left|top|right"
+                 height="15"
+                 layout="topleft"
+                 left="70"
+                 name="created"
+                 top_delta="0"
+                 width="200" />
+            </panel>
+            <panel
+             follows="left|top|right"
+             height="210"
+             layout="topleft"
+             left="10"
+             name="landmark_edit_panel"
+             width="290">
+                <text
+                 follows="left|top"
+                 height="15"
+                 layout="topleft"
+                 left="0"
+                 name="title_label"
+                 top_pad="10"
+                 value="Title:"
+                 width="290" />
+                <line_editor
+                 background_image_disabled="task_panel_background.png"
+                 follows="left|top|right"
+                 height="22"
+                 layout="topleft"
+                 left="0"
+                 max_length="63"
+                 name="title_editor"
+                 prevalidate_callback="ascii"
+                 text_readonly_color="white"
+                 top_pad="5"
+                 width="290" />
+                <text
+                 follows="left|top"
+                 height="15"
+                 layout="topleft"
+                 left="0"
+                 name="notes_label"
+                 top_pad="10"
+                 value="My notes:"
+                 width="290" />
+                <text_editor
+                 bg_readonly_color="DkGray2"
+                 follows="all"
+                 height="70"
+                 layout="topleft"
+                 left="0"
+                 max_length="127"
+                 name="notes_editor"
+                 read_only="true"
+                 text_readonly_color="white"
+                 top_pad="5"
+                 width="290"
+                 wrap="true" />
+                <text
+                 follows="left|top"
+                 height="15"
+                 layout="topleft"
+                 left="0"
+                 name="folder_label"
+                 top_pad="15"
+                 value="Landmark location:"
+                 width="290" />
+                <combo_box
+                 follows="bottom|left|right"
+                 height="20"
+                 layout="topleft"
+                 left="0"
+                 name="folder_combo"
+                 top_pad="5"
+                 width="200" />
+            </panel>
+        </panel>
+    </scroll_container>
+</panel>
diff --git a/indra/newview/skins/default/xui/en/panel_landmarks.xml b/indra/newview/skins/default/xui/en/panel_landmarks.xml
index 5293043ba7..91fcf4b5f2 100644
--- a/indra/newview/skins/default/xui/en/panel_landmarks.xml
+++ b/indra/newview/skins/default/xui/en/panel_landmarks.xml
@@ -31,7 +31,7 @@
              left="0"
              mouse_opaque="true"
              name="favorites_list"
-             start_folder="favorite"
+             start_folder="Favorite"
              width="380"/>
         </accordion_tab>
         <accordion_tab
@@ -47,7 +47,7 @@
              left="0"
              mouse_opaque="true"
              name="landmarks_list"
-             start_folder="landmark"
+             start_folder="Landmarks"
              width="380"/>
         </accordion_tab>
         <accordion_tab
@@ -63,13 +63,13 @@
              left="0"
              mouse_opaque="true"
              name="my_inventory_list"
-             start_folder="inventory"
+             start_folder="INVENTORY"
              width="380"/>
-        </accordion_tab>
-        <accordion_tab
-         layout="topleft"
-         name="tab_library"
-         title="Library">
+          </accordion_tab>
+          <accordion_tab
+           layout="topleft"
+           name="tab_library"
+           title="Library">
             <inventory_subtree_panel
              allow_multi_select="true"
              border="true"
@@ -79,7 +79,7 @@
              left="0"
              mouse_opaque="true"
              name="library_list"
-             start_folder="library"
+             start_folder="LIBRARY"
              width="380"/>
         </accordion_tab>
     </accordion>
diff --git a/indra/newview/skins/default/xui/en/panel_nearby_chat_bar.xml b/indra/newview/skins/default/xui/en/panel_nearby_chat_bar.xml
index 2182163da5..555fedb1ff 100644
--- a/indra/newview/skins/default/xui/en/panel_nearby_chat_bar.xml
+++ b/indra/newview/skins/default/xui/en/panel_nearby_chat_bar.xml
@@ -42,13 +42,17 @@
      width="20" />
     <button
      follows="right"
+     is_toggle="true"
      width="45"
      top="0"
      layout="topleft"
      left_pad="8"
      label="Log"
      height="23"
+     name="show_nearby_chat"
      tool_tip="Show/hide nearby chat log">
-    <button.commit_callback function="Floater.Toggle" parameter="nearby_chat"/>
+        <button.init_callback
+           function="Button.SetDockableFloaterToggle"
+           parameter="nearby_chat" />
     </button>
 </panel>
diff --git a/indra/newview/skins/default/xui/en/panel_pick_info.xml b/indra/newview/skins/default/xui/en/panel_pick_info.xml
index a67ae59b4a..3cc9c3f38a 100644
--- a/indra/newview/skins/default/xui/en/panel_pick_info.xml
+++ b/indra/newview/skins/default/xui/en/panel_pick_info.xml
@@ -30,7 +30,7 @@
      text_color="white"
      top="0"
      value="Pick Info"
-     use_elipsis="true"
+     use_ellipses="true"
      width="275" />
     <scroll_container
      color="DkGray2"
diff --git a/indra/newview/skins/default/xui/en/panel_place_profile.xml b/indra/newview/skins/default/xui/en/panel_place_profile.xml
new file mode 100644
index 0000000000..7e073f064d
--- /dev/null
+++ b/indra/newview/skins/default/xui/en/panel_place_profile.xml
@@ -0,0 +1,979 @@
+<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
+<panel
+ background_visible="true"
+ follows="all"
+ height="570"
+ layout="topleft"
+ left="0"
+ min_height="350"
+ name="place_profile"
+ top="20"
+ width="330">
+    <string
+     name="on"
+     value="On" />
+    <string
+     name="off"
+     value="Off" />
+    <string
+     name="anyone"
+     value="Anyone" />
+    <string
+     name="available"
+     value="available" />
+    <string
+     name="allocated"
+     value="allocated" />
+    <string
+     name="title_place"
+     value="Place Profile" />
+    <string
+     name="title_teleport_history"
+     value="Teleport History Location" />
+    <string
+     name="not_available"
+     value="(N\A)" />
+    <string
+     name="unknown"
+     value="(unknown)" />
+    <string
+     name="public"
+     value="(public)" />
+    <string
+     name="none_text"
+     value="(none)" />
+    <string
+     name="sale_pending_text"
+     value="(Sale Pending)" />
+    <string
+     name="group_owned_text"
+     value="(Group Owned)" />
+    <string
+     name="price_text"
+     value="L$" />
+    <string
+     name="area_text"
+     value="m²" />
+    <string
+     name="all_residents_text"
+     value="All Residents" />
+    <string
+     name="group_text"
+     value="Group" />
+    <string
+     name="can_resell">
+        Purchased land in this region may be resold.
+    </string>
+    <string
+     name="can_not_resell">
+        Purchased land in this region may not be resold.
+    </string>
+    <string
+     name="can_change">
+        Purchased land in this region may be joined or subdivided.
+    </string>
+    <string
+     name="can_not_change">
+        Purchased land in this region may not be joined or subdivided.
+    </string>
+    <string
+     name="server_update_text">
+        Place information not available without server update.
+    </string>
+    <string
+     name="server_error_text">
+        Information about this location is unavailable at this time, please try again later.
+    </string>
+    <string
+     name="server_forbidden_text">
+        Information about this location is unavailable due to access restrictions.  Please check your permissions with the parcel owner.
+    </string>
+    <string
+     name="acquired_date">
+        [wkday,datetime,local] [mth,datetime,local] [day,datetime,local] [hour,datetime,local]:[min,datetime,local]:[second,datetime,local] [year,datetime,local]
+    </string>
+    <button
+     follows="top|right"
+     height="23"
+     image_overlay="BackArrow_Off"
+     layout="topleft"
+     left="10"
+     name="back_btn"
+     picture_style="true"
+     tab_stop="false"
+     top="0"
+     width="23" />
+    <text
+     follows="top|left|right"
+     font="SansSerifHugeBold"
+     height="26"
+     layout="topleft"
+     left_pad="10"
+     name="title"
+     text_color="white"
+     top="0"
+     use_ellipses="true"
+     value="Place Profile"
+     width="275" />
+    <scroll_container
+     color="DkGray2"
+     follows="all"
+     height="533"
+     layout="topleft"
+     left="10"
+     name="place_scroll"
+     opaque="true"
+     top_pad="5"
+     width="313">
+        <panel
+         bg_alpha_color="DkGray2"
+         follows="all"
+         height="533"
+         layout="topleft"
+         left="0"
+         min_height="300"
+         name="scrolling_panel"
+         top="0"
+         value="&gt;"
+         width="313">
+            <texture_picker
+             enabled="false"
+             follows="top|left"
+             height="190"
+             layout="topleft"
+             left="10"
+             name="logo"
+             top="10"
+             width="290" />
+            <layout_stack
+             border_size="0"
+             clip="false"
+             follows="all"
+             height="50"
+             layout="topleft"
+             mouse_opaque="false"
+             name="panel_stack"
+             orientation="horizontal"
+             top_pad="-65"
+             width="100">
+                <layout_panel
+                 follows="left|right"
+                 height="50"
+                 layout="topleft"
+                 left="0"
+                 min_height="50"
+                 min_width="50"
+                 mouse_opaque="false"
+                 name="here_panel"
+                 top="0"
+                 user_resize="false"
+                 width="60">
+                    <icon
+                     follows="top|left"
+                     height="50"
+                     image_name="YouAreHere_Badge"
+                     layout="topleft"
+                     left="0"
+                     name="icon_you_are_here"
+                     top="0"
+                     width="50" />
+                </layout_panel>
+                <layout_panel
+                 follows="left|right"
+                 height="60"
+                 layout="topleft"
+                 min_height="50"
+                 min_width="60"
+                 mouse_opaque="false"
+                 name="for_sale_panel"
+                 top="0"
+                 user_resize="false"
+                 width="60">
+                    <icon
+                     follows="top|left"
+                     height="50"
+                     image_name="ForSale_Badge"
+                     layout="topleft"
+                     left="10"
+                     name="icon_for_sale"
+                     top="0"
+                     width="50" />
+                </layout_panel>
+            </layout_stack>
+            <text
+             follows="left|top|right"
+             font="SansSerifLarge"
+             height="14"
+             layout="topleft"
+             left="10"
+             name="region_title"
+             text_color="white"
+             top_pad="5"
+             use_ellipses="true"
+             value="SampleRegion"
+             width="290" />
+       <!-- <icon
+             follows="top|right"
+             height="16"
+             image_name="Icon_For_Sale"
+             layout="topleft"
+             left="3"
+             mouse_opaque="true"
+             name="icon_for_sale"
+             width="16" />-->
+            <text
+             follows="left|top|right"
+             height="14"
+             layout="topleft"
+             left="10"
+             name="parcel_title"
+             top_pad="4"
+             use_ellipses="true"
+             value="SampleParcel, Name Long (145, 228, 26)"
+             width="285" />
+            <expandable_text
+             follows="left|top|right"
+             height="50"
+             layout="topleft"
+             left="5"
+             name="description"
+             top_pad="10"
+             value="Du waltz die spritz"
+             width="300" />
+            <text
+             follows="left|top"
+             height="14"
+             layout="topleft"
+             left="10"
+             name="owner_label"
+             text_color="White"
+             top_pad="0"
+             value="Owner:"
+             width="90" />
+         <!--TODO: HOOK THIS NAME UP WITH AN INSPECTOR  -->
+            <text
+             follows="left|top|right"
+             height="14"
+             layout="topleft"
+             left_pad="1"
+             name="owner_value"
+             top_delta="0"
+             value="Alex Superduperlongenamenton"
+             width="205" />
+            <accordion
+             follows="all"
+             height="230"
+             layout="topleft"
+             left="0"
+             name="advanced_info_accordion"
+             top_pad="10"
+             width="313">
+                <accordion_tab
+                 layout="topleft"
+                 name="parcel_characteristics_tab"
+                 title="Parcel">
+                    <scroll_container
+                     color="DkGray2"
+                     follows="all"
+                     height="132"
+                     layout="topleft"
+                     left="0"
+                     name="parcel_scroll"
+                     opaque="true"
+                     top="0"
+                     width="290">
+                        <panel
+                         follows="all"
+                         height="165"
+                         layout="topleft"
+                         left="0"
+                         top="0"
+                         width="275">
+                            <icon
+                             follows="top|left"
+                             height="16"
+                             image_name="parcel_drk_M"
+                             layout="topleft"
+                             left="20"
+                             name="icon_M"
+                             top="0"
+                             width="18" />
+                            <icon
+                             follows="top|left"
+                             height="16"
+                             image_name="parcel_drk_R"
+                             layout="topleft"
+                             left="20"
+                             name="icon_R"
+                             top="0"
+                             width="18" />
+                            <icon
+                             follows="top|left"
+                             height="16"
+                             image_name="parcel_drk_PG"
+                             layout="topleft"
+                             left="20"
+                             name="icon_PG"
+                             top="0"
+                             visible="false"
+                             width="18" />
+                            <text
+                             follows="left|top"
+                             height="16"
+                             layout="topleft"
+                             left_pad="8"
+                             name="rating_label"
+                             value="Rating:"
+                             width="80" />
+                            <text
+                             follows="right|top"
+                             height="16"
+                             layout="topleft"
+                             left_pad="0"
+                             name="rating_value"
+                             top_delta="0"
+                             value="Mature"
+                             width="120" />
+                            <icon
+                             follows="top|left"
+                             height="18"
+                             image_name="parcel_drk_Voice"
+                             layout="topleft"
+                             left="20"
+                             name="icon_Voice"
+                             top_pad="5"
+                             width="22" />
+                            <icon
+                             follows="top|left"
+                             height="18"
+                             image_name="parcel_drk_VoiceNo"
+                             layout="topleft"
+                             left="20"
+                             name="icon_VoiceNo"
+                             top_delta="0"
+                             visible="false"
+                             width="22" />
+                            <text
+                             follows="left|top"
+                             height="18"
+                             layout="topleft"
+                             left_pad="8"
+                             name="voice_label"
+                             top_delta="0"
+                             value="Voice:"
+                             width="76" />
+                            <text
+                             follows="right|top"
+                             height="18"
+                             layout="topleft"
+                             left_pad="0"
+                             name="voice_value"
+                             top_delta="0"
+                             value="On"
+                             width="60" />
+                            <icon
+                             follows="top|left"
+                             height="18"
+                             image_name="parcel_drk_Fly"
+                             layout="topleft"
+                             left="20"
+                             name="icon_Fly"
+                             top_pad="3"
+                             width="22" />
+                            <icon
+                             follows="top|left"
+                             height="18"
+                             image_name="parcel_drk_FlyNo"
+                             layout="topleft"
+                             left="20"
+                             name="icon_FlyNo"
+                             top_delta="0"
+                             visible="false"
+                             width="22" />
+                            <text
+                             follows="left|top"
+                             height="16"
+                             layout="topleft"
+                             left_pad="8"
+                             name="fly_label"
+                             value="Fly:"
+                             width="76" />
+                            <text
+                             follows="right|top"
+                             height="16"
+                             layout="topleft"
+                             left_pad="0"
+                             name="fly_value"
+                             top_delta="0"
+                             value="On"
+                             width="60" />
+                            <icon
+                             follows="top|left"
+                             height="18"
+                             image_name="parcel_drk_Push"
+                             layout="topleft"
+                             left="20"
+                             name="icon_Push"
+                             top_pad="3"
+                             visible="false"
+                             width="22" />
+                            <icon
+                             follows="top|left"
+                             height="18"
+                             image_name="parcel_drk_PushNo"
+                             layout="topleft"
+                             left="20"
+                             name="icon_PushNo"
+                             top_delta="0"
+                             width="22" />
+                            <text
+                             follows="left|top"
+                             height="14"
+                             layout="topleft"
+                             left_pad="8"
+                             name="push_label"
+                             value="Push:"
+                             width="76" />
+                            <text
+                             follows="right|top"
+                             height="14"
+                             layout="topleft"
+                             left_pad="0"
+                             name="push_value"
+                             top_delta="0"
+                             value="Off"
+                             width="60" />
+                            <icon
+                             follows="top|left"
+                             height="18"
+                             image_name="parcel_drk_Build"
+                             layout="topleft"
+                             left="20"
+                             name="icon_Build"
+                             top_pad="3"
+                             width="22" />
+                            <icon
+                             follows="top|left"
+                             height="18"
+                             image_name="parcel_drk_BuildNo"
+                             layout="topleft"
+                             left="20"
+                             name="icon_BuildNo"
+                             top_delta="0"
+                             visible="false" />
+                            <text
+                             follows="left|top"
+                             height="14"
+                             layout="topleft"
+                             left_pad="8"
+                             name="build_label"
+                             value="Build:"
+                             width="76" />
+                            <text
+                             follows="right|top"
+                             height="15"
+                             layout="topleft"
+                             left_pad="0"
+                             name="build_value"
+                             top_delta="0"
+                             value="On"
+                             width="60" />
+                            <icon
+                             follows="top|left"
+                             height="18"
+                             image_name="parcel_drk_Scripts"
+                             layout="topleft"
+                             left="20"
+                             name="icon_Scripts"
+                             top_pad="3"
+                             width="22" />
+                            <icon
+                             follows="top|left"
+                             height="18"
+                             image_name="parcel_drk_ScriptsNo"
+                             layout="topleft"
+                             left="20"
+                             name="icon_ScriptsNo"
+                             top_delta="0"
+                             visible="false" />
+                            <text
+                             follows="left|top"
+                             height="14"
+                             layout="topleft"
+                             left_pad="8"
+                             name="scripts_label"
+                             value="Scripts:"
+                             width="76" />
+                            <text
+                             follows="right|top"
+                             height="14"
+                             layout="topleft"
+                             left_pad="0"
+                             name="scripts_value"
+                             top_delta="0"
+                             value="On"
+                             width="60" />
+                            <icon
+                             follows="top|left"
+                             height="18"
+                             image_name="parcel_drk_Damage"
+                             layout="topleft"
+                             left="20"
+                             name="icon_Damage"
+                             top_pad="7"
+                             visible="false"
+                             width="22" />
+                            <icon
+                             follows="top|left"
+                             height="18"
+                             image_name="parcel_drk_DamageNo"
+                             layout="topleft"
+                             left="20"
+                             name="icon_DamageNo"
+                             top_delta="0" />
+                            <text
+                             follows="left|top"
+                             height="14"
+                             layout="topleft"
+                             left_pad="8"
+                             name="damage_label"
+                             value="Damage:"
+                             width="76" />
+                            <text
+                             follows="right|top"
+                             height="14"
+                             layout="topleft"
+                             left_pad="0"
+                             name="damage_value"
+                             top_delta="0"
+                             value="Off"
+                             width="60" />
+                            <button
+                             follows="bottom|right"
+                             height="19"
+                             label="About Land"
+                             layout="topleft"
+                             name="about_land_btn"
+                             right="-5"
+                             tab_stop="false"
+                             top="138"
+                             width="90">
+                                <click_callback
+                                 function="ShowFloater"
+                                 parameter="about_land" />
+                            </button>
+                        </panel>
+                    </scroll_container>
+                </accordion_tab>
+                <accordion_tab
+                 expanded="false"
+                 layout="topleft"
+                 name="region_information_tab"
+                 title="Region">
+                    <panel
+                     follows="all"
+                     height="125"
+                     layout="topleft"
+                     left="0"
+                     top="0"
+                     width="290">
+                        <text
+                         follows="left|top"
+                         height="15"
+                         layout="topleft"
+                         left="10"
+                         name="region_name_label"
+                         top_pad="5"
+                         value="Region:"
+                         width="80" />
+                        <text
+                         follows="left|top|right"
+                         height="15"
+                         layout="topleft"
+                         left_pad="0"
+                         name="region_name"
+                         top_delta="0"
+                         value="Mooseland"
+                         width="195" />
+                        <text
+                         follows="left|top"
+                         height="15"
+                         layout="topleft"
+                         left="10"
+                         name="region_type_label"
+                         top_pad="5"
+                         value="Type:"
+                         width="80" />
+                        <text
+                         follows="left|top|right"
+                         height="15"
+                         layout="topleft"
+                         left_pad="0"
+                         name="region_type"
+                         top_delta="0"
+                         value="Moose"
+                         width="195" />
+                        <text
+                         follows="left|top"
+                         height="15"
+                         layout="topleft"
+                         left="10"
+                         name="region_rating_label"
+                         top_pad="7"
+                         value="Rating:"
+                         width="80" />
+                        <icon
+                         follows="top|left"
+                         height="16"
+                         image_name="parcel_drk_M"
+                         layout="topleft"
+                         left_pad="0"
+                         name="icon_M"
+                         width="18" />
+                        <icon
+                         follows="top|left"
+                         height="16"
+                         image_name="parcel_drk_R"
+                         layout="topleft"
+                         left_delta="0"
+                         name="icon_R"
+                         top_delta="0"
+                         visible="false"
+                         width="18" />
+                        <icon
+                         follows="top|left"
+                         height="16"
+                         image_name="parcel_drk_PG"
+                         layout="topleft"
+                         left_delta="0"
+                         name="icon_PG"
+                         top_delta="0"
+                         visible="false"
+                         width="18" />
+                        <text
+                         follows="left|top|right"
+                         height="15"
+                         layout="topleft"
+                         left_pad="10"
+                         name="region_rating"
+                         value="Explicit"
+                         width="100" />
+                        <text
+                         follows="left|top"
+                         height="15"
+                         layout="topleft"
+                         left="10"
+                         name="region_owner_label"
+                         top_pad="5"
+                         value="Owner:"
+                         width="80" />
+                        <text
+                         follows="left|top|right"
+                         height="15"
+                         layout="topleft"
+                         left_pad="0"
+                         name="region_owner"
+                         top_delta="0"
+                         value="moose Van Moose"
+                         width="195" />
+                        <text
+                         follows="left|top"
+                         height="15"
+                         layout="topleft"
+                         left="10"
+                         name="region_group_label"
+                         top_pad="5"
+                         value="Group:"
+                         width="80" />
+                        <text
+                         follows="left|top|right"
+                         height="15"
+                         layout="topleft"
+                         left_pad="0"
+                         name="region_group"
+                         top_delta="0"
+                         use_ellipses="true"
+                         width="195">
+                            The Mighty Moose of mooseville soundvillemoose
+                        </text>
+                        <button
+                         follows="bottom|right"
+                         height="19"
+                         label="Region/Estate"
+                         layout="topleft"
+                         name="region_info_btn"
+                         right="-5"
+                         tab_stop="false"
+                         width="105">
+                            <click_callback
+                             function="ShowFloater"
+                             parameter="region_info" />
+                        </button>
+                    </panel>
+                </accordion_tab>
+                <accordion_tab
+                 expanded="false"
+                 layout="topleft"
+                 name="estate_information_tab"
+                 title="Estate">
+                    <panel
+                     follows="all"
+                     height="189"
+                     layout="topleft"
+                     left="0"
+                     top="0"
+                     width="290">
+                        <text
+                         follows="left|top"
+                         height="15"
+                         layout="topleft"
+                         left="10"
+                         name="estate_name_label"
+                         top_pad="5"
+                         value="Estate:"
+                         width="80" />
+                        <text
+                         follows="left|top|right"
+                         height="15"
+                         layout="topleft"
+                         left="90"
+                         name="estate_name"
+                         top_delta="0"
+                         width="160" />
+                        <text
+                         follows="left|top"
+                         height="15"
+                         layout="topleft"
+                         left="10"
+                         name="estate_rating_label"
+                         top_pad="5"
+                         value="Rating:"
+                         width="80" />
+                        <text
+                         follows="left|top|right"
+                         height="15"
+                         layout="topleft"
+                         left="90"
+                         name="estate_rating"
+                         top_delta="0"
+                         width="160" />
+                        <text
+                         follows="left|top"
+                         height="15"
+                         layout="topleft"
+                         left="10"
+                         name="estate_owner_label"
+                         top_pad="5"
+                         value="Owner:"
+                         width="80" />
+                        <text
+                         follows="left|top|right"
+                         height="15"
+                         layout="topleft"
+                         left="90"
+                         name="estate_owner"
+                         top_delta="0"
+                         width="160" />
+                        <text
+                         follows="left|top"
+                         height="15"
+                         layout="topleft"
+                         left="10"
+                         name="covenant_label"
+                         top_pad="5"
+                         value="Covenant:"
+                         width="220" />
+                        <text_editor
+                         bg_focus_color="DkGray2"
+                         bg_readonly_color="DkGray2"
+                         follows="left|top|right"
+                         handle_edit_keys_directly="true"
+                         height="90"
+                         layout="topleft"
+                         left="10"
+                         max_length="65535"
+                         name="covenant"
+                         read_only="true"
+                         top_pad="0"
+                         width="280" />
+                    </panel>
+                </accordion_tab>
+                <accordion_tab
+                 expanded="false"
+                 layout="topleft"
+                 name="sales_tab"
+                 title="For Sale">
+                    <panel
+                     follows="all"
+                     height="300"
+                     layout="topleft"
+                     left="0"
+                     top="0"
+                     width="290">
+                        <text
+                         follows="left|top"
+                         height="15"
+                         layout="topleft"
+                         left="10"
+                         name="sales_price_label"
+                         top_pad="5"
+                         value="Price:"
+                         width="100" />
+                        <text
+                         follows="left|top|right"
+                         height="15"
+                         layout="topleft"
+                         left="110"
+                         name="sales_price"
+                         top_delta="0"
+                         width="140" />
+                        <text
+                         follows="left|top"
+                         height="15"
+                         layout="topleft"
+                         left="10"
+                         name="area_label"
+                         top_pad="5"
+                         value="Area:"
+                         width="100" />
+                        <text
+                         follows="left|top|right"
+                         height="15"
+                         layout="topleft"
+                         left="110"
+                         name="area"
+                         top_delta="0"
+                         width="140" />
+                        <text
+                         follows="left|top"
+                         height="15"
+                         layout="topleft"
+                         left="10"
+                         name="traffic_label"
+                         top_pad="5"
+                         value="Traffic:"
+                         width="100" />
+                        <text
+                         follows="left|top|right"
+                         height="15"
+                         layout="topleft"
+                         left="110"
+                         name="traffic"
+                         top_delta="0"
+                         width="140" />
+                        <text
+                         follows="left|top"
+                         height="15"
+                         layout="topleft"
+                         left="10"
+                         name="primitives_label"
+                         top_pad="5"
+                         value="Primitives:"
+                         width="100" />
+                        <text
+                         follows="left|top|right"
+                         height="15"
+                         layout="topleft"
+                         left="110"
+                         name="primitives"
+                         top_delta="0"
+                         width="140" />
+                        <text
+                         follows="left|top"
+                         height="15"
+                         layout="topleft"
+                         left="10"
+                         name="parcel_scripts_label"
+                         top_pad="5"
+                         value="Scripts:"
+                         width="100" />
+                        <text
+                         follows="left|top|right"
+                         height="15"
+                         layout="topleft"
+                         left="110"
+                         name="parcel_scripts"
+                         top_delta="0"
+                         width="140" />
+                        <text
+                         follows="left|top"
+                         height="15"
+                         layout="topleft"
+                         left="10"
+                         name="terraform_limits_label"
+                         top_pad="5"
+                         value="Terraform limits:"
+                         width="100" />
+                        <text
+                         follows="left|top|right"
+                         height="15"
+                         layout="topleft"
+                         left="110"
+                         name="terraform_limits"
+                         top_delta="0"
+                         width="140" />
+                        <text
+                         follows="left|top"
+                         height="15"
+                         layout="topleft"
+                         left="10"
+                         name="subdivide_label"
+                         top_pad="5"
+                         value="Subdivide/Join ability:"
+                         width="220" />
+                        <text_editor
+                         bg_focus_color="DkGray2"
+                         bg_readonly_color="DkGray2"
+                         follows="left|top|right"
+                         height="45"
+                         layout="topleft"
+                         left="10"
+                         max_length="65535"
+                         name="subdivide"
+                         read_only="true"
+                         top_pad="5"
+                         width="245" />
+                        <text
+                         follows="left|top"
+                         height="15"
+                         layout="topleft"
+                         left="10"
+                         name="resale_label"
+                         top_pad="5"
+                         value="ReSale ability:"
+                         width="80" />
+                        <text_editor
+                         bg_focus_color="DkGray2"
+                         bg_readonly_color="DkGray2"
+                         follows="left|top|right"
+                         height="45"
+                         layout="topleft"
+                         left="10"
+                         max_length="65535"
+                         name="resale"
+                         read_only="true"
+                         top_pad="5"
+                         width="245" />
+                        <text
+                         follows="left|top"
+                         height="15"
+                         layout="topleft"
+                         left="10"
+                         name="sale_to_label"
+                         top_pad="5"
+                         value="For sale to:"
+                         width="80" />
+                        <text
+                         follows="left|top|right"
+                         height="15"
+                         layout="topleft"
+                         left="90"
+                         name="sale_to"
+                         top_delta="0"
+                         width="160" />
+                    </panel>
+                </accordion_tab>
+            </accordion>
+        </panel>
+    </scroll_container>
+</panel>
diff --git a/indra/newview/skins/default/xui/en/panel_places.xml b/indra/newview/skins/default/xui/en/panel_places.xml
index 5aa53ab46b..87ac5be74a 100644
--- a/indra/newview/skins/default/xui/en/panel_places.xml
+++ b/indra/newview/skins/default/xui/en/panel_places.xml
@@ -40,14 +40,26 @@ background_visible="true"
      top_pad="10"
      width="313" />
     <panel
-     class="panel_place_info"
-     filename="panel_place_info.xml"
+     class="panel_place_profile"
+     filename="panel_place_profile.xml"
      follows="all"
      height="533"
      layout="topleft"
      left="0"
      help_topic="places_info_tab"
-     name="panel_place_info"
+     name="panel_place_profile"
+     top="5"
+     visible="false"
+     width="313" />
+    <panel
+     class="panel_landmark_info"
+     filename="panel_landmark_info.xml"
+     follows="all"
+     height="533"
+     layout="topleft"
+     left="0"
+     help_topic="places_info_tab"
+     name="panel_landmark_info"
      top="5"
      visible="false"
      width="313" />
diff --git a/indra/newview/skins/default/xui/en/panel_profile.xml b/indra/newview/skins/default/xui/en/panel_profile.xml
index 5af7d7d674..c3a92f9d9a 100644
--- a/indra/newview/skins/default/xui/en/panel_profile.xml
+++ b/indra/newview/skins/default/xui/en/panel_profile.xml
@@ -157,7 +157,7 @@
          value="http://librarianavengers.org"
          width="280"
          word_wrap="false"
-         use_elipsis="true"
+         use_ellipses="true"
          />
         <text
          follows="left|top"
diff --git a/indra/newview/skins/default/xui/en/panel_profile_view.xml b/indra/newview/skins/default/xui/en/panel_profile_view.xml
index 195b731531..4b2e901718 100644
--- a/indra/newview/skins/default/xui/en/panel_profile_view.xml
+++ b/indra/newview/skins/default/xui/en/panel_profile_view.xml
@@ -36,7 +36,7 @@
      text_color="white"
      top="0"
      value="(Loading...)"
-     use_elipsis="true"
+     use_ellipses="true"
      width="275" />
     <text
      follows="top|left"
diff --git a/indra/newview/skins/default/xui/en/widgets/gesture_combo_box.xml b/indra/newview/skins/default/xui/en/widgets/gesture_combo_box.xml
index ab4ad94089..6171be034f 100644
--- a/indra/newview/skins/default/xui/en/widgets/gesture_combo_box.xml
+++ b/indra/newview/skins/default/xui/en/widgets/gesture_combo_box.xml
@@ -15,14 +15,14 @@
                           image_disabled_selected="ComboButton_Disabled_Selected" />
   <gesture_combo_box.drop_down_button name="Drop Down Button"
                               label=""
+                              halign="center"
                               hover_glow_amount="0.15"
                               font="SansSerif"
                               scale_image="true"
-                              pad_right="24"
-                              image_unselected="DropDown_Off"
-                              image_selected="DropDown_Selected"
-                              image_disabled="DropDown_Disabled"
-                              image_disabled_selected="DropDown_Disabled_Selected" />
+                              image_unselected="PushButton_Off"
+                              image_selected="PushButton_Selected"
+                              image_disabled="PushButton_Disabled"
+                              image_disabled_selected="PushButton_Selected_Disabled" />
   <gesture_combo_box.combo_list bg_writeable_color="MenuDefaultBgColor"
                                 scroll_bar_bg_visible="true" />
   <gesture_combo_box.combo_editor name="Combo Text Entry"
diff --git a/indra/newview/skins/default/xui/en/widgets/talk_button.xml b/indra/newview/skins/default/xui/en/widgets/talk_button.xml
new file mode 100644
index 0000000000..725492052c
--- /dev/null
+++ b/indra/newview/skins/default/xui/en/widgets/talk_button.xml
@@ -0,0 +1,37 @@
+<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
+<!-- Derives from LLUICtrl -->
+<talk_button>
+  <!-- To make speak button look green when selected set:
+    image_selected="SegmentedBtn_Left_Selected"
+    image_unselected="SegmentedBtn_Left_Off"
+  -->
+  <speak_button
+    name="left"
+    label="Speak"
+    label_selected="Speak"
+    font="SansSerifSmall"
+    tab_stop="false"
+    is_toggle="true"
+    picture_style="true"
+    />
+  <show_button
+    name="right"
+    label=""
+    left="0"
+    top="0"
+    right="20"
+    bottom="0"
+    tab_stop="false"
+    is_toggle="true"
+    picture_style="true"
+    image_selected="ComboButton_Selected"
+    image_unselected="ComboButton_Off"
+    />
+  <monitor
+    name="monitor"
+    left="0"
+    top="18"
+    right="18"
+    bottom="0"
+    />
+</talk_button>
-- 
cgit v1.2.3


From 0520ad677a380e81f6d166bfbcbed23333533b77 Mon Sep 17 00:00:00 2001
From: Leyla Farazha <leyla@lindenlab.com>
Date: Wed, 4 Nov 2009 15:06:56 -0800
Subject: EXT-1739   	 Preferences > Sounds > Device settings --
 Input/Output controls don't work EXT-2073   	 Need ability to change font
 style of tab headers EXT-1505   	 Kill text drop shadow on Menu and
 Tabs reviewed by Richard

---
 indra/llui/llmenugl.cpp                            | 24 ++++----------
 indra/llui/lltabcontainer.cpp                      |  4 ++-
 indra/newview/llfloatervoicedevicesettings.cpp     | 17 ++++++++++
 indra/newview/llfloatervoicedevicesettings.h       |  2 ++
 .../default/xui/en/panel_preferences_sound.xml     | 37 ++++++++++++++--------
 .../skins/default/xui/en/widgets/tab_container.xml |  1 +
 6 files changed, 52 insertions(+), 33 deletions(-)

(limited to 'indra')

diff --git a/indra/llui/llmenugl.cpp b/indra/llui/llmenugl.cpp
index 91e7e46195..36d8e5ed71 100644
--- a/indra/llui/llmenugl.cpp
+++ b/indra/llui/llmenugl.cpp
@@ -459,12 +459,6 @@ void LLMenuItemGL::draw( void )
 
 	LLColor4 color;
 
-	LLFontGL::ShadowType shadow_style = LLFontGL::NO_SHADOW;
-	if (getEnabled() && !mDrawTextDisabled )
-	{
-		shadow_style = LLFontGL::DROP_SHADOW_SOFT;
-	}
-
 	if ( getEnabled() && getHighlight() )
 	{
 		color = mHighlightForeground.get();
@@ -482,26 +476,26 @@ void LLMenuItemGL::draw( void )
 	if (mBriefItem)
 	{
 		mFont->render( mLabel, 0, BRIEF_PAD_PIXELS / 2, 0, color,
-					   LLFontGL::LEFT, LLFontGL::BOTTOM, LLFontGL::NORMAL, shadow_style );
+					   LLFontGL::LEFT, LLFontGL::BOTTOM, LLFontGL::NORMAL);
 	}
 	else
 	{
 		if( !mDrawBoolLabel.empty() )
 		{
 			mFont->render( mDrawBoolLabel.getWString(), 0, (F32)LEFT_PAD_PIXELS, ((F32)MENU_ITEM_PADDING / 2.f) + 1.f, color,
-						   LLFontGL::LEFT, LLFontGL::BOTTOM, LLFontGL::NORMAL, shadow_style, S32_MAX, S32_MAX, NULL, FALSE );
+						   LLFontGL::LEFT, LLFontGL::BOTTOM, LLFontGL::NORMAL, LLFontGL::NO_SHADOW, S32_MAX, S32_MAX, NULL, FALSE );
 		}
 		mFont->render( mLabel.getWString(), 0, (F32)LEFT_PLAIN_PIXELS, ((F32)MENU_ITEM_PADDING / 2.f) + 1.f, color,
-					   LLFontGL::LEFT, LLFontGL::BOTTOM, LLFontGL::NORMAL, shadow_style, S32_MAX, S32_MAX, NULL, FALSE );
+					   LLFontGL::LEFT, LLFontGL::BOTTOM, LLFontGL::NORMAL, LLFontGL::NO_SHADOW, S32_MAX, S32_MAX, NULL, FALSE );
 		if( !mDrawAccelLabel.empty() )
 		{
 			mFont->render( mDrawAccelLabel.getWString(), 0, (F32)getRect().mRight - (F32)RIGHT_PLAIN_PIXELS, ((F32)MENU_ITEM_PADDING / 2.f) + 1.f, color,
-						   LLFontGL::RIGHT, LLFontGL::BOTTOM, LLFontGL::NORMAL, shadow_style, S32_MAX, S32_MAX, NULL, FALSE );
+						   LLFontGL::RIGHT, LLFontGL::BOTTOM, LLFontGL::NORMAL, LLFontGL::NO_SHADOW, S32_MAX, S32_MAX, NULL, FALSE );
 		}
 		if( !mDrawBranchLabel.empty() )
 		{
 			mFont->render( mDrawBranchLabel.getWString(), 0, (F32)getRect().mRight - (F32)RIGHT_PAD_PIXELS, ((F32)MENU_ITEM_PADDING / 2.f) + 1.f, color,
-						   LLFontGL::RIGHT, LLFontGL::BOTTOM, LLFontGL::NORMAL, shadow_style, S32_MAX, S32_MAX, NULL, FALSE );
+						   LLFontGL::RIGHT, LLFontGL::BOTTOM, LLFontGL::NORMAL, LLFontGL::NO_SHADOW, S32_MAX, S32_MAX, NULL, FALSE );
 		}
 	}
 
@@ -1460,12 +1454,6 @@ void LLMenuItemBranchDownGL::draw( void )
 		gl_rect_2d( 0, getRect().getHeight(), getRect().getWidth(), 0 );
 	}
 
-	LLFontGL::ShadowType shadow_style = LLFontGL::NO_SHADOW;
-	if (getEnabled() && !getDrawTextDisabled() )
-	{
-		shadow_style = LLFontGL::DROP_SHADOW_SOFT;
-	}
-
 	LLColor4 color;
 	if (getHighlight())
 	{
@@ -1480,7 +1468,7 @@ void LLMenuItemBranchDownGL::draw( void )
 		color = mDisabledColor.get();
 	}
 	getFont()->render( mLabel.getWString(), 0, (F32)getRect().getWidth() / 2.f, (F32)LABEL_BOTTOM_PAD_PIXELS, color,
-				   LLFontGL::HCENTER, LLFontGL::BOTTOM, LLFontGL::NORMAL, shadow_style );
+				   LLFontGL::HCENTER, LLFontGL::BOTTOM, LLFontGL::NORMAL);
 
 
 	// underline navigation key only when keyboard navigation has been initiated
diff --git a/indra/llui/lltabcontainer.cpp b/indra/llui/lltabcontainer.cpp
index cde4c75518..04c57dcb4e 100644
--- a/indra/llui/lltabcontainer.cpp
+++ b/indra/llui/lltabcontainer.cpp
@@ -155,7 +155,7 @@ LLTabContainer::LLTabContainer(const LLTabContainer::Params& p)
 	mTotalTabWidth(0),
 	mTabPosition(p.tab_position),
 	mFontHalign(p.font_halign),
-	mFont(p.font.isProvided() ? p.font() : (mIsVertical ? LLFontGL::getFontSansSerif() : LLFontGL::getFontSansSerifSmall())),
+	mFont(p.font),
 	mFirstTabParams(p.first_tab),
 	mMiddleTabParams(p.middle_tab),
 	mLastTabParams(p.last_tab)
@@ -946,6 +946,7 @@ void LLTabContainer::addTabPanel(const TabPanelParams& panel)
 			p.scale_image(true);
 			p.font_halign = mFontHalign;
 			p.tab_stop(false);
+			p.label_shadow(false);
 			if (indent)
 			{
 				p.pad_left(indent);
@@ -965,6 +966,7 @@ void LLTabContainer::addTabPanel(const TabPanelParams& panel)
 			p.image_unselected(tab_img);
 			p.image_selected(tab_selected_img);
 			p.tab_stop(false);
+			p.label_shadow(false);
 			// Try to squeeze in a bit more text
 			p.pad_left(4);
 			p.pad_right(2);
diff --git a/indra/newview/llfloatervoicedevicesettings.cpp b/indra/newview/llfloatervoicedevicesettings.cpp
index aca9198f59..bbeb287171 100644
--- a/indra/newview/llfloatervoicedevicesettings.cpp
+++ b/indra/newview/llfloatervoicedevicesettings.cpp
@@ -49,6 +49,9 @@
 #include "lluictrlfactory.h"
 
 
+static LLRegisterPanelClassWrapper<LLPanelVoiceDeviceSettings> t_panel_group_general("panel_voice_device_settings");
+
+
 LLPanelVoiceDeviceSettings::LLPanelVoiceDeviceSettings()
 	: LLPanel()
 {
@@ -82,8 +85,22 @@ BOOL LLPanelVoiceDeviceSettings::postBuild()
 	return TRUE;
 }
 
+// virtual
+void LLPanelVoiceDeviceSettings::handleVisibilityChange ( BOOL new_visibility )
+{
+	if (new_visibility)
+	{
+		initialize();	
+	}
+	else
+	{
+		cleanup();
+	}
+}
 void LLPanelVoiceDeviceSettings::draw()
 {
+	refresh();
+
 	// let user know that volume indicator is not yet available
 	bool is_in_tuning_mode = gVoiceClient->inTuningMode();
 	childSetVisible("wait_text", !is_in_tuning_mode);
diff --git a/indra/newview/llfloatervoicedevicesettings.h b/indra/newview/llfloatervoicedevicesettings.h
index f1603dc414..d67283d0a2 100644
--- a/indra/newview/llfloatervoicedevicesettings.h
+++ b/indra/newview/llfloatervoicedevicesettings.h
@@ -50,6 +50,8 @@ public:
 	void initialize();
 	void cleanup();
 
+	/*virtual*/ void handleVisibilityChange ( BOOL new_visibility );
+	
 protected:
 	static void onCommitInputDevice(LLUICtrl* ctrl, void* user_data);
 	static void onCommitOutputDevice(LLUICtrl* ctrl, void* user_data);
diff --git a/indra/newview/skins/default/xui/en/panel_preferences_sound.xml b/indra/newview/skins/default/xui/en/panel_preferences_sound.xml
index 832c9775ce..c1df7bd501 100644
--- a/indra/newview/skins/default/xui/en/panel_preferences_sound.xml
+++ b/indra/newview/skins/default/xui/en/panel_preferences_sound.xml
@@ -336,19 +336,20 @@
          top_delta="19"
          width="200" />
     </radio_group>
-    <button
-     control_name="ShowDeviceSettings"
-     follows="left|bottom"
-     height="19"
-     is_toggle="true"
-     label="Input / Output  Devices"
-     layout="topleft"
-     left="165"
-     top_pad="12"
-     name="device_settings_btn"
-     width="190" />
+  <button
+   control_name="ShowDeviceSettings"
+   follows="left|bottom"
+   height="19"
+   is_toggle="true"
+   label="Input / Output  Devices"
+   layout="topleft"
+   left="165"
+   top_pad="12"
+   name="device_settings_btn"
+   width="190">
+  </button>
     <panel
-    background_visible="true"
+     background_visible="true"
      bg_alpha_color="DkGray"
      visiblity_control="ShowDeviceSettings"
      border="false"
@@ -357,8 +358,13 @@
      label="DeviceSettings"
      layout="topleft"
      left="0"
-     name="Device Settings"
+     name="device_settings_panel"
+     class="panel_voice_device_settings"
      width="501">
+      <panel.string
+        name="default_text">
+        Default
+      </panel.string>
       <icon
              height="18"
              image_name="Microphone_On"
@@ -382,6 +388,7 @@
     </text>
     <combo_box
      height="19"
+     control_name="VoiceInputAudioDevice"
      layout="topleft"
      left="165"
      max_chars="128"
@@ -400,7 +407,8 @@
      width="200">
         My volume:
     </text>
-      <slider
+      <slider_bar
+        control_name="AudioLevelMic" 
      follows="left|top"
      height="17"
      increment="0.05"
@@ -492,6 +500,7 @@
         Output
     </text>
     <combo_box
+     control_name="VoiceOutputAudioDevice"
      height="19"
      layout="topleft"
      left="165"
diff --git a/indra/newview/skins/default/xui/en/widgets/tab_container.xml b/indra/newview/skins/default/xui/en/widgets/tab_container.xml
index fe2f1423b7..f1401140de 100644
--- a/indra/newview/skins/default/xui/en/widgets/tab_container.xml
+++ b/indra/newview/skins/default/xui/en/widgets/tab_container.xml
@@ -2,6 +2,7 @@
 <tab_container tab_min_width="60"
                tab_max_width="150"
                font_halign="center"
+               font="SansSerif" 
                tab_height="21">
   <first_tab tab_top_image_unselected="TabTop_Left_Off"
                tab_top_image_selected="TabTop_Left_Selected"
-- 
cgit v1.2.3


From 0bd2567bf5648808a95c7826581199bb371597cb Mon Sep 17 00:00:00 2001
From: Monroe Linden <monroe@lindenlab.com>
Date: Wed, 4 Nov 2009 15:59:04 -0800
Subject: Fix for DEV-42076 (media controls should not fade out while mouse is
 hovered over them).

Updated LLPanelPrimMediaControls::isMouseOver() to do the right thing with the new structure of the panel.
---
 indra/newview/llpanelprimmediacontrols.cpp | 33 ++++++++++++++++++------------
 1 file changed, 20 insertions(+), 13 deletions(-)

(limited to 'indra')

diff --git a/indra/newview/llpanelprimmediacontrols.cpp b/indra/newview/llpanelprimmediacontrols.cpp
index 58ca481b77..0b2a7e8756 100644
--- a/indra/newview/llpanelprimmediacontrols.cpp
+++ b/indra/newview/llpanelprimmediacontrols.cpp
@@ -691,24 +691,31 @@ bool LLPanelPrimMediaControls::isMouseOver()
 		getWindow()->getCursorPosition(&cursor_pos_window);
 		getWindow()->convertCoords(cursor_pos_window, &cursor_pos_gl);
 		
-		LLPanel* controls_panel = NULL;
-		controls_panel = getChild<LLPanel>("media_hover_controls");
-		if(controls_panel && !controls_panel->getVisible())
-		{
-			// The hover controls aren't visible -- use the focused controls instead.
-			controls_panel = getChild<LLPanel>("media_focused_controls");
-		}
+		LLView* controls_view = NULL;
+		controls_view = getChild<LLView>("media_controls");
 		
-		if(controls_panel && controls_panel->getVisible())
+		if(controls_view && controls_view->getVisible())
 		{
-			controls_panel->screenPointToLocal(cursor_pos_gl.mX, cursor_pos_gl.mY, &x, &y);
+			controls_view->screenPointToLocal(cursor_pos_gl.mX, cursor_pos_gl.mY, &x, &y);
 
-			LLView *hit_child = controls_panel->childFromPoint(x, y);
-			if(hit_child)
+			LLView *hit_child = controls_view->childFromPoint(x, y);
+			if(hit_child && hit_child->getVisible())
 			{
 				// This was useful for debugging both coordinate translation and view hieararchy problems...
-//				llinfos << "mouse coords: " << x << ", " << y << " hit child " << hit_child->getName() << llendl;
-				result = true;
+				// llinfos << "mouse coords: " << x << ", " << y << " hit child " << hit_child->getName() << llendl;
+
+				// This will be a direct child of the LLLayoutStack, which should be a layout_panel.
+				// These may not shown/hidden by the logic in updateShape(), so we need to do another hit test on the children of the layout panel,
+				// which are the actual controls.
+				hit_child->screenPointToLocal(cursor_pos_gl.mX, cursor_pos_gl.mY, &x, &y);
+				
+				LLView *hit_child_2 = hit_child->childFromPoint(x, y);
+				if(hit_child_2 && hit_child_2->getVisible())
+				{
+					// This was useful for debugging both coordinate translation and view hieararchy problems...
+					// llinfos << "    mouse coords: " << x << ", " << y << " hit child 2 " << hit_child_2->getName() << llendl;
+					result = true;
+				}
 			}
 		}
 	}
-- 
cgit v1.2.3


From 33eac5dc0a1dfc0624dcfc75bec35155fbb9c917 Mon Sep 17 00:00:00 2001
From: Rick Pasetto <rick@lindenlab.com>
Date: Wed, 4 Nov 2009 16:11:39 -0800
Subject: Fix typo in XUI file that broke media controls

---
 indra/newview/skins/default/xui/en/panel_prim_media_controls.xml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

(limited to 'indra')

diff --git a/indra/newview/skins/default/xui/en/panel_prim_media_controls.xml b/indra/newview/skins/default/xui/en/panel_prim_media_controls.xml
index 7b34e2931e..d384abf038 100644
--- a/indra/newview/skins/default/xui/en/panel_prim_media_controls.xml
+++ b/indra/newview/skins/default/xui/en/panel_prim_media_controls.xml
@@ -254,7 +254,7 @@
 		  image_selected="button_anim_pause.tga"
 		  image_unselected="button_anim_pause.tga"
 		  layout="topleft"
-		  tool_tip = "Pause media"
+		  tool_tip = "Pause media">
 		<button.commit_callback
 			function="MediaCtrl.Pause" />
 	  </button>
-- 
cgit v1.2.3


From c527ade45beb1db2e1801646945812344a520ed0 Mon Sep 17 00:00:00 2001
From: "Eric M. Tulla (BigPapi)" <tulla@lindenlab.com>
Date: Wed, 4 Nov 2009 19:27:00 -0500
Subject: Fix for DEV-32672 / VWR-13349. Prim move grid display wasn't
 mipmapping properly.

---
 indra/newview/llmaniptranslate.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

(limited to 'indra')

diff --git a/indra/newview/llmaniptranslate.cpp b/indra/newview/llmaniptranslate.cpp
index 2153f77336..f1b3a37677 100644
--- a/indra/newview/llmaniptranslate.cpp
+++ b/indra/newview/llmaniptranslate.cpp
@@ -163,7 +163,7 @@ void LLManipTranslate::restoreGL()
 
 	GLuint* d = new GLuint[rez*rez];	
 
-	gGL.getTexUnit(0)->bindManual(LLTexUnit::TT_TEXTURE, sGridTex->getTexName());
+	gGL.getTexUnit(0)->bindManual(LLTexUnit::TT_TEXTURE, sGridTex->getTexName(), true);
 	gGL.getTexUnit(0)->setTextureFilteringOption(LLTexUnit::TFO_TRILINEAR);
 
 	while (rez >= 1)
-- 
cgit v1.2.3


From b03ccaec164ea01e87d8bf6d9a507a0606151ab6 Mon Sep 17 00:00:00 2001
From: "Justin C. Rounds (Chuck)" <chuck@lindenlab.com>
Date: Wed, 4 Nov 2009 19:39:50 -0500
Subject: Changed rollover graphic on Favorites links.
 http://jira.secondlife.com/browse/EXT-2218

---
 .../skins/default/textures/navbar/Favorite_Link_Over.png  | Bin 0 -> 191 bytes
 indra/newview/skins/default/textures/textures.xml         |   5 +----
 .../newview/skins/default/xui/en/favorites_bar_button.xml |   8 ++++----
 3 files changed, 5 insertions(+), 8 deletions(-)
 create mode 100644 indra/newview/skins/default/textures/navbar/Favorite_Link_Over.png

(limited to 'indra')

diff --git a/indra/newview/skins/default/textures/navbar/Favorite_Link_Over.png b/indra/newview/skins/default/textures/navbar/Favorite_Link_Over.png
new file mode 100644
index 0000000000..d4f126f969
Binary files /dev/null and b/indra/newview/skins/default/textures/navbar/Favorite_Link_Over.png differ
diff --git a/indra/newview/skins/default/textures/textures.xml b/indra/newview/skins/default/textures/textures.xml
index 4aafe462b7..8be90cb03e 100644
--- a/indra/newview/skins/default/textures/textures.xml
+++ b/indra/newview/skins/default/textures/textures.xml
@@ -89,6 +89,7 @@
   <texture name="Favorite_Star_Off" file_name="navbar/Favorite_Star_Off.png" preload="false" />
   <texture name="Favorite_Star_Press" file_name="navbar/Favorite_Star_Press.png" preload="false" />
   <texture name="Favorite_Star_Over" file_name="navbar/Favorite_Star_Over.png" preload="false" />
+  <texture name="Favorite_Link_Over" file_name="navbar/Favorite_Link_Over.png" preload="false" />
 
   <texture name="FileMenu_BarSelect" file_name="navbar/FileMenu_BarSelect.png" preload="false" scale.left="2" scale.top="0" scale.right="2" scale.bottom="0" />
   <texture name="FileMenu_BG" file_name="navbar/FileMenu_BG.png" preload="false" />
@@ -396,10 +397,6 @@
   <texture name="TabIcon_Home_Off" file_name="taskpanel/TabIcon_Home_Off.png" preload="false" />
   <texture name="TabIcon_Home_Over" file_name="taskpanel/TabIcon_Home_Over.png" preload="false" />
   <texture name="TabIcon_Home_Selected" file_name="taskpanel/TabIcon_Home_Selected.png" preload="false" />
-  <texture name="TabIcon_Inventory_Large" file_name="taskpanel/TabIcon_Inventory_Large.png" preload="false" />
-  <texture name="TabIcon_Inventory_Off" file_name="taskpanel/TabIcon_Inventory_Off.png" preload="false" />
-  <texture name="TabIcon_Inventory_Over" file_name="taskpanel/TabIcon_Inventory_Over.png" preload="false" />
-  <texture name="TabIcon_Inventory_Selected" file_name="taskpanel/TabIcon_Inventory_Selected.png" preload="false" />
   <texture name="TabIcon_Me_Large" file_name="taskpanel/TabIcon_Me_Large.png" preload="false" />
   <texture name="TabIcon_Me_Off" file_name="taskpanel/TabIcon_Me_Off.png" preload="false" />
   <texture name="TabIcon_Me_Over" file_name="taskpanel/TabIcon_Me_Over.png" preload="false" />
diff --git a/indra/newview/skins/default/xui/en/favorites_bar_button.xml b/indra/newview/skins/default/xui/en/favorites_bar_button.xml
index c35cbb1539..361f5a7bc8 100644
--- a/indra/newview/skins/default/xui/en/favorites_bar_button.xml
+++ b/indra/newview/skins/default/xui/en/favorites_bar_button.xml
@@ -9,10 +9,10 @@
  image_disabled_selected="transparent.j2c"
  image_selected="transparent.j2c"
  image_unselected="transparent.j2c"
- image_hover_selected="FileMenu_BarSelect"
- image_hover_unselected="FileMenu_BarSelect"
- image_pressed="FileMenu_BarSelect"
- image_pressed_selected="FileMenu_BarSelect"
+ image_hover_selected="Favorite_Link_Over"
+ image_hover_unselected="Favorite_Link_Over"
+ image_pressed="Favorite_Link_Over"
+ image_pressed_selected="Favorite_Link_Over"
  hover_glow_amount="0.15"
  layout="topleft"
  left="0"
-- 
cgit v1.2.3


From 4656c5671cfe523e351b5c91ae45d5026fb69e04 Mon Sep 17 00:00:00 2001
From: Erica <erica@lindenlab.com>
Date: Wed, 4 Nov 2009 17:09:37 -0800
Subject: EXT-2220 Make envelope icon for unread messages

---
 .../skins/default/textures/bottomtray/Notices_Unread.png | Bin 0 -> 333 bytes
 indra/newview/skins/default/textures/textures.xml        |   7 ++++++-
 indra/newview/skins/default/xui/en/panel_bottomtray.xml  |  15 +++++++++------
 3 files changed, 15 insertions(+), 7 deletions(-)
 create mode 100644 indra/newview/skins/default/textures/bottomtray/Notices_Unread.png

(limited to 'indra')

diff --git a/indra/newview/skins/default/textures/bottomtray/Notices_Unread.png b/indra/newview/skins/default/textures/bottomtray/Notices_Unread.png
new file mode 100644
index 0000000000..98f1f04b9a
Binary files /dev/null and b/indra/newview/skins/default/textures/bottomtray/Notices_Unread.png differ
diff --git a/indra/newview/skins/default/textures/textures.xml b/indra/newview/skins/default/textures/textures.xml
index 8be90cb03e..2b9ebd0573 100644
--- a/indra/newview/skins/default/textures/textures.xml
+++ b/indra/newview/skins/default/textures/textures.xml
@@ -89,7 +89,6 @@
   <texture name="Favorite_Star_Off" file_name="navbar/Favorite_Star_Off.png" preload="false" />
   <texture name="Favorite_Star_Press" file_name="navbar/Favorite_Star_Press.png" preload="false" />
   <texture name="Favorite_Star_Over" file_name="navbar/Favorite_Star_Over.png" preload="false" />
-  <texture name="Favorite_Link_Over" file_name="navbar/Favorite_Link_Over.png" preload="false" />
 
   <texture name="FileMenu_BarSelect" file_name="navbar/FileMenu_BarSelect.png" preload="false" scale.left="2" scale.top="0" scale.right="2" scale.bottom="0" />
   <texture name="FileMenu_BG" file_name="navbar/FileMenu_BG.png" preload="false" />
@@ -234,6 +233,8 @@
   <texture name="NearbyVoice_Lvl3" file_name="bottomtray/NearbyVoice_Lvl3.png" preload="false" />
   <texture name="NearbyVoice_On" file_name="bottomtray/NearbyVoice_On.png" preload="false" />
 
+  <texture name="Notices_Unread" file_name="bottomtray/Notices_Unread.png" preload="true" />
+
   <texture name="Object_Cone" file_name="build/Object_Cone.png" preload="false" />
   <texture name="Object_Cube" file_name="build/Object_Cube.png" preload="false" />
   <texture name="Object_Cylinder" file_name="build/Object_Cylinder.png" preload="false" />
@@ -397,6 +398,10 @@
   <texture name="TabIcon_Home_Off" file_name="taskpanel/TabIcon_Home_Off.png" preload="false" />
   <texture name="TabIcon_Home_Over" file_name="taskpanel/TabIcon_Home_Over.png" preload="false" />
   <texture name="TabIcon_Home_Selected" file_name="taskpanel/TabIcon_Home_Selected.png" preload="false" />
+  <texture name="TabIcon_Inventory_Large" file_name="taskpanel/TabIcon_Inventory_Large.png" preload="false" />
+  <texture name="TabIcon_Inventory_Off" file_name="taskpanel/TabIcon_Inventory_Off.png" preload="false" />
+  <texture name="TabIcon_Inventory_Over" file_name="taskpanel/TabIcon_Inventory_Over.png" preload="false" />
+  <texture name="TabIcon_Inventory_Selected" file_name="taskpanel/TabIcon_Inventory_Selected.png" preload="false" />
   <texture name="TabIcon_Me_Large" file_name="taskpanel/TabIcon_Me_Large.png" preload="false" />
   <texture name="TabIcon_Me_Off" file_name="taskpanel/TabIcon_Me_Off.png" preload="false" />
   <texture name="TabIcon_Me_Over" file_name="taskpanel/TabIcon_Me_Over.png" preload="false" />
diff --git a/indra/newview/skins/default/xui/en/panel_bottomtray.xml b/indra/newview/skins/default/xui/en/panel_bottomtray.xml
index 3149a1f7b3..1da5f0e74d 100644
--- a/indra/newview/skins/default/xui/en/panel_bottomtray.xml
+++ b/indra/newview/skins/default/xui/en/panel_bottomtray.xml
@@ -60,7 +60,7 @@
          min_width="96"
          name="speak_panel"
          user_resize="false">
-         <talk_button
+         <chiclet_talk
           follows="right"
           height="23"
           speak_button.tab_stop="true"
@@ -93,7 +93,7 @@
          min_width="76"
          name="gesture_panel"
          user_resize="false">
-         <gesture_combo_box
+         <button
            follows="right"
           height="23"
           label="Gesture"
@@ -258,11 +258,11 @@
          user_resize="false">
             <chiclet_notification
              follows="right"
-             height="25"
+             height="23"
              layout="topleft"
              left="0"
              name="sys_well"
-             top="3"
+             top="4"
              width="34">
               <button
               auto_resize="true"
@@ -271,7 +271,10 @@
                follows="right"
                flash_color="EmphasisColor"
                name="Unread"
-               image_overlay="Widget_UpArrow" />
+               picture_style="true"
+               image_overlay="Notices_Unread"
+               width="20"
+               />
                <unread_notifications
                width="34"
                height="23"
@@ -288,6 +291,6 @@
          layout="topleft"
          right="-1"
          top="0"
-         width="10"/>
+         width="26"/>
     </layout_stack>
 </panel>
\ No newline at end of file
-- 
cgit v1.2.3