summaryrefslogtreecommitdiff
path: root/indra/newview/llfloaterregioninfo.h
diff options
context:
space:
mode:
authorLogan Dethrow <log@lindenlab.com>2011-07-12 13:59:26 -0400
committerLogan Dethrow <log@lindenlab.com>2011-07-12 13:59:26 -0400
commitb750a5afb7833d91aed88d9d1f75ee0b4bc2aa80 (patch)
treeee54bbaed8f2f6016915cd3bb0506805e33179aa /indra/newview/llfloaterregioninfo.h
parent543943279894d76662833c3b4e35efd7d09a91fc (diff)
parent44c7c6feaa824f4049d326965cb066e76ebefee3 (diff)
merge
Diffstat (limited to 'indra/newview/llfloaterregioninfo.h')
-rw-r--r--indra/newview/llfloaterregioninfo.h120
1 files changed, 86 insertions, 34 deletions
diff --git a/indra/newview/llfloaterregioninfo.h b/indra/newview/llfloaterregioninfo.h
index 2b87c27fcf..e7917c382c 100644
--- a/indra/newview/llfloaterregioninfo.h
+++ b/indra/newview/llfloaterregioninfo.h
@@ -34,6 +34,8 @@
#include "llhost.h"
#include "llpanel.h"
+#include "llenvmanager.h" // for LLEnvironmentSettings
+
class LLAvatarName;
class LLDispatcher;
class LLLineEditor;
@@ -46,6 +48,7 @@ class LLInventoryItem;
class LLCheckBoxCtrl;
class LLComboBox;
class LLNameListCtrl;
+class LLRadioGroup;
class LLSliderCtrl;
class LLSpinCtrl;
class LLTextBox;
@@ -53,11 +56,17 @@ class LLVFS;
class LLPanelRegionGeneralInfo;
class LLPanelRegionDebugInfo;
-class LLPanelRegionTextureInfo;
class LLPanelRegionTerrainInfo;
class LLPanelEstateInfo;
class LLPanelEstateCovenant;
+class LLEventTimer;
+class LLEnvironmentSettings;
+class LLWLParamManager;
+class LLWaterParamManager;
+class LLWLParamSet;
+class LLWaterParamSet;
+
class LLFloaterRegionInfo : public LLFloater
{
friend class LLFloaterReg;
@@ -79,6 +88,7 @@ public:
static LLPanelEstateInfo* getPanelEstate();
static LLPanelEstateCovenant* getPanelCovenant();
+ static LLPanelRegionTerrainInfo* getPanelRegionTerrain();
// from LLPanel
virtual void refresh();
@@ -96,6 +106,7 @@ private:
boost::signals2::connection mConsoleReplySignalConnection;;
protected:
+ void onTabSelected(const LLSD& param);
void refreshFromRegion(LLViewerRegion* region);
// member data
@@ -208,44 +219,25 @@ private:
/////////////////////////////////////////////////////////////////////////////
-class LLPanelRegionTextureInfo : public LLPanelRegionInfo
+class LLPanelRegionTerrainInfo : public LLPanelRegionInfo
{
+ LOG_CLASS(LLPanelRegionTerrainInfo);
+
public:
- LLPanelRegionTextureInfo();
- ~LLPanelRegionTextureInfo() {}
-
- virtual bool refreshFromRegion(LLViewerRegion* region);
-
- // LLPanel && LLView
- virtual BOOL postBuild();
+ LLPanelRegionTerrainInfo() : LLPanelRegionInfo() {}
+ ~LLPanelRegionTerrainInfo() {}
-protected:
- virtual BOOL sendUpdate();
+ virtual BOOL postBuild(); // LLPanel
- static void onClickDump(void* data);
- BOOL validateTextureSizes();
-};
+ virtual bool refreshFromRegion(LLViewerRegion* region); // refresh local settings from region update from simulator
+ void setEnvControls(bool available); // Whether environment settings are available for this region
-/////////////////////////////////////////////////////////////////////////////
+ BOOL validateTextureSizes();
-class LLPanelRegionTerrainInfo : public LLPanelRegionInfo
-{
-public:
- LLPanelRegionTerrainInfo()
- : LLPanelRegionInfo() {}
- ~LLPanelRegionTerrainInfo() {}
- // LLPanel
- virtual BOOL postBuild();
+ //static void onChangeAnything(LLUICtrl* ctrl, void* userData); // callback for any change, to enable commit button
- virtual bool refreshFromRegion(LLViewerRegion* region);
-
-protected:
virtual BOOL sendUpdate();
- void onChangeUseEstateTime();
- void onChangeFixedSun();
- void onChangeSunHour();
-
static void onClickDownloadRaw(void*);
static void onClickUploadRaw(void*);
static void onClickBakeTerrain(void*);
@@ -319,10 +311,10 @@ public:
BOOL getGlobalTime();
void setGlobalTime(bool b);
- BOOL getFixedSun();
+ BOOL getFixedSun(); // *TODO: deprecated
- F32 getSunHour();
- void setSunHour(F32 sun_hour);
+ F32 getSunHour(); // *TODO: deprecated
+ void setSunHour(F32 sun_hour); // *TODO: deprecated
const std::string getEstateName() const;
void setEstateName(const std::string& name);
@@ -337,7 +329,6 @@ public:
// If visible from mainland, allowed agent and allowed groups
// are ignored, so must disable UI.
void setAccessAllowedEnabled(bool enable_agent, bool enable_group, bool enable_ban);
-
protected:
virtual BOOL sendUpdate();
// confirmation dialog callback
@@ -417,4 +408,65 @@ protected:
EAssetStatus mAssetStatus;
};
+/////////////////////////////////////////////////////////////////////////////
+
+class LLPanelEnvironmentInfo : public LLPanelRegionInfo
+{
+ LOG_CLASS(LLPanelEnvironmentInfo);
+
+public:
+ LLPanelEnvironmentInfo();
+
+ // LLPanel
+ /*virtual*/ BOOL postBuild();
+ /*virtual*/ void onOpen(const LLSD& key);
+
+ // LLView
+ /*virtual*/ void handleVisibilityChange(BOOL new_visibility);
+
+ // LLPanelRegionInfo
+ /*virtual*/ bool refreshFromRegion(LLViewerRegion* region);
+
+private:
+ void refresh();
+ void setControlsEnabled(bool enabled);
+ void setApplyProgress(bool started);
+ void setDirty(bool dirty);
+
+ void sendRegionSunUpdate();
+
+ void populateWaterPresetsList();
+ void populateSkyPresetsList();
+ void populateDayCyclesList();
+
+ bool getSelectedWaterParams(LLSD& water_params);
+ bool getSelectedSkyParams(LLSD& sky_params, std::string& preset_name);
+ bool getSelectedDayCycleParams(LLSD& day_cycle, LLSD& sky_map, short& scope);
+
+ void onSwitchRegionSettings();
+ void onSwitchDayCycle();
+
+ void onSelectWaterPreset();
+ void onSelectSkyPreset();
+ void onSelectDayCycle();
+
+ void onBtnApply();
+ void onBtnCancel();
+
+ void onRegionSettingschange();
+ void onRegionSettingsApplied(bool ok);
+
+ /// New environment settings that are being applied to the region.
+ LLEnvironmentSettings mNewRegionSettings;
+
+ bool mEnableEditing;
+
+ LLRadioGroup* mRegionSettingsRadioGroup;
+ LLRadioGroup* mDayCycleSettingsRadioGroup;
+
+ LLComboBox* mWaterPresetCombo;
+ LLComboBox* mSkyPresetCombo;
+ LLComboBox* mDayCyclePresetCombo;
+};
+
#endif