aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/linden/indra/newview/llviewercontrol.cpp
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--linden/indra/newview/llviewercontrol.cpp24
1 files changed, 16 insertions, 8 deletions
diff --git a/linden/indra/newview/llviewercontrol.cpp b/linden/indra/newview/llviewercontrol.cpp
index 98d19bc..9651fa3 100644
--- a/linden/indra/newview/llviewercontrol.cpp
+++ b/linden/indra/newview/llviewercontrol.cpp
@@ -43,7 +43,7 @@
43#include "lldrawpoolterrain.h" 43#include "lldrawpoolterrain.h"
44#include "llflexibleobject.h" 44#include "llflexibleobject.h"
45#include "llfeaturemanager.h" 45#include "llfeaturemanager.h"
46#include "llglslshader.h" 46#include "llviewershadermgr.h"
47#include "llnetmap.h" 47#include "llnetmap.h"
48#include "llpanelgeneral.h" 48#include "llpanelgeneral.h"
49#include "llpanelinput.h" 49#include "llpanelinput.h"
@@ -76,14 +76,14 @@ BOOL gHackGodmode = FALSE;
76#endif 76#endif
77 77
78 78
79std::map<LLString, LLControlGroup*> gSettings; 79std::map<std::string, LLControlGroup*> gSettings;
80LLControlGroup gSavedSettings; // saved at end of session 80LLControlGroup gSavedSettings; // saved at end of session
81LLControlGroup gSavedPerAccountSettings; // saved at end of session 81LLControlGroup gSavedPerAccountSettings; // saved at end of session
82LLControlGroup gColors; // read-only 82LLControlGroup gColors; // read-only
83LLControlGroup gCrashSettings; // saved at end of session 83LLControlGroup gCrashSettings; // saved at end of session
84 84
85LLString gLastRunVersion; 85std::string gLastRunVersion;
86LLString gCurrentVersion; 86std::string gCurrentVersion;
87 87
88extern BOOL gResizeScreenTexture; 88extern BOOL gResizeScreenTexture;
89extern BOOL gDebugGL; 89extern BOOL gDebugGL;
@@ -114,7 +114,7 @@ static bool handleTerrainDetailChanged(const LLSD& newvalue)
114 114
115static bool handleSetShaderChanged(const LLSD& newvalue) 115static bool handleSetShaderChanged(const LLSD& newvalue)
116{ 116{
117 LLShaderMgr::setShaders(); 117 LLViewerShaderMgr::instance()->setShaders();
118 return true; 118 return true;
119} 119}
120 120
@@ -141,6 +141,12 @@ static bool handleAvatarLODChanged(const LLSD& newvalue)
141 return true; 141 return true;
142} 142}
143 143
144static bool handleAvatarMaxVisibleChanged(const LLSD& newvalue)
145{
146 LLVOAvatar::sMaxVisible = (U32) newvalue.asInteger();
147 return true;
148}
149
144static bool handleTerrainLODChanged(const LLSD& newvalue) 150static bool handleTerrainLODChanged(const LLSD& newvalue)
145{ 151{
146 LLVOSurfacePatch::sLODFactor = (F32)newvalue.asReal(); 152 LLVOSurfacePatch::sLODFactor = (F32)newvalue.asReal();
@@ -271,7 +277,7 @@ static bool handleAudioStreamMusicChanged(const LLSD& newvalue)
271 // otherwise music will briefly stop 277 // otherwise music will briefly stop
272 if ( !gAudiop->isInternetStreamPlaying() ) 278 if ( !gAudiop->isInternetStreamPlaying() )
273 { 279 {
274 gAudiop->startInternetStream(LLViewerParcelMgr::getInstance()->getAgentParcel()->getMusicURL().c_str()); 280 gAudiop->startInternetStream(LLViewerParcelMgr::getInstance()->getAgentParcel()->getMusicURL());
275 } 281 }
276 } 282 }
277 } 283 }
@@ -385,7 +391,7 @@ static bool handleDebugViewsChanged(const LLSD& newvalue)
385static bool handleLogFileChanged(const LLSD& newvalue) 391static bool handleLogFileChanged(const LLSD& newvalue)
386{ 392{
387 std::string log_filename = newvalue.asString(); 393 std::string log_filename = newvalue.asString();
388 LLFile::remove(log_filename.c_str()); 394 LLFile::remove(log_filename);
389 LLError::logToFile(log_filename); 395 LLError::logToFile(log_filename);
390 return true; 396 return true;
391} 397}
@@ -454,6 +460,7 @@ void settings_setup_listeners()
454 gSavedSettings.getControl("RenderAvatarCloth")->getSignal()->connect(boost::bind(&handleSetShaderChanged, _1)); 460 gSavedSettings.getControl("RenderAvatarCloth")->getSignal()->connect(boost::bind(&handleSetShaderChanged, _1));
455 gSavedSettings.getControl("WindLightUseAtmosShaders")->getSignal()->connect(boost::bind(&handleSetShaderChanged, _1)); 461 gSavedSettings.getControl("WindLightUseAtmosShaders")->getSignal()->connect(boost::bind(&handleSetShaderChanged, _1));
456 gSavedSettings.getControl("RenderGammaFull")->getSignal()->connect(boost::bind(&handleSetShaderChanged, _1)); 462 gSavedSettings.getControl("RenderGammaFull")->getSignal()->connect(boost::bind(&handleSetShaderChanged, _1));
463 gSavedSettings.getControl("RenderAvatarMaxVisible")->getSignal()->connect(boost::bind(&handleAvatarMaxVisibleChanged, _1));
457 gSavedSettings.getControl("RenderVolumeLODFactor")->getSignal()->connect(boost::bind(&handleVolumeLODChanged, _1)); 464 gSavedSettings.getControl("RenderVolumeLODFactor")->getSignal()->connect(boost::bind(&handleVolumeLODChanged, _1));
458 gSavedSettings.getControl("RenderAvatarLODFactor")->getSignal()->connect(boost::bind(&handleAvatarLODChanged, _1)); 465 gSavedSettings.getControl("RenderAvatarLODFactor")->getSignal()->connect(boost::bind(&handleAvatarLODChanged, _1));
459 gSavedSettings.getControl("RenderTerrainLODFactor")->getSignal()->connect(boost::bind(&handleTerrainLODChanged, _1)); 466 gSavedSettings.getControl("RenderTerrainLODFactor")->getSignal()->connect(boost::bind(&handleTerrainLODChanged, _1));
@@ -686,4 +693,5 @@ void test_cached_control()
686 693
687 if((std::string)test_BrowserHomePage != "http://www.secondlife.com") llerrs << "Fail BrowserHomePage" << llendl; 694 if((std::string)test_BrowserHomePage != "http://www.secondlife.com") llerrs << "Fail BrowserHomePage" << llendl;
688} 695}
689#endif // TEST_CACHED_CONTROL \ No newline at end of file 696#endif // TEST_CACHED_CONTROL
697