Merge branch 'release/2025.04' of https://github.com/secondlife/viewer

# Conflicts:
#	indra/newview/llinventorybridge.cpp
#	indra/newview/llmodelpreview.cpp
#	indra/newview/llpanelface.cpp
#	indra/newview/llviewercamera.cpp
#	indra/newview/llviewerregion.cpp
#	indra/newview/skins/default/colors.xml
master
Ansariel 2025-05-14 21:56:38 +02:00
commit 469795979f
19 changed files with 196 additions and 203 deletions

View File

@ -430,9 +430,7 @@ void ll_set_device_module_capture_device(rtc::scoped_refptr<webrtc::AudioDeviceM
// has it at 0
device_module->SetRecordingDevice(device + 1);
#endif
device_module->SetStereoRecording(false);
device_module->InitMicrophone();
device_module->InitRecording();
}
void LLWebRTCImpl::setCaptureDevice(const std::string &id)
@ -473,6 +471,8 @@ void LLWebRTCImpl::setCaptureDevice(const std::string &id)
ll_set_device_module_capture_device(mPeerDeviceModule, recordingDevice);
if (recording)
{
mPeerDeviceModule->SetStereoRecording(false);
mPeerDeviceModule->InitRecording();
mPeerDeviceModule->StartRecording();
}
});
@ -494,9 +494,7 @@ void ll_set_device_module_render_device(rtc::scoped_refptr<webrtc::AudioDeviceMo
#else
device_module->SetPlayoutDevice(device + 1);
#endif
device_module->SetStereoPlayout(true);
device_module->InitSpeaker();
device_module->InitPlayout();
}
void LLWebRTCImpl::setRenderDevice(const std::string &id)
@ -540,6 +538,8 @@ void LLWebRTCImpl::setRenderDevice(const std::string &id)
ll_set_device_module_render_device(mPeerDeviceModule, playoutDevice);
if (playing)
{
mPeerDeviceModule->SetStereoPlayout(true);
mPeerDeviceModule->InitPlayout();
mPeerDeviceModule->StartPlayout();
}
});

View File

@ -11279,7 +11279,7 @@ Change of this parameter will affect the layout of buttons in notification toast
<key>RenderMinFreeMainMemoryThreshold</key>
<map>
<key>Comment</key>
<string>Minimum of available physical memory in MB before textures get scaled down</string>
<string>If available free physical memory is below this value textures get agresively scaled down</string>
<key>Persist</key>
<integer>0</integer>
<key>Type</key>

View File

