summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
authorLoren Shih <seraph@lindenlab.com>2010-03-03 11:03:46 -0500
committerLoren Shih <seraph@lindenlab.com>2010-03-03 11:03:46 -0500
commit0ac63ffbb1acb32278645f6a9ab97cdc271c8d30 (patch)
tree0acf4fba455152d0ac0106a3162580cfe35d00b3 /indra
parent6ebc1d8858e77ed00d3363ce1d8d18be5dc2a3a2 (diff)
EXT-4013 : Functionality loss: Inspect object
Detail button implemented as instructed; this brings up the old 1.23 multi-inspect floater.
Diffstat (limited to 'indra')
-rw-r--r--indra/newview/llsidepaneltaskinfo.cpp16
-rw-r--r--indra/newview/llsidepaneltaskinfo.h2
-rw-r--r--indra/newview/skins/default/xui/en/sidepanel_task_info.xml11
3 files changed, 29 insertions, 0 deletions
diff --git a/indra/newview/llsidepaneltaskinfo.cpp b/indra/newview/llsidepaneltaskinfo.cpp
index 0630981d7e..6ebe55e362 100644
--- a/indra/newview/llsidepaneltaskinfo.cpp
+++ b/indra/newview/llsidepaneltaskinfo.cpp
@@ -100,6 +100,8 @@ BOOL LLSidepanelTaskInfo::postBuild()
mPayBtn->setClickedCallback(boost::bind(&LLSidepanelTaskInfo::onPayButtonClicked, this));
mBuyBtn = getChild<LLButton>("buy_btn");
mBuyBtn->setClickedCallback(boost::bind(&LLSidepanelTaskInfo::onBuyButtonClicked, this));
+ mDetailsBtn = getChild<LLButton>("details_btn");
+ mDetailsBtn->setClickedCallback(boost::bind(&LLSidepanelTaskInfo::onDetailsButtonClicked, this));
mLabelGroupName = getChild<LLNameBox>("Group Name Proxy");
@@ -1122,6 +1124,15 @@ void LLSidepanelTaskInfo::updateVerbs()
//mEditBtn->setEnabled(obj && obj->permModify());
*/
+ LLSafeHandle<LLObjectSelection> object_selection = LLSelectMgr::getInstance()->getSelection();
+ const BOOL multi_select = (object_selection->getNumNodes() > 1);
+
+ mOpenBtn->setVisible(!multi_select);
+ mPayBtn->setVisible(!multi_select);
+ mBuyBtn->setVisible(!multi_select);
+ mDetailsBtn->setVisible(multi_select);
+ mDetailsBtn->setEnabled(multi_select);
+
mOpenBtn->setEnabled(enable_object_open());
mPayBtn->setEnabled(enable_pay_object());
mBuyBtn->setEnabled(enable_buy_object());
@@ -1145,6 +1156,11 @@ void LLSidepanelTaskInfo::onBuyButtonClicked()
doClickAction(CLICK_ACTION_BUY);
}
+void LLSidepanelTaskInfo::onDetailsButtonClicked()
+{
+ LLFloaterReg::showInstance("inspect", LLSD());
+}
+
// virtual
void LLSidepanelTaskInfo::save()
{
diff --git a/indra/newview/llsidepaneltaskinfo.h b/indra/newview/llsidepaneltaskinfo.h
index cf36c20767..e41627435f 100644
--- a/indra/newview/llsidepaneltaskinfo.h
+++ b/indra/newview/llsidepaneltaskinfo.h
@@ -109,10 +109,12 @@ protected:
void onOpenButtonClicked();
void onPayButtonClicked();
void onBuyButtonClicked();
+ void onDetailsButtonClicked();
private:
LLButton* mOpenBtn;
LLButton* mPayBtn;
LLButton* mBuyBtn;
+ LLButton* mDetailsBtn;
protected:
LLViewerObject* getObject();
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 d2c9e56bc3..6588663bac 100644
--- a/indra/newview/skins/default/xui/en/sidepanel_task_info.xml
+++ b/indra/newview/skins/default/xui/en/sidepanel_task_info.xml
@@ -549,5 +549,16 @@
name="buy_btn"
top="0"
width="100" />
+ <button
+ follows="bottom|left"
+ height="23"
+ label="Details"
+ layout="topleft"
+ left="5"
+ name="details_btn"
+ top="0"
+ width="100"
+ visible="false" />
+
</panel>
</panel>