summaryrefslogtreecommitdiff
path: root/indra/newview/llfloaterpreference.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/llfloaterpreference.cpp')
-rw-r--r--indra/newview/llfloaterpreference.cpp32
1 files changed, 14 insertions, 18 deletions
diff --git a/indra/newview/llfloaterpreference.cpp b/indra/newview/llfloaterpreference.cpp
index 813f9a06b7..45ff38421f 100644
--- a/indra/newview/llfloaterpreference.cpp
+++ b/indra/newview/llfloaterpreference.cpp
@@ -108,6 +108,8 @@
#include "llpluginclassmedia.h"
#include "llteleporthistorystorage.h"
+#include "lllogininstance.h" // to check if logged in yet
+
const F32 MAX_USER_FAR_CLIP = 512.f;
const F32 MIN_USER_FAR_CLIP = 64.f;
@@ -221,11 +223,6 @@ bool callback_clear_browser_cache(const LLSD& notification, const LLSD& response
void handleNameTagOptionChanged(const LLSD& newvalue)
{
- S32 name_tag_option = S32(newvalue);
- if(name_tag_option==2)
- {
- gSavedSettings.setBOOL("SmallAvatarNames", TRUE);
- }
LLVOAvatar::invalidateNameTags();
}
@@ -322,7 +319,6 @@ LLFloaterPreference::LLFloaterPreference(const LLSD& key)
sSkin = gSavedSettings.getString("SkinCurrent");
- gSavedSettings.getControl("AvatarNameTagMode")->getCommitSignal()->connect(boost::bind(&handleNameTagOptionChanged, _2));
gSavedSettings.getControl("NameTagShowSLIDs")->getCommitSignal()->connect(boost::bind(&handleNameTagOptionChanged, _2));
}
@@ -339,8 +335,6 @@ BOOL LLFloaterPreference::postBuild()
LLTabContainer* tabcontainer = getChild<LLTabContainer>("pref core");
if (!tabcontainer->selectTab(gSavedSettings.getS32("LastPrefTab")))
tabcontainer->selectFirstTab();
- S32 show_avatar_nametag_options = gSavedSettings.getS32("AvatarNameTagMode");
- handleNameTagOptionChanged(LLSD(show_avatar_nametag_options));
std::string cache_location = gDirUtilp->getExpandedFilename(LL_PATH_CACHE, "");
childSetText("cache_location", cache_location);
@@ -522,13 +516,15 @@ void LLFloaterPreference::onOpen(const LLSD& key)
// if they're not adult or a god, they shouldn't see the adult selection, so delete it
if (!gAgent.isAdult() && !gAgent.isGodlike())
{
- // we're going to remove the adult entry from the combo. This obviously depends
- // on the order of items in the XML file, but there doesn't seem to be a reasonable
- // way to depend on the field in XML called 'name'.
- maturity_combo->remove(0);
+ // we're going to remove the adult entry from the combo
+ LLScrollListCtrl* maturity_list = maturity_combo->findChild<LLScrollListCtrl>("ComboBox");
+ if (maturity_list)
+ {
+ maturity_list->deleteItems(LLSD(SIM_ACCESS_ADULT));
+ }
}
childSetVisible("maturity_desired_combobox", true);
- childSetVisible("maturity_desired_textbox", false);
+ childSetVisible("maturity_desired_textbox", false);
}
else
{
@@ -881,6 +877,8 @@ void LLFloaterPreference::refreshEnabledState()
ctrl_wind_light->setEnabled(ctrl_shader_enable->getEnabled() && shaders);
// now turn off any features that are unavailable
disableUnavailableSettings();
+
+ childSetEnabled ("block_list", LLLoginInstance::getInstance()->authSuccess());
}
void LLFloaterPreference::disableUnavailableSettings()
@@ -1102,10 +1100,8 @@ void LLFloaterPreference::onClickLogPath()
{
return; //Canceled!
}
- std::string chat_log_dir = picker.getDirName();
- std::string chat_log_top_folder= gDirUtilp->getBaseFileName(chat_log_dir);
- gSavedPerAccountSettings.setString("InstantMessageLogPath",chat_log_dir);
- gSavedPerAccountSettings.setString("InstantMessageLogFolder",chat_log_top_folder);
+
+ gSavedPerAccountSettings.setString("InstantMessageLogPath", picker.getDirName());
}
void LLFloaterPreference::setPersonalInfo(const std::string& visibility, bool im_via_email, const std::string& email)
@@ -1218,7 +1214,7 @@ void LLFloaterPreference::applyResolution()
gSavedSettings.setS32("FullScreenWidth", supported_resolutions[resIndex].mWidth);
gSavedSettings.setS32("FullScreenHeight", supported_resolutions[resIndex].mHeight);
- gViewerWindow->requestResolutionUpdate(gSavedSettings.getBOOL("WindowFullScreen"));
+ gViewerWindow->requestResolutionUpdate(gSavedSettings.getBOOL("FullScreen"));
send_agent_update(TRUE);