@ -3626,10 +3626,6 @@ void LLIMMgr::addMessage(
}
}
// <FS:PP> Configurable IM sounds
// //Play sound for new conversations
// if (!skip_message && !gAgent.isDoNotDisturb() && (gSavedSettings.getBOOL("PlaySoundNewConversation")))
// <FS:PP> Option to automatically ignore and leave all conference (ad-hoc) chats
static LLCachedControl<bool> ignoreAdHocSessions(gSavedSettings, "FSIgnoreAdHocSessions");
if (dialog != IM_NOTHING_SPECIAL && !is_group_chat && ignoreAdHocSessions && !from_linden)
@ -3641,7 +3637,6 @@ void LLIMMgr::addMessage(
//<FS:Beq> [FIRE-21385] Add inviter name/UUID to ad-hoc ignored messages
LLSD args;
args["AVATAR_NAME"] = LLSLURL("agent", other_participant_id, "about").getSLURLString();
// LL_INFOS() << "Ignoring conference (ad-hoc) chat from " << new_session_id.asString() << LL_ENDL;
LL_INFOS() << "Ignoring conference (ad-hoc) chat from " << args["AVATAR_NAME"] << LL_ENDL;
if (!gIMMgr->leaveSession(new_session_id))
{
@ -3649,7 +3644,6 @@ void LLIMMgr::addMessage(
}
else if (reportIgnoredAdHocSession)
{
// report_to_nearby_chat(LLTrans::getString("IgnoredAdHocSession"));
FSCommon::report_to_nearby_chat(LLTrans::getString("IgnoredAdHocSession", args));
}
//</FS:Beq>
@ -3658,18 +3652,32 @@ void LLIMMgr::addMessage(
}
// </FS:PP>
if(!do_not_disturb && PlayModeUISndNewIncomingIMSession != 0 && dialog == IM_NOTHING_SPECIAL && !play_snd_mention)
// <FS:PP> Configurable IM sounds
////Play sound for new conversations
//if (!skip_message && !gAgent.isDoNotDisturb() && (gSavedSettings.getBOOL("PlaySoundNewConversation")))
//{
// static LLCachedControl<bool> play_snd_mention_pref(gSavedSettings, "PlaySoundChatMention", false);
// if (!play_snd_mention_pref || !LLUrlRegistry::getInstance()->containsAgentMention(msg))
// {
// make_ui_sound("UISndNewIncomingIMSession");
// }
//}
if (!do_not_disturb && !play_snd_mention)
{
make_ui_sound("UISndNewIncomingIMSession");
}
else if(!do_not_disturb && PlayModeUISndNewIncomingGroupIMSession != 0 && dialog != IM_NOTHING_SPECIAL && is_group_chat && !play_snd_mention)
{
make_ui_sound("UISndNewIncomingGroupIMSession");
}
else if(!do_not_disturb && PlayModeUISndNewIncomingConfIMSession != 0 && dialog != IM_NOTHING_SPECIAL && !is_group_chat && !play_snd_mention)
{
make_ui_sound("UISndNewIncomingConfIMSession");
if (PlayModeUISndNewIncomingIMSession != 0 && dialog == IM_NOTHING_SPECIAL)
{
make_ui_sound("UISndNewIncomingIMSession");
}
else if (PlayModeUISndNewIncomingGroupIMSession != 0 && dialog != IM_NOTHING_SPECIAL && is_group_chat)
{
make_ui_sound("UISndNewIncomingGroupIMSession");
}
else if (PlayModeUISndNewIncomingConfIMSession != 0 && dialog != IM_NOTHING_SPECIAL && !is_group_chat)
{
make_ui_sound("UISndNewIncomingConfIMSession");
}
}
// </FS:PP>
}
else
{

View File

@ -3270,12 +3270,16 @@ bool LLFolderBridge::dragCategoryIntoFolder(LLInventoryCategory* inv_cat,
if (dest_res == MY_OUTFITS_SUBFOLDER && create_outfit)
{
// turn it into outfit
dropToMyOutfitsSubfolder(inv_cat, mUUID, LLFolderType::FT_OUTFIT, cb);
dropToMyOutfitsSubfolder(inv_cat, mUUID, cb);
}
else
{
// or link it?
dropToMyOutfitsSubfolder(inv_cat, mUUID, LLFolderType::FT_NONE, cb);
LLInvFVBridge::changeCategoryParent(
model,
(LLViewerInventoryCategory*)inv_cat,
mUUID,
move_is_into_trash);
if (cb) cb->fire(inv_cat->getUUID());
}
break;
case MY_OUTFITS_SUBFOLDER:
@ -4403,7 +4407,7 @@ void LLFolderBridge::perform_pasteFromClipboard()
const bool move_is_into_current_outfit = (mUUID == current_outfit_id);
const bool move_is_into_my_outfits = (mUUID == my_outifts_id) || model->isObjectDescendentOf(mUUID, my_outifts_id);
const bool move_is_into_outfit = /*move_is_into_my_outfits ||*/ (getCategory() && getCategory()->getPreferredType()==LLFolderType::FT_OUTFIT); // <FS:Ansariel> Unable to copy&paste into outfits anymore
const bool move_is_into_outfit = move_is_into_my_outfits || (getCategory() && getCategory()->getPreferredType()==LLFolderType::FT_OUTFIT);
const bool move_is_into_marketplacelistings = model->isObjectDescendentOf(mUUID, marketplacelistings_id);
const bool move_is_into_favorites = (mUUID == favorites_id);
const bool move_is_into_lost_and_found = model->isObjectDescendentOf(mUUID, lost_and_found_id);
@ -4496,20 +4500,18 @@ void LLFolderBridge::perform_pasteFromClipboard()
return;
}
}
// <FS:Ansariel> Unable to copy&paste into outfits anymore
//if (move_is_into_outfit)
if (move_is_into_my_outfits)
// </FS:Ansariel>
if (move_is_into_outfit)
{
// <FS:Ansariel> Unable to copy&paste into outfits anymore
//if (!move_is_into_my_outfits && item && can_move_to_outfit(item, move_is_into_current_outfit))
if (move_is_into_outfit && item && can_move_to_outfit(item, move_is_into_current_outfit))
// </FS:Ansariel>
bool handled = false;
if (mUUID != my_outifts_id
&& dest_folder->getPreferredType() == LLFolderType::FT_OUTFIT
&& item
&& can_move_to_outfit(item, move_is_into_current_outfit))
{
// todo: this is going to create dupplicate folders?
dropToOutfit(item, move_is_into_current_outfit, cb);
handled = true;
}
else if (/*move_is_into_my_outfits &&*/ LLAssetType::AT_CATEGORY == obj->getType()) // <FS:Ansariel> Unable to copy&paste into outfits anymore
else if (move_is_into_my_outfits && LLAssetType::AT_CATEGORY == obj->getType())
{
LLViewerInventoryCategory* cat = model->getCategory(item_id);
U32 max_items_to_wear = gSavedSettings.getU32("WearFolderLimit");
@ -4518,39 +4520,39 @@ void LLFolderBridge::perform_pasteFromClipboard()
if (mUUID == my_outifts_id)
{
dropToMyOutfits(cat, cb);
}
else if (move_is_into_my_outfits)
{
EMyOutfitsSubfolderType res = myoutfit_object_subfolder_type(model, mUUID, my_outifts_id);
if (res == MY_OUTFITS_SUBFOLDER)
{
// turn it into outfit
dropToMyOutfitsSubfolder(cat, mUUID, LLFolderType::FT_OUTFIT, cb);
}
else
{
dropToMyOutfitsSubfolder(cat, mUUID, LLFolderType::FT_NONE, cb);
}
}
}
else if (cat && can_move_to_my_outfits_as_subfolder(model, cat))
{
if (LLClipboard::instance().isCutMode())
{
changeCategoryParent(model, cat, parent_id, false);
if (cb) cb->fire(item_id);
handled = true;
}
else
{
copy_inventory_category(model, cat, parent_id);
EMyOutfitsSubfolderType dest_res = myoutfit_object_subfolder_type(model, mUUID, my_outifts_id);
if (dest_res == MY_OUTFITS_SUBFOLDER)
{
// turn it into outfit
dropToMyOutfitsSubfolder(cat, mUUID, cb);
handled = true;
}
}
}
else
if (!handled && cat && can_move_to_my_outfits_as_subfolder(model, cat))
{
LLNotificationsUtil::add("MyOutfitsPasteFailed");
EMyOutfitsSubfolderType dest_res = myoutfit_object_subfolder_type(model, mUUID, my_outifts_id);
if (dest_res == MY_OUTFITS_SUBFOLDER || mUUID == my_outifts_id)
{
if (LLClipboard::instance().isCutMode())
{
changeCategoryParent(model, cat, parent_id, false);
}
else
{
copy_inventory_category(model, cat, parent_id);
}
if (cb) cb->fire(item_id);
handled = true;
}
}
}
else
if (!handled)
{
LLNotificationsUtil::add("MyOutfitsPasteFailed");
}
@ -6071,12 +6073,11 @@ void LLFolderBridge::dropToMyOutfits(LLInventoryCategory* inv_cat, LLPointer<LLI
inv_cat->getThumbnailUUID());
}
void LLFolderBridge::dropToMyOutfitsSubfolder(LLInventoryCategory* inv_cat, const LLUUID& dest_id, LLFolderType::EType preferred_type, LLPointer<LLInventoryCallback> cb)
void LLFolderBridge::dropToMyOutfitsSubfolder(LLInventoryCategory* inv_cat, const LLUUID& dest_id, LLPointer<LLInventoryCallback> cb)
{
const LLUUID outfits_id = getInventoryModel()->findCategoryUUIDForType(LLFolderType::FT_MY_OUTFITS);
inventory_func_type func = boost::bind(outfitFolderCreatedCallback, inv_cat->getUUID(), _1, cb, mInventoryPanel);
getInventoryModel()->createNewCategory(dest_id,
preferred_type,
LLFolderType::FT_OUTFIT,
inv_cat->getName(),
func,
inv_cat->getThumbnailUUID());

View File

@ -397,7 +397,7 @@ protected:
void dropToFavorites(LLInventoryItem* inv_item, LLPointer<LLInventoryCallback> cb = NULL);
void dropToOutfit(LLInventoryItem* inv_item, bool move_is_into_current_outfit, LLPointer<LLInventoryCallback> cb = NULL);
void dropToMyOutfits(LLInventoryCategory* inv_cat, LLPointer<LLInventoryCallback> cb = NULL);
void dropToMyOutfitsSubfolder(LLInventoryCategory* inv_cat, const LLUUID& dest, LLFolderType::EType preferred_type, LLPointer<LLInventoryCallback> cb = NULL);
void dropToMyOutfitsSubfolder(LLInventoryCategory* inv_cat, const LLUUID& dest, LLPointer<LLInventoryCallback> cb = NULL);
//--------------------------------------------------------------------
// Messy hacks for handling folder options

View File

@ -478,6 +478,25 @@ void copy_inventory_category(LLInventoryModel* model,
gInventory.createNewCategory(parent_id, LLFolderType::FT_NONE, cat->getName(), func, cat->getThumbnailUUID());
}
void copy_inventory_category(LLInventoryModel* model,
LLViewerInventoryCategory* cat,
const LLUUID& parent_id,
const LLUUID& root_copy_id,
bool move_no_copy_items,
LLPointer<LLInventoryCallback> callback)
{
// Create the initial folder
inventory_func_type func = [model, cat, root_copy_id, move_no_copy_items, callback](const LLUUID& new_id)
{
copy_inventory_category_content(new_id, model, cat, root_copy_id, move_no_copy_items);
if (callback)
{
callback.get()->fire(new_id);
}
};
gInventory.createNewCategory(parent_id, LLFolderType::FT_NONE, cat->getName(), func, cat->getThumbnailUUID());
}
void copy_cb(const LLUUID& dest_folder, const LLUUID& root_id)
{
// Decrement the count in root_id since that one item won't be copied over
@ -2508,6 +2527,12 @@ bool can_move_to_my_outfits_as_subfolder(LLInventoryModel* model, LLInventoryCat
return false;
}
if (inv_cat->getPreferredType() != LLFolderType::FT_NONE)
{
// only normal folders can become subfodlers
return false;
}
constexpr size_t MAX_CONTENT = 255;
if (cats->size() > MAX_CONTENT)
{

View File

@ -85,6 +85,7 @@ void rename_category(LLInventoryModel* model, const LLUUID& cat_id, const std::s
void copy_inventory_category(LLInventoryModel* model, LLViewerInventoryCategory* cat, const LLUUID& parent_id, const LLUUID& root_copy_id = LLUUID::null, bool move_no_copy_items = false);
void copy_inventory_category(LLInventoryModel* model, LLViewerInventoryCategory* cat, const LLUUID& parent_id, const LLUUID& root_copy_id, bool move_no_copy_items, inventory_func_type callback);
void copy_inventory_category(LLInventoryModel* model, LLViewerInventoryCategory* cat, const LLUUID& parent_id, const LLUUID& root_copy_id, bool move_no_copy_items, LLPointer<LLInventoryCallback> callback);
void copy_inventory_category_content(const LLUUID& new_cat_uuid, LLInventoryModel* model, LLViewerInventoryCategory* cat, const LLUUID& root_copy_id, bool move_no_copy_items);

View File

@ -65,7 +65,7 @@ const S32 FAST_LOAD_THUMBNAIL_TRSHOLD = 50; // load folders below this value imm
bool dragCategoryIntoFolder(LLUUID dest_id, LLInventoryCategory* inv_cat, bool drop, std::string& tooltip_msg, bool is_link);
bool dragItemIntoFolder(LLUUID folder_id, LLInventoryItem* inv_item, bool drop, std::string& tooltip_msg, bool user_confirm);
void dropToMyOutfits(LLInventoryCategory* inv_cat);
void dropToMyOutfitsSubfolder(LLInventoryCategory* inv_cat, const LLUUID& dest_id, LLFolderType::EType preferred_type);
void dropToMyOutfitsSubfolder(LLInventoryCategory* inv_cat, const LLUUID& dest_id);
class LLGalleryPanel: public LLPanel
{
@ -3970,11 +3970,14 @@ bool dragCategoryIntoFolder(LLUUID dest_id, LLInventoryCategory* inv_cat,
if (dest_res == MY_OUTFITS_SUBFOLDER && create_outfit)
{
// turn it into outfit
dropToMyOutfitsSubfolder(inv_cat, dest_id, LLFolderType::FT_OUTFIT);
dropToMyOutfitsSubfolder(inv_cat, dest_id);
}
else
{
dropToMyOutfitsSubfolder(inv_cat, dest_id, LLFolderType::FT_NONE);
gInventory.changeCategoryParent(
(LLViewerInventoryCategory*)inv_cat,
dest_id,
move_is_into_trash);
}
break;
case MY_OUTFITS_SUBFOLDER:
@ -4153,10 +4156,10 @@ void dropToMyOutfits(LLInventoryCategory* inv_cat)
gInventory.createNewCategory(dest_id, LLFolderType::FT_OUTFIT, inv_cat->getName(), func, inv_cat->getThumbnailUUID());
}
void dropToMyOutfitsSubfolder(LLInventoryCategory* inv_cat, const LLUUID &dest_id, LLFolderType::EType preferred_type)
void dropToMyOutfitsSubfolder(LLInventoryCategory* inv_cat, const LLUUID &dest_id)
{
// Note: creation will take time, so passing folder id to callback is slightly unreliable,
// but so is collecting and passing descendants' ids
inventory_func_type func = boost::bind(&outfitFolderCreatedCallback, inv_cat->getUUID(), _1);
gInventory.createNewCategory(dest_id, preferred_type, inv_cat->getName(), func, inv_cat->getThumbnailUUID());
gInventory.createNewCategory(dest_id, LLFolderType::FT_OUTFIT, inv_cat->getName(), func, inv_cat->getThumbnailUUID());
}

View File

@ -6215,13 +6215,7 @@ bool LLMeshRepository::meshUploadEnabled()
bool LLMeshRepository::meshRezEnabled()
{
static LLCachedControl<bool> mesh_enabled(gSavedSettings, "MeshEnabled");
LLViewerRegion *region = gAgent.getRegion();
if(mesh_enabled &&
region)
{
return region->meshRezEnabled();
}
return false;
return mesh_enabled;
}
// Threading: main thread only

View File

@ -3473,6 +3473,8 @@ void LLModelPreview::updateStatusMessages()
S32 phys_tris = 0;
S32 phys_hulls = 0;
S32 phys_points = 0;
S32 which_mode = 0;
S32 file_mode = 1;
//get the triangle count for the whole scene
for (LLModelLoader::scene::iterator iter = mScene[LLModel::LOD_PHYSICS].begin(), endIter = mScene[LLModel::LOD_PHYSICS].end(); iter != endIter; ++iter)
@ -3623,31 +3625,26 @@ void LLModelPreview::updateStatusMessages()
fmp->childEnable("simplify_cancel");
fmp->childEnable("decompose_cancel");
}
// <FS:Beq> move the closing bracket for the if(fmp) to prevent possible crash
// }
LLCtrlSelectionInterface* iface = fmp->childGetSelectionInterface("physics_lod_combo");
S32 which_mode = 0;
S32 file_mode = 1;
if (iface)
{
which_mode = iface->getFirstSelectedIndex();
file_mode = iface->getItemCount() - 1;
}
if (which_mode == file_mode)
{
mFMP->childEnable("physics_file");
mFMP->childEnable("physics_browse");
}
else
{
mFMP->childDisable("physics_file");
mFMP->childDisable("physics_browse");
}
}
// </FS:Beq>
if (which_mode == file_mode)
{
mFMP->childEnable("physics_file");
mFMP->childEnable("physics_browse");
}
else
{
mFMP->childDisable("physics_file");
mFMP->childDisable("physics_browse");
}
LLSpinCtrl* crease = mFMP->getChild<LLSpinCtrl>("crease_angle");

View File

@ -793,6 +793,17 @@ void LLOutfitGallery::updateAddedCategory(LLUUID cat_id)
LLViewerInventoryCategory *cat = gInventory.getCategory(cat_id);
if (!cat) return;
if (!isOutfitFolder(cat))
{
// Assume a subfolder that contains or will contain outfits, track it
const LLUUID outfits = gInventory.findCategoryUUIDForType(LLFolderType::FT_MY_OUTFITS);
mOutfitsObserver->addCategory(cat_id, [this, outfits]()
{
observerCallback(outfits);
});
return;
}
std::string name = cat->getName();
LLOutfitGalleryItem* item = buildGalleryItem(name, cat_id);
mOutfitMap.insert(LLOutfitGallery::outfit_map_value_t(cat_id, item));

View File

@ -150,6 +150,17 @@ void LLOutfitsList::updateAddedCategory(LLUUID cat_id)
LLViewerInventoryCategory *cat = gInventory.getCategory(cat_id);
if (!cat) return;
if (!isOutfitFolder(cat))
{
// Assume a subfolder that contains or will contain outfits, track it
const LLUUID outfits = gInventory.findCategoryUUIDForType(LLFolderType::FT_MY_OUTFITS);
mCategoriesObserver->addCategory(cat_id, [this, outfits]()
{
observerCallback(outfits);
});
return;
}
std::string name = cat->getName();
outfit_accordion_tab_params tab_params(get_accordion_tab_params());
@ -890,49 +901,38 @@ void LLOutfitListBase::observerCallback(const LLUUID& category_id)
refreshList(category_id);
}
class LLIsOutfitListFolder : public LLInventoryCollectFunctor
bool LLOutfitListBase::isOutfitFolder(LLViewerInventoryCategory* cat) const
{
public:
LLIsOutfitListFolder()
if (!cat)
{
mOutfitsId = gInventory.findCategoryUUIDForType(LLFolderType::FT_MY_OUTFITS);
}
virtual ~LLIsOutfitListFolder() {}
bool operator()(LLInventoryCategory* cat, LLInventoryItem* item) override
{
if (cat)
{
if (cat->getPreferredType() == LLFolderType::FT_OUTFIT)
{
return true;
}
if (cat->getPreferredType() == LLFolderType::FT_NONE
&& cat->getParentUUID() == mOutfitsId)
{
LLViewerInventoryCategory* inv_cat = dynamic_cast<LLViewerInventoryCategory*>(cat);
if (inv_cat && inv_cat->getDescendentCount() > 3)
{
LLInventoryModel::cat_array_t* cats;
LLInventoryModel::item_array_t* items;
gInventory.getDirectDescendentsOf(inv_cat->getUUID(), cats, items);
if (cats->empty() // protection against outfits inside
&& items->size() > 3) // eyes, skin, hair and shape are required
{
// For now assume this to be an old style outfit, not a subfolder
// but ideally no such 'outfits' should be left in My Outfits
// Todo: stop counting FT_NONE as outfits,
// convert obvious outfits into FT_OUTFIT
return true;
}
}
}
}
return false;
}
protected:
LLUUID mOutfitsId;
};
if (cat->getPreferredType() == LLFolderType::FT_OUTFIT)
{
return true;
}
// assumes that folder is somewhere inside MyOutfits
if (cat->getPreferredType() == LLFolderType::FT_NONE)
{
LLViewerInventoryCategory* inv_cat = dynamic_cast<LLViewerInventoryCategory*>(cat);
if (inv_cat && inv_cat->getDescendentCount() > 3)
{
LLInventoryModel::cat_array_t* cats;
LLInventoryModel::item_array_t* items;
gInventory.getDirectDescendentsOf(inv_cat->getUUID(), cats, items);
if (cats->empty() // protection against outfits inside
&& items->size() > 3) // arbitrary, if doesn't have at least base parts, not an outfit
{
// For now assume this to be an old style outfit, not a subfolder
// but ideally no such 'outfits' should be left in My Outfits
// Todo: stop counting FT_NONE as outfits,
// convert obvious outfits into FT_OUTFIT
return true;
}
}
}
return false;
}
void LLOutfitListBase::refreshList(const LLUUID& category_id)
{
@ -943,13 +943,13 @@ void LLOutfitListBase::refreshList(const LLUUID& category_id)
LLInventoryModel::item_array_t item_array;
// Collect all sub-categories of a given category.
LLIsOutfitListFolder is_outfit;
LLIsType is_category(LLAssetType::AT_CATEGORY);
gInventory.collectDescendentsIf(
category_id,
cat_array,
item_array,
LLInventoryModel::EXCLUDE_TRASH,
is_outfit);
is_category);
// Memorize item names for each UUID
std::map<LLUUID, std::string> names;
@ -1510,7 +1510,12 @@ bool LLOutfitAccordionCtrlTab::handleToolTip(S32 x, S32 y, MASK mask)
{
LLSD params;
params["inv_type"] = LLInventoryType::IT_CATEGORY;
params["thumbnail_id"] = gInventory.getCategory(mFolderID)->getThumbnailUUID();
LLViewerInventoryCategory* cat = gInventory.getCategory(mFolderID);
if (cat)
{
params["thumbnail_id"] = cat->getThumbnailUUID();
}
// else consider returning
params["item_id"] = mFolderID;
// <FS:Ansariel> Make thumbnail tooltip work properly

View File

@ -123,6 +123,8 @@ protected:
void onOutfitsRemovalConfirmation(const LLSD& notification, const LLSD& response);
virtual void onChangeOutfitSelection(LLWearableItemsList* list, const LLUUID& category_id) = 0;
bool isOutfitFolder(LLViewerInventoryCategory* cat) const;
static void onIdle(void* userdata);
void onIdleRefreshList();

View File

@ -1147,7 +1147,6 @@ void LLPanelFace::updateUI(bool force_set_values /*false*/)
}
mRadioPbrType->setEnabled(editable);
const bool pbr_selected = mComboMatMedia->getCurrentIndex() == MATMEDIA_PBR;
const bool media_selected = mComboMatMedia->getCurrentIndex() == MATMEDIA_MEDIA;
const bool texture_info_selected = pbr_selected && mRadioPbrType->getSelectedIndex() != PBRTYPE_RENDER_MATERIAL_ID;
mCheckSyncSettings->setEnabled(editable);
@ -1451,7 +1450,7 @@ void LLPanelFace::updateUI(bool force_set_values /*false*/)
mShinyScaleU->setValue(spec_scale_s);
mBumpyScaleU->setValue(norm_scale_s);
mTexScaleU->setEnabled(editable && (has_material || media_selected));
mTexScaleU->setEnabled(editable && has_material);
// <FS:CR> Materials alignment
//mShinyScaleU->setEnabled(editable && has_material && specmap_id.notNull());
//mBumpyScaleU->setEnabled(editable && has_material && normmap_id.notNull());
@ -1496,7 +1495,7 @@ void LLPanelFace::updateUI(bool force_set_values /*false*/)
bool norm_scale_tentative = !identical_norm_scale_t;
bool spec_scale_tentative = !identical_spec_scale_t;
mTexScaleV->setEnabled(editable && (has_material || media_selected));
mTexScaleV->setEnabled(editable && has_material);
// <FS:CR> Materials alignment
//mShinyScaleV->setEnabled(editable && has_material && specmap_id.notNull());
//mBumpyScaleV->setEnabled(editable && has_material && normmap_id.notNull());
@ -1545,7 +1544,7 @@ void LLPanelFace::updateUI(bool force_set_values /*false*/)
mShinyOffsetU->setTentative(LLSD(spec_offset_u_tentative));
mBumpyOffsetU->setTentative(LLSD(norm_offset_u_tentative));
mTexOffsetU->setEnabled(editable && (has_material || media_selected));
mTexOffsetU->setEnabled(editable && has_material);
// <FS:CR> Materials alignment
//mShinyOffsetU->setEnabled(editable && has_material && specmap_id.notNull());
//mBumpyOffsetU->setEnabled(editable && has_material && normmap_id.notNull());
@ -1578,7 +1577,7 @@ void LLPanelFace::updateUI(bool force_set_values /*false*/)
mBumpyOffsetV->setTentative(LLSD(norm_offset_v_tentative));
mShinyOffsetV->setTentative(LLSD(spec_offset_v_tentative));
mTexOffsetV->setEnabled(editable && (has_material || media_selected));
mTexOffsetV->setEnabled(editable && has_material);
// <FS:CR> Materials alignment
//mShinyOffsetV->setEnabled(editable && has_material && specmap_id.notNull());
//mBumpyOffsetV->setEnabled(editable && has_material && normmap_id.notNull());
@ -1608,7 +1607,7 @@ void LLPanelFace::updateUI(bool force_set_values /*false*/)
F32 norm_rot_deg = norm_rotation * RAD_TO_DEG;
F32 spec_rot_deg = spec_rotation * RAD_TO_DEG;
mTexRotate->setEnabled(editable && (has_material || media_selected));
mTexRotate->setEnabled(editable && has_material);
// <FS:CR> Materials alignment
//mShinyRotate->setEnabled(editable && has_material && specmap_id.notNull());
//mBumpyRotate->setEnabled(editable && has_material && normmap_id.notNull());
@ -1730,7 +1729,7 @@ void LLPanelFace::updateUI(bool force_set_values /*false*/)
mTexRepeat->setValue(editable ? repeats : 1.0f);
}
mTexRepeat->setTentative(LLSD(repeats_tentative));
mTexRepeat->setEnabled(!identical_planar_texgen && enabled && (has_material || media_selected));
mTexRepeat->setEnabled(has_material && !identical_planar_texgen && enabled);
// <FS:CR> FIRE-11407 - Flip buttons
mBtnTexFlipScaleU->setEnabled(enabled);
mBtnTexFlipScaleV->setEnabled(enabled);

