aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/linden/indra/newview/llpanelinventory.cpp
diff options
context:
space:
mode:
authorJacek Antonelli2008-08-15 23:44:54 -0500
committerJacek Antonelli2008-08-15 23:44:54 -0500
commitb2afb8800bb033a04bb3ecdf0363068d56648ef1 (patch)
tree3568129b5bbddb47cd39d622b4137a8fbff4abaf /linden/indra/newview/llpanelinventory.cpp
parentSecond Life viewer sources 1.14.0.1 (diff)
downloadmeta-impy-b2afb8800bb033a04bb3ecdf0363068d56648ef1.zip
meta-impy-b2afb8800bb033a04bb3ecdf0363068d56648ef1.tar.gz
meta-impy-b2afb8800bb033a04bb3ecdf0363068d56648ef1.tar.bz2
meta-impy-b2afb8800bb033a04bb3ecdf0363068d56648ef1.tar.xz
Second Life viewer sources 1.15.0.2
Diffstat (limited to '')
-rw-r--r--linden/indra/newview/llpanelinventory.cpp53
1 files changed, 34 insertions, 19 deletions
diff --git a/linden/indra/newview/llpanelinventory.cpp b/linden/indra/newview/llpanelinventory.cpp
index d9638fd..2089a6c 100644
--- a/linden/indra/newview/llpanelinventory.cpp
+++ b/linden/indra/newview/llpanelinventory.cpp
@@ -4,6 +4,7 @@
4 * 4 *
5 * Copyright (c) 2002-2007, Linden Research, Inc. 5 * Copyright (c) 2002-2007, Linden Research, Inc.
6 * 6 *
7 * Second Life Viewer Source Code
7 * The source code in this file ("Source Code") is provided by Linden Lab 8 * The source code in this file ("Source Code") is provided by Linden Lab
8 * to you under the terms of the GNU General Public License, version 2.0 9 * to you under the terms of the GNU General Public License, version 2.0
9 * ("GPL"), unless you have obtained a separate licensing agreement 10 * ("GPL"), unless you have obtained a separate licensing agreement
@@ -93,6 +94,7 @@ protected:
93 LLString mName; 94 LLString mName;
94 mutable LLString mDisplayName; 95 mutable LLString mDisplayName;
95 LLPanelInventory* mPanel; 96 LLPanelInventory* mPanel;
97 U32 mFlags;
96 98
97 LLInventoryItem* findItem() const; 99 LLInventoryItem* findItem() const;
98 100
@@ -100,7 +102,8 @@ public:
100 LLTaskInvFVBridge( 102 LLTaskInvFVBridge(
101 LLPanelInventory* panel, 103 LLPanelInventory* panel,
102 const LLUUID& uuid, 104 const LLUUID& uuid,
103 const LLString& name); 105 const LLString& name,
106 U32 flags=0);
104 virtual ~LLTaskInvFVBridge( void ) {} 107 virtual ~LLTaskInvFVBridge( void ) {}
105 108
106 virtual LLFontGL::StyleFlags getLabelStyle() const { return LLFontGL::NORMAL; } 109 virtual LLFontGL::StyleFlags getLabelStyle() const { return LLFontGL::NORMAL; }
@@ -152,11 +155,14 @@ public:
152LLTaskInvFVBridge::LLTaskInvFVBridge( 155LLTaskInvFVBridge::LLTaskInvFVBridge(
153 LLPanelInventory* panel, 156 LLPanelInventory* panel,
154 const LLUUID& uuid, 157 const LLUUID& uuid,
155 const LLString& name): 158 const LLString& name,
159 U32 flags):
156 mUUID(uuid), 160 mUUID(uuid),
157 mName(name), 161 mName(name),
158 mPanel(panel) 162 mPanel(panel),
163 mFlags(flags)
159{ 164{
165
160} 166}
161 167
162LLInventoryItem* LLTaskInvFVBridge::findItem() const 168LLInventoryItem* LLTaskInvFVBridge::findItem() const
@@ -322,7 +328,13 @@ U32 LLTaskInvFVBridge::getCreationDate() const
322 328
323LLViewerImage* LLTaskInvFVBridge::getIcon() const 329LLViewerImage* LLTaskInvFVBridge::getIcon() const
324{ 330{
325 return get_item_icon(LLAssetType::AT_OBJECT, LLInventoryType::IT_OBJECT, 0); 331 BOOL item_is_multi = FALSE;
332 if ( mFlags & LLInventoryItem::II_FLAGS_OBJECT_HAS_MULTIPLE_ITEMS )
333 {
334 item_is_multi = TRUE;
335 }
336
337 return get_item_icon(LLAssetType::AT_OBJECT, LLInventoryType::IT_OBJECT, 0, item_is_multi );
326} 338}
327 339
328void LLTaskInvFVBridge::openItem() 340void LLTaskInvFVBridge::openItem()
@@ -867,7 +879,7 @@ LLTaskTextureBridge::LLTaskTextureBridge(
867 879
868LLViewerImage* LLTaskTextureBridge::getIcon() const 880LLViewerImage* LLTaskTextureBridge::getIcon() const
869{ 881{
870 return get_item_icon(LLAssetType::AT_TEXTURE, mInventoryType, 0); 882 return get_item_icon(LLAssetType::AT_TEXTURE, mInventoryType, 0, FALSE);
871} 883}
872 884
873void LLTaskTextureBridge::openItem() 885void LLTaskTextureBridge::openItem()
@@ -919,7 +931,7 @@ LLTaskSoundBridge::LLTaskSoundBridge(
919 931
920LLViewerImage* LLTaskSoundBridge::getIcon() const 932LLViewerImage* LLTaskSoundBridge::getIcon() const
921{ 933{
922 return get_item_icon(LLAssetType::AT_SOUND, LLInventoryType::IT_SOUND, 0); 934 return get_item_icon(LLAssetType::AT_SOUND, LLInventoryType::IT_SOUND, 0, FALSE);
923} 935}
924 936
925void LLTaskSoundBridge::openItem() 937void LLTaskSoundBridge::openItem()
@@ -1051,7 +1063,7 @@ LLTaskLandmarkBridge::LLTaskLandmarkBridge(
1051 1063
1052LLViewerImage* LLTaskLandmarkBridge::getIcon() const 1064LLViewerImage* LLTaskLandmarkBridge::getIcon() const
1053{ 1065{
1054 return get_item_icon(LLAssetType::AT_LANDMARK, LLInventoryType::IT_LANDMARK, 0); 1066 return get_item_icon(LLAssetType::AT_LANDMARK, LLInventoryType::IT_LANDMARK, 0, FALSE);
1055} 1067}
1056 1068
1057 1069
@@ -1082,7 +1094,7 @@ LLTaskCallingCardBridge::LLTaskCallingCardBridge(
1082 1094
1083LLViewerImage* LLTaskCallingCardBridge::getIcon() const 1095LLViewerImage* LLTaskCallingCardBridge::getIcon() const
1084{ 1096{
1085 return get_item_icon(LLAssetType::AT_CALLINGCARD, LLInventoryType::IT_CALLINGCARD, 0); 1097 return get_item_icon(LLAssetType::AT_CALLINGCARD, LLInventoryType::IT_CALLINGCARD, 0, FALSE);
1086} 1098}
1087 1099
1088BOOL LLTaskCallingCardBridge::isItemRenameable() const 1100BOOL LLTaskCallingCardBridge::isItemRenameable() const
@@ -1122,7 +1134,7 @@ LLTaskScriptBridge::LLTaskScriptBridge(
1122 1134
1123LLViewerImage* LLTaskScriptBridge::getIcon() const 1135LLViewerImage* LLTaskScriptBridge::getIcon() const
1124{ 1136{
1125 return get_item_icon(LLAssetType::AT_SCRIPT, LLInventoryType::IT_LSL, 0); 1137 return get_item_icon(LLAssetType::AT_SCRIPT, LLInventoryType::IT_LSL, 0, FALSE);
1126} 1138}
1127 1139
1128 1140
@@ -1221,9 +1233,14 @@ LLTaskObjectBridge::LLTaskObjectBridge(
1221 1233
1222LLViewerImage* LLTaskObjectBridge::getIcon() const 1234LLViewerImage* LLTaskObjectBridge::getIcon() const
1223{ 1235{
1224 return get_item_icon(LLAssetType::AT_OBJECT, LLInventoryType::IT_OBJECT, 0); 1236 BOOL item_is_multi = FALSE;
1225} 1237 if ( mFlags & LLInventoryItem::II_FLAGS_OBJECT_HAS_MULTIPLE_ITEMS )
1238 {
1239 item_is_multi = TRUE;
1240 }
1226 1241
1242 return get_item_icon(LLAssetType::AT_OBJECT, LLInventoryType::IT_OBJECT, 0, item_is_multi);
1243}
1227 1244
1228///---------------------------------------------------------------------------- 1245///----------------------------------------------------------------------------
1229/// Class LLTaskNotecardBridge 1246/// Class LLTaskNotecardBridge
@@ -1252,7 +1269,7 @@ LLTaskNotecardBridge::LLTaskNotecardBridge(
1252 1269
1253LLViewerImage* LLTaskNotecardBridge::getIcon() const 1270LLViewerImage* LLTaskNotecardBridge::getIcon() const
1254{ 1271{
1255 return get_item_icon(LLAssetType::AT_NOTECARD, LLInventoryType::IT_NOTECARD, 0); 1272 return get_item_icon(LLAssetType::AT_NOTECARD, LLInventoryType::IT_NOTECARD, 0, FALSE);
1256} 1273}
1257 1274
1258void LLTaskNotecardBridge::openItem() 1275void LLTaskNotecardBridge::openItem()
@@ -1318,7 +1335,7 @@ LLTaskGestureBridge::LLTaskGestureBridge(
1318 1335
1319LLViewerImage* LLTaskGestureBridge::getIcon() const 1336LLViewerImage* LLTaskGestureBridge::getIcon() const
1320{ 1337{
1321 return get_item_icon(LLAssetType::AT_GESTURE, LLInventoryType::IT_GESTURE, 0); 1338 return get_item_icon(LLAssetType::AT_GESTURE, LLInventoryType::IT_GESTURE, 0, FALSE);
1322} 1339}
1323 1340
1324void LLTaskGestureBridge::openItem() 1341void LLTaskGestureBridge::openItem()
@@ -1378,7 +1395,7 @@ LLTaskAnimationBridge::LLTaskAnimationBridge(
1378 1395
1379LLViewerImage* LLTaskAnimationBridge::getIcon() const 1396LLViewerImage* LLTaskAnimationBridge::getIcon() const
1380{ 1397{
1381 return get_item_icon(LLAssetType::AT_ANIMATION, LLInventoryType::IT_ANIMATION, 0); 1398 return get_item_icon(LLAssetType::AT_ANIMATION, LLInventoryType::IT_ANIMATION, 0, FALSE);
1382} 1399}
1383 1400
1384void LLTaskAnimationBridge::openItem() 1401void LLTaskAnimationBridge::openItem()
@@ -1447,7 +1464,6 @@ public:
1447 1464
1448protected: 1465protected:
1449 LLAssetType::EType mAssetType; 1466 LLAssetType::EType mAssetType;
1450 U32 mWearableType;
1451}; 1467};
1452 1468
1453LLTaskWearableBridge::LLTaskWearableBridge( 1469LLTaskWearableBridge::LLTaskWearableBridge(
@@ -1456,15 +1472,14 @@ LLTaskWearableBridge::LLTaskWearableBridge(
1456 const LLString& name, 1472 const LLString& name,
1457 LLAssetType::EType asset_type, 1473 LLAssetType::EType asset_type,
1458 U32 flags) : 1474 U32 flags) :
1459 LLTaskInvFVBridge(panel, uuid, name), 1475 LLTaskInvFVBridge(panel, uuid, name, flags),
1460 mAssetType( asset_type ), 1476 mAssetType( asset_type )
1461 mWearableType(flags)
1462{ 1477{
1463} 1478}
1464 1479
1465LLViewerImage* LLTaskWearableBridge::getIcon() const 1480LLViewerImage* LLTaskWearableBridge::getIcon() const
1466{ 1481{
1467 return get_item_icon(mAssetType, LLInventoryType::IT_WEARABLE, mWearableType); 1482 return get_item_icon(mAssetType, LLInventoryType::IT_WEARABLE, mFlags, FALSE );
1468} 1483}
1469 1484
1470 1485