summaryrefslogtreecommitdiff
path: root/indra/newview/llfloatereditextdaycycle.cpp
diff options
context:
space:
mode:
authorGraham Linden <graham@lindenlab.com>2018-09-10 23:22:42 +0100
committerGraham Linden <graham@lindenlab.com>2018-09-10 23:22:42 +0100
commit48ec44c2faac816615a4709b0e71e2a0a88e9885 (patch)
tree2964a04a7fa075890a28bcfd64ea7bb30772cdea /indra/newview/llfloatereditextdaycycle.cpp
parent555dfdc6ef0dab37bc4eaf6ae0b00a857f0609da (diff)
parent6246c8077e5ee81321cff52250d3b99eab81cd57 (diff)
Merge
Diffstat (limited to 'indra/newview/llfloatereditextdaycycle.cpp')
-rw-r--r--indra/newview/llfloatereditextdaycycle.cpp10
1 files changed, 7 insertions, 3 deletions
diff --git a/indra/newview/llfloatereditextdaycycle.cpp b/indra/newview/llfloatereditextdaycycle.cpp
index 0b59239f8c..ce4797c380 100644
--- a/indra/newview/llfloatereditextdaycycle.cpp
+++ b/indra/newview/llfloatereditextdaycycle.cpp
@@ -62,8 +62,6 @@
#include "llenvironment.h"
#include "lltrans.h"
-extern LLControlGroup gSavedSettings;
-
//=========================================================================
namespace {
const std::string track_tabs[] = {
@@ -116,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");
@@ -260,6 +259,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;
@@ -891,7 +895,7 @@ void LLFloaterEditExtDayCycle::updateButtons()
//mAddFrameButton->setEnabled(can_add);
//mDeleteFrameButton->setEnabled(!can_add);
mAddFrameButton->setEnabled(true && mCanMod);
- mDeleteFrameButton->setEnabled(true && mCanMod);
+ mDeleteFrameButton->setEnabled(isRemovingFrameAllowed() && mCanMod);
}
void LLFloaterEditExtDayCycle::updateSlider()