diff --git a/indra/newview/llfloaterhardwaresettings.cpp b/indra/newview/llfloaterhardwaresettings.cpp index 2e5a4a7f5..23da0629b 100644 --- a/indra/newview/llfloaterhardwaresettings.cpp +++ b/indra/newview/llfloaterhardwaresettings.cpp @@ -96,6 +96,7 @@ void LLFloaterHardwareSettings::refreshEnabledState() childSetMinValue("GrapicsCardTextureMemory", min_tex_mem); childSetMaxValue("GrapicsCardTextureMemory", max_tex_mem); + mLastVBOState = LLVertexBuffer::sEnableVBOs; if (!LLFeatureManager::getInstance()->isFeatureAvailable("RenderVBOEnable") || !gGLManager.mHasVertexBufferObject) { @@ -158,6 +159,13 @@ void LLFloaterHardwareSettings::onClose(bool app_quitting) } } +// virtual +void LLFloaterHardwareSettings::draw() +{ + if(mLastVBOState == !LLVertexBuffer::sEnableVBOs) + refreshEnabledState(); + LLFloater::draw(); +} //============================================================================ diff --git a/indra/newview/llfloaterhardwaresettings.h b/indra/newview/llfloaterhardwaresettings.h index bdf3fb13b..0d78d67a2 100644 --- a/indra/newview/llfloaterhardwaresettings.h +++ b/indra/newview/llfloaterhardwaresettings.h @@ -75,6 +75,9 @@ public: /// sync up menu with parameters void refresh(); + /// Draw the panel... + void draw(); + /// Apply the changed values. void apply(); @@ -87,6 +90,7 @@ public: protected: LLSliderCtrl* mCtrlVideoCardMem; + //Retained values for cancel/reset BOOL mUseVBO; BOOL mUseFBO; BOOL mUseAniso; @@ -96,6 +100,7 @@ protected: F32 mFogRatio; BOOL mProbeHardwareOnStartup; + bool mLastVBOState; //track changes to LLVertexBuffer::sEnableVBOs every frame. Bleh. private: // one instance on the inside static LLFloaterHardwareSettings* sHardwareSettings;