View File

@ -76,18 +76,14 @@ LLViewerCamera::LLViewerCamera() : LLCamera()
mAverageSpeed = 0.f;
mAverageAngularSpeed = 0.f;
// <FS:Zi> add a way to disconnect/reconnect the "CameraAngle" changed signal
// mCameraAngleChangedSignal = gSavedSettings.getControl("CameraAngle")->getCommitSignal()->connect(boost::bind(&LLViewerCamera::updateCameraAngle, this, _2));
connectCameraAngleSignal();
// </FS:Zi>
}
LLViewerCamera::~LLViewerCamera()
{
// <FS:Zi> add a way to disconnect/reconnect the "CameraAngle" changed signal
// mCameraAngleChangedSignal.disconnect();
disconnectCameraAngleSignal();
// </FS:Zi>
LLPointer<LLControlVariable> cntrl_ptr = gSavedSettings.getControl("CameraAngle");
if (cntrl_ptr.notNull())
{
cntrl_ptr->getCommitSignal()->connect([](LLControlVariable* control, const LLSD& value, const LLSD& previous)
{
LLViewerCamera::getInstance()->setDefaultFOV((F32)value.asReal());
});
}
}
void LLViewerCamera::updateCameraLocation(const LLVector3 &center, const LLVector3 &up_direction, const LLVector3 &point_of_interest)
@ -834,24 +830,3 @@ bool LLViewerCamera::isDefaultFOVChanged()
return false;
}
void LLViewerCamera::updateCameraAngle(const LLSD& value)
{
setDefaultFOV((F32)value.asReal());
}
// <FS:Zi> add a way to disconnect/reconnect the "CameraAngle" changed signal
void LLViewerCamera::connectCameraAngleSignal()
{
if (mCameraAngleChangedSignal.connected())
{
mCameraAngleChangedSignal.disconnect();
}
mCameraAngleChangedSignal = gSavedSettings.getControl("CameraAngle")->getCommitSignal()->connect(boost::bind(&LLViewerCamera::updateCameraAngle, this, _2));
}
void LLViewerCamera::disconnectCameraAngleSignal()
{
mCameraAngleChangedSignal.disconnect();
}
// </FS:Zi>

