summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
authorAndrew Dyukov <adyukov@productengine.com>2010-07-27 18:30:35 +0300
committerAndrew Dyukov <adyukov@productengine.com>2010-07-27 18:30:35 +0300
commit4c693bfe89e930ce958a65b4521f36d5079dd907 (patch)
treee5d1f94763436a3706dc870b44f2da5f56e0e457 /indra
parent431a6771ccf22501d47d0f09168926239aa21854 (diff)
EXT-2707 FIXED Fixed incorrectness of coalesced objects icons in inventory.
Bug was caused by multiobject's icon name index substitution with ordinary object's one. It happened because index was set depending on asset type in switch that followed "if" which set index for multiobject regardless of its result. - Added returning index icon name inside of "if" block to avoid change of the index by switch for multiobject. Reviewed by Mike Antipov at https://codereview.productengine.com/secondlife/r/804/ --HG-- branch : product-engine
Diffstat (limited to 'indra')
-rw-r--r--indra/newview/llpanelgroupgeneral.cpp20
-rw-r--r--indra/newview/llpanelgroupgeneral.h1
2 files changed, 8 insertions, 13 deletions
diff --git a/indra/newview/llpanelgroupgeneral.cpp b/indra/newview/llpanelgroupgeneral.cpp
index 8e1b7ba4d9..2302772803 100644
--- a/indra/newview/llpanelgroupgeneral.cpp
+++ b/indra/newview/llpanelgroupgeneral.cpp
@@ -184,8 +184,7 @@ BOOL LLPanelGroupGeneral::postBuild()
mComboActiveTitle = getChild<LLComboBox>("active_title", recurse);
if (mComboActiveTitle)
{
- mComboActiveTitle->setCommitCallback(onCommitTitle, this);
- mComboActiveTitle->resetDirty();
+ mComboActiveTitle->setCommitCallback(onCommitAny, this);
}
mIncompleteMemberDataStr = getString("incomplete_member_data_str");
@@ -278,16 +277,6 @@ void LLPanelGroupGeneral::onCommitEnrollment(LLUICtrl* ctrl, void* data)
}
// static
-void LLPanelGroupGeneral::onCommitTitle(LLUICtrl* ctrl, void* data)
-{
- LLPanelGroupGeneral* self = (LLPanelGroupGeneral*)data;
- if (self->mGroupID.isNull() || !self->mAllowEdit) return;
- LLGroupMgr::getInstance()->sendGroupTitleUpdate(self->mGroupID,self->mComboActiveTitle->getCurrentID());
- self->update(GC_TITLES);
- self->mComboActiveTitle->resetDirty();
-}
-
-// static
void LLPanelGroupGeneral::onClickInfo(void *userdata)
{
LLPanelGroupGeneral *self = (LLPanelGroupGeneral *)userdata;
@@ -356,6 +345,13 @@ void LLPanelGroupGeneral::draw()
bool LLPanelGroupGeneral::apply(std::string& mesg)
{
+ if (!mGroupID.isNull() && mAllowEdit && mComboActiveTitle && mComboActiveTitle->isDirty())
+ {
+ LLGroupMgr::getInstance()->sendGroupTitleUpdate(mGroupID,mComboActiveTitle->getCurrentID());
+ update(GC_TITLES);
+ mComboActiveTitle->resetDirty();
+ }
+
BOOL has_power_in_group = gAgent.hasPowerInGroup(mGroupID,GP_GROUP_CHANGE_IDENTITY);
if (has_power_in_group || mGroupID.isNull())
diff --git a/indra/newview/llpanelgroupgeneral.h b/indra/newview/llpanelgroupgeneral.h
index 6f4fa994da..358d353074 100644
--- a/indra/newview/llpanelgroupgeneral.h
+++ b/indra/newview/llpanelgroupgeneral.h
@@ -77,7 +77,6 @@ private:
static void onFocusEdit(LLFocusableElement* ctrl, void* data);
static void onCommitAny(LLUICtrl* ctrl, void* data);
static void onCommitUserOnly(LLUICtrl* ctrl, void* data);
- static void onCommitTitle(LLUICtrl* ctrl, void* data);
static void onCommitEnrollment(LLUICtrl* ctrl, void* data);
static void onClickInfo(void* userdata);
static void onReceiveNotices(LLUICtrl* ctrl, void* data);