Converted frequently occuring setting lookups to LLCachedControl

Added LLObjectList::getAvatar(LLUUID) for type-safe and quicker lookup
Added F32 overload to LLSD because using F64 needlessly is silly.
   (And its lack of F32 overload caused issues with LLCachedControl<F32>)
This commit is contained in:
unknown
2010-10-07 21:36:13 -05:00
parent 49e4959bf5
commit fe9a3d2ba2
41 changed files with 365 additions and 209 deletions

View File

@@ -2939,7 +2939,8 @@ const std::string LLFolderView::getFilterSubString(BOOL trim)
void LLFolderView::filter( LLInventoryFilter& filter )
{
LLFastTimer t2(LLFastTimer::FTM_FILTER);
filter.setFilterCount(llclamp(gSavedSettings.getS32("FilterItemsPerFrame"), 1, 5000));
static LLCachedControl<S32> filter_items_per_frame("FilterItemsPerFrame",500);
filter.setFilterCount(llclamp((S32)filter_items_per_frame, 1, 5000));
if (getCompletedFilterGeneration() < filter.getCurrentGeneration())
{
@@ -4394,8 +4395,8 @@ void LLFolderView::doIdle()
{
LLFastTimer t2(LLFastTimer::FTM_INVENTORY);
BOOL debug_filters = gSavedSettings.getBOOL("DebugInventoryFilters");
if (debug_filters != getDebugFilters())
static LLCachedControl<bool> debug_filters("DebugInventoryFilters",false);
if (debug_filters != (bool)getDebugFilters())
{
mDebugFilters = debug_filters;
arrangeAll();