summaryrefslogtreecommitdiff
path: root/indra/newview/llpanelprofileclassifieds.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/llpanelprofileclassifieds.cpp')
-rw-r--r--indra/newview/llpanelprofileclassifieds.cpp22
1 files changed, 20 insertions, 2 deletions
diff --git a/indra/newview/llpanelprofileclassifieds.cpp b/indra/newview/llpanelprofileclassifieds.cpp
index 3fbaad4dee..307935f45f 100644
--- a/indra/newview/llpanelprofileclassifieds.cpp
+++ b/indra/newview/llpanelprofileclassifieds.cpp
@@ -650,6 +650,8 @@ BOOL LLPanelProfileClassified::postBuild()
mSnapshotCtrl->setOnSelectCallback(boost::bind(&LLPanelProfileClassified::onTextureSelected, this));
mSnapshotCtrl->setMouseEnterCallback(boost::bind(&LLPanelProfileClassified::onTexturePickerMouseEnter, this));
mSnapshotCtrl->setMouseLeaveCallback(boost::bind(&LLPanelProfileClassified::onTexturePickerMouseLeave, this));
+ mSnapshotCtrl->setAllowLocalTexture(FALSE);
+ mSnapshotCtrl->setBakeTextureEnabled(FALSE);
mEditIcon->setVisible(false);
mMapButton->setCommitCallback(boost::bind(&LLPanelProfileClassified::onMapClick, this));
@@ -667,7 +669,7 @@ BOOL LLPanelProfileClassified::postBuild()
mCategoryCombo->add(LLTrans::getString(iter->second));
}
- mClassifiedNameEdit->setKeystrokeCallback(boost::bind(&LLPanelProfileClassified::onChange, this), NULL);
+ mClassifiedNameEdit->setKeystrokeCallback(boost::bind(&LLPanelProfileClassified::onTitleChange, this), NULL);
mClassifiedDescEdit->setKeystrokeCallback(boost::bind(&LLPanelProfileClassified::onChange, this));
mCategoryCombo->setCommitCallback(boost::bind(&LLPanelProfileClassified::onChange, this));
mContentTypeCombo->setCommitCallback(boost::bind(&LLPanelProfileClassified::onChange, this));
@@ -935,6 +937,8 @@ void LLPanelProfileClassified::onCancelClick()
}
else
{
+ updateTabLabel(mClassifiedNameText->getValue());
+
// Reload data to undo changes to forms
LLAvatarPropertiesProcessor::getInstance()->sendClassifiedInfoRequest(getClassifiedId());
}
@@ -955,7 +959,7 @@ void LLPanelProfileClassified::onSaveClick()
}
if(isNew() || isNewWithErrors())
{
- if(gStatusBar->getBalance() < getPriceForListing())
+ if(gStatusBar->getBalance() < MINIMUM_PRICE_FOR_LISTING)
{
LLNotificationsUtil::add("ClassifiedInsufficientFunds");
return;
@@ -1403,6 +1407,12 @@ void LLPanelProfileClassified::onChange()
enableSave(isDirty());
}
+void LLPanelProfileClassified::onTitleChange()
+{
+ updateTabLabel(getClassifiedName());
+ onChange();
+}
+
void LLPanelProfileClassified::doSave()
{
//*TODO: Fix all of this
@@ -1428,6 +1438,14 @@ void LLPanelProfileClassified::doSave()
void LLPanelProfileClassified::onPublishFloaterPublishClicked()
{
+ if (mPublishFloater->getPrice() < MINIMUM_PRICE_FOR_LISTING)
+ {
+ LLSD args;
+ args["MIN_PRICE"] = MINIMUM_PRICE_FOR_LISTING;
+ LLNotificationsUtil::add("MinClassifiedPrice", args);
+ return;
+ }
+
setPriceForListing(mPublishFloater->getPrice());
doSave();