From d62079002df2d8391c7205029f2ff1242aaddf6a Mon Sep 17 00:00:00 2001
From: Rider Linden <rider@lindenlab.com>
Date: Fri, 24 Aug 2018 12:39:14 -0700
Subject: [PATCH] Some work on clearDirtyFlag and fix a unit test.

---
 indra/newview/llfloaterfixedenvironment.cpp  | 15 +++++++++++++++
 indra/newview/llfloaterfixedenvironment.h    |  2 +-
 indra/newview/tests/llviewernetwork_test.cpp |  4 ++--
 3 files changed, 18 insertions(+), 3 deletions(-)

diff --git a/indra/newview/llfloaterfixedenvironment.cpp b/indra/newview/llfloaterfixedenvironment.cpp
index 6f7bd85699d..915bc687d8d 100644
--- a/indra/newview/llfloaterfixedenvironment.cpp
+++ b/indra/newview/llfloaterfixedenvironment.cpp
@@ -442,6 +442,21 @@ void LLFloaterFixedEnvironment::onInventoryUpdated(LLUUID asset_id, LLUUID inven
 }
 
 
+void LLFloaterFixedEnvironment::clearDirtyFlag()
+{
+    mIsDirty = false;
+
+    S32 count = mTab->getTabCount();
+
+    for (S32 idx = 0; idx < count; ++idx)
+    {
+        LLSettingsEditPanel *panel = static_cast<LLSettingsEditPanel *>(mTab->getPanelByIndex(idx));
+        if (panel)
+            panel->clearIsDirty();
+    }
+
+}
+
 void LLFloaterFixedEnvironment::doSelectFromInventory()
 {
     LLFloaterSettingsPicker *picker = getSettingsPicker();
diff --git a/indra/newview/llfloaterfixedenvironment.h b/indra/newview/llfloaterfixedenvironment.h
index b610aef5f71..85a9ba0141a 100644
--- a/indra/newview/llfloaterfixedenvironment.h
+++ b/indra/newview/llfloaterfixedenvironment.h
@@ -103,7 +103,7 @@ class LLFloaterFixedEnvironment : public LLFloater
 
     bool                    getIsDirty() const  { return mIsDirty; }
     void                    setDirtyFlag()      { mIsDirty = true; }
-    virtual void            clearDirtyFlag()    { mIsDirty = false; }
+    virtual void            clearDirtyFlag();
 
     void                    doSelectFromInventory();
     void                    onPanelDirtyFlagChanged(bool);
diff --git a/indra/newview/tests/llviewernetwork_test.cpp b/indra/newview/tests/llviewernetwork_test.cpp
index d1dddf8e7e2..22b576eb224 100644
--- a/indra/newview/tests/llviewernetwork_test.cpp
+++ b/indra/newview/tests/llviewernetwork_test.cpp
@@ -258,7 +258,7 @@ namespace tut
 					  std::string("https://login.aditi.lindenlab.com/cgi-bin/login.cgi"));
 		ensure_equals("Aditi helper uri",
 					  LLGridManager::getInstance()->getHelperURI("util.aditi.lindenlab.com"),
-					  std::string("http://aditi-secondlife.webdev.lindenlab.com/helpers/"));
+					  std::string("https://aditi-secondlife.webdev.lindenlab.com/helpers/"));
 		ensure_equals("Aditi login page",
 					  LLGridManager::getInstance()->getLoginPage("util.aditi.lindenlab.com"),
 					  std::string("https://viewer-splash.secondlife.com/"));
@@ -330,7 +330,7 @@ namespace tut
 					  std::string("https://login.aditi.lindenlab.com/cgi-bin/login.cgi"));
 		ensure_equals("Aditi helper uri",
 					  LLGridManager::getInstance()->getHelperURI("util.aditi.lindenlab.com"),
-					  std::string("http://aditi-secondlife.webdev.lindenlab.com/helpers/"));
+					  std::string("https://aditi-secondlife.webdev.lindenlab.com/helpers/"));
 		ensure_equals("Aditi login page",
 					  LLGridManager::getInstance()->getLoginPage("util.aditi.lindenlab.com"),
 					  std::string("https://viewer-splash.secondlife.com/"));
-- 
GitLab