diff options
-rw-r--r-- | indra/newview/llfloatereditextdaycycle.cpp | 6 | ||||
-rw-r--r-- | indra/newview/llfloatereditextdaycycle.h | 1 | ||||
-rw-r--r-- | indra/newview/llpanelenvironment.cpp | 3 |
3 files changed, 9 insertions, 1 deletions
diff --git a/indra/newview/llfloatereditextdaycycle.cpp b/indra/newview/llfloatereditextdaycycle.cpp index 2295e4f10b..166d53fc74 100644 --- a/indra/newview/llfloatereditextdaycycle.cpp +++ b/indra/newview/llfloatereditextdaycycle.cpp @@ -114,6 +114,7 @@ namespace { const std::string LLFloaterEditExtDayCycle::KEY_INVENTORY_ID("inventory_id"); const std::string LLFloaterEditExtDayCycle::KEY_EDIT_CONTEXT("edit_context"); const std::string LLFloaterEditExtDayCycle::KEY_DAY_LENGTH("day_length"); +const std::string LLFloaterEditExtDayCycle::KEY_CANMOD("canmod"); const std::string LLFloaterEditExtDayCycle::VALUE_CONTEXT_INVENTORY("inventory"); const std::string LLFloaterEditExtDayCycle::VALUE_CONTEXT_PARCEL("parcel"); @@ -234,6 +235,11 @@ void LLFloaterEditExtDayCycle::onOpen(const LLSD& key) mEditContext = CONTEXT_REGION; } + if (key.has(KEY_CANMOD)) + { + mCanMod = key[KEY_CANMOD].asBoolean(); + } + if (mEditContext == CONTEXT_UNKNOWN) { LL_WARNS("ENVDAYEDIT") << "Unknown editing context!" << LL_ENDL; diff --git a/indra/newview/llfloatereditextdaycycle.h b/indra/newview/llfloatereditextdaycycle.h index d808dc60c5..76f7d705a2 100644 --- a/indra/newview/llfloatereditextdaycycle.h +++ b/indra/newview/llfloatereditextdaycycle.h @@ -57,6 +57,7 @@ public: static const std::string KEY_INVENTORY_ID; static const std::string KEY_EDIT_CONTEXT; static const std::string KEY_DAY_LENGTH; + static const std::string KEY_CANMOD; static const std::string VALUE_CONTEXT_INVENTORY; static const std::string VALUE_CONTEXT_PARCEL; diff --git a/indra/newview/llpanelenvironment.cpp b/indra/newview/llpanelenvironment.cpp index e1676fbb13..3edfd4156c 100644 --- a/indra/newview/llpanelenvironment.cpp +++ b/indra/newview/llpanelenvironment.cpp @@ -384,7 +384,8 @@ void LLPanelEnvironmentInfo::onBtnEdit() LLFloaterEditExtDayCycle *dayeditor = getEditFloater(); LLSD params(LLSDMap(LLFloaterEditExtDayCycle::KEY_EDIT_CONTEXT, (mCurrentParcelId == INVALID_PARCEL_ID) ? LLFloaterEditExtDayCycle::VALUE_CONTEXT_REGION : LLFloaterEditExtDayCycle::VALUE_CONTEXT_REGION) - (LLFloaterEditExtDayCycle::KEY_DAY_LENGTH, mCurrentEnvironment ? (S32)(mCurrentEnvironment->mDayLength.value()) : FOURHOURS)); + (LLFloaterEditExtDayCycle::KEY_DAY_LENGTH, mCurrentEnvironment ? (S32)(mCurrentEnvironment->mDayLength.value()) : FOURHOURS) + (LLFloaterEditExtDayCycle::KEY_CANMOD, LLSD::Boolean(true))); dayeditor->openFloater(params); if (mCurrentEnvironment->mDayCycle) |