diff --git a/indra/newview/llavataractions.cpp b/indra/newview/llavataractions.cpp index 3456ba49cb..8b05acc318 100644 --- a/indra/newview/llavataractions.cpp +++ b/indra/newview/llavataractions.cpp @@ -440,15 +440,15 @@ void LLAvatarActions::showProfile(const LLUUID& id) if (id.notNull()) { // - if (gSavedSettings.getBOOL("FSUseWebProfiles")) +// LLAvatarNameCache::get(id, boost::bind(&on_avatar_name_show_profile, _1, _2)); + if (gSavedSettings.getBOOL("FSUseWebProfiles")) + { + showProfileWeb(id); + } + else { - showProfileWeb(id); - } - else - { showProfileLegacy(id); } -// LLAvatarNameCache::get(id, boost::bind(&on_avatar_name_show_profile, _1, _2)); // } } @@ -466,12 +466,11 @@ bool LLAvatarActions::profileVisible(const LLUUID& id) LLFloater* LLAvatarActions::getProfileFloater(const LLUUID& id) { // - if (!gSavedSettings.getBOOL("FSUseWebProfiles")) - { - FSFloaterProfile *browser = dynamic_cast - (LLFloaterReg::findInstance("floater_profile", LLSD().with("id", id))); - return browser; - } + if (!gSavedSettings.getBOOL("FSUseWebProfiles")) + { + FSFloaterProfile* browser = LLFloaterReg::findTypedInstance("floater_profile", LLSD().with("id", id)); + return browser; + } // LLFloaterWebContent *browser = dynamic_cast (LLFloaterReg::findInstance(get_profile_floater_name(id), LLSD().with("id", id))); @@ -493,7 +492,7 @@ void LLAvatarActions::showProfileLegacy(const LLUUID& id) { if (id.notNull()) { - LLFloaterReg::showInstance("floater_profile", LLSD().with("id", id)); + LLFloaterReg::showInstance("floater_profile", LLSD().with("id", id)); } } // @@ -758,49 +757,42 @@ namespace action_give_inventory * Checks My Inventory visibility. */ -// static bool is_give_inventory_acceptable() +// static bool is_give_inventory_acceptable() // [SL:KB] - Patch: Inventory-ShareSelection | Checked: 2011-06-29 (Catznip-2.6.0e) | Added: Catznip-2.6.0e - static bool is_give_inventory_acceptable(const uuid_set_t inventory_selected_uuids) + static bool is_give_inventory_acceptable(const uuid_set_t inventory_selected_uuids) // [/SL:KB] - { -// LLInventoryPanel* active_panel = get_active_inventory_panel(); -// if (!active_panel) return false; - -// // check selection in the panel + { +// // check selection in the panel // const std::set inventory_selected_uuids = LLAvatarActions::getInventorySelectedUUIDs(); -// - if (inventory_selected_uuids.empty()) return false; // nothing selected + if (inventory_selected_uuids.empty()) return false; // nothing selected - bool acceptable = false; -// std::set::const_iterator it = inventory_selected_uuids.begin(); -// const std::set::const_iterator it_end = inventory_selected_uuids.end(); + bool acceptable = false; + std::set::const_iterator it = inventory_selected_uuids.begin(); + const std::set::const_iterator it_end = inventory_selected_uuids.end(); + for (; it != it_end; ++it) + { + LLViewerInventoryCategory* inv_cat = gInventory.getCategory(*it); + // any category can be offered. + if (inv_cat) + { + acceptable = true; + continue; + } - uuid_set_t::const_iterator it = inventory_selected_uuids.begin(); - const uuid_set_t::const_iterator it_end = inventory_selected_uuids.end(); - for (; it != it_end; ++it) - { - LLViewerInventoryCategory* inv_cat = gInventory.getCategory(*it); - // any category can be offered. - if (inv_cat) - { - acceptable = true; - continue; - } + LLViewerInventoryItem* inv_item = gInventory.getItem(*it); + // check if inventory item can be given + if (LLGiveInventory::isInventoryGiveAcceptable(inv_item)) + { + acceptable = true; + continue; + } - LLViewerInventoryItem* inv_item = gInventory.getItem(*it); - // check if inventory item can be given - if (LLGiveInventory::isInventoryGiveAcceptable(inv_item)) - { - acceptable = true; - continue; - } - - // there are neither item nor category in inventory - acceptable = false; - break; - } - return acceptable; - } + // there are neither item nor category in inventory + acceptable = false; + break; + } + return acceptable; + } static void build_items_string(const std::set& inventory_selected_uuids , std::string& items_string) diff --git a/indra/newview/llgroupactions.cpp b/indra/newview/llgroupactions.cpp index 3f232f1f4e..56a7938ab3 100755 --- a/indra/newview/llgroupactions.cpp +++ b/indra/newview/llgroupactions.cpp @@ -44,6 +44,7 @@ // Firestorm includes #include "exogroupmutelist.h" +#include "fscommon.h" #include "fsdata.h" #include "fsfloatercontacts.h" #include "fsfloatergroup.h" @@ -98,7 +99,7 @@ public: //LLSD params; //params["people_panel_tab_name"] = "groups_panel"; //LLFloaterSidePanelContainer::showPanel("people", "panel_people", params); - if (gSavedSettings.getBOOL("FSUseV2Friends") && gSavedSettings.getString("FSInternalSkinCurrent") != "Vintage") + if (gSavedSettings.getBOOL("FSUseV2Friends") && !FSCommon::isLegacySkin()) { LLSD params; params["people_panel_tab_name"] = "groups_panel"; @@ -612,15 +613,6 @@ LLUUID LLGroupActions::startIM(const LLUUID& group_id) { if (group_id.isNull()) return LLUUID::null; -// [RLVa:KB] - Checked: 2013-05-09 (RLVa-1.4.9) - if ( (!RlvActions::canStartIM(group_id)) && (!RlvActions::hasOpenGroupSession(group_id)) ) - { - make_ui_sound("UISndInvalidOp"); - RlvUtil::notifyBlocked(RLV_STRING_BLOCKED_STARTIM, LLSD().with("RECIPIENT", LLSLURL("group", group_id, "about").getSLURLString())); - return LLUUID::null; - } -// [/RLVa:KB] - // [RLVa:KB] - Checked: 2013-05-09 (RLVa-1.4.9) if ( (!RlvActions::canStartIM(group_id)) && (!RlvActions::hasOpenGroupSession(group_id)) ) { @@ -838,13 +830,6 @@ bool LLGroupActions::canEjectFromGroup(const LLUUID& idGroup, const LLUUID& idAg void LLGroupActions::ejectFromGroup(const LLUUID& idGroup, const LLUUID& idAgent) { - // FIRE-8499 - Eject from group confirmation - //if (!canEjectFromGroup(idGroup, idAgent)) - // return; - - //uuid_vec_t idAgents; - //idAgents.push_back(idAgent); - //LLGroupMgr::instance().sendGroupMemberEjects(idGroup, idAgents); LLSD args; LLSD payload; payload["avatar_id"] = idAgent; @@ -877,7 +862,6 @@ bool LLGroupActions::callbackEject(const LLSD& notification, const LLSD& respons LLGroupMgr::instance().sendGroupMemberEjects(idGroup, idAgents); } return false; - // } // [/SL:KB]