View File

@ -43,7 +43,6 @@ class alignas(16) LLViewerCamera : public LLCamera, public LLSimpleton<LLViewerC
LL_ALIGN_NEW
public:
LLViewerCamera();
~LLViewerCamera();
typedef enum
{
@ -66,7 +65,6 @@ public:
const LLVector3 &point_of_interest);
static void updateFrustumPlanes(LLCamera& camera, bool ortho = false, bool zflip = false, bool no_hacks = false);
void updateCameraAngle(const LLSD& value);
void setPerspective(bool for_selection, S32 x, S32 y_from_bot, S32 width, S32 height, bool limit_select_distance, F32 z_near = 0, F32 z_far = 0);
const LLMatrix4 &getProjection() const;
@ -126,15 +124,7 @@ protected:
F32 mZoomFactor;
S16 mZoomSubregion;
boost::signals2::connection mCameraAngleChangedSignal;
public:
// <FS:Zi> Enable external classes to disconnect and connect the "CameraAngle" settings
// changed signal, so classes can copy and overwrite the camera class and restore
// the signal handler
void connectCameraAngleSignal();
void disconnectCameraAngleSignal();
// </FS:Zi>
};

View File

@ -3983,19 +3983,6 @@ bool LLViewerRegion::bakesOnMeshEnabled() const
mSimulatorFeatures["BakesOnMeshEnabled"].asBoolean());
}
bool LLViewerRegion::meshRezEnabled() const
{
// <FS:Beq> FIRE-35602 and many similar reports - Mesh not appearing after TP/login
if(!mSimulatorFeaturesReceived)
{
LL_DEBUGS("MeshRez") << "MeshRezEnabled: SimulatorFeatures not received yet. Defaulting to true" << LL_ENDL;
return true;
}
// </FS:Beq>
return (mSimulatorFeatures.has("MeshRezEnabled") &&
mSimulatorFeatures["MeshRezEnabled"].asBoolean());
}
bool LLViewerRegion::dynamicPathfindingEnabled() const
{
return ( mSimulatorFeatures.has("DynamicPathfindingEnabled") &&

View File

@ -356,7 +356,6 @@ public:
void getInfo(LLSD& info);
bool meshRezEnabled() const;
bool meshUploadEnabled() const;
bool bakesOnMeshEnabled() const;

View File

@ -6565,8 +6565,6 @@ bool LLViewerWindow::cubeSnapshot(const LLVector3& origin, LLCubeMapArray* cubea
glm::mat4 saved_proj = get_current_projection();
glm::mat4 saved_mod = get_current_modelview();
camera->disconnectCameraAngleSignal(); // <FS:Zi> disconnect the "CameraAngle" changed signal
// camera constants for the square, cube map capture image
camera->setAspect(1.0); // must set aspect ratio first to avoid undesirable clamping of vertical FoV
camera->setViewNoBroadcast(F_PI_BY_TWO);
@ -6694,8 +6692,6 @@ bool LLViewerWindow::cubeSnapshot(const LLVector3& origin, LLCubeMapArray* cubea
setup3DViewport();
LLPipeline::sUseOcclusion = old_occlusion;
camera->connectCameraAngleSignal(); // <FS:Zi> reconnect the "CameraAngle" changed signal so mouselook zoom keeps working
// ====================================================
return true;
}