From 8227a0b270f6e7cc521adeb7b97ad2d5fb646973 Mon Sep 17 00:00:00 2001 From: Rider Linden Date: Fri, 21 Dec 2018 15:30:57 -0800 Subject: SL-10279: Rework the environment pannel. Still in progress. --- indra/newview/llenvironment.cpp | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'indra/newview/llenvironment.cpp') diff --git a/indra/newview/llenvironment.cpp b/indra/newview/llenvironment.cpp index a8a386edee..3541eb40fa 100644 --- a/indra/newview/llenvironment.cpp +++ b/indra/newview/llenvironment.cpp @@ -1600,6 +1600,7 @@ LLEnvironment::EnvironmentInfo::ptr_t LLEnvironment::EnvironmentInfo::extract(LL LLSD daynames = environment[KEY_DAYNAMES]; if (daynames.isArray()) { + pinfo->mDayCycleName.clear(); for (S32 index = 0; index < pinfo->mNameList.size(); ++index) { pinfo->mNameList[index] = daynames[index].asString(); @@ -1607,9 +1608,19 @@ LLEnvironment::EnvironmentInfo::ptr_t LLEnvironment::EnvironmentInfo::extract(LL } else if (daynames.isString()) { + for (std::string &name: pinfo->mNameList) + { + name.clear(); + } + pinfo->mDayCycleName = daynames.asString(); } } + else if (pinfo->mDayCycle) + { + pinfo->mDayCycleName = pinfo->mDayCycle->getName(); + } + if (environment.has(KEY_ENVVERSION)) { -- cgit v1.2.3