summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
Diffstat (limited to 'indra')
-rw-r--r--indra/newview/llgroupiconctrl.cpp20
-rw-r--r--indra/newview/llgroupiconctrl.h8
-rw-r--r--indra/newview/llinspectgroup.cpp3
-rw-r--r--indra/newview/lltexturectrl.cpp2
-rw-r--r--indra/newview/skins/default/xui/en/inspect_group.xml2
5 files changed, 21 insertions, 14 deletions
diff --git a/indra/newview/llgroupiconctrl.cpp b/indra/newview/llgroupiconctrl.cpp
index 271dd44c1f..7c2a3cad43 100644
--- a/indra/newview/llgroupiconctrl.cpp
+++ b/indra/newview/llgroupiconctrl.cpp
@@ -74,9 +74,16 @@ LLGroupIconCtrl::~LLGroupIconCtrl()
LLGroupMgr::getInstance()->removeObserver(this);
}
-void LLGroupIconCtrl::setIconId(const LLSD& value)
+void LLGroupIconCtrl::setIconId(const LLUUID& icon_id)
{
- LLIconCtrl::setValue(value);
+ if (icon_id.notNull())
+ {
+ LLIconCtrl::setValue(icon_id);
+ }
+ else
+ {
+ LLIconCtrl::setValue(mDefaultIconName, LLViewerFetchedTexture::BOOST_UI);
+ }
}
void LLGroupIconCtrl::setValue(const LLSD& value)
@@ -122,14 +129,7 @@ bool LLGroupIconCtrl::updateFromCache()
LLGroupMgrGroupData* group_data = LLGroupMgr::getInstance()->getGroupData(mGroupId);
if (!group_data) return false;
- if (group_data->mInsigniaID.notNull())
- {
- LLIconCtrl::setValue(group_data->mInsigniaID);
- }
- else
- {
- LLIconCtrl::setValue(mDefaultIconName, LLViewerFetchedTexture::BOOST_UI);
- }
+ setIconId(group_data->mInsigniaID);
if (mDrawTooltip && !group_data->mName.empty())
{
diff --git a/indra/newview/llgroupiconctrl.h b/indra/newview/llgroupiconctrl.h
index f8b22cf581..43e384d3e2 100644
--- a/indra/newview/llgroupiconctrl.h
+++ b/indra/newview/llgroupiconctrl.h
@@ -66,7 +66,13 @@ public:
*/
virtual void setValue(const LLSD& value);
- void setIconId(const LLSD& value);
+ /**
+ * Sets icon_id as icon value directly. Avoids LLGroupMgr cache checks for group id
+ * Uses default icon in case id is null.
+ *
+ * @params icon_id - it is processed as icon id, default image will be used in case id is null.
+ */
+ void setIconId(const LLUUID& icon_id);
// LLGroupMgrObserver observer trigger
virtual void changed(LLGroupChange gc);
diff --git a/indra/newview/llinspectgroup.cpp b/indra/newview/llinspectgroup.cpp
index 8e91af321e..0c5a91e48a 100644
--- a/indra/newview/llinspectgroup.cpp
+++ b/indra/newview/llinspectgroup.cpp
@@ -233,7 +233,8 @@ void LLInspectGroup::processGroupData()
getChild<LLUICtrl>("group_details")->setValue( LLSD(data->mCharter) );
- getChild<LLUICtrl>("group_icon")->setValue( LLSD(data->mInsigniaID) );
+ // LLGroupIconCtrl
+ getChild<LLUICtrl>("group_icon")->setValue(LLSD(mGroupID));
std::string cost;
bool is_member = LLGroupActions::isInGroup(mGroupID);
diff --git a/indra/newview/lltexturectrl.cpp b/indra/newview/lltexturectrl.cpp
index e5aa740a33..980810835e 100644
--- a/indra/newview/lltexturectrl.cpp
+++ b/indra/newview/lltexturectrl.cpp
@@ -1393,7 +1393,7 @@ void LLTextureCtrl::setOnTextureSelectedCallback(texture_selected_callback cb)
void LLTextureCtrl::setImageAssetName(const std::string& name)
{
- LLPointer<LLUIImage> imagep = LLUI::getUIImage(name, LLGLTexture::BOOST_PREVIEW);
+ LLPointer<LLUIImage> imagep = LLUI::getUIImage(name);
if(imagep)
{
LLViewerFetchedTexture* pTexture = dynamic_cast<LLViewerFetchedTexture*>(imagep->getImage().get());
diff --git a/indra/newview/skins/default/xui/en/inspect_group.xml b/indra/newview/skins/default/xui/en/inspect_group.xml
index 324ff3eabd..a69585074c 100644
--- a/indra/newview/skins/default/xui/en/inspect_group.xml
+++ b/indra/newview/skins/default/xui/en/inspect_group.xml
@@ -66,7 +66,7 @@ Fear the moose! Fear it! And the mongoose too!
width="220">
L$123 to join
</text>
- <icon
+ <group_icon
follows="all"
height="38"
right="-10"