From bec4708fbab662651a7ebc28a3900b8a5e90c28b Mon Sep 17 00:00:00 2001 From: Todd Stinson Date: Thu, 5 Jul 2012 17:54:04 -0700 Subject: Adding the pathfinding attributes to the object profile panel. --- indra/newview/llsidepaneltaskinfo.cpp | 35 + indra/newview/llsidepaneltaskinfo.h | 2 + .../skins/default/xui/en/sidepanel_task_info.xml | 1134 ++++++++++---------- 3 files changed, 613 insertions(+), 558 deletions(-) (limited to 'indra') diff --git a/indra/newview/llsidepaneltaskinfo.cpp b/indra/newview/llsidepaneltaskinfo.cpp index 62d6016476..c351b1a128 100644 --- a/indra/newview/llsidepaneltaskinfo.cpp +++ b/indra/newview/llsidepaneltaskinfo.cpp @@ -61,6 +61,9 @@ #include "llspinctrl.h" #include "roles_constants.h" #include "llgroupactions.h" +#include "lltextbase.h" +#include "llstring.h" +#include "lltrans.h" ///---------------------------------------------------------------------------- /// Class llsidepaneltaskinfo @@ -146,6 +149,7 @@ BOOL LLSidepanelTaskInfo::postBuild() mDAEditCost = getChild("Edit Cost"); mDALabelClickAction = getChildView("label click action"); mDAComboClickAction = getChild("clickaction"); + mDAPathfindingAttributes = getChild("pathfinding_attributes_value"); mDAB = getChildView("B:"); mDAO = getChildView("O:"); mDAG = getChildView("G:"); @@ -242,6 +246,9 @@ void LLSidepanelTaskInfo::disableAll() mDAComboClickAction->clear(); } + mDAPathfindingAttributes->setEnabled(FALSE); + mDAPathfindingAttributes->setValue(LLStringUtil::null); + mDAB->setVisible(FALSE); mDAO->setVisible(FALSE); mDAG->setVisible(FALSE); @@ -329,6 +336,34 @@ void LLSidepanelTaskInfo::refresh() getChildView("perm_modify")->setEnabled(TRUE); getChild("perm_modify")->setValue(MODIFY_INFO_STRINGS[string_index]); + std::string pfAttrName; + + if ((mObjectSelection->getFirstRootNode() + && LLSelectMgr::getInstance()->selectGetRootsNonPathfinding()) + || LLSelectMgr::getInstance()->selectGetNonPathfinding()) + { + pfAttrName = "Pathfinding_Object_Attr_None"; + } + else if ((mObjectSelection->getFirstRootNode() + && LLSelectMgr::getInstance()->selectGetRootsPermanent()) + || LLSelectMgr::getInstance()->selectGetPermanent()) + { + pfAttrName = "Pathfinding_Object_Attr_Permanent"; + } + else if ((mObjectSelection->getFirstRootNode() + && LLSelectMgr::getInstance()->selectGetRootsCharacter()) + || LLSelectMgr::getInstance()->selectGetCharacter()) + { + pfAttrName = "Pathfinding_Object_Attr_Character"; + } + else + { + pfAttrName = "Pathfinding_Object_Attr_MultiSelect"; + } + + mDAPathfindingAttributes->setEnabled(TRUE); + mDAPathfindingAttributes->setValue(LLTrans::getString(pfAttrName)); + getChildView("Permissions:")->setEnabled(TRUE); // Update creator text field diff --git a/indra/newview/llsidepaneltaskinfo.h b/indra/newview/llsidepaneltaskinfo.h index be0fee2127..124229af06 100644 --- a/indra/newview/llsidepaneltaskinfo.h +++ b/indra/newview/llsidepaneltaskinfo.h @@ -41,6 +41,7 @@ class LLCheckBoxCtrl; class LLComboBox; class LLNameBox; class LLViewerObject; +class LLTextBase; class LLSidepanelTaskInfo : public LLSidepanelInventorySubpanel { @@ -150,6 +151,7 @@ private: LLUICtrl* mDAEditCost; LLView* mDALabelClickAction; LLComboBox* mDAComboClickAction; + LLTextBase* mDAPathfindingAttributes; LLView* mDAB; LLView* mDAO; LLView* mDAG; diff --git a/indra/newview/skins/default/xui/en/sidepanel_task_info.xml b/indra/newview/skins/default/xui/en/sidepanel_task_info.xml index d246918cd3..e9a787cef0 100644 --- a/indra/newview/skins/default/xui/en/sidepanel_task_info.xml +++ b/indra/newview/skins/default/xui/en/sidepanel_task_info.xml @@ -1,437 +1,437 @@ - - Deed - - - Deed - - - You can modify this object - - - You can modify these objects - - - You can't modify this object - - - You can't modify these objects - - - You can't modify this object across a region boundary - - - You can't modify these objects across a region boundary - - - This object has linked parts - - - Price: L$ - - - Total Price: L$ - - - Price Per: L$ - - - Mixed Price - - - Mixed Sale - + height="570" + layout="topleft" + name="object properties" + help_topic="object_properties" + title="Object Profile" + width="333"> + + Deed + + + Deed + + + You can modify this object + + + You can modify these objects + + + You can't modify this object + + + You can't modify these objects + + + You can't modify this object across a region boundary + + + You can't modify these objects across a region boundary + + + This object has linked parts + + + Price: L$ + + + Total Price: L$ + + + Price Per: L$ + + + Mixed Price + + + Mixed Sale + +