summaryrefslogtreecommitdiff
path: root/indra/newview/llfloaterbuycontents.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/llfloaterbuycontents.cpp')
-rw-r--r--indra/newview/llfloaterbuycontents.cpp24
1 files changed, 12 insertions, 12 deletions
diff --git a/indra/newview/llfloaterbuycontents.cpp b/indra/newview/llfloaterbuycontents.cpp
index 9bde3b1dac..76ec5da303 100644
--- a/indra/newview/llfloaterbuycontents.cpp
+++ b/indra/newview/llfloaterbuycontents.cpp
@@ -69,9 +69,9 @@ BOOL LLFloaterBuyContents::postBuild()
getChild<LLUICtrl>("cancel_btn")->setCommitCallback( boost::bind(&LLFloaterBuyContents::onClickCancel, this));
getChild<LLUICtrl>("buy_btn")->setCommitCallback( boost::bind(&LLFloaterBuyContents::onClickBuy, this));
- childDisable("item_list");
- childDisable("buy_btn");
- childDisable("wear_check");
+ getChildView("item_list")->setEnabled(FALSE);
+ getChildView("buy_btn")->setEnabled(FALSE);
+ getChildView("wear_check")->setEnabled(FALSE);
setDefaultBtn("cancel_btn"); // to avoid accidental buy (SL-43130)
@@ -129,9 +129,9 @@ void LLFloaterBuyContents::show(const LLSaleInfo& sale_info)
gCacheName->getGroupName(owner_id, owner_name);
}
- floater->childSetTextArg("contains_text", "[NAME]", node->mName);
- floater->childSetTextArg("buy_text", "[AMOUNT]", llformat("%d", sale_info.getSalePrice()));
- floater->childSetTextArg("buy_text", "[NAME]", owner_name);
+ floater->getChild<LLUICtrl>("contains_text")->setTextArg("[NAME]", node->mName);
+ floater->getChild<LLUICtrl>("buy_text")->setTextArg("[AMOUNT]", llformat("%d", sale_info.getSalePrice()));
+ floater->getChild<LLUICtrl>("buy_text")->setTextArg("[NAME]", owner_name);
// Must do this after the floater is created, because
// sometimes the inventory is already there and
@@ -169,7 +169,7 @@ void LLFloaterBuyContents::inventoryChanged(LLViewerObject* obj,
}
// default to turning off the buy button.
- childDisable("buy_btn");
+ getChildView("buy_btn")->setEnabled(FALSE);
LLUUID owner_id;
BOOL is_group_owned;
@@ -210,7 +210,7 @@ void LLFloaterBuyContents::inventoryChanged(LLViewerObject* obj,
// There will be at least one item shown in the display, so go
// ahead and enable the buy button.
- childEnable("buy_btn");
+ getChildView("buy_btn")->setEnabled(TRUE);
// Create the line in the list
LLSD row;
@@ -256,8 +256,8 @@ void LLFloaterBuyContents::inventoryChanged(LLViewerObject* obj,
if (wearable_count > 0)
{
- childEnable("wear_check");
- childSetValue("wear_check", LLSD(false) );
+ getChildView("wear_check")->setEnabled(TRUE);
+ getChild<LLUICtrl>("wear_check")->setValue(LLSD(false) );
}
removeVOInventoryListener();
@@ -268,7 +268,7 @@ void LLFloaterBuyContents::onClickBuy()
{
// Make sure this wasn't selected through other mechanisms
// (ie, being the default button and pressing enter.
- if(!childIsEnabled("buy_btn"))
+ if(!getChildView("buy_btn")->getEnabled())
{
// We shouldn't be enabled. Just close.
closeFloater();
@@ -276,7 +276,7 @@ void LLFloaterBuyContents::onClickBuy()
}
// We may want to wear this item
- if (childGetValue("wear_check"))
+ if (getChild<LLUICtrl>("wear_check")->getValue())
{
LLInventoryState::sWearNewClothing = TRUE;
}