viewer#1425 Fix missed 'static' declarations

master
Andrey Kleshchev 2024-05-22 12:45:54 +03:00
parent 25b19eb6b8
commit 6f7e50e2b2
3 changed files with 9 additions and 9 deletions

View File

@ -1208,8 +1208,8 @@ void LLInvFVBridge::addMarketplaceContextMenuOptions(U32 flags,
LLInventoryModel::cat_array_t categories;
LLInventoryModel::item_array_t items;
gInventory.collectDescendents(local_version_folder_id, categories, items, FALSE);
LLCachedControl<U32> max_depth(gSavedSettings, "InventoryOutboxMaxFolderDepth", 4);
LLCachedControl<U32> max_count(gSavedSettings, "InventoryOutboxMaxFolderCount", 20);
static LLCachedControl<U32> max_depth(gSavedSettings, "InventoryOutboxMaxFolderDepth", 4);
static LLCachedControl<U32> max_count(gSavedSettings, "InventoryOutboxMaxFolderCount", 20);
if (categories.size() >= max_count
|| depth > (max_depth + 1))
{

View File

@ -423,7 +423,7 @@ void LLOutfitGallery::updateRowsIfNeeded()
bool compareGalleryItem(LLOutfitGalleryItem* item1, LLOutfitGalleryItem* item2)
{
LLCachedControl<S32> sort_by_name(gSavedSettings, "OutfitGallerySortOrder", 0);
static LLCachedControl<S32> sort_by_name(gSavedSettings, "OutfitGallerySortOrder", 0);
switch (sort_by_name())
{
case 2:
@ -1047,7 +1047,7 @@ void LLOutfitGalleryItem::setOutfitFavorite(bool is_favorite)
{
mFavorite = is_favorite;
LLCachedControl<bool> use_color(gSavedSettings, "InventoryFavoritesColorText");
static LLCachedControl<bool> use_color(gSavedSettings, "InventoryFavoritesColorText");
mOutfitNameText->setReadOnlyColor((mFavorite && use_color()) ? sDefaultFavoriteColor.get() : sDefaultTextColor.get());
}
@ -1062,7 +1062,7 @@ void LLOutfitGalleryItem::setOutfitWorn(bool value)
mOutfitWornText->setValue(value ? worn_string : "");
mOutfitNameText->setText(mOutfitName); // refresh LLTextViewModel to pick up font changes
LLCachedControl<bool> use_color(gSavedSettings, "InventoryFavoritesColorText");
static LLCachedControl<bool> use_color(gSavedSettings, "InventoryFavoritesColorText");
mOutfitNameText->setReadOnlyColor((mFavorite && use_color()) ? sDefaultFavoriteColor.get() : sDefaultTextColor.get());
}
@ -1414,7 +1414,7 @@ void LLOutfitGallerySortMenu::onUpdateItemsVisibility()
bool LLOutfitGallerySortMenu::onEnable(LLSD::String param)
{
LLCachedControl<S32> sort_order(gSavedSettings, "OutfitGallerySortOrder", 0);
static LLCachedControl<S32> sort_order(gSavedSettings, "OutfitGallerySortOrder", 0);
if ("favorites_to_top" == param)
{
return sort_order == 2;

View File

@ -225,7 +225,7 @@ void LLOutfitsList::updateAddedCategory(LLUUID cat_id)
tab->setDropDownStateChangedCallback(boost::bind(&LLOutfitsList::resetItemSelection, this, list, cat_id));
// Depending on settings, force showing list items that don't match current filter(EXT-7158)
LLCachedControl<bool> list_filter(gSavedSettings, "OutfitListFilterFullList");
static LLCachedControl<bool> list_filter(gSavedSettings, "OutfitListFilterFullList");
list->setForceShowingUnmatchedItems(list_filter(), false);
// Setting list commit callback to monitor currently selected wearable item.
@ -1556,12 +1556,12 @@ bool LLOutfitListSortMenu::onEnable(LLSD::String param)
{
if ("favorites_to_top" == param)
{
LLCachedControl<S32> sort_order(gSavedSettings, "OutfitListSortOrder", 0);
static LLCachedControl<S32> sort_order(gSavedSettings, "OutfitListSortOrder", 0);
return sort_order == 1;
}
else if ("show_entire_outfit" == param)
{
LLCachedControl<bool> filter_mode(gSavedSettings, "OutfitListFilterFullList", 0);
static LLCachedControl<bool> filter_mode(gSavedSettings, "OutfitListFilterFullList", 0);
return filter_mode;
}