From c238fa3ac5a3f93dcbf95e3cf7a7f8b576ab751c Mon Sep 17 00:00:00 2001 From: Rider Linden Date: Tue, 8 May 2018 16:57:14 -0700 Subject: Add save/update functionality hooks to fixed editor. --- indra/newview/llflyoutcombobtn.h | 71 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 71 insertions(+) create mode 100644 indra/newview/llflyoutcombobtn.h (limited to 'indra/newview/llflyoutcombobtn.h') diff --git a/indra/newview/llflyoutcombobtn.h b/indra/newview/llflyoutcombobtn.h new file mode 100644 index 0000000000..ebf7564422 --- /dev/null +++ b/indra/newview/llflyoutcombobtn.h @@ -0,0 +1,71 @@ +/** + * @file llsaveoutfitcombobtn.h + * @brief Represents outfit save/save as combo button. + * + * $LicenseInfo:firstyear=2010&license=viewerlgpl$ + * Second Life Viewer Source Code + * Copyright (C) 2010, 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_LLSAVECOMBOBTN_H +#define LL_LLSAVECOMBOBTN_H + +/*TODO: Make this button generic */ + +class LLButton; + +#include "lltoggleablemenu.h" + +/** + * Represents outfit Save/Save As combo button. + */ +class LLFlyoutComboBtn +{ + LOG_CLASS(LLFlyoutComboBtn); +public: + LLFlyoutComboBtn(LLPanel* parent, const std::string &action_button, const std::string &flyout_button, const std::string &menu_file); + + void setMenuItemEnabled(const std::string &item, bool enabled); + void setShownBtnEnabled(bool enabled); + + U32 getItemCount(); + void setSelectedItem(S32 itemno); + void setSelectedItem(const std::string &item); + + void setAction(LLUICtrl::commit_callback_t cb); + +protected: + void onFlyoutButton(LLUICtrl *, const LLSD &); + void onFlyoutItemSelected(LLUICtrl *, const LLSD &); + void onFlyoutAction(LLUICtrl *, const LLSD &); + + void setSelectedItem(LLMenuItemGL *pitem); + +private: + LLPanel * mParent; + LLToggleableMenu * mFlyoutMenu; + std::string mActionButton; + std::string mFlyoutButton; + + std::string mSelectedName; + + LLUICtrl::commit_signal_t mActionSignal; +}; +#endif // LL_LLSAVEOUTFITCOMBOBTN_H -- cgit v1.2.3 From b6ba9dd565b59e516571445e56f9dafe3bdf4061 Mon Sep 17 00:00:00 2001 From: andreykproductengine Date: Tue, 22 May 2018 20:32:56 +0300 Subject: MAINT-8344 Day Cycle Editor (part 4, finalization) --- indra/newview/llflyoutcombobtn.h | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) (limited to 'indra/newview/llflyoutcombobtn.h') diff --git a/indra/newview/llflyoutcombobtn.h b/indra/newview/llflyoutcombobtn.h index ebf7564422..517752d8db 100644 --- a/indra/newview/llflyoutcombobtn.h +++ b/indra/newview/llflyoutcombobtn.h @@ -24,8 +24,8 @@ * $/LicenseInfo$ */ -#ifndef LL_LLSAVECOMBOBTN_H -#define LL_LLSAVECOMBOBTN_H +#ifndef LL_LLFLYOUTCOMBOBTN_H +#define LL_LLFLYOUTCOMBOBTN_H /*TODO: Make this button generic */ @@ -33,14 +33,11 @@ class LLButton; #include "lltoggleablemenu.h" -/** - * Represents outfit Save/Save As combo button. - */ -class LLFlyoutComboBtn +class LLFlyoutComboBtnCtrl { - LOG_CLASS(LLFlyoutComboBtn); + LOG_CLASS(LLFlyoutComboBtnCtrl); public: - LLFlyoutComboBtn(LLPanel* parent, const std::string &action_button, const std::string &flyout_button, const std::string &menu_file); + LLFlyoutComboBtnCtrl(LLPanel* parent, const std::string &action_button, const std::string &flyout_button, const std::string &menu_file); void setMenuItemEnabled(const std::string &item, bool enabled); void setShownBtnEnabled(bool enabled); @@ -68,4 +65,4 @@ private: LLUICtrl::commit_signal_t mActionSignal; }; -#endif // LL_LLSAVEOUTFITCOMBOBTN_H +#endif // LL_LLFLYOUTCOMBOBTN_H -- 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/llflyoutcombobtn.h | 1 + 1 file changed, 1 insertion(+) (limited to 'indra/newview/llflyoutcombobtn.h') diff --git a/indra/newview/llflyoutcombobtn.h b/indra/newview/llflyoutcombobtn.h index 517752d8db..741ad03a37 100644 --- a/indra/newview/llflyoutcombobtn.h +++ b/indra/newview/llflyoutcombobtn.h @@ -41,6 +41,7 @@ public: void setMenuItemEnabled(const std::string &item, bool enabled); void setShownBtnEnabled(bool enabled); + void setMenuItemVisible(const std::string &item, bool visible); U32 getItemCount(); void setSelectedItem(S32 itemno); -- cgit v1.2.3 From a4c49904c67e123df0d8e1f68714cf13acfa1ffc Mon Sep 17 00:00:00 2001 From: andreykproductengine Date: Mon, 3 Sep 2018 19:32:22 +0300 Subject: MAINT-8989 Menu updates button instead of executing command --- indra/newview/llflyoutcombobtn.h | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'indra/newview/llflyoutcombobtn.h') diff --git a/indra/newview/llflyoutcombobtn.h b/indra/newview/llflyoutcombobtn.h index 741ad03a37..b0dd4abadf 100644 --- a/indra/newview/llflyoutcombobtn.h +++ b/indra/newview/llflyoutcombobtn.h @@ -37,7 +37,11 @@ class LLFlyoutComboBtnCtrl { LOG_CLASS(LLFlyoutComboBtnCtrl); public: - LLFlyoutComboBtnCtrl(LLPanel* parent, const std::string &action_button, const std::string &flyout_button, const std::string &menu_file); + LLFlyoutComboBtnCtrl(LLPanel* parent, + const std::string &action_button, + const std::string &flyout_button, + const std::string &menu_file, + bool apply_immediately = true); void setMenuItemEnabled(const std::string &item, bool enabled); void setShownBtnEnabled(bool enabled); @@ -52,6 +56,7 @@ public: protected: void onFlyoutButton(LLUICtrl *, const LLSD &); void onFlyoutItemSelected(LLUICtrl *, const LLSD &); + bool onFlyoutItemCheck(LLUICtrl *, const LLSD &); void onFlyoutAction(LLUICtrl *, const LLSD &); void setSelectedItem(LLMenuItemGL *pitem); @@ -63,6 +68,7 @@ private: std::string mFlyoutButton; std::string mSelectedName; + bool mApplyImmediately; LLUICtrl::commit_signal_t mActionSignal; }; -- cgit v1.2.3 From 64e45b5b6ef8ded7bbea1b376e5bf2cbb0d6f5a4 Mon Sep 17 00:00:00 2001 From: Rider Linden Date: Fri, 4 Jan 2019 17:10:28 -0800 Subject: SL-10041, SL-9758: Environment tab is disabled(shows can't do this) when EM does not allow parcel override. "Commit" button now reads "Apply to Parcel" or "Apply to Region" as needed. --- indra/newview/llflyoutcombobtn.h | 1 + 1 file changed, 1 insertion(+) (limited to 'indra/newview/llflyoutcombobtn.h') diff --git a/indra/newview/llflyoutcombobtn.h b/indra/newview/llflyoutcombobtn.h index b0dd4abadf..e41cd0cecb 100644 --- a/indra/newview/llflyoutcombobtn.h +++ b/indra/newview/llflyoutcombobtn.h @@ -46,6 +46,7 @@ public: void setMenuItemEnabled(const std::string &item, bool enabled); void setShownBtnEnabled(bool enabled); void setMenuItemVisible(const std::string &item, bool visible); + void setMenuItemLabel(const std::string &item, const std::string &label); U32 getItemCount(); void setSelectedItem(S32 itemno); -- cgit v1.2.3