From 5e544ee35d70fa9e27774ba30ccae06aa6d4d5f9 Mon Sep 17 00:00:00 2001 From: Rider Linden Date: Tue, 23 Jan 2018 12:03:03 -0800 Subject: Adding a couple files that got skipped. --- indra/newview/llpanelenvironment.h | 80 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 80 insertions(+) create mode 100644 indra/newview/llpanelenvironment.h (limited to 'indra/newview/llpanelenvironment.h') diff --git a/indra/newview/llpanelenvironment.h b/indra/newview/llpanelenvironment.h new file mode 100644 index 0000000000..8b5238d3e2 --- /dev/null +++ b/indra/newview/llpanelenvironment.h @@ -0,0 +1,80 @@ +/** + * @file llpanelenvironment.h + * @brief LLPanelExperiences class definition + * + * $LicenseInfo:firstyear=2013&license=viewerlgpl$ + * Second Life Viewer Source Code + * Copyright (C) 2013, Linden Research, Inc. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; + * version 2.1 of the License only. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + * + * Linden Research, Inc., 945 Battery Street, San Francisco, CA 94111 USA + * $/LicenseInfo$ + */ + +#ifndef LL_LLPANELENVIRONMENT_H +#define LL_LLPANELENVIRONMENT_H + +#include "llaccordionctrltab.h" +#include "llradiogroup.h" +#include "llcheckboxctrl.h" +#include "llsliderctrl.h" +#include "llsettingsdaycycle.h" + +class LLViewerRegion; + +class LLPanelEnvironmentInfo : public LLPanel +{ + LOG_CLASS(LLPanelEnvironmentInfo); + +public: + LLPanelEnvironmentInfo(); + + // LLPanel + /*virtual*/ BOOL postBuild(); + /*virtual*/ void onOpen(const LLSD& key); + + // LLView + /*virtual*/ void onVisibilityChange(BOOL new_visibility); + + + virtual void refresh(); + +protected: + void setControlsEnabled(bool enabled); + void setApplyProgress(bool started); + void setDirty(bool dirty); + + void onSwitchDefaultSelection(); + + void onBtnApply(); + void onBtnCancel(); + void onBtnEdit(); + + virtual void doApply(); // = 0; + + /// New environment settings that are being applied to the region. + // LLEnvironmentSettings mNewRegionSettings; + + bool mEnableEditing; + + LLRadioGroup* mRegionSettingsRadioGroup; + LLSliderCtrl* mDayLengthSlider; + LLSliderCtrl* mDayOffsetSlider; + LLCheckBoxCtrl* mAllowOverRide; + + LLSettingsDay::ptr_t mEditingDayCycle; +}; +#endif // LL_LLPANELEXPERIENCES_H -- cgit v1.2.3 From 536aeb54a6130f3d1e20405c8f6cbd29201de26d Mon Sep 17 00:00:00 2001 From: Rider Linden Date: Tue, 23 Jan 2018 17:34:25 -0800 Subject: MAINT-8052: One more step towards parcel environments. --- indra/newview/llpanelenvironment.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'indra/newview/llpanelenvironment.h') diff --git a/indra/newview/llpanelenvironment.h b/indra/newview/llpanelenvironment.h index 8b5238d3e2..4f62488f21 100644 --- a/indra/newview/llpanelenvironment.h +++ b/indra/newview/llpanelenvironment.h @@ -63,7 +63,10 @@ protected: void onBtnCancel(); void onBtnEdit(); + void onEditiCommited(LLSettingsDay::ptr_t newday); + virtual void doApply(); // = 0; + virtual void doEditCommited(LLSettingsDay::ptr_t &newday); /// New environment settings that are being applied to the region. // LLEnvironmentSettings mNewRegionSettings; -- cgit v1.2.3 From 2d41de9007ce485e2c7e96c487d609cfe1690c29 Mon Sep 17 00:00:00 2001 From: Rider Linden Date: Wed, 24 Jan 2018 13:36:59 -0800 Subject: MAINT-8052: Parcel environments. Set, clear and get. --- indra/newview/llpanelenvironment.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'indra/newview/llpanelenvironment.h') diff --git a/indra/newview/llpanelenvironment.h b/indra/newview/llpanelenvironment.h index 4f62488f21..7cc7ddae6f 100644 --- a/indra/newview/llpanelenvironment.h +++ b/indra/newview/llpanelenvironment.h @@ -37,8 +37,6 @@ class LLViewerRegion; class LLPanelEnvironmentInfo : public LLPanel { - LOG_CLASS(LLPanelEnvironmentInfo); - public: LLPanelEnvironmentInfo(); @@ -53,6 +51,8 @@ public: virtual void refresh(); protected: + LOG_CLASS(LLPanelEnvironmentInfo); + void setControlsEnabled(bool enabled); void setApplyProgress(bool started); void setDirty(bool dirty); @@ -65,7 +65,7 @@ protected: void onEditiCommited(LLSettingsDay::ptr_t newday); - virtual void doApply(); // = 0; + virtual void doApply() = 0; virtual void doEditCommited(LLSettingsDay::ptr_t &newday); /// New environment settings that are being applied to the region. -- cgit v1.2.3 From eadf0b910174274e7c83fe37e417f576a7350edb Mon Sep 17 00:00:00 2001 From: Rider Linden Date: Wed, 15 Aug 2018 13:35:53 -0700 Subject: MAINT-8990, MAINT-9002: First pass rework on environment panels, region/parcel --- indra/newview/llpanelenvironment.h | 90 ++++++++++++++++++++++++++++---------- 1 file changed, 67 insertions(+), 23 deletions(-) (limited to 'indra/newview/llpanelenvironment.h') diff --git a/indra/newview/llpanelenvironment.h b/indra/newview/llpanelenvironment.h index 7cc7ddae6f..29c9c411ba 100644 --- a/indra/newview/llpanelenvironment.h +++ b/indra/newview/llpanelenvironment.h @@ -32,52 +32,96 @@ #include "llcheckboxctrl.h" #include "llsliderctrl.h" #include "llsettingsdaycycle.h" +#include "llenvironment.h" +#include "llparcel.h" +#include "llsettingspicker.h" +#include "llfloatereditextdaycycle.h" class LLViewerRegion; class LLPanelEnvironmentInfo : public LLPanel { public: - LLPanelEnvironmentInfo(); + LLPanelEnvironmentInfo(); // LLPanel - /*virtual*/ BOOL postBuild(); - /*virtual*/ void onOpen(const LLSD& key); + virtual BOOL postBuild() override; + virtual void onOpen(const LLSD& key) override; // LLView - /*virtual*/ void onVisibilityChange(BOOL new_visibility); + virtual void onVisibilityChange(BOOL new_visibility) override; + virtual void refresh() override; - virtual void refresh(); + S32 getCurrentParcelId() const { return mCurrentParcelId; } + void setCurrentParcelId(S32 parcel_id) { mCurrentParcelId = parcel_id; } + + virtual bool isRegion() const = 0; + virtual LLParcel * getParcel() = 0; + virtual bool canEdit() = 0; protected: LOG_CLASS(LLPanelEnvironmentInfo); - void setControlsEnabled(bool enabled); - void setApplyProgress(bool started); - void setDirty(bool dirty); + static const std::string RDG_ENVIRONMENT_SELECT; + static const std::string RDO_USEDEFAULT; + static const std::string RDO_USEINV; + static const std::string RDO_USECUSTOM; + static const std::string EDT_INVNAME; + static const std::string BTN_SELECTINV; + static const std::string BTN_EDIT; + static const std::string SLD_DAYLENGTH; + static const std::string SLD_DAYOFFSET; + static const std::string CHK_ALLOWOVERRIDE; + static const std::string BTN_APPLY; + static const std::string BTN_CANCEL; + + static const std::string STR_LABEL_USEDEFAULT; + static const std::string STR_LABEL_USEREGION; + static const std::string STR_LABEL_UNKNOWNINV; + + static const S32 DIRTY_FLAG_DAYCYCLE; + static const S32 DIRTY_FLAG_DAYLENGTH; + static const S32 DIRTY_FLAG_DAYOFFSET; + + static const S32 DIRTY_FLAG_MASK; + + void setControlsEnabled(bool enabled); + void setApplyProgress(bool started); + void setDirtyFlag(S32 flag); + bool getIsDirty() const { return (mDirtyFlag != 0); } + bool getIsDirtyFlag(S32 flag) const { return ((mDirtyFlag & flag) != 0); } + + void onSwitchDefaultSelection(); + void onSldDayLengthChanged(F32 value); + void onSldDayOffsetChanged(F32 value); + void onBtnApply(); + void onBtnReset(); + void onBtnEdit(); + void onBtnSelect(); + + void onPickerCommited(LLUUID asset_id); + void onEditiCommited(LLSettingsDay::ptr_t newday); + void onPickerAssetDownloaded(LLSettingsBase::ptr_t settings); - void onSwitchDefaultSelection(); + void handleEnvironmentReceived(S32 parcel_id, LLEnvironment::EnvironmentInfo::ptr_t envifo); - void onBtnApply(); - void onBtnCancel(); - void onBtnEdit(); + virtual void doEditCommited(LLSettingsDay::ptr_t &newday); - void onEditiCommited(LLSettingsDay::ptr_t newday); + void refreshFromSource(); - virtual void doApply() = 0; - virtual void doEditCommited(LLSettingsDay::ptr_t &newday); + std::string getInventoryNameForAssetId(LLUUID asset_id); - /// New environment settings that are being applied to the region. - // LLEnvironmentSettings mNewRegionSettings; + LLFloaterSettingsPicker * getSettingsPicker(); + LLFloaterEditExtDayCycle * getEditFloater(); - bool mEnableEditing; + LLEnvironment::EnvironmentInfo::ptr_t mCurrentEnvironment; + S32 mCurrentParcelId; - LLRadioGroup* mRegionSettingsRadioGroup; - LLSliderCtrl* mDayLengthSlider; - LLSliderCtrl* mDayOffsetSlider; - LLCheckBoxCtrl* mAllowOverRide; - LLSettingsDay::ptr_t mEditingDayCycle; +private: + LLHandle mSettingsFloater; + LLHandle mEditFloater; + S32 mDirtyFlag; }; #endif // LL_LLPANELEXPERIENCES_H -- cgit v1.2.3 From 68158f0340729d9f7e5a4b3e64bfc154a105ab6c Mon Sep 17 00:00:00 2001 From: Rider Linden Date: Thu, 16 Aug 2018 09:43:54 -0700 Subject: Pass call backs into parcel and region change methods. --- indra/newview/llpanelenvironment.h | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'indra/newview/llpanelenvironment.h') diff --git a/indra/newview/llpanelenvironment.h b/indra/newview/llpanelenvironment.h index 29c9c411ba..66224f8ba7 100644 --- a/indra/newview/llpanelenvironment.h +++ b/indra/newview/llpanelenvironment.h @@ -89,8 +89,10 @@ protected: void setControlsEnabled(bool enabled); void setApplyProgress(bool started); void setDirtyFlag(S32 flag); - bool getIsDirty() const { return (mDirtyFlag != 0); } - bool getIsDirtyFlag(S32 flag) const { return ((mDirtyFlag & flag) != 0); } + void clearDirtyFlag(S32 flag); + bool getIsDirty() const { return (mDirtyFlag != 0); } + bool getIsDirtyFlag(S32 flag) const { return ((mDirtyFlag & flag) != 0); } + S32 getDirtyFlag() const { return mDirtyFlag; } void onSwitchDefaultSelection(); void onSldDayLengthChanged(F32 value); @@ -100,10 +102,11 @@ protected: void onBtnEdit(); void onBtnSelect(); + virtual void doApply(); + void onPickerCommited(LLUUID asset_id); void onEditiCommited(LLSettingsDay::ptr_t newday); void onPickerAssetDownloaded(LLSettingsBase::ptr_t settings); - void handleEnvironmentReceived(S32 parcel_id, LLEnvironment::EnvironmentInfo::ptr_t envifo); virtual void doEditCommited(LLSettingsDay::ptr_t &newday); -- cgit v1.2.3 From 7f25bef9c4bd5bf277331040711f13eb69b9c6d1 Mon Sep 17 00:00:00 2001 From: Rider Linden Date: Thu, 16 Aug 2018 16:27:53 -0700 Subject: MAINT-7703: Estate level switch turns of parcel environments. --- indra/newview/llpanelenvironment.h | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'indra/newview/llpanelenvironment.h') diff --git a/indra/newview/llpanelenvironment.h b/indra/newview/llpanelenvironment.h index 66224f8ba7..9a7ce289f0 100644 --- a/indra/newview/llpanelenvironment.h +++ b/indra/newview/llpanelenvironment.h @@ -80,19 +80,19 @@ protected: static const std::string STR_LABEL_USEREGION; static const std::string STR_LABEL_UNKNOWNINV; - static const S32 DIRTY_FLAG_DAYCYCLE; - static const S32 DIRTY_FLAG_DAYLENGTH; - static const S32 DIRTY_FLAG_DAYOFFSET; + static const U32 DIRTY_FLAG_DAYCYCLE; + static const U32 DIRTY_FLAG_DAYLENGTH; + static const U32 DIRTY_FLAG_DAYOFFSET; - static const S32 DIRTY_FLAG_MASK; + static const U32 DIRTY_FLAG_MASK; void setControlsEnabled(bool enabled); void setApplyProgress(bool started); - void setDirtyFlag(S32 flag); - void clearDirtyFlag(S32 flag); + void setDirtyFlag(U32 flag); + void clearDirtyFlag(U32 flag); bool getIsDirty() const { return (mDirtyFlag != 0); } - bool getIsDirtyFlag(S32 flag) const { return ((mDirtyFlag & flag) != 0); } - S32 getDirtyFlag() const { return mDirtyFlag; } + bool getIsDirtyFlag(U32 flag) const { return ((mDirtyFlag & flag) != 0); } + U32 getDirtyFlag() const { return mDirtyFlag; } void onSwitchDefaultSelection(); void onSldDayLengthChanged(F32 value); -- cgit v1.2.3 From 1716129fd23ff35e030808406af1a8f796dc4b01 Mon Sep 17 00:00:00 2001 From: Rider Linden Date: Fri, 17 Aug 2018 12:35:42 -0700 Subject: MAINT-8826, MAINT-8990, MAINT-9002, MAINT-7703: Rework for environment pannels in Region/Estate and Parcel. Enable/disable by permission. Edit the correct environment. Dirty flags for changes. Estate owner disallow switch. --- indra/newview/llpanelenvironment.h | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'indra/newview/llpanelenvironment.h') diff --git a/indra/newview/llpanelenvironment.h b/indra/newview/llpanelenvironment.h index 9a7ce289f0..2fcfb725a1 100644 --- a/indra/newview/llpanelenvironment.h +++ b/indra/newview/llpanelenvironment.h @@ -105,11 +105,9 @@ protected: virtual void doApply(); void onPickerCommited(LLUUID asset_id); - void onEditiCommited(LLSettingsDay::ptr_t newday); + void onEditCommited(LLSettingsDay::ptr_t newday); void onPickerAssetDownloaded(LLSettingsBase::ptr_t settings); - void handleEnvironmentReceived(S32 parcel_id, LLEnvironment::EnvironmentInfo::ptr_t envifo); - - virtual void doEditCommited(LLSettingsDay::ptr_t &newday); + void onEnvironmentReceived(S32 parcel_id, LLEnvironment::EnvironmentInfo::ptr_t envifo); void refreshFromSource(); -- cgit v1.2.3 From 1e3ee272ae811b862a529b6f3bbebb50a0c22580 Mon Sep 17 00:00:00 2001 From: Rider Linden Date: Fri, 17 Aug 2018 15:37:10 -0700 Subject: Add an apparent time of day. More OSX complaints. --- indra/newview/llpanelenvironment.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'indra/newview/llpanelenvironment.h') diff --git a/indra/newview/llpanelenvironment.h b/indra/newview/llpanelenvironment.h index 2fcfb725a1..44e3c11a82 100644 --- a/indra/newview/llpanelenvironment.h +++ b/indra/newview/llpanelenvironment.h @@ -75,6 +75,8 @@ protected: static const std::string CHK_ALLOWOVERRIDE; static const std::string BTN_APPLY; static const std::string BTN_CANCEL; + static const std::string LBL_TIMEOFDAY; + static const std::string STR_LABEL_USEDEFAULT; static const std::string STR_LABEL_USEREGION; @@ -104,6 +106,8 @@ protected: virtual void doApply(); + void udpateApparentTimeOfDay(); + void onPickerCommited(LLUUID asset_id); void onEditCommited(LLSettingsDay::ptr_t newday); void onPickerAssetDownloaded(LLSettingsBase::ptr_t settings); @@ -121,6 +125,8 @@ protected: private: + static void onIdlePlay(void *); + LLHandle mSettingsFloater; LLHandle mEditFloater; S32 mDirtyFlag; -- cgit v1.2.3 From 477c66c890d5d87318705415315aaf9464bec2ff Mon Sep 17 00:00:00 2001 From: Rider Linden Date: Tue, 21 Aug 2018 11:37:59 -0700 Subject: Lest couple nullptr checks and disable the controls on legacy regions. --- indra/newview/llpanelenvironment.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'indra/newview/llpanelenvironment.h') diff --git a/indra/newview/llpanelenvironment.h b/indra/newview/llpanelenvironment.h index 44e3c11a82..971f12c7e7 100644 --- a/indra/newview/llpanelenvironment.h +++ b/indra/newview/llpanelenvironment.h @@ -76,6 +76,9 @@ protected: static const std::string BTN_APPLY; static const std::string BTN_CANCEL; static const std::string LBL_TIMEOFDAY; + static const std::string PNL_SETTINGS; + static const std::string PNL_BUTTONS; + static const std::string PNL_DISABLED; static const std::string STR_LABEL_USEDEFAULT; -- cgit v1.2.3 From d5f2267369d2695a8aec7c1d0cfa25954ae3c706 Mon Sep 17 00:00:00 2001 From: Rider Linden Date: Fri, 24 Aug 2018 11:59:28 -0700 Subject: Remove "Commit" from fixed editor. Check isDirty() before replacing or closing fixed editor. --- indra/newview/llpanelenvironment.h | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) (limited to 'indra/newview/llpanelenvironment.h') diff --git a/indra/newview/llpanelenvironment.h b/indra/newview/llpanelenvironment.h index 971f12c7e7..6a0c784708 100644 --- a/indra/newview/llpanelenvironment.h +++ b/indra/newview/llpanelenvironment.h @@ -44,17 +44,16 @@ class LLPanelEnvironmentInfo : public LLPanel public: LLPanelEnvironmentInfo(); - // LLPanel virtual BOOL postBuild() override; virtual void onOpen(const LLSD& key) override; - // LLView + virtual BOOL isDirty() const override { return getIsDirty(); } virtual void onVisibilityChange(BOOL new_visibility) override; virtual void refresh() override; - S32 getCurrentParcelId() const { return mCurrentParcelId; } - void setCurrentParcelId(S32 parcel_id) { mCurrentParcelId = parcel_id; } + S32 getCurrentParcelId() const { return mCurrentParcelId; } + void setCurrentParcelId(S32 parcel_id) { mCurrentParcelId = parcel_id; } virtual bool isRegion() const = 0; virtual LLParcel * getParcel() = 0; @@ -95,9 +94,9 @@ protected: void setApplyProgress(bool started); void setDirtyFlag(U32 flag); void clearDirtyFlag(U32 flag); - bool getIsDirty() const { return (mDirtyFlag != 0); } - bool getIsDirtyFlag(U32 flag) const { return ((mDirtyFlag & flag) != 0); } - U32 getDirtyFlag() const { return mDirtyFlag; } + bool getIsDirty() const { return (mDirtyFlag != 0); } + bool getIsDirtyFlag(U32 flag) const { return ((mDirtyFlag & flag) != 0); } + U32 getDirtyFlag() const { return mDirtyFlag; } void onSwitchDefaultSelection(); void onSldDayLengthChanged(F32 value); @@ -130,8 +129,8 @@ protected: private: static void onIdlePlay(void *); - LLHandle mSettingsFloater; - LLHandle mEditFloater; - S32 mDirtyFlag; + LLHandle mSettingsFloater; + LLHandle mEditFloater; + S32 mDirtyFlag; }; #endif // LL_LLPANELEXPERIENCES_H -- cgit v1.2.3 From 06a77dd5fe228a3bbf4c57ae3b0c51937871d6a2 Mon Sep 17 00:00:00 2001 From: Rider Linden Date: Fri, 24 Aug 2018 16:46:07 -0700 Subject: is dirty code in day cycle editor. When environment panel closes disconnect commit hook for crash. --- indra/newview/llpanelenvironment.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'indra/newview/llpanelenvironment.h') diff --git a/indra/newview/llpanelenvironment.h b/indra/newview/llpanelenvironment.h index 6a0c784708..b867a7b61d 100644 --- a/indra/newview/llpanelenvironment.h +++ b/indra/newview/llpanelenvironment.h @@ -120,15 +120,19 @@ protected: std::string getInventoryNameForAssetId(LLUUID asset_id); LLFloaterSettingsPicker * getSettingsPicker(); - LLFloaterEditExtDayCycle * getEditFloater(); + LLFloaterEditExtDayCycle * getEditFloater(bool create = true); LLEnvironment::EnvironmentInfo::ptr_t mCurrentEnvironment; S32 mCurrentParcelId; + private: static void onIdlePlay(void *); + typedef boost::signals2::connection connection_t; + + connection_t mCommitConnection; LLHandle mSettingsFloater; LLHandle mEditFloater; S32 mDirtyFlag; -- cgit v1.2.3 From 2fd4ce55af8c68b8ae5eea72566cdb6d87d3a842 Mon Sep 17 00:00:00 2001 From: Rider Linden Date: Mon, 10 Sep 2018 11:22:36 -0700 Subject: MAINT-9115: When selecting no parcel or a parcel without a day cycle, close the day cycle editor if it is not dirty, if dirty just disable commit. --- indra/newview/llpanelenvironment.h | 1 + 1 file changed, 1 insertion(+) (limited to 'indra/newview/llpanelenvironment.h') diff --git a/indra/newview/llpanelenvironment.h b/indra/newview/llpanelenvironment.h index b867a7b61d..a8a1f018cf 100644 --- a/indra/newview/llpanelenvironment.h +++ b/indra/newview/llpanelenvironment.h @@ -121,6 +121,7 @@ protected: LLFloaterSettingsPicker * getSettingsPicker(); LLFloaterEditExtDayCycle * getEditFloater(bool create = true); + void updateEditFloater(const LLEnvironment::EnvironmentInfo::ptr_t &nextenv); LLEnvironment::EnvironmentInfo::ptr_t mCurrentEnvironment; S32 mCurrentParcelId; -- cgit v1.2.3 From 43c8f5959f8afaf2f67fbbf49e78965802859b55 Mon Sep 17 00:00:00 2001 From: andreykproductengine Date: Mon, 10 Sep 2018 16:44:56 +0300 Subject: MAINT-9099 Adjustable region altitudes. --- indra/newview/llpanelenvironment.h | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) (limited to 'indra/newview/llpanelenvironment.h') diff --git a/indra/newview/llpanelenvironment.h b/indra/newview/llpanelenvironment.h index a8a1f018cf..7469da9c05 100644 --- a/indra/newview/llpanelenvironment.h +++ b/indra/newview/llpanelenvironment.h @@ -71,11 +71,13 @@ protected: static const std::string BTN_EDIT; static const std::string SLD_DAYLENGTH; static const std::string SLD_DAYOFFSET; + static const std::string SLD_ALTITUDES; static const std::string CHK_ALLOWOVERRIDE; static const std::string BTN_APPLY; static const std::string BTN_CANCEL; static const std::string LBL_TIMEOFDAY; static const std::string PNL_SETTINGS; + static const std::string PNL_ENVIRONMENT_ALTITUDES; static const std::string PNL_BUTTONS; static const std::string PNL_DISABLED; @@ -83,10 +85,12 @@ protected: static const std::string STR_LABEL_USEDEFAULT; static const std::string STR_LABEL_USEREGION; static const std::string STR_LABEL_UNKNOWNINV; + static const std::string STR_ALTITUDE_DESCRIPTION; static const U32 DIRTY_FLAG_DAYCYCLE; static const U32 DIRTY_FLAG_DAYLENGTH; static const U32 DIRTY_FLAG_DAYOFFSET; + static const U32 DIRTY_FLAG_ALTITUDES; static const U32 DIRTY_FLAG_MASK; @@ -97,10 +101,12 @@ protected: bool getIsDirty() const { return (mDirtyFlag != 0); } bool getIsDirtyFlag(U32 flag) const { return ((mDirtyFlag & flag) != 0); } U32 getDirtyFlag() const { return mDirtyFlag; } + void updateAltLabel(const std::string &alt_name, U32 sky_index, F32 alt_value); void onSwitchDefaultSelection(); void onSldDayLengthChanged(F32 value); void onSldDayOffsetChanged(F32 value); + void onAltSliderCallback(LLUICtrl *cntrl, const LLSD &data); void onBtnApply(); void onBtnReset(); void onBtnEdit(); @@ -126,6 +132,23 @@ protected: LLEnvironment::EnvironmentInfo::ptr_t mCurrentEnvironment; S32 mCurrentParcelId; + class AltitudeData + { + public: + AltitudeData() : + mAltitudeIndex(0), mLabelIndex(0), mAltitude(0) + {} + AltitudeData(U32 altitude_index, U32 label_index, F32 altitude) : + mAltitudeIndex(altitude_index), mLabelIndex(label_index), mAltitude(altitude) + {} + + U32 mAltitudeIndex; + U32 mLabelIndex; + F32 mAltitude; + }; + typedef std::map altitudes_data_t; + altitudes_data_t mAltitudes; + private: -- cgit v1.2.3 From 4fe44b9033ee793134b7c080c71931c62c33ddf9 Mon Sep 17 00:00:00 2001 From: Rider Linden Date: Tue, 11 Sep 2018 17:10:32 -0700 Subject: SL-9626: When the panel loses visibility the picker is now automatically closed. Also picker checks handle to parent rather than pointer to parent. --- indra/newview/llpanelenvironment.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'indra/newview/llpanelenvironment.h') diff --git a/indra/newview/llpanelenvironment.h b/indra/newview/llpanelenvironment.h index 7469da9c05..bd3db34332 100644 --- a/indra/newview/llpanelenvironment.h +++ b/indra/newview/llpanelenvironment.h @@ -125,7 +125,7 @@ protected: std::string getInventoryNameForAssetId(LLUUID asset_id); - LLFloaterSettingsPicker * getSettingsPicker(); + LLFloaterSettingsPicker * getSettingsPicker(bool create = true); LLFloaterEditExtDayCycle * getEditFloater(bool create = true); void updateEditFloater(const LLEnvironment::EnvironmentInfo::ptr_t &nextenv); -- cgit v1.2.3 From 27a76a7e731bd13fb5d0862a932f40ea5c9c7119 Mon Sep 17 00:00:00 2001 From: Rider Linden Date: Wed, 12 Sep 2018 17:05:27 -0700 Subject: SL-1402, SL-1193, SL-976: Corrected strings and layout for named bugs ("Use Shared Environment", no selection format in panel, Missing String in give object) Also Rider learned how to spell Committed --- indra/newview/llpanelenvironment.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'indra/newview/llpanelenvironment.h') diff --git a/indra/newview/llpanelenvironment.h b/indra/newview/llpanelenvironment.h index bd3db34332..c18092e2e5 100644 --- a/indra/newview/llpanelenvironment.h +++ b/indra/newview/llpanelenvironment.h @@ -116,8 +116,8 @@ protected: void udpateApparentTimeOfDay(); - void onPickerCommited(LLUUID asset_id); - void onEditCommited(LLSettingsDay::ptr_t newday); + void onPickerCommitted(LLUUID asset_id); + void onEditCommitted(LLSettingsDay::ptr_t newday); void onPickerAssetDownloaded(LLSettingsBase::ptr_t settings); void onEnvironmentReceived(S32 parcel_id, LLEnvironment::EnvironmentInfo::ptr_t envifo); -- cgit v1.2.3 From 7c6ac0740dac946275ef3f904614688f4b73f850 Mon Sep 17 00:00:00 2001 From: Rider Linden Date: Fri, 14 Sep 2018 09:52:28 -0700 Subject: SL-1556: Correctly identify when the selected parcel is in another region and display a message about cross region environments. --- indra/newview/llpanelenvironment.h | 28 +++++++++++++++++----------- 1 file changed, 17 insertions(+), 11 deletions(-) (limited to 'indra/newview/llpanelenvironment.h') diff --git a/indra/newview/llpanelenvironment.h b/indra/newview/llpanelenvironment.h index c18092e2e5..fdf0fe46a7 100644 --- a/indra/newview/llpanelenvironment.h +++ b/indra/newview/llpanelenvironment.h @@ -52,12 +52,10 @@ public: virtual void refresh() override; - S32 getCurrentParcelId() const { return mCurrentParcelId; } - void setCurrentParcelId(S32 parcel_id) { mCurrentParcelId = parcel_id; } - virtual bool isRegion() const = 0; virtual LLParcel * getParcel() = 0; virtual bool canEdit() = 0; + virtual S32 getParcelId() = 0; protected: LOG_CLASS(LLPanelEnvironmentInfo); @@ -80,12 +78,15 @@ protected: static const std::string PNL_ENVIRONMENT_ALTITUDES; static const std::string PNL_BUTTONS; static const std::string PNL_DISABLED; - + static const std::string TXT_DISABLED; static const std::string STR_LABEL_USEDEFAULT; static const std::string STR_LABEL_USEREGION; static const std::string STR_LABEL_UNKNOWNINV; static const std::string STR_ALTITUDE_DESCRIPTION; + static const std::string STR_NO_PARCEL; + static const std::string STR_CROSS_REGION; + static const std::string STR_LEGACY; static const U32 DIRTY_FLAG_DAYCYCLE; static const U32 DIRTY_FLAG_DAYLENGTH; @@ -94,7 +95,7 @@ protected: static const U32 DIRTY_FLAG_MASK; - void setControlsEnabled(bool enabled); + bool setControlsEnabled(bool enabled); void setApplyProgress(bool started); void setDirtyFlag(U32 flag); void clearDirtyFlag(U32 flag); @@ -121,7 +122,7 @@ protected: void onPickerAssetDownloaded(LLSettingsBase::ptr_t settings); void onEnvironmentReceived(S32 parcel_id, LLEnvironment::EnvironmentInfo::ptr_t envifo); - void refreshFromSource(); + virtual void refreshFromSource() = 0; std::string getInventoryNameForAssetId(LLUUID asset_id); @@ -129,8 +130,10 @@ protected: LLFloaterEditExtDayCycle * getEditFloater(bool create = true); void updateEditFloater(const LLEnvironment::EnvironmentInfo::ptr_t &nextenv); + void setCrossRegion(bool val) { mCrossRegion = val; } + void setNoSelection(bool val) { mNoSelection = val; } + LLEnvironment::EnvironmentInfo::ptr_t mCurrentEnvironment; - S32 mCurrentParcelId; class AltitudeData { @@ -156,9 +159,12 @@ private: typedef boost::signals2::connection connection_t; - connection_t mCommitConnection; - LLHandle mSettingsFloater; - LLHandle mEditFloater; - S32 mDirtyFlag; + connection_t mCommitConnection; + LLHandle mSettingsFloater; + LLHandle mEditFloater; + S32 mDirtyFlag; + bool mCrossRegion; + bool mNoSelection; + }; #endif // LL_LLPANELEXPERIENCES_H -- cgit v1.2.3 From 17fb7d0bf4cc4db1c3f30dbbbdee7610d168336c Mon Sep 17 00:00:00 2001 From: Rider Linden Date: Mon, 17 Sep 2018 14:21:38 -0700 Subject: SL-9667, SL-9669: Do not attempt to request environment for non-eep parcels, use handle to panel passed to static for callbacks. --- indra/newview/llpanelenvironment.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'indra/newview/llpanelenvironment.h') diff --git a/indra/newview/llpanelenvironment.h b/indra/newview/llpanelenvironment.h index fdf0fe46a7..a632acfd03 100644 --- a/indra/newview/llpanelenvironment.h +++ b/indra/newview/llpanelenvironment.h @@ -121,6 +121,7 @@ protected: void onEditCommitted(LLSettingsDay::ptr_t newday); void onPickerAssetDownloaded(LLSettingsBase::ptr_t settings); void onEnvironmentReceived(S32 parcel_id, LLEnvironment::EnvironmentInfo::ptr_t envifo); + static void _onEnvironmentReceived(LLHandle that_h, S32 parcel_id, LLEnvironment::EnvironmentInfo::ptr_t envifo); virtual void refreshFromSource() = 0; @@ -132,6 +133,7 @@ protected: void setCrossRegion(bool val) { mCrossRegion = val; } void setNoSelection(bool val) { mNoSelection = val; } + void setNoEnvironmentSupport(bool val) { mNoEnvironment = val; } LLEnvironment::EnvironmentInfo::ptr_t mCurrentEnvironment; @@ -165,6 +167,6 @@ private: S32 mDirtyFlag; bool mCrossRegion; bool mNoSelection; - + bool mNoEnvironment; }; #endif // LL_LLPANELEXPERIENCES_H -- cgit v1.2.3 From cae08e0096f75827851a8c9447e163ddb0132f2d Mon Sep 17 00:00:00 2001 From: Rider Linden Date: Wed, 19 Sep 2018 15:31:23 -0700 Subject: SL-9661: Trigger an event when the settings on a parcel or region are changed. Environment panel montiors this event and updates itself when it occurs. --- indra/newview/llpanelenvironment.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'indra/newview/llpanelenvironment.h') diff --git a/indra/newview/llpanelenvironment.h b/indra/newview/llpanelenvironment.h index a632acfd03..2753e766ac 100644 --- a/indra/newview/llpanelenvironment.h +++ b/indra/newview/llpanelenvironment.h @@ -43,6 +43,7 @@ class LLPanelEnvironmentInfo : public LLPanel { public: LLPanelEnvironmentInfo(); + virtual ~LLPanelEnvironmentInfo(); virtual BOOL postBuild() override; virtual void onOpen(const LLSD& key) override; @@ -137,6 +138,8 @@ protected: LLEnvironment::EnvironmentInfo::ptr_t mCurrentEnvironment; + void onEnvironmentChanged(LLEnvironment::EnvSelection_t env); + class AltitudeData { public: @@ -162,6 +165,7 @@ private: typedef boost::signals2::connection connection_t; connection_t mCommitConnection; + connection_t mChangeMonitor; LLHandle mSettingsFloater; LLHandle mEditFloater; S32 mDirtyFlag; -- cgit v1.2.3 From 18dd6f076e3d3936e6b5a426d8c5476fac4c4e58 Mon Sep 17 00:00:00 2001 From: andreykproductengine Date: Tue, 25 Sep 2018 20:27:59 +0300 Subject: SL-1961 EEP Altitude labels auto-adjustment --- indra/newview/llpanelenvironment.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'indra/newview/llpanelenvironment.h') diff --git a/indra/newview/llpanelenvironment.h b/indra/newview/llpanelenvironment.h index 2753e766ac..93fe186d6f 100644 --- a/indra/newview/llpanelenvironment.h +++ b/indra/newview/llpanelenvironment.h @@ -71,6 +71,7 @@ protected: static const std::string SLD_DAYLENGTH; static const std::string SLD_DAYOFFSET; static const std::string SLD_ALTITUDES; + static const std::string ICN_GROUND; static const std::string CHK_ALLOWOVERRIDE; static const std::string BTN_APPLY; static const std::string BTN_CANCEL; @@ -104,6 +105,7 @@ protected: bool getIsDirtyFlag(U32 flag) const { return ((mDirtyFlag & flag) != 0); } U32 getDirtyFlag() const { return mDirtyFlag; } void updateAltLabel(const std::string &alt_name, U32 sky_index, F32 alt_value); + void readjustAltLabels(); void onSwitchDefaultSelection(); void onSldDayLengthChanged(F32 value); -- cgit v1.2.3 From 41a6504c5e121f4ee35f06adc297485d21f4d14d Mon Sep 17 00:00:00 2001 From: andreykproductengine Date: Wed, 26 Sep 2018 18:14:44 +0300 Subject: SL-983 EEP - When selecting a new parcel with the day editor open follow in editor --- indra/newview/llpanelenvironment.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'indra/newview/llpanelenvironment.h') diff --git a/indra/newview/llpanelenvironment.h b/indra/newview/llpanelenvironment.h index 93fe186d6f..9bc0b9df9c 100644 --- a/indra/newview/llpanelenvironment.h +++ b/indra/newview/llpanelenvironment.h @@ -132,7 +132,7 @@ protected: LLFloaterSettingsPicker * getSettingsPicker(bool create = true); LLFloaterEditExtDayCycle * getEditFloater(bool create = true); - void updateEditFloater(const LLEnvironment::EnvironmentInfo::ptr_t &nextenv); + void updateEditFloater(const LLEnvironment::EnvironmentInfo::ptr_t &nextenv, bool enable); void setCrossRegion(bool val) { mCrossRegion = val; } void setNoSelection(bool val) { mNoSelection = val; } -- cgit v1.2.3 From 57ff71c915727abe09e794da4aa1615eb43f0abf Mon Sep 17 00:00:00 2001 From: andreykproductengine Date: Thu, 4 Oct 2018 22:12:17 +0300 Subject: SL-9654 [EEP] Settings Picker reliability --- indra/newview/llpanelenvironment.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'indra/newview/llpanelenvironment.h') diff --git a/indra/newview/llpanelenvironment.h b/indra/newview/llpanelenvironment.h index 9bc0b9df9c..01b9b9c562 100644 --- a/indra/newview/llpanelenvironment.h +++ b/indra/newview/llpanelenvironment.h @@ -120,7 +120,7 @@ protected: void udpateApparentTimeOfDay(); - void onPickerCommitted(LLUUID asset_id); + void onPickerCommitted(LLUUID item_id); void onEditCommitted(LLSettingsDay::ptr_t newday); void onPickerAssetDownloaded(LLSettingsBase::ptr_t settings); void onEnvironmentReceived(S32 parcel_id, LLEnvironment::EnvironmentInfo::ptr_t envifo); -- cgit v1.2.3 From d60588ec4fe6adc67de7938bc8ed9570f6cb187c Mon Sep 17 00:00:00 2001 From: andreykproductengine Date: Fri, 5 Oct 2018 17:12:58 +0300 Subject: SL-9822 Minimizing viewer resets day editor's values --- indra/newview/llpanelenvironment.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'indra/newview/llpanelenvironment.h') diff --git a/indra/newview/llpanelenvironment.h b/indra/newview/llpanelenvironment.h index 01b9b9c562..3ed631db41 100644 --- a/indra/newview/llpanelenvironment.h +++ b/indra/newview/llpanelenvironment.h @@ -171,6 +171,8 @@ private: LLHandle mSettingsFloater; LLHandle mEditFloater; S32 mDirtyFlag; + S32 mEditorLastParcelId; + LLUUID mEditorLastRegionId; bool mCrossRegion; bool mNoSelection; bool mNoEnvironment; -- cgit v1.2.3 From e9faa3cce8897af2a4303538672e2262ed39520a Mon Sep 17 00:00:00 2001 From: maxim_productengine Date: Thu, 25 Oct 2018 18:16:34 +0300 Subject: SL-9960 [EEP] Allow drag and drop inventory setting to the "Settings from Inventory" field --- indra/newview/llpanelenvironment.h | 31 ++++++++++++++++++++++++++++++- 1 file changed, 30 insertions(+), 1 deletion(-) (limited to 'indra/newview/llpanelenvironment.h') diff --git a/indra/newview/llpanelenvironment.h b/indra/newview/llpanelenvironment.h index 3ed631db41..2c070eb21f 100644 --- a/indra/newview/llpanelenvironment.h +++ b/indra/newview/llpanelenvironment.h @@ -41,6 +41,7 @@ class LLViewerRegion; class LLPanelEnvironmentInfo : public LLPanel { + friend class LLSettingsDropTarget; public: LLPanelEnvironmentInfo(); virtual ~LLPanelEnvironmentInfo(); @@ -81,6 +82,7 @@ protected: static const std::string PNL_BUTTONS; static const std::string PNL_DISABLED; static const std::string TXT_DISABLED; + static const std::string SDT_DROP_TARGET; static const std::string STR_LABEL_USEDEFAULT; static const std::string STR_LABEL_USEREGION; @@ -177,4 +179,31 @@ private: bool mNoSelection; bool mNoEnvironment; }; -#endif // LL_LLPANELEXPERIENCES_H + +class LLSettingsDropTarget : public LLView +{ +public: + struct Params : public LLInitParam::Block + { + Params() + { + changeDefault(mouse_opaque, false); + changeDefault(follows.flags, FOLLOWS_ALL); + } + }; + LLSettingsDropTarget(const Params&); + ~LLSettingsDropTarget() {}; + + virtual BOOL handleDragAndDrop(S32 x, S32 y, MASK mask, BOOL drop, + EDragAndDropType cargo_type, + void* cargo_data, + EAcceptance* accept, + std::string& tooltip_msg); + void setPanel(LLPanelEnvironmentInfo* panel) { mEnvironmentInfoPanel = panel; }; + void setDndEnabled(bool dnd_enabled) { mDndEnabled = dnd_enabled; }; + +protected: + LLPanelEnvironmentInfo* mEnvironmentInfoPanel; + bool mDndEnabled; +}; +#endif // LL_LLPANELENVIRONMENT_H -- cgit v1.2.3 From 77b278b7f5615a6ba93b47c2a0d8a2338dc27dc2 Mon Sep 17 00:00:00 2001 From: andreykproductengine Date: Mon, 12 Nov 2018 16:41:40 +0200 Subject: SL-9620 Viewer crashes after clicking "Commit" button while editing Day Cycle preset --- indra/newview/llpanelenvironment.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'indra/newview/llpanelenvironment.h') diff --git a/indra/newview/llpanelenvironment.h b/indra/newview/llpanelenvironment.h index 2c070eb21f..bca7743145 100644 --- a/indra/newview/llpanelenvironment.h +++ b/indra/newview/llpanelenvironment.h @@ -160,7 +160,7 @@ protected: }; typedef std::map altitudes_data_t; altitudes_data_t mAltitudes; - + S32 mCurEnvVersion; private: -- cgit v1.2.3 From 76071d4fe8f2b88e33d0393fe00dc2ce88f71935 Mon Sep 17 00:00:00 2001 From: andreykproductengine Date: Wed, 5 Dec 2018 22:13:49 +0200 Subject: SL-10091 EEP Filter out dupplicate refreshes and callbacks --- indra/newview/llpanelenvironment.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'indra/newview/llpanelenvironment.h') diff --git a/indra/newview/llpanelenvironment.h b/indra/newview/llpanelenvironment.h index bca7743145..05f25fa78f 100644 --- a/indra/newview/llpanelenvironment.h +++ b/indra/newview/llpanelenvironment.h @@ -142,7 +142,7 @@ protected: LLEnvironment::EnvironmentInfo::ptr_t mCurrentEnvironment; - void onEnvironmentChanged(LLEnvironment::EnvSelection_t env); + void onEnvironmentChanged(LLEnvironment::EnvSelection_t env, S32 version); class AltitudeData { @@ -160,7 +160,7 @@ protected: }; typedef std::map altitudes_data_t; altitudes_data_t mAltitudes; - S32 mCurEnvVersion; + S32 mCurEnvVersion; // used to filter duplicate callbacks/refreshes private: -- cgit v1.2.3 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/llpanelenvironment.h | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) (limited to 'indra/newview/llpanelenvironment.h') diff --git a/indra/newview/llpanelenvironment.h b/indra/newview/llpanelenvironment.h index 05f25fa78f..a0a60a2bf9 100644 --- a/indra/newview/llpanelenvironment.h +++ b/indra/newview/llpanelenvironment.h @@ -62,13 +62,9 @@ public: protected: LOG_CLASS(LLPanelEnvironmentInfo); - static const std::string RDG_ENVIRONMENT_SELECT; - static const std::string RDO_USEDEFAULT; - static const std::string RDO_USEINV; - static const std::string RDO_USECUSTOM; - static const std::string EDT_INVNAME; static const std::string BTN_SELECTINV; static const std::string BTN_EDIT; + static const std::string BTN_USEDEFAULT; static const std::string SLD_DAYLENGTH; static const std::string SLD_DAYOFFSET; static const std::string SLD_ALTITUDES; @@ -106,17 +102,19 @@ protected: bool getIsDirty() const { return (mDirtyFlag != 0); } bool getIsDirtyFlag(U32 flag) const { return ((mDirtyFlag & flag) != 0); } U32 getDirtyFlag() const { return mDirtyFlag; } - void updateAltLabel(const std::string &alt_name, U32 sky_index, F32 alt_value); + void updateAltLabel(const std::string &alt_name, U32 sky_index, F32 alt_value); void readjustAltLabels(); - void onSwitchDefaultSelection(); void onSldDayLengthChanged(F32 value); void onSldDayOffsetChanged(F32 value); void onAltSliderCallback(LLUICtrl *cntrl, const LLSD &data); + void onAltSliderMouseUp(); + void onBtnApply(); void onBtnReset(); void onBtnEdit(); void onBtnSelect(); + void onBtnDefault(); virtual void doApply(); @@ -124,14 +122,19 @@ protected: void onPickerCommitted(LLUUID item_id); void onEditCommitted(LLSettingsDay::ptr_t newday); + void onDayLenOffsetMouseUp(); + void onPickerAssetDownloaded(LLSettingsBase::ptr_t settings); void onEnvironmentReceived(S32 parcel_id, LLEnvironment::EnvironmentInfo::ptr_t envifo); static void _onEnvironmentReceived(LLHandle that_h, S32 parcel_id, LLEnvironment::EnvironmentInfo::ptr_t envifo); + virtual void refreshFromSource() = 0; std::string getInventoryNameForAssetId(LLUUID asset_id); + std::string getNameForTrackIndex(S32 index); + LLFloaterSettingsPicker * getSettingsPicker(bool create = true); LLFloaterEditExtDayCycle * getEditFloater(bool create = true); void updateEditFloater(const LLEnvironment::EnvironmentInfo::ptr_t &nextenv, bool enable); -- cgit v1.2.3 From 5fe626afabd2857980e8011ceb6081f9e9f108c7 Mon Sep 17 00:00:00 2001 From: Rider Linden Date: Wed, 2 Jan 2019 15:13:47 -0800 Subject: SL-10279: Most functionality now present. Still needs some cleanup on the bump code. --- indra/newview/llpanelenvironment.h | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) (limited to 'indra/newview/llpanelenvironment.h') diff --git a/indra/newview/llpanelenvironment.h b/indra/newview/llpanelenvironment.h index a0a60a2bf9..3649abe939 100644 --- a/indra/newview/llpanelenvironment.h +++ b/indra/newview/llpanelenvironment.h @@ -36,6 +36,7 @@ #include "llparcel.h" #include "llsettingspicker.h" #include "llfloatereditextdaycycle.h" +#include "llestateinfomodel.h" class LLViewerRegion; @@ -87,6 +88,7 @@ protected: static const std::string STR_NO_PARCEL; static const std::string STR_CROSS_REGION; static const std::string STR_LEGACY; + static const std::string STR_DISALLOWED; static const U32 DIRTY_FLAG_DAYCYCLE; static const U32 DIRTY_FLAG_DAYLENGTH; @@ -110,14 +112,10 @@ protected: void onAltSliderCallback(LLUICtrl *cntrl, const LLSD &data); void onAltSliderMouseUp(); - void onBtnApply(); - void onBtnReset(); void onBtnEdit(); void onBtnSelect(); void onBtnDefault(); - virtual void doApply(); - void udpateApparentTimeOfDay(); void onPickerCommitted(LLUUID item_id); @@ -162,12 +160,15 @@ protected: F32 mAltitude; }; typedef std::map altitudes_data_t; - altitudes_data_t mAltitudes; - S32 mCurEnvVersion; // used to filter duplicate callbacks/refreshes + altitudes_data_t mAltitudes; + S32 mCurEnvVersion; // used to filter duplicate callbacks/refreshes +protected: + void refreshFromEstate(); + bool mAllowOverride; private: - static void onIdlePlay(void *); + static void onIdlePlay(void *); typedef boost::signals2::connection connection_t; @@ -181,6 +182,7 @@ private: bool mCrossRegion; bool mNoSelection; bool mNoEnvironment; + }; class LLSettingsDropTarget : public LLView -- cgit v1.2.3 From 69a84d81728203868923bbf27f8bce0d8b0c8e86 Mon Sep 17 00:00:00 2001 From: andreykproductengine Date: Fri, 4 Jan 2019 17:09:09 +0200 Subject: SL-10279 Fix altitude description repositioning code --- indra/newview/llpanelenvironment.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'indra/newview/llpanelenvironment.h') diff --git a/indra/newview/llpanelenvironment.h b/indra/newview/llpanelenvironment.h index 3649abe939..c78aee89ed 100644 --- a/indra/newview/llpanelenvironment.h +++ b/indra/newview/llpanelenvironment.h @@ -104,7 +104,7 @@ protected: bool getIsDirty() const { return (mDirtyFlag != 0); } bool getIsDirtyFlag(U32 flag) const { return ((mDirtyFlag & flag) != 0); } U32 getDirtyFlag() const { return mDirtyFlag; } - void updateAltLabel(const std::string &alt_name, U32 sky_index, F32 alt_value); + void updateAltLabel(const std::string &alt_prefix, U32 sky_index, F32 alt_value); void readjustAltLabels(); void onSldDayLengthChanged(F32 value); -- cgit v1.2.3 From 0969632b11383e83a53bce3a10379945be7ad8c2 Mon Sep 17 00:00:00 2001 From: Rider Linden Date: Fri, 4 Jan 2019 12:32:23 -0800 Subject: Move some estate requests into the LLEstateInfoModel and out of the Region floater. Fix issue where user could potentially be looking at one set of estate options and update the estate they were standing in by mistake. --- indra/newview/llpanelenvironment.h | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'indra/newview/llpanelenvironment.h') diff --git a/indra/newview/llpanelenvironment.h b/indra/newview/llpanelenvironment.h index 3649abe939..abdbda864b 100644 --- a/indra/newview/llpanelenvironment.h +++ b/indra/newview/llpanelenvironment.h @@ -97,14 +97,14 @@ protected: static const U32 DIRTY_FLAG_MASK; - bool setControlsEnabled(bool enabled); + bool setControlsEnabled(bool enabled); void setApplyProgress(bool started); void setDirtyFlag(U32 flag); void clearDirtyFlag(U32 flag); bool getIsDirty() const { return (mDirtyFlag != 0); } bool getIsDirtyFlag(U32 flag) const { return ((mDirtyFlag & flag) != 0); } U32 getDirtyFlag() const { return mDirtyFlag; } - void updateAltLabel(const std::string &alt_name, U32 sky_index, F32 alt_value); + void updateAltLabel(const std::string &alt_name, U32 sky_index, F32 alt_value); void readjustAltLabels(); void onSldDayLengthChanged(F32 value); @@ -164,16 +164,18 @@ protected: S32 mCurEnvVersion; // used to filter duplicate callbacks/refreshes protected: + typedef boost::signals2::connection connection_t; + void refreshFromEstate(); bool mAllowOverride; private: static void onIdlePlay(void *); - typedef boost::signals2::connection connection_t; - connection_t mCommitConnection; connection_t mChangeMonitor; + connection_t mUpdateConnection; + LLHandle mSettingsFloater; LLHandle mEditFloater; S32 mDirtyFlag; -- cgit v1.2.3 From 1badfb0e96959725fbe2895994607a088f4a808b Mon Sep 17 00:00:00 2001 From: Rider Linden Date: Mon, 7 Jan 2019 10:24:55 -0800 Subject: SL-9883: Hide controls and display message if parcel < 128m --- indra/newview/llpanelenvironment.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'indra/newview/llpanelenvironment.h') diff --git a/indra/newview/llpanelenvironment.h b/indra/newview/llpanelenvironment.h index 6690386b92..dd3a309780 100644 --- a/indra/newview/llpanelenvironment.h +++ b/indra/newview/llpanelenvironment.h @@ -89,6 +89,9 @@ protected: static const std::string STR_CROSS_REGION; static const std::string STR_LEGACY; static const std::string STR_DISALLOWED; + static const std::string STR_TOO_SMALL; + + static const S32 MINIMUM_PARCEL_SIZE; static const U32 DIRTY_FLAG_DAYCYCLE; static const U32 DIRTY_FLAG_DAYLENGTH; @@ -98,7 +101,6 @@ protected: static const U32 DIRTY_FLAG_MASK; bool setControlsEnabled(bool enabled); - void setApplyProgress(bool started); void setDirtyFlag(U32 flag); void clearDirtyFlag(U32 flag); bool getIsDirty() const { return (mDirtyFlag != 0); } @@ -126,7 +128,7 @@ protected: void onEnvironmentReceived(S32 parcel_id, LLEnvironment::EnvironmentInfo::ptr_t envifo); static void _onEnvironmentReceived(LLHandle that_h, S32 parcel_id, LLEnvironment::EnvironmentInfo::ptr_t envifo); - + virtual bool isLargeEnough() = 0; virtual void refreshFromSource() = 0; std::string getInventoryNameForAssetId(LLUUID asset_id); -- cgit v1.2.3 From ac85669c67be03bfb77f81e9bf51e7f1d4d6ee78 Mon Sep 17 00:00:00 2001 From: andreykproductengine Date: Tue, 8 Jan 2019 19:54:59 +0200 Subject: SL-10060 EEP Add reset default sky altitudes functionality --- indra/newview/llpanelenvironment.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'indra/newview/llpanelenvironment.h') diff --git a/indra/newview/llpanelenvironment.h b/indra/newview/llpanelenvironment.h index dd3a309780..18ab64dc12 100644 --- a/indra/newview/llpanelenvironment.h +++ b/indra/newview/llpanelenvironment.h @@ -66,6 +66,7 @@ protected: static const std::string BTN_SELECTINV; static const std::string BTN_EDIT; static const std::string BTN_USEDEFAULT; + static const std::string BTN_RST_ALTITUDES; static const std::string SLD_DAYLENGTH; static const std::string SLD_DAYOFFSET; static const std::string SLD_ALTITUDES; @@ -117,6 +118,7 @@ protected: void onBtnEdit(); void onBtnSelect(); void onBtnDefault(); + void onBtnRstAltitudes(); void udpateApparentTimeOfDay(); -- cgit v1.2.3 From 13c537e9a0f05857f89085b91ac098921c317fb1 Mon Sep 17 00:00:00 2001 From: andreykproductengine Date: Wed, 9 Jan 2019 21:57:12 +0200 Subject: SL-10279 Readjusting altitude slider --- indra/newview/llpanelenvironment.h | 1 + 1 file changed, 1 insertion(+) (limited to 'indra/newview/llpanelenvironment.h') diff --git a/indra/newview/llpanelenvironment.h b/indra/newview/llpanelenvironment.h index 18ab64dc12..b5debe69c2 100644 --- a/indra/newview/llpanelenvironment.h +++ b/indra/newview/llpanelenvironment.h @@ -71,6 +71,7 @@ protected: static const std::string SLD_DAYOFFSET; static const std::string SLD_ALTITUDES; static const std::string ICN_GROUND; + static const std::string ICN_WATER; static const std::string CHK_ALLOWOVERRIDE; static const std::string BTN_APPLY; static const std::string BTN_CANCEL; -- cgit v1.2.3 From 00d8caa359a216620db46d49696bc79a95fe8dc2 Mon Sep 17 00:00:00 2001 From: andreykproductengine Date: Thu, 10 Jan 2019 22:11:11 +0200 Subject: SL-10279 Finalize drag and drop support --- indra/newview/llpanelenvironment.h | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) (limited to 'indra/newview/llpanelenvironment.h') diff --git a/indra/newview/llpanelenvironment.h b/indra/newview/llpanelenvironment.h index b5debe69c2..87ce0772b2 100644 --- a/indra/newview/llpanelenvironment.h +++ b/indra/newview/llpanelenvironment.h @@ -123,7 +123,8 @@ protected: void udpateApparentTimeOfDay(); - void onPickerCommitted(LLUUID item_id); + void onPickerCommitted(LLUUID item_id, std::string source); + void onPickerCommitted(LLUUID item_id, S32 track_num = LLEnvironment::NO_TRACK); void onEditCommitted(LLSettingsDay::ptr_t newday); void onDayLenOffsetMouseUp(); @@ -154,13 +155,13 @@ protected: { public: AltitudeData() : - mAltitudeIndex(0), mLabelIndex(0), mAltitude(0) + mTrackIndex(0), mLabelIndex(0), mAltitude(0) {} - AltitudeData(U32 altitude_index, U32 label_index, F32 altitude) : - mAltitudeIndex(altitude_index), mLabelIndex(label_index), mAltitude(altitude) + AltitudeData(U32 track_index, U32 label_index, F32 altitude) : + mTrackIndex(track_index), mLabelIndex(label_index), mAltitude(altitude) {} - U32 mAltitudeIndex; + U32 mTrackIndex; U32 mLabelIndex; F32 mAltitude; }; @@ -211,11 +212,12 @@ public: void* cargo_data, EAcceptance* accept, std::string& tooltip_msg); - void setPanel(LLPanelEnvironmentInfo* panel) { mEnvironmentInfoPanel = panel; }; + void setPanel(LLPanelEnvironmentInfo* panel, std::string track) { mEnvironmentInfoPanel = panel; mTrack = track; }; void setDndEnabled(bool dnd_enabled) { mDndEnabled = dnd_enabled; }; protected: LLPanelEnvironmentInfo* mEnvironmentInfoPanel; + std::string mTrack; bool mDndEnabled; }; #endif // LL_LLPANELENVIRONMENT_H -- cgit v1.2.3 From 8740c54fb074b8ab2349dc5a3317e1578de3d812 Mon Sep 17 00:00:00 2001 From: Rider Linden Date: Thu, 7 Mar 2019 15:26:01 -0800 Subject: SL-10700: If a track is empty show the name of the track used below it. If all tracks are empty for a parcel are empty report thath it uses region settings. --- indra/newview/llpanelenvironment.h | 3 --- 1 file changed, 3 deletions(-) (limited to 'indra/newview/llpanelenvironment.h') diff --git a/indra/newview/llpanelenvironment.h b/indra/newview/llpanelenvironment.h index 87ce0772b2..9eb4040758 100644 --- a/indra/newview/llpanelenvironment.h +++ b/indra/newview/llpanelenvironment.h @@ -85,7 +85,6 @@ protected: static const std::string STR_LABEL_USEDEFAULT; static const std::string STR_LABEL_USEREGION; - static const std::string STR_LABEL_UNKNOWNINV; static const std::string STR_ALTITUDE_DESCRIPTION; static const std::string STR_NO_PARCEL; static const std::string STR_CROSS_REGION; @@ -135,8 +134,6 @@ protected: virtual bool isLargeEnough() = 0; virtual void refreshFromSource() = 0; - std::string getInventoryNameForAssetId(LLUUID asset_id); - std::string getNameForTrackIndex(S32 index); LLFloaterSettingsPicker * getSettingsPicker(bool create = true); -- cgit v1.2.3 From bfc4b9fcf4bb3266e06c2f954854a430cca5075f Mon Sep 17 00:00:00 2001 From: andreykproductengine Date: Fri, 2 Aug 2019 20:23:06 +0300 Subject: SL-11668 Changes caused by Arrow Keys were not commited --- indra/newview/llpanelenvironment.h | 1 + 1 file changed, 1 insertion(+) (limited to 'indra/newview/llpanelenvironment.h') diff --git a/indra/newview/llpanelenvironment.h b/indra/newview/llpanelenvironment.h index 9eb4040758..50ec1165be 100644 --- a/indra/newview/llpanelenvironment.h +++ b/indra/newview/llpanelenvironment.h @@ -126,6 +126,7 @@ protected: void onPickerCommitted(LLUUID item_id, S32 track_num = LLEnvironment::NO_TRACK); void onEditCommitted(LLSettingsDay::ptr_t newday); void onDayLenOffsetMouseUp(); + void commitDayLenOffsetChanges(bool need_callback); void onPickerAssetDownloaded(LLSettingsBase::ptr_t settings); void onEnvironmentReceived(S32 parcel_id, LLEnvironment::EnvironmentInfo::ptr_t envifo); -- cgit v1.2.3 From 7ff09d05f2023ce8eb26acc46da22f8d86743de5 Mon Sep 17 00:00:00 2001 From: maxim_productengine Date: Mon, 7 Oct 2019 12:41:00 +0300 Subject: SL-12024 Remove 'Estate warning' message and show just region name instead --- indra/newview/llpanelenvironment.h | 1 + 1 file changed, 1 insertion(+) (limited to 'indra/newview/llpanelenvironment.h') diff --git a/indra/newview/llpanelenvironment.h b/indra/newview/llpanelenvironment.h index 50ec1165be..38e3f09e34 100644 --- a/indra/newview/llpanelenvironment.h +++ b/indra/newview/llpanelenvironment.h @@ -80,6 +80,7 @@ protected: static const std::string PNL_ENVIRONMENT_ALTITUDES; static const std::string PNL_BUTTONS; static const std::string PNL_DISABLED; + static const std::string PNL_REGION_MSG; static const std::string TXT_DISABLED; static const std::string SDT_DROP_TARGET; -- cgit v1.2.3