Commits

Vadim Savchuk committed 93aef42 Merge

Merge from default branch

Comments (0)

Files changed (10)

indra/llui/llaccordionctrl.cpp

 #include "llfocusmgr.h"
 #include "lllocalcliprect.h"
 
+#include "lltrans.h"
+
 #include "boost/bind.hpp"
 
 static const S32 DRAGGER_BAR_MARGIN = 4;
 {
 	initNoTabsWidget(params.no_matched_tabs_text);
 
+	mNoVisibleTabsOrigString = LLTrans::getString(params.no_visible_tabs_text.initial_value().asString());
 	mSingleExpansion = params.single_expansion;
 	if(mFitParent && !mSingleExpansion)
 	{
 {
 	LLTextBox::Params tp = tb_params;
 	tp.rect(getLocalRect());
-	mNoMatchedTabsOrigString = tp.initial_value().asString();
+	mNoMatchedTabsOrigString = LLTrans::getString(tp.initial_value().asString());
 	mNoVisibleTabsHelpText = LLUICtrlFactory::create<LLTextBox>(tp, this);
 }
 

indra/newview/featuretable.txt

-version 21
+version 22
 
 // NOTE: This is mostly identical to featuretable_mac.txt with a few differences
 // Should be combined into one table
 RenderShaderLightingMaxLevel	1	3
 SkyUseClassicClouds			1	1
 WatchdogDisabled				1	1
+RenderUseStreamVBO			1	1
 
 
 //
 RenderAvatarVP				0	0
 RenderAvatarCloth			0	0
 
+// ATI cards generally perform better when not using VBOs for streaming data
+
+list ATI
+RenderUseStreamVBO			1	0
 
 /// Tweaked NVIDIA
 

indra/newview/llappearancemgr.cpp

 
 	for (S32 type = 0; type < LLWearableType::WT_COUNT; ++type)
 	{
-		llinfos << "type " << type << " requested " << requested_by_type[type] << " found " << found_by_type[type] << llendl;
+		if (requested_by_type[type] > found_by_type[type])
+		{
+			llwarns << "got fewer wearables than requested, type " << type << ": requested " << requested_by_type[type] << ", found " << found_by_type[type] << llendl;
+		}
 		if (found_by_type[type] > 0)
 			continue;
 		if (
 	bool timed_out = isTimedOut();
 	bool missing_completed = isMissingCompleted();
 	bool done = timed_out || missing_completed;
-	
-	llinfos << "polling missing wearables, waiting for items " << mTypesToRecover.size()
-			<< " links " << mTypesToLink.size()
-			<< " wearables, timed out " << timed_out
-			<< " elapsed " << mWaitTime.getElapsedTimeF32()
-			<< " done " << done << llendl;
+
+	if (!done)
+	{
+		llinfos << "polling missing wearables, waiting for items " << mTypesToRecover.size()
+				<< " links " << mTypesToLink.size()
+				<< " wearables, timed out " << timed_out
+				<< " elapsed " << mWaitTime.getElapsedTimeF32()
+				<< " done " << done << llendl;
+	}
 
 	if (done)
 	{
 	}
 	
 	mResolved += 1;  // just counting callbacks, not successes.
-	llinfos << "onWearableAssetFetch, resolved count " << mResolved << " of requested " << getFoundList().size() << llendl;
-	if (wearable)
-	{
-		llinfos << "wearable found, type " << wearable->getType() << " asset " << wearable->getAssetID() << llendl;
-	}
-	else
+	llinfos << "resolved " << mResolved << "/" << getFoundList().size() << llendl;
+	if (!wearable)
 	{
 		llwarns << "no wearable found" << llendl;
 	}
 		LLFoundData& data = *iter;
 		if(wearable->getAssetID() == data.mAssetID)
 		{
+			// Failing this means inventory or asset server are corrupted in a way we don't handle.
+			if ((data.mWearableType >= LLWearableType::WT_COUNT) || (wearable->getType() != data.mWearableType))
+			{
+				llwarns << "recovered wearable but type invalid. inventory wearable type: " << data.mWearableType << " asset wearable type: " << wearable->getType() << llendl;
+				break;
+			}
+
 			data.mWearable = wearable;
-			// Failing this means inventory or asset server are corrupted in a way we don't handle.
-			llassert((data.mWearableType < LLWearableType::WT_COUNT) && (wearable->getType() == data.mWearableType));
-			break;
 		}
 	}
 }
 	// the saved outfit stored as a folder link
 	updateIsDirty();
 
-	dumpCat(getCOF(),"COF, start");
+	//dumpCat(getCOF(),"COF, start");
 
 	bool follow_folder_links = true;
 	LLUUID current_outfit_id = getCOF();
 	{
 		LLFoundData& found = *it;
 
-		llinfos << "waiting for onWearableAssetFetch callback, asset " << found.mAssetID.asString() << llendl;
+		lldebugs << "waiting for onWearableAssetFetch callback, asset " << found.mAssetID.asString() << llendl;
 
 		// Fetch the wearables about to be worn.
 		LLWearableList::instance().getAsset(found.mAssetID,

indra/newview/llinventorybridge.cpp

 BOOL LLFolderBridge::dragCategoryIntoFolder(LLInventoryCategory* inv_cat,
 											BOOL drop)
 {
-	// This should never happen, but if an inventory item is incorrectly parented,
-	// the UI will get confused and pass in a NULL.
-	if(!inv_cat) return FALSE;
 
 	LLInventoryModel* model = getInventoryModel();
-	if(!model) return FALSE;
-
+
+	if (!inv_cat) return FALSE; // shouldn't happen, but in case item is incorrectly parented in which case inv_cat will be NULL
+	if (!model) return FALSE;
 	if (!isAgentAvatarValid()) return FALSE;
-
-	// cannot drag categories into library
-	if(!isAgentInventory())
-	{
-		return FALSE;
-	}
+	if (!isAgentInventory()) return FALSE; // cannot drag categories into library
+
 
 	// check to make sure source is agent inventory, and is represented there.
 	LLToolDragAndDrop::ESource source = LLToolDragAndDrop::getInstance()->getSource();
-	BOOL is_agent_inventory = (model->getCategory(inv_cat->getUUID()) != NULL)
+	const BOOL is_agent_inventory = (model->getCategory(inv_cat->getUUID()) != NULL)
 		&& (LLToolDragAndDrop::SOURCE_AGENT == source);
 
 	BOOL accept = FALSE;
-	S32 i;
-	LLInventoryModel::cat_array_t	descendent_categories;
-	LLInventoryModel::item_array_t	descendent_items;
-	if(is_agent_inventory)
-	{
-		const LLUUID& cat_id = inv_cat->getUUID();
-
-		// Is the destination the trash?
-		const LLUUID trash_id = model->findCategoryUUIDForType(LLFolderType::FT_TRASH);
-		BOOL move_is_into_trash = (mUUID == trash_id)
-			|| model->isObjectDescendentOf(mUUID, trash_id);
-		BOOL is_movable = (!LLFolderType::lookupIsProtectedType(inv_cat->getPreferredType()));
-		const LLUUID current_outfit_id = model->findCategoryUUIDForType(LLFolderType::FT_CURRENT_OUTFIT);
-		BOOL move_is_into_current_outfit = (mUUID == current_outfit_id);
-		BOOL move_is_into_outfit = (getCategory() && getCategory()->getPreferredType()==LLFolderType::FT_OUTFIT);
-		if (move_is_into_current_outfit || move_is_into_outfit)
+	if (is_agent_inventory)
+	{
+		const LLUUID &cat_id = inv_cat->getUUID();
+		const LLUUID &trash_id = model->findCategoryUUIDForType(LLFolderType::FT_TRASH, false);
+		const LLUUID &current_outfit_id = model->findCategoryUUIDForType(LLFolderType::FT_CURRENT_OUTFIT, false);
+		
+		const BOOL move_is_into_trash = (mUUID == trash_id) || model->isObjectDescendentOf(mUUID, trash_id);
+		const BOOL move_is_into_outfit = getCategory() && (getCategory()->getPreferredType() == LLFolderType::FT_OUTFIT);
+		const BOOL move_is_into_current_outfit = (mUUID == current_outfit_id);
+
+		//--------------------------------------------------------------------------------
+		// Determine if folder can be moved.
+		//
+
+		BOOL is_movable = TRUE;
+		if (LLFolderType::lookupIsProtectedType(inv_cat->getPreferredType()))
+			is_movable = FALSE;
+		if (move_is_into_outfit)
+			is_movable = FALSE;
+		if (mUUID == gInventory.findCategoryUUIDForType(LLFolderType::FT_FAVORITE))
+			is_movable = FALSE;
+		LLInventoryModel::cat_array_t descendent_categories;
+		LLInventoryModel::item_array_t descendent_items;
+		gInventory.collectDescendents(cat_id, descendent_categories, descendent_items, FALSE);
+		for (S32 i=0; i < descendent_categories.count(); ++i)
 		{
-			// BAP - restrictions?
-			is_movable = true;
+			LLInventoryCategory* category = descendent_categories[i];
+			if(LLFolderType::lookupIsProtectedType(category->getPreferredType()))
+			{
+				// Can't move "special folders" (e.g. Textures Folder).
+				is_movable = FALSE;
+				break;
+			}
 		}
-
-		if (mUUID == gInventory.findCategoryUUIDForType(LLFolderType::FT_FAVORITE))
+		if (move_is_into_trash)
 		{
-			is_movable = FALSE; // It's generally movable but not into Favorites folder. EXT-1604
-		}
-
-		if( is_movable )
-		{
-			gInventory.collectDescendents( cat_id, descendent_categories, descendent_items, FALSE );
-
-			for( i = 0; i < descendent_categories.count(); i++ )
+			for (S32 i=0; i < descendent_items.count(); ++i)
 			{
-				LLInventoryCategory* category = descendent_categories[i];
-				if(LLFolderType::lookupIsProtectedType(category->getPreferredType()))
+				LLInventoryItem* item = descendent_items[i];
+				if (get_is_item_worn(item->getUUID()))
 				{
-					// ...can't move "special folders" like Textures
 					is_movable = FALSE;
-					break;
-				}
-			}
-
-			if( is_movable )
-			{
-				if( move_is_into_trash )
-				{
-					for( i = 0; i < descendent_items.count(); i++ )
-					{
-						LLInventoryItem* item = descendent_items[i];
-						if (get_is_item_worn(item->getUUID()))
-						{
-							is_movable = FALSE;
-							break; // It's generally movable, but not into the trash!
-						}
-					}
+					break; // It's generally movable, but not into the trash.
 				}
 			}
 		}
 
+		// 
+		//--------------------------------------------------------------------------------
+
 		accept = is_movable
 			&& (mUUID != cat_id)								// Can't move a folder into itself
 			&& (mUUID != inv_cat->getParentUUID())				// Avoid moves that would change nothing
 			// Look for any gestures and deactivate them
 			if (move_is_into_trash)
 			{
-				for (i = 0; i < descendent_items.count(); i++)
+				for (S32 i=0; i < descendent_items.count(); i++)
 				{
 					LLInventoryItem* item = descendent_items[i];
 					if (item->getType() == LLAssetType::AT_GESTURE
 										BOOL drop)
 {
 	LLInventoryModel* model = getInventoryModel();
+
 	if(!model || !inv_item) return FALSE;
-
-	// cannot drag into library
-	if(!isAgentInventory())
-	{
-		return FALSE;
-	}
-
+	if(!isAgentInventory()) return FALSE; // cannot drag into library
 	if (!isAgentAvatarValid()) return FALSE;
 
 	LLToolDragAndDrop::ESource source = LLToolDragAndDrop::getInstance()->getSource();
 	LLViewerObject* object = NULL;
 	if(LLToolDragAndDrop::SOURCE_AGENT == source)
 	{
-		const LLUUID &trash_id = model->findCategoryUUIDForType(LLFolderType::FT_TRASH);
-		const LLUUID &current_outfit_id = model->findCategoryUUIDForType(LLFolderType::FT_CURRENT_OUTFIT);
-		const LLUUID& favorites_id = model->findCategoryUUIDForType(LLFolderType::FT_FAVORITE);
+		const LLUUID &trash_id = model->findCategoryUUIDForType(LLFolderType::FT_TRASH, false);
+		const LLUUID &current_outfit_id = model->findCategoryUUIDForType(LLFolderType::FT_CURRENT_OUTFIT, false);
+		const LLUUID &favorites_id = model->findCategoryUUIDForType(LLFolderType::FT_FAVORITE, false);
 
 		const BOOL move_is_into_trash = (mUUID == trash_id) || model->isObjectDescendentOf(mUUID, trash_id);
 		const BOOL move_is_into_current_outfit = (mUUID == current_outfit_id);

indra/newview/llinventorymodel.cpp

 			}
 		}
 
+		// Invalidate all categories that failed fetching descendents for whatever
+		// reason (e.g. one of the descendents was a broken link).
+		for (cat_set_t::iterator invalid_cat_it = invalid_categories.begin();
+			 invalid_cat_it != invalid_categories.end();
+			 invalid_cat_it++)
+		{
+			LLViewerInventoryCategory* cat = (*invalid_cat_it).get();
+			cat->setVersion(NO_VERSION);
+			llinfos << "Invalidating category name: " << cat->getName() << " UUID: " << cat->getUUID() << " due to invalid descendents cache" << llendl;
+		}
+
 		// At this point, we need to set the known descendents for each
 		// category which successfully cached so that we do not
 		// needlessly fetch descendents for categories which we have.
 			}
 		}
 
-		// Invalidate all categories that failed fetching descendents for whatever
-		// reason (e.g. one of the descendents was a broken link).
-		for (cat_set_t::iterator invalid_cat_it = invalid_categories.begin();
-			 invalid_cat_it != invalid_categories.end();
-			 invalid_cat_it++)
-		{
-			LLViewerInventoryCategory* cat = (*invalid_cat_it).get();
-			cat->setVersion(NO_VERSION);
-			llinfos << "Invalidating category name: " << cat->getName() << " UUID: " << cat->getUUID() << " due to invalid descendents cache" << llendl;
-		}
-
 		if(remove_inventory_file)
 		{
 			// clean up the gunzipped file.

indra/newview/llviewerobject.cpp

 	
 	{
 		LLViewerRegion* regionp = LLWorld::getInstance()->getRegionFromHandle(region_handle);
-		if(regionp != mRegionp && regionp && mRegionp)
+		if(regionp != mRegionp && regionp && mRegionp)//region cross
 		{
+			//this is the redundant position and region update, but it is necessary in case the viewer misses the following 
+			//position and region update messages from sim.
+			//this redundant update should not cause any problems.
 			LLVector3 delta_pos =  mRegionp->getOriginAgent() - regionp->getOriginAgent();
-			setPosition(getPosition() + delta_pos) ; //update the region position immediately.		
+			setPositionParent(getPosition() + delta_pos); //update to the new region position immediately.
+			setRegion(regionp) ; //change the region.
 		}
-		mRegionp = regionp ;
+		else
+		{
+			mRegionp = regionp ;
+		}
 	}	
 	
 	if (!mRegionp)

indra/newview/llvotree.cpp

 	//
 	//  Load Species-Specific data 
 	//
+	static const S32 MAX_TREE_TEXTURE_VIRTURE_SIZE_RESET_INTERVAL = 32 ; //frames.
 	mTreeImagep = LLViewerTextureManager::getFetchedTexture(sSpeciesTable[mSpecies]->mTextureID, TRUE, LLViewerTexture::BOOST_NONE, LLViewerTexture::LOD_TEXTURE);
+	mTreeImagep->setMaxVirtualSizeResetInterval(MAX_TREE_TEXTURE_VIRTURE_SIZE_RESET_INTERVAL); //allow to wait for at most 16 frames to reset virtual size.
+
 	mBranchLength = sSpeciesTable[mSpecies]->mBranchLength;
 	mTrunkLength = sSpeciesTable[mSpecies]->mTrunkLength;
 	mLeafScale = sSpeciesTable[mSpecies]->mLeafScale;

indra/newview/pipeline.cpp

 			}
 		}
 	}
-	llpushcallstacks ;
 	{
 		LLFastTimer ftm(FTM_STATESORT_DRAWABLE);
 		for (LLCullResult::drawable_list_t::iterator iter = sCull->beginVisibleList();
 			}
 		}
 	}
-	llpushcallstacks ;	
 	{
 		LLFastTimer ftm(FTM_CLIENT_COPY);
 		LLVertexBuffer::clientCopy();
 	}
-	llpushcallstacks ;
-	
-	postSort(camera);
-	llpushcallstacks ;
+	
+	postSort(camera);	
 }
 
 void LLPipeline::stateSort(LLSpatialGroup* group, LLCamera& camera)
 
 	assertInitialized();
 
+	llpushcallstacks ;
 	//rebuild drawable geometry
 	for (LLCullResult::sg_list_t::iterator i = sCull->beginDrawableGroups(); i != sCull->endDrawableGroups(); ++i)
 	{
 			group->rebuildGeom();
 		}
 	}
-
+	llpushcallstacks ;
 	//rebuild groups
 	sCull->assertDrawMapsEmpty();
 
 
 
 	rebuildPriorityGroups();
+	llpushcallstacks ;
 
 	const S32 bin_count = 1024*8;
 		
 
 		std::sort(sCull->beginAlphaGroups(), sCull->endAlphaGroups(), LLSpatialGroup::CompareDepthGreater());
 	}
-	
+	llpushcallstacks ;
 	// only render if the flag is set. The flag is only set if we are in edit mode or the toggle is set in the menus
 	if (LLFloaterReg::instanceVisible("beacons") && !sShadowRender)
 	{
 			forAllVisibleDrawables(renderSoundHighlights);
 		}
 	}
-
+	llpushcallstacks ;
 	// If managing your telehub, draw beacons at telehub and currently selected spawnpoint.
 	if (LLFloaterTelehub::renderBeacons())
 	{
 	}
 
 	//LLSpatialGroup::sNoDelete = FALSE;
+	llpushcallstacks ;
 }
 
 

indra/newview/skins/default/xui/en/panel_outfits_list.xml

      background_visible="true"
      bg_alpha_color="DkGray2"
      bg_opaque_color="DkGray2"
-     no_matched_tabs_text.value="Didn't find what you're looking for? Try [secondlife:///app/search/all/[SEARCH_TERM] Search]."
+     no_matched_tabs_text.value="NoOutfitsTabsMatched"
      no_matched_tabs_text.v_pad="10"
-     no_visible_tabs_text.value="..."
+     no_visible_tabs_text.value="NoOutfits"
      follows="all"
      height="400"
      layout="topleft"

indra/newview/skins/default/xui/en/strings.xml

 	<string name="PanelDirEventsDateText">[mthnum,datetime,slt]/[day,datetime,slt]</string>
 
 	<!-- panel contents -->
+	<string name="PanelContentsTooltip">Content of object</string>
 	<string name="PanelContentsNewScript">New Script</string>
 	<string name="PanelContentsTooltip">Content of object</string>
 
   <!-- panel preferences general -->
   <string name="BusyModeResponseDefault">The Resident you messaged is in &apos;busy mode&apos; which means they have requested not to be disturbed.  Your message will still be shown in their IM panel for later viewing.</string>
 
+	<!-- Outfits Panel -->
+	<string name="NoOutfits">You don't have any outfits yet. Try [secondlife:///app/search/all/ Search]</string>
+	<string name="NoOutfitsTabsMatched">Didn't find what you're looking for? Try [secondlife:///app/search/all/[SEARCH_TERM] Search].</string>
+
 	<!-- Mute -->
 	<string name="MuteByName">(By name)</string>
 	<string name="MuteAgent">(Resident)</string>