summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
Diffstat (limited to 'indra')
-rw-r--r--indra/newview/llagentwearables.cpp1
-rw-r--r--indra/newview/llappearancemgr.cpp37
-rw-r--r--indra/newview/llinventorybridge.cpp14
-rw-r--r--indra/newview/llvoavatar.cpp5
-rw-r--r--indra/newview/llvoavatar.h4
-rw-r--r--indra/newview/llvoavatarself.cpp26
-rw-r--r--indra/newview/llvoavatarself.h4
-rw-r--r--indra/newview/llwearable.cpp33
-rw-r--r--indra/newview/skins/default/xui/es/menu_viewer.xml2
-rw-r--r--indra/newview/skins/default/xui/pt/panel_login.xml10
10 files changed, 111 insertions, 25 deletions
diff --git a/indra/newview/llagentwearables.cpp b/indra/newview/llagentwearables.cpp
index 7b55282ee5..ea10917901 100644
--- a/indra/newview/llagentwearables.cpp
+++ b/indra/newview/llagentwearables.cpp
@@ -1759,6 +1759,7 @@ void LLAgentWearables::setWearableOutfit(const LLInventoryItem::item_array_t& it
if (mAvatarObject)
{
+ mAvatarObject->setCompositeUpdatesEnabled(TRUE);
mAvatarObject->updateVisualParams();
mAvatarObject->invalidateAll();
}
diff --git a/indra/newview/llappearancemgr.cpp b/indra/newview/llappearancemgr.cpp
index 82110f3ab7..f2d15757c9 100644
--- a/indra/newview/llappearancemgr.cpp
+++ b/indra/newview/llappearancemgr.cpp
@@ -1130,6 +1130,22 @@ void LLAppearanceManager::updateAgentWearables(LLWearableHoldingPattern* holder,
// dec_busy_count();
}
+static void remove_non_link_items(LLInventoryModel::item_array_t &items)
+{
+ LLInventoryModel::item_array_t pruned_items;
+ for (LLInventoryModel::item_array_t::const_iterator iter = items.begin();
+ iter != items.end();
+ ++iter)
+ {
+ const LLViewerInventoryItem *item = (*iter);
+ if (item && item->getIsLinkType())
+ {
+ pruned_items.push_back((*iter));
+ }
+ }
+ items = pruned_items;
+}
+
void LLAppearanceManager::updateAppearanceFromCOF()
{
// update dirty flag to see if the state of the COF matches
@@ -1143,13 +1159,17 @@ void LLAppearanceManager::updateAppearanceFromCOF()
bool follow_folder_links = true;
LLUUID current_outfit_id = getCOF();
- // Find all the wearables that are in the COF's subtree.
+ // Find all the wearables that are in the COF's subtree.
lldebugs << "LLAppearanceManager::updateFromCOF()" << llendl;
LLInventoryModel::item_array_t wear_items;
LLInventoryModel::item_array_t obj_items;
LLInventoryModel::item_array_t gest_items;
getUserDescendents(current_outfit_id, wear_items, obj_items, gest_items, follow_folder_links);
-
+ // Get rid of non-links in case somehow the COF was corrupted.
+ remove_non_link_items(wear_items);
+ remove_non_link_items(obj_items);
+ remove_non_link_items(gest_items);
+
if(!wear_items.count())
{
LLNotificationsUtil::add("CouldNotPutOnOutfit");
@@ -1173,7 +1193,7 @@ void LLAppearanceManager::updateAppearanceFromCOF()
{
LLViewerInventoryItem *item = wear_items.get(i);
LLViewerInventoryItem *linked_item = item ? item->getLinkedItem() : NULL;
- if (item && linked_item)
+ if (item && item->getIsLinkType() && linked_item)
{
LLFoundData found(linked_item->getUUID(),
linked_item->getAssetUUID(),
@@ -1200,11 +1220,11 @@ void LLAppearanceManager::updateAppearanceFromCOF()
{
if (!item)
{
- llwarns << "attempt to wear a null item " << llendl;
+ llwarns << "Attempt to wear a null item " << llendl;
}
else if (!linked_item)
{
- llwarns << "attempt to wear a broken link " << item->getName() << llendl;
+ llwarns << "Attempt to wear a broken link [ name:" << item->getName() << " ] " << llendl;
}
}
}
@@ -1734,6 +1754,13 @@ BOOL LLAppearanceManager::getIsProtectedCOFItem(const LLUUID& obj_id) const
{
if (!getIsInCOF(obj_id)) return FALSE;
+ // If a non-link somehow ended up in COF, allow deletion.
+ const LLInventoryObject *obj = gInventory.getObject(obj_id);
+ if (obj && !obj->getIsLinkType())
+ {
+ return FALSE;
+ }
+
// For now, don't allow direct deletion from the COF. Instead, force users
// to choose "Detach" or "Take Off".
return TRUE;
diff --git a/indra/newview/llinventorybridge.cpp b/indra/newview/llinventorybridge.cpp
index 27a40c6ba0..ceeffea1c9 100644
--- a/indra/newview/llinventorybridge.cpp
+++ b/indra/newview/llinventorybridge.cpp
@@ -683,14 +683,15 @@ void LLInvFVBridge::addTrashContextMenuOptions(menuentry_vec_t &items,
void LLInvFVBridge::addDeleteContextMenuOptions(menuentry_vec_t &items,
menuentry_vec_t &disabled_items)
{
+
+ const LLInventoryObject *obj = getInventoryObject();
+
// Don't allow delete as a direct option from COF folder.
- if (isCOFFolder())
+ if (obj && obj->getIsLinkType() && isCOFFolder())
{
return;
}
- const LLInventoryObject *obj = getInventoryObject();
-
// "Remove link" and "Delete" are the same operation.
if (obj && obj->getIsLinkType() && !get_is_item_worn(mUUID))
{
@@ -2689,8 +2690,7 @@ void LLFolderBridge::buildContextMenu(LLMenuGL& menu, U32 flags)
LLViewerInventoryCategory *cat = getCategory();
// BAP removed protected check to re-enable standard ops in untyped folders.
// Not sure what the right thing is to do here.
- if (!isCOFFolder() && cat && cat->getPreferredType()!=LLFolderType::FT_OUTFIT /*&&
- LLAssetType::lookupIsProtectedCategoryType(cat->getPreferredType())*/)
+ if (!isCOFFolder() && cat && (cat->getPreferredType() != LLFolderType::FT_OUTFIT))
{
// Do not allow to create 2-level subfolder in the Calling Card/Friends folder. EXT-694.
if (!LLFriendCardsManager::instance().isCategoryInFriendFolder(cat))
@@ -4276,7 +4276,7 @@ void LLObjectBridge::buildContextMenu(LLMenuGL& menu, U32 flags)
items.push_back(std::string("Attach Separator"));
items.push_back(std::string("Detach From Yourself"));
}
- else if (!isItemInTrash() && !isLinkedObjectInTrash() && !isLinkedObjectMissing())
+ else if (!isItemInTrash() && !isLinkedObjectInTrash() && !isLinkedObjectMissing() && !isCOFFolder())
{
items.push_back(std::string("Attach Separator"));
items.push_back(std::string("Object Wear"));
@@ -4702,7 +4702,7 @@ void LLWearableBridge::buildContextMenu(LLMenuGL& menu, U32 flags)
disabled_items.push_back(std::string("Wearable Edit"));
}
// Don't allow items to be worn if their baseobj is in the trash.
- if (isLinkedObjectInTrash() || isLinkedObjectMissing())
+ if (isLinkedObjectInTrash() || isLinkedObjectMissing() || isCOFFolder())
{
disabled_items.push_back(std::string("Wearable Wear"));
disabled_items.push_back(std::string("Wearable Add"));
diff --git a/indra/newview/llvoavatar.cpp b/indra/newview/llvoavatar.cpp
index 72b9c6df98..f5e83ed025 100644
--- a/indra/newview/llvoavatar.cpp
+++ b/indra/newview/llvoavatar.cpp
@@ -5785,11 +5785,6 @@ void LLVOAvatar::invalidateAll()
{
}
-// virtual
-void LLVOAvatar::setCompositeUpdatesEnabled( BOOL b )
-{
-}
-
void LLVOAvatar::onGlobalColorChanged(const LLTexGlobalColor* global_color, BOOL upload_bake )
{
if (global_color == mTexSkinColor)
diff --git a/indra/newview/llvoavatar.h b/indra/newview/llvoavatar.h
index b5f0ec7176..d5485413f4 100644
--- a/indra/newview/llvoavatar.h
+++ b/indra/newview/llvoavatar.h
@@ -526,7 +526,9 @@ protected:
public:
virtual void invalidateComposite(LLTexLayerSet* layerset, BOOL upload_result);
virtual void invalidateAll();
- virtual void setCompositeUpdatesEnabled(BOOL b);
+ virtual void setCompositeUpdatesEnabled(bool b) {}
+ virtual void setCompositeUpdatesEnabled(U32 index, bool b) {}
+ virtual bool isCompositeUpdateEnabled(U32 index) { return false; }
//--------------------------------------------------------------------
// Static texture/mesh/baked dictionary
diff --git a/indra/newview/llvoavatarself.cpp b/indra/newview/llvoavatarself.cpp
index 7dc8772753..32c24b3ebd 100644
--- a/indra/newview/llvoavatarself.cpp
+++ b/indra/newview/llvoavatarself.cpp
@@ -765,6 +765,7 @@ void LLVOAvatarSelf::removeMissingBakedTextures()
{
for (U32 i = 0; i < mBakedTextureDatas.size(); i++)
{
+ mBakedTextureDatas[i].mTexLayerSet->setUpdatesEnabled(TRUE);
invalidateComposite(mBakedTextureDatas[i].mTexLayerSet, FALSE);
}
updateMeshTextures();
@@ -952,6 +953,7 @@ void LLVOAvatarSelf::wearableUpdated( EWearableType type, BOOL upload_result )
{
if (mBakedTextureDatas[index].mTexLayerSet)
{
+ mBakedTextureDatas[index].mTexLayerSet->setUpdatesEnabled(true);
invalidateComposite(mBakedTextureDatas[index].mTexLayerSet, upload_result);
}
break;
@@ -1364,17 +1366,31 @@ void LLVOAvatarSelf::invalidateAll()
//-----------------------------------------------------------------------------
// setCompositeUpdatesEnabled()
//-----------------------------------------------------------------------------
-void LLVOAvatarSelf::setCompositeUpdatesEnabled( BOOL b )
+void LLVOAvatarSelf::setCompositeUpdatesEnabled( bool b )
{
for (U32 i = 0; i < mBakedTextureDatas.size(); i++)
{
- if (mBakedTextureDatas[i].mTexLayerSet )
- {
- mBakedTextureDatas[i].mTexLayerSet->setUpdatesEnabled( b );
- }
+ setCompositeUpdatesEnabled(i, b);
+ }
+}
+
+void LLVOAvatarSelf::setCompositeUpdatesEnabled(U32 index, bool b)
+{
+ if (mBakedTextureDatas[index].mTexLayerSet )
+ {
+ mBakedTextureDatas[index].mTexLayerSet->setUpdatesEnabled( b );
}
}
+bool LLVOAvatarSelf::isCompositeUpdateEnabled(U32 index)
+{
+ if (mBakedTextureDatas[index].mTexLayerSet)
+ {
+ return mBakedTextureDatas[index].mTexLayerSet->getUpdatesEnabled();
+ }
+ return false;
+}
+
void LLVOAvatarSelf::setupComposites()
{
for (U32 i = 0; i < mBakedTextureDatas.size(); i++)
diff --git a/indra/newview/llvoavatarself.h b/indra/newview/llvoavatarself.h
index df3493c434..9514abc5bc 100644
--- a/indra/newview/llvoavatarself.h
+++ b/indra/newview/llvoavatarself.h
@@ -232,7 +232,9 @@ public:
public:
/* virtual */ void invalidateComposite(LLTexLayerSet* layerset, BOOL upload_result);
/* virtual */ void invalidateAll();
- /* virtual */ void setCompositeUpdatesEnabled(BOOL b); // only works for self
+ /* virtual */ void setCompositeUpdatesEnabled(bool b); // only works for self
+ /* virtual */ void setCompositeUpdatesEnabled(U32 index, bool b);
+ /* virtual */ bool isCompositeUpdateEnabled(U32 index);
void setupComposites();
void updateComposites();
diff --git a/indra/newview/llwearable.cpp b/indra/newview/llwearable.cpp
index acfbc23f62..3334c17a8f 100644
--- a/indra/newview/llwearable.cpp
+++ b/indra/newview/llwearable.cpp
@@ -56,6 +56,35 @@ using namespace LLVOAvatarDefines;
// static
S32 LLWearable::sCurrentDefinitionVersion = 1;
+// support class - remove for 2.1 (hackity hack hack)
+class LLOverrideBakedTextureUpdate
+{
+public:
+ LLOverrideBakedTextureUpdate(bool temp_state)
+ {
+ mAvatar = gAgent.getAvatarObject();
+ U32 num_bakes = (U32) LLVOAvatarDefines::BAKED_NUM_INDICES;
+ for( U32 index = 0; index < num_bakes; ++index )
+ {
+ composite_enabled[index] = mAvatar->isCompositeUpdateEnabled(index);
+ }
+ mAvatar->setCompositeUpdatesEnabled(temp_state);
+ }
+
+ ~LLOverrideBakedTextureUpdate()
+ {
+ U32 num_bakes = (U32)LLVOAvatarDefines::BAKED_NUM_INDICES;
+ for( U32 index = 0; index < num_bakes; ++index )
+ {
+ mAvatar->setCompositeUpdatesEnabled(index, composite_enabled[index]);
+ }
+ }
+
+private:
+ bool composite_enabled[LLVOAvatarDefines::BAKED_NUM_INDICES];
+ LLVOAvatarSelf *mAvatar;
+};
+
// Private local functions
static std::string terse_F32_to_string(F32 f);
static std::string asset_id_to_filename(const LLUUID &asset_id);
@@ -216,6 +245,10 @@ BOOL LLWearable::importFile( LLFILE* file )
char text_buffer[2048]; /* Flawfinder: ignore */
S32 fields_read = 0;
+ // suppress texlayerset updates while wearables are being imported. Layersets will be updated
+ // when the wearables are "worn", not loaded. Note state will be restored when this object is destroyed.
+ LLOverrideBakedTextureUpdate stop_bakes(false);
+
// read header and version
fields_read = fscanf( file, "LLWearable version %d\n", &mDefinitionVersion );
if( fields_read != 1 )
diff --git a/indra/newview/skins/default/xui/es/menu_viewer.xml b/indra/newview/skins/default/xui/es/menu_viewer.xml
index 9c08fbb2c8..a0886b3e00 100644
--- a/indra/newview/skins/default/xui/es/menu_viewer.xml
+++ b/indra/newview/skins/default/xui/es/menu_viewer.xml
@@ -11,7 +11,7 @@
<menu_item_check label="Mi Inventario" name="Inventory"/>
<menu_item_check label="Mi Inventario" name="ShowSidetrayInventory"/>
<menu_item_check label="Mis gestos" name="Gestures"/>
- <menu label="Mi estatus" name="Status">
+ <menu label="Mi estado" name="Status">
<menu_item_call label="Ausente" name="Set Away"/>
<menu_item_call label="Ocupado" name="Set Busy"/>
</menu>
diff --git a/indra/newview/skins/default/xui/pt/panel_login.xml b/indra/newview/skins/default/xui/pt/panel_login.xml
index 415451b49f..61cdbaef13 100644
--- a/indra/newview/skins/default/xui/pt/panel_login.xml
+++ b/indra/newview/skins/default/xui/pt/panel_login.xml
@@ -12,12 +12,19 @@
Primeiro nome:
</text>
<line_editor label="Nome" name="first_name_edit" tool_tip="[SECOND_LIFE] First Name"/>
+ <text name="last_name_text">
+ Sobrenome:
+ </text>
<line_editor label="Sobrenome" name="last_name_edit" tool_tip="[SECOND_LIFE] Last Name"/>
+ <text name="password_text">
+ Senha:
+ </text>
<check_box label="Lembrar senha" name="remember_check"/>
<text name="start_location_text">
Começar em:
</text>
<combo_box name="start_location_combo">
+ <combo_box.item label="Última posição" name="MyLastLocation"/>
<combo_box.item label="Minha casa" name="MyHome"/>
</combo_box>
<button label="conectar" name="connect_btn"/>
@@ -26,6 +33,9 @@
<text name="create_new_account_text">
Cadastre-se
</text>
+ <text name="forgot_password_text">
+ Esqueceu seu nome ou senha?
+ </text>
<text name="login_help">
Precisa de ajuda ao conectar?
</text>