RLVa string constants rework (part 2)
parent
aebcd1855d
commit
7256da3e34
|
|
@ -719,7 +719,7 @@ bool idle_startup()
|
|||
}
|
||||
|
||||
// [RLVa:KB] - Patch: RLVa-2.1.0
|
||||
if (gSavedSettings.getBOOL(RLV_SETTING_MAIN))
|
||||
if (gSavedSettings.get<bool>(RlvSettingNames::Main))
|
||||
{
|
||||
show_connect_box = TRUE;
|
||||
}
|
||||
|
|
@ -874,7 +874,7 @@ bool idle_startup()
|
|||
}
|
||||
|
||||
// [RLVa:KB] - Checked: RLVa-0.2.1
|
||||
if (gSavedSettings.getBOOL(RLV_SETTING_MAIN))
|
||||
if (gSavedSettings.get<bool>(RlvSettingNames::Main))
|
||||
{
|
||||
RlvHandler::setEnabled(true);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -778,7 +778,7 @@ void settings_setup_listeners()
|
|||
gSavedSettings.getControl("RenderAutoMuteByteLimit")->getSignal()->connect(boost::bind(&handleRenderAutoMuteByteLimitChanged, _2));
|
||||
gSavedPerAccountSettings.getControl("AvatarHoverOffsetZ")->getCommitSignal()->connect(boost::bind(&handleAvatarHoverOffsetChanged, _2));
|
||||
// [RLVa:KB] - Checked: 2015-12-27 (RLVa-1.5.0)
|
||||
gSavedSettings.getControl("RestrainedLove")->getSignal()->connect(boost::bind(&RlvSettings::onChangedSettingMain, _2));
|
||||
gSavedSettings.getControl(RlvSettingNames::Main)->getSignal()->connect(boost::bind(&RlvSettings::onChangedSettingMain, _2));
|
||||
// [/RLVa:KB]
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -2660,14 +2660,14 @@ void process_chat_from_simulator(LLMessageSystem *msg, void **user_data)
|
|||
(((gRlvHandler.hasBehaviour(RLV_BHVR_RECVCHAT)) && (!gRlvHandler.isException(RLV_BHVR_RECVCHAT, from_id))) ||
|
||||
((gRlvHandler.hasBehaviour(RLV_BHVR_RECVCHATFROM)) && (gRlvHandler.isException(RLV_BHVR_RECVCHATFROM, from_id))) ))
|
||||
{
|
||||
if ( (gRlvHandler.filterChat(mesg, false)) && (!gSavedSettings.getBOOL("RestrainedLoveShowEllipsis")) )
|
||||
if ( (gRlvHandler.filterChat(mesg, false)) && (!gSavedSettings.get<bool>(RlvSettingNames::ShowEllipsis)) )
|
||||
return;
|
||||
}
|
||||
else if ((fIsEmote) &&
|
||||
(((gRlvHandler.hasBehaviour(RLV_BHVR_RECVEMOTE)) && (!gRlvHandler.isException(RLV_BHVR_RECVEMOTE, from_id))) ||
|
||||
((gRlvHandler.hasBehaviour(RLV_BHVR_RECVEMOTEFROM)) && (gRlvHandler.isException(RLV_BHVR_RECVEMOTEFROM, from_id))) ))
|
||||
{
|
||||
if (!gSavedSettings.getBOOL("RestrainedLoveShowEllipsis"))
|
||||
if (!gSavedSettings.get<bool>(RlvSettingNames::ShowEllipsis))
|
||||
return;
|
||||
mesg = "/me ...";
|
||||
}
|
||||
|
|
|
|||
|
|
@ -100,9 +100,9 @@ void RlvSettings::initClass()
|
|||
{
|
||||
initCompatibilityMode(LLStringUtil::null);
|
||||
|
||||
s_fTempAttach = rlvGetSetting<bool>(RLV_SETTING_ENABLETEMPATTACH, true);
|
||||
if (gSavedSettings.controlExists(RLV_SETTING_ENABLETEMPATTACH))
|
||||
gSavedSettings.getControl(RLV_SETTING_ENABLETEMPATTACH)->getSignal()->connect(boost::bind(&onChangedSettingBOOL, _2, &s_fTempAttach));
|
||||
s_fTempAttach = rlvGetSetting<bool>(RlvSettingNames::EnableTempAttach, true);
|
||||
if (gSavedSettings.controlExists(RlvSettingNames::EnableTempAttach))
|
||||
gSavedSettings.getControl(RlvSettingNames::EnableTempAttach)->getSignal()->connect(boost::bind(&onChangedSettingBOOL, _2, &s_fTempAttach));
|
||||
|
||||
#ifdef RLV_EXPERIMENTAL_COMPOSITEFOLDERS
|
||||
s_fCompositeFolders = rlvGetSetting<bool>(RLV_SETTING_ENABLECOMPOSITES, false);
|
||||
|
|
@ -110,19 +110,19 @@ void RlvSettings::initClass()
|
|||
gSavedSettings.getControl(RLV_SETTING_ENABLECOMPOSITES)->getSignal()->connect(boost::bind(&onChangedSettingBOOL, _2, &s_fCompositeFolders));
|
||||
#endif // RLV_EXPERIMENTAL_COMPOSITEFOLDERS
|
||||
|
||||
s_fLegacyNaming = rlvGetSetting<bool>(RLV_SETTING_ENABLELEGACYNAMING, true);
|
||||
if (gSavedSettings.controlExists(RLV_SETTING_ENABLELEGACYNAMING))
|
||||
gSavedSettings.getControl(RLV_SETTING_ENABLELEGACYNAMING)->getSignal()->connect(boost::bind(&onChangedSettingBOOL, _2, &s_fLegacyNaming));
|
||||
s_fLegacyNaming = rlvGetSetting<bool>(RlvSettingNames::EnableLegacyNaming, true);
|
||||
if (gSavedSettings.controlExists(RlvSettingNames::EnableLegacyNaming))
|
||||
gSavedSettings.getControl(RlvSettingNames::EnableLegacyNaming)->getSignal()->connect(boost::bind(&onChangedSettingBOOL, _2, &s_fLegacyNaming));
|
||||
|
||||
s_fCanOOC = rlvGetSetting<bool>(RLV_SETTING_CANOOC, true);
|
||||
s_fNoSetEnv = rlvGetSetting<bool>(RLV_SETTING_NOSETENV, false);
|
||||
s_fCanOOC = rlvGetSetting<bool>(RlvSettingNames::CanOoc, true);
|
||||
s_fNoSetEnv = rlvGetSetting<bool>(RlvSettingNames::NoSetEnv, false);
|
||||
|
||||
// Don't allow toggling RLVaLoginLastLocation from the debug settings floater
|
||||
if (gSavedPerAccountSettings.controlExists(RLV_SETTING_LOGINLASTLOCATION))
|
||||
gSavedPerAccountSettings.getControl(RLV_SETTING_LOGINLASTLOCATION)->setHiddenFromSettingsEditor(true);
|
||||
if (gSavedPerAccountSettings.controlExists(RlvSettingNames::LoginLastLocation))
|
||||
gSavedPerAccountSettings.getControl(RlvSettingNames::LoginLastLocation)->setHiddenFromSettingsEditor(true);
|
||||
|
||||
if (gSavedSettings.controlExists(RLV_SETTING_TOPLEVELMENU))
|
||||
gSavedSettings.getControl(RLV_SETTING_TOPLEVELMENU)->getSignal()->connect(boost::bind(&onChangedMenuLevel));
|
||||
if (gSavedSettings.controlExists(RlvSettingNames::TopLevelMenu))
|
||||
gSavedSettings.getControl(RlvSettingNames::TopLevelMenu)->getSignal()->connect(boost::bind(&onChangedMenuLevel));
|
||||
|
||||
int nMinMaturity = gSavedSettings.getS32("RLVaExperienceMaturityThreshold");
|
||||
s_nExperienceMinMaturity = (nMinMaturity == 0) ? 0 : ((nMinMaturity == 1) ? SIM_ACCESS_PG : ((nMinMaturity == 2) ? SIM_ACCESS_MATURE : SIM_ACCESS_ADULT));
|
||||
|
|
@ -136,12 +136,12 @@ void RlvSettings::initClass()
|
|||
// Checked: 2010-04-01 (RLVa-1.2.0c) | Modified: RLVa-0.2.1d
|
||||
void RlvSettings::updateLoginLastLocation()
|
||||
{
|
||||
if ( (!LLApp::isQuitting()) && (gSavedPerAccountSettings.controlExists(RLV_SETTING_LOGINLASTLOCATION)) )
|
||||
if ( (!LLApp::isQuitting()) && (gSavedPerAccountSettings.controlExists(RlvSettingNames::LoginLastLocation)) )
|
||||
{
|
||||
BOOL fValue = (gRlvHandler.hasBehaviour(RLV_BHVR_TPLOC)) || (!RlvActions::canStand());
|
||||
if (gSavedPerAccountSettings.getBOOL(RLV_SETTING_LOGINLASTLOCATION) != fValue)
|
||||
bool fValue = (gRlvHandler.hasBehaviour(RLV_BHVR_TPLOC)) || (!RlvActions::canStand());
|
||||
if (gSavedPerAccountSettings.get<bool>(RlvSettingNames::LoginLastLocation) != fValue)
|
||||
{
|
||||
gSavedPerAccountSettings.setBOOL(RLV_SETTING_LOGINLASTLOCATION, fValue);
|
||||
gSavedPerAccountSettings.set<bool>(RlvSettingNames::LoginLastLocation, fValue);
|
||||
gSavedPerAccountSettings.saveToFile(gSavedSettings.getString("PerAccountSettingsFile"), TRUE);
|
||||
}
|
||||
}
|
||||
|
|
@ -607,7 +607,7 @@ void RlvUtil::notifyFailedAssertion(const std::string& strAssert, const std::str
|
|||
// Don't show the same assertion over and over, or if the user opted out
|
||||
static std::string strAssertPrev, strFilePrev; static int nLinePrev;
|
||||
if ( ((strAssertPrev == strAssert) && (strFile == strFilePrev) && (nLine == nLinePrev)) ||
|
||||
(!rlvGetSetting<bool>(RLV_SETTING_SHOWASSERTIONFAIL, true)) )
|
||||
(!rlvGetSetting<bool>(RlvSettingNames::ShowAssertionFail, true)) )
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
|
@ -705,7 +705,7 @@ bool rlvMenuMainToggleVisible(LLUICtrl* pMenuCtrl)
|
|||
if (pMenuItem)
|
||||
{
|
||||
static std::string strLabel = pMenuItem->getLabel();
|
||||
if ((bool)gSavedSettings.getBOOL(RLV_SETTING_MAIN) == rlv_handler_t::isEnabled())
|
||||
if ((bool)gSavedSettings.get<bool>(RlvSettingNames::Main) == rlv_handler_t::isEnabled())
|
||||
pMenuItem->setLabel(strLabel);
|
||||
else
|
||||
pMenuItem->setLabel(strLabel + " " + LLTrans::getString("RLVaPendingRestart"));
|
||||
|
|
@ -716,7 +716,7 @@ bool rlvMenuMainToggleVisible(LLUICtrl* pMenuCtrl)
|
|||
// Checked: 2011-08-16 (RLVa-1.4.0b) | Added: RLVa-1.4.0b
|
||||
void rlvMenuToggleVisible()
|
||||
{
|
||||
bool fTopLevel = rlvGetSetting(RLV_SETTING_TOPLEVELMENU, true);
|
||||
bool fTopLevel = rlvGetSetting(RlvSettingNames::TopLevelMenu, true);
|
||||
bool fRlvEnabled = rlv_handler_t::isEnabled();
|
||||
|
||||
LLMenuGL* pRLVaMenuMain = gMenuBarView->findChildMenuByName("RLVa Main", FALSE);
|
||||
|
|
|
|||
|
|
@ -63,13 +63,21 @@ class RlvGCTimer;
|
|||
// RlvSettings
|
||||
//
|
||||
|
||||
#ifdef CATZNIP_STRINGVIEW
|
||||
template<typename T> inline T rlvGetSetting(const boost::string_view& strSetting, const T& defaultValue)
|
||||
#else
|
||||
template<typename T> inline T rlvGetSetting(const std::string& strSetting, const T& defaultValue)
|
||||
#endif // CATZNIP_STRINGVIEW
|
||||
{
|
||||
RLV_ASSERT_DBG(gSavedSettings.controlExists(strSetting));
|
||||
return (gSavedSettings.controlExists(strSetting)) ? gSavedSettings.get<T>(strSetting) : defaultValue;
|
||||
}
|
||||
|
||||
#ifdef CATZNIP_STRINGVIEW
|
||||
template<typename T> inline T rlvGetPerUserSetting(const boost::string_view& strSetting, const T& defaultValue)
|
||||
#else
|
||||
template<typename T> inline T rlvGetPerUserSetting(const std::string& strSetting, const T& defaultValue)
|
||||
#endif // CATZNIP_STRINGVIEW
|
||||
{
|
||||
RLV_ASSERT_DBG(gSavedPerAccountSettings.controlExists(strSetting));
|
||||
return (gSavedPerAccountSettings.controlExists(strSetting)) ? gSavedPerAccountSettings.get<T>(strSetting) : defaultValue;
|
||||
|
|
@ -78,29 +86,29 @@ template<typename T> inline T rlvGetPerUserSetting(const std::string& strSetting
|
|||
class RlvSettings
|
||||
{
|
||||
public:
|
||||
static bool getDebug() { return rlvGetSetting<bool>(RLV_SETTING_DEBUG, false); }
|
||||
static bool getDebug() { return rlvGetSetting<bool>(RlvSettingNames::Debug, false); }
|
||||
static bool getCanOOC() { return s_fCanOOC; }
|
||||
static bool getForbidGiveToRLV() { return rlvGetSetting<bool>(RLV_SETTING_FORBIDGIVETORLV, true); }
|
||||
static bool getForbidGiveToRLV() { return rlvGetSetting<bool>(RlvSettingNames::ForbidGiveToRlv, true); }
|
||||
static bool getNoSetEnv() { return s_fNoSetEnv; }
|
||||
|
||||
static std::string getWearAddPrefix() { return rlvGetSetting<std::string>(RLV_SETTING_WEARADDPREFIX, LLStringUtil::null); }
|
||||
static std::string getWearReplacePrefix() { return rlvGetSetting<std::string>(RLV_SETTING_WEARREPLACEPREFIX, LLStringUtil::null); }
|
||||
static std::string getWearAddPrefix() { return rlvGetSetting<std::string>(RlvSettingNames::WearAddPrefix, LLStringUtil::null); }
|
||||
static std::string getWearReplacePrefix() { return rlvGetSetting<std::string>(RlvSettingNames::WearReplacePrefix, LLStringUtil::null); }
|
||||
|
||||
static bool getDebugHideUnsetDup() { return rlvGetSetting<bool>(RLV_SETTING_DEBUGHIDEUNSETDUP, false); }
|
||||
static bool getDebugHideUnsetDup() { return rlvGetSetting<bool>(RlvSettingNames::DebugHideUnsetDup, false); }
|
||||
#ifdef RLV_EXPERIMENTAL_COMPOSITEFOLDERS
|
||||
static BOOL getEnableComposites() { return s_fCompositeFolders; }
|
||||
#endif // RLV_EXPERIMENTAL_COMPOSITEFOLDERS
|
||||
static bool getEnableIMQuery() { return rlvGetSetting<bool>("RLVaEnableIMQuery", true); }
|
||||
static bool getEnableIMQuery() { return rlvGetSetting<bool>(RlvSettingNames::EnableIMQuery, true); }
|
||||
static bool getEnableLegacyNaming() { return s_fLegacyNaming; }
|
||||
static bool getEnableSharedWear() { return rlvGetSetting<bool>(RLV_SETTING_ENABLESHAREDWEAR, false); }
|
||||
static bool getEnableSharedWear() { return rlvGetSetting<bool>(RlvSettingNames::EnableSharedWear, false); }
|
||||
static bool getEnableTemporaryAttachments() { return s_fTempAttach; }
|
||||
static bool getHideLockedLayers() { return rlvGetSetting<bool>(RLV_SETTING_HIDELOCKEDLAYER, false); }
|
||||
static bool getHideLockedAttach() { return rlvGetSetting<bool>(RLV_SETTING_HIDELOCKEDATTACH, false); }
|
||||
static bool getHideLockedInventory() { return rlvGetSetting<bool>(RLV_SETTING_HIDELOCKEDINVENTORY, false); }
|
||||
static bool getSharedInvAutoRename() { return rlvGetSetting<bool>(RLV_SETTING_SHAREDINVAUTORENAME, true); }
|
||||
static bool getSplitRedirectChat() { return rlvGetSetting<bool>(RLV_SETTING_SPLITREDIRECTCHAT, false); }
|
||||
static bool getHideLockedLayers() { return rlvGetSetting<bool>(RlvSettingNames::HideLockedLayer, false); }
|
||||
static bool getHideLockedAttach() { return rlvGetSetting<bool>(RlvSettingNames::HideLockedAttach, false); }
|
||||
static bool getHideLockedInventory() { return rlvGetSetting<bool>(RlvSettingNames::HideLockedInventory, false); }
|
||||
static bool getSharedInvAutoRename() { return rlvGetSetting<bool>(RlvSettingNames::SharedInvAutoRename, true); }
|
||||
static bool getSplitRedirectChat() { return rlvGetSetting<bool>(RlvSettingNames::SplitRedirectChat, false); }
|
||||
|
||||
static bool getLoginLastLocation() { return rlvGetPerUserSetting<bool>(RLV_SETTING_LOGINLASTLOCATION, true); }
|
||||
static bool getLoginLastLocation() { return rlvGetPerUserSetting<bool>(RlvSettingNames::LoginLastLocation, true); }
|
||||
static void updateLoginLastLocation();
|
||||
|
||||
static void initCompatibilityMode(std::string strCompatList);
|
||||
|
|
|
|||
|
|
@ -365,32 +365,58 @@ enum ERlvAttachGroupType
|
|||
// Settings
|
||||
//
|
||||
|
||||
#define RLV_SETTING_MAIN "RestrainedLove"
|
||||
#define RLV_SETTING_DEBUG "RestrainedLoveDebug"
|
||||
#define RLV_SETTING_CANOOC "RestrainedLoveCanOOC"
|
||||
#define RLV_SETTING_FORBIDGIVETORLV "RestrainedLoveForbidGiveToRLV"
|
||||
#define RLV_SETTING_NOSETENV "RestrainedLoveNoSetEnv"
|
||||
#define RLV_SETTING_SHOWELLIPSIS "RestrainedLoveShowEllipsis"
|
||||
#define RLV_SETTING_WEARADDPREFIX "RestrainedLoveStackWhenFolderBeginsWith"
|
||||
#define RLV_SETTING_WEARREPLACEPREFIX "RestrainedLoveReplaceWhenFolderBeginsWith"
|
||||
namespace RlvSettingNames
|
||||
{
|
||||
#ifdef CATZNIP_STRINGVIEW
|
||||
/*inline*/ constexpr boost::string_view Main = make_string_view("RestrainedLove");
|
||||
/*inline*/ constexpr boost::string_view Debug = make_string_view("RestrainedLoveDebug");
|
||||
/*inline*/ constexpr boost::string_view CanOoc = make_string_view("RestrainedLoveCanOOC");
|
||||
/*inline*/ constexpr boost::string_view ForbidGiveToRlv = make_string_view("RestrainedLoveForbidGiveToRLV");
|
||||
/*inline*/ constexpr boost::string_view NoSetEnv = make_string_view("RestrainedLoveNoSetEnv");
|
||||
/*inline*/ constexpr boost::string_view ShowEllipsis = make_string_view("RestrainedLoveShowEllipsis");
|
||||
/*inline*/ constexpr boost::string_view WearAddPrefix = make_string_view("RestrainedLoveStackWhenFolderBeginsWith");
|
||||
/*inline*/ constexpr boost::string_view WearReplacePrefix = make_string_view("RestrainedLoveReplaceWhenFolderBeginsWith");
|
||||
|
||||
#define RLV_SETTING_DEBUGHIDEUNSETDUP "RLVaDebugHideUnsetDuplicate"
|
||||
#define RLV_SETTING_ENABLECOMPOSITES "RLVaEnableCompositeFolders"
|
||||
#define RLV_SETTING_ENABLELEGACYNAMING "RLVaEnableLegacyNaming"
|
||||
#define RLV_SETTING_ENABLESHAREDWEAR "RLVaEnableSharedWear"
|
||||
#define RLV_SETTING_ENABLETEMPATTACH "RLVaEnableTemporaryAttachments"
|
||||
#define RLV_SETTING_HIDELOCKEDLAYER "RLVaHideLockedLayers"
|
||||
#define RLV_SETTING_HIDELOCKEDATTACH "RLVaHideLockedAttachments"
|
||||
#define RLV_SETTING_HIDELOCKEDINVENTORY "RLVaHideLockedInventory"
|
||||
#define RLV_SETTING_LOGINLASTLOCATION "RLVaLoginLastLocation"
|
||||
#define RLV_SETTING_SHAREDINVAUTORENAME "RLVaSharedInvAutoRename"
|
||||
#define RLV_SETTING_SHOWASSERTIONFAIL "RLVaShowAssertionFailures"
|
||||
#define RLV_SETTING_SPLITREDIRECTCHAT "RLVaSplitRedirectChat"
|
||||
#define RLV_SETTING_TOPLEVELMENU "RLVaTopLevelMenu"
|
||||
#define RLV_SETTING_WEARREPLACEUNLOCKED "RLVaWearReplaceUnlocked"
|
||||
/*inline*/ constexpr boost::string_view DebugHideUnsetDup = make_string_view("RLVaDebugHideUnsetDuplicate");
|
||||
/*inline*/ constexpr boost::string_view EnableIMQuery = make_string_view("RLVaEnableIMQuery");
|
||||
/*inline*/ constexpr boost::string_view EnableLegacyNaming = make_string_view("RLVaEnableLegacyNaming");
|
||||
/*inline*/ constexpr boost::string_view EnableSharedWear = make_string_view("RLVaEnableSharedWear");
|
||||
/*inline*/ constexpr boost::string_view EnableTempAttach = make_string_view("RLVaEnableTemporaryAttachments");
|
||||
/*inline*/ constexpr boost::string_view HideLockedLayer = make_string_view("RLVaHideLockedLayers");
|
||||
/*inline*/ constexpr boost::string_view HideLockedAttach = make_string_view("RLVaHideLockedAttachments");
|
||||
/*inline*/ constexpr boost::string_view HideLockedInventory = make_string_view("RLVaHideLockedInventory");
|
||||
/*inline*/ constexpr boost::string_view LoginLastLocation = make_string_view("RLVaLoginLastLocation");
|
||||
/*inline*/ constexpr boost::string_view SharedInvAutoRename = make_string_view("RLVaSharedInvAutoRename");
|
||||
/*inline*/ constexpr boost::string_view ShowAssertionFail = make_string_view("RLVaShowAssertionFailures");
|
||||
/*inline*/ constexpr boost::string_view SplitRedirectChat = make_string_view("RLVaSplitRedirectChat");
|
||||
/*inline*/ constexpr boost::string_view TopLevelMenu = make_string_view("RLVaTopLevelMenu");
|
||||
/*inline*/ constexpr boost::string_view WearReplaceUnlocked = make_string_view("RLVaWearReplaceUnlocked");
|
||||
#else
|
||||
constexpr const char Main[] = "RestrainedLove";
|
||||
constexpr const char Debug[] = "RestrainedLoveDebug";
|
||||
constexpr const char CanOoc[] = "RestrainedLoveCanOOC";
|
||||
constexpr const char ForbidGiveToRlv[] = "RestrainedLoveForbidGiveToRLV";
|
||||
constexpr const char NoSetEnv[] = "RestrainedLoveNoSetEnv";
|
||||
constexpr const char ShowEllipsis[] = "RestrainedLoveShowEllipsis";
|
||||
constexpr const char WearAddPrefix[] = "RestrainedLoveStackWhenFolderBeginsWith";
|
||||
constexpr const char WearReplacePrefix[] = "RestrainedLoveReplaceWhenFolderBeginsWith";
|
||||
|
||||
#define RLV_SETTING_FIRSTUSE_PREFIX "FirstRLV"
|
||||
#define RLV_SETTING_FIRSTUSE_GIVETORLV RLV_SETTING_FIRSTUSE_PREFIX"GiveToRLV"
|
||||
constexpr const char DebugHideUnsetDup[] = "RLVaDebugHideUnsetDuplicate";
|
||||
constexpr const char EnableIMQuery[] = "RLVaEnableIMQuery";
|
||||
constexpr const char EnableLegacyNaming[] = "RLVaEnableLegacyNaming";
|
||||
constexpr const char EnableSharedWear[] = "RLVaEnableSharedWear";
|
||||
constexpr const char EnableTempAttach[] = "RLVaEnableTemporaryAttachments";
|
||||
constexpr const char HideLockedLayer[] = "RLVaHideLockedLayers";
|
||||
constexpr const char HideLockedAttach[] = "RLVaHideLockedAttachments";
|
||||
constexpr const char HideLockedInventory[] = "RLVaHideLockedInventory";
|
||||
constexpr const char LoginLastLocation[] = "RLVaLoginLastLocation";
|
||||
constexpr const char SharedInvAutoRename[] = "RLVaSharedInvAutoRename";
|
||||
constexpr const char ShowAssertionFail[] = "RLVaShowAssertionFailures";
|
||||
constexpr const char SplitRedirectChat[] = "RLVaSplitRedirectChat";
|
||||
constexpr const char TopLevelMenu[] = "RLVaTopLevelMenu";
|
||||
constexpr const char WearReplaceUnlocked[] = "RLVaWearReplaceUnlocked";
|
||||
#endif // CATZNIP_STRINGVIEW
|
||||
}
|
||||
|
||||
// ============================================================================
|
||||
// Strings (see rlva_strings.xml)
|
||||
|
|
|
|||
|
|
@ -35,8 +35,8 @@ RlvExtGetSet::RlvExtGetSet()
|
|||
{
|
||||
m_DbgAllowed.insert(std::pair<std::string, S16>("AvatarSex", DBG_READ | DBG_WRITE | DBG_PSEUDO));
|
||||
m_DbgAllowed.insert(std::pair<std::string, S16>("RenderResolutionDivisor", DBG_READ | DBG_WRITE));
|
||||
m_DbgAllowed.insert(std::pair<std::string, S16>(RLV_SETTING_FORBIDGIVETORLV, DBG_READ));
|
||||
m_DbgAllowed.insert(std::pair<std::string, S16>(RLV_SETTING_NOSETENV, DBG_READ));
|
||||
m_DbgAllowed.insert(std::pair<std::string, S16>(RlvSettingNames::ForbidGiveToRlv, DBG_READ));
|
||||
m_DbgAllowed.insert(std::pair<std::string, S16>(RlvSettingNames::NoSetEnv, DBG_READ));
|
||||
m_DbgAllowed.insert(std::pair<std::string, S16>("WindLightUseAtmosShaders", DBG_READ));
|
||||
|
||||
// Cache persistance of every setting
|
||||
|
|
|
|||
|
|
@ -1240,7 +1240,7 @@ bool RlvHandler::filterChat(std::string& strUTF8Text, bool fFilterEmote) const
|
|||
}
|
||||
|
||||
if (fFilter)
|
||||
strUTF8Text = (gSavedSettings.getBOOL("RestrainedLoveShowEllipsis")) ? "..." : "";
|
||||
strUTF8Text = (gSavedSettings.get<bool>(RlvSettingNames::ShowEllipsis)) ? "..." : "";
|
||||
return fFilter;
|
||||
}
|
||||
|
||||
|
|
@ -1520,7 +1520,7 @@ bool RlvHandler::setEnabled(bool fEnable)
|
|||
|
||||
// Reset to show assertions if the viewer version changed
|
||||
if (gSavedSettings.getString("LastRunVersion") != gLastRunVersion)
|
||||
gSavedSettings.setBOOL("RLVaShowAssertionFailures", TRUE);
|
||||
gSavedSettings.set<bool>(RlvSettingNames::ShowAssertionFail, TRUE);
|
||||
}
|
||||
|
||||
return m_fEnabled;
|
||||
|
|
|
|||
|
|
@ -631,7 +631,7 @@ void RlvAttachmentLockWatchdog::onAttach(const LLViewerObject* pAttachObj, const
|
|||
if ( (pAttachObj != *itAttachObj) && (gRlvAttachmentLocks.isLockedAttachment(*itAttachObj)) )
|
||||
{
|
||||
// Fail if we encounter a non-detachable attachment (unless we're only replacing detachable attachments)
|
||||
if (gSavedSettings.getBOOL("RLVaWearReplaceUnlocked"))
|
||||
if (gSavedSettings.get<bool>(RlvSettingNames::WearReplaceUnlocked))
|
||||
idsAttachObjExcept.push_back((*itAttachObj)->getID());
|
||||
else
|
||||
fAttachAllowed = false;
|
||||
|
|
|
|||
Loading…
Reference in New Issue