summaryrefslogtreecommitdiff
path: root/indra/newview/llfloatereditextdaycycle.h
diff options
context:
space:
mode:
authorRider Linden <rider@lindenlab.com>2018-01-23 17:34:25 -0800
committerRider Linden <rider@lindenlab.com>2018-01-23 17:34:25 -0800
commit536aeb54a6130f3d1e20405c8f6cbd29201de26d (patch)
tree8cc33f38b3ce3e2c2ad881e7929997d6a0ec515c /indra/newview/llfloatereditextdaycycle.h
parent5e544ee35d70fa9e27774ba30ccae06aa6d4d5f9 (diff)
MAINT-8052: One more step towards parcel environments.
Diffstat (limited to 'indra/newview/llfloatereditextdaycycle.h')
-rw-r--r--indra/newview/llfloatereditextdaycycle.h146
1 files changed, 75 insertions, 71 deletions
diff --git a/indra/newview/llfloatereditextdaycycle.h b/indra/newview/llfloatereditextdaycycle.h
index bed5db14b2..8b5a087edb 100644
--- a/indra/newview/llfloatereditextdaycycle.h
+++ b/indra/newview/llfloatereditextdaycycle.h
@@ -28,6 +28,8 @@
#define LL_LLFLOATEREDITEXTDAYCYCLE_H
#include "llfloater.h"
+#include "llsettingsdaycycle.h"
+#include <boost/signals2.hpp>
class LLCheckBoxCtrl;
class LLComboBox;
@@ -43,90 +45,92 @@ class LLFloaterEditExtDayCycle : public LLFloater
LOG_CLASS(LLFloaterEditExtDayCycle);
public:
- LLFloaterEditExtDayCycle(const LLSD &key);
-
- /*virtual*/ BOOL postBuild();
- /*virtual*/ void onOpen(const LLSD& key);
- /*virtual*/ void onClose(bool app_quitting);
- /*virtual*/ void draw();
-
-private:
-
- /// sync the time slider with day cycle structure
- void syncTimeSlider();
-
- // makes sure key slider has what's in day cycle
- void loadTrack();
+ typedef boost::signals2::signal<void(LLSettingsDay::ptr_t)> edit_commit_signal_t;
+ typedef boost::signals2::connection connection_t;
- /// makes sure day cycle data structure has what's in menu
- void applyTrack();
+ LLFloaterEditExtDayCycle(const LLSD &key);
- /// refresh the sky presets combobox
- void refreshSkyPresetsList();
+ BOOL postBuild();
+ void onOpen(const LLSD& key);
+ void onClose(bool app_quitting);
- /// refresh the day cycle combobox
- void refreshDayCyclesList();
+ void onVisibilityChange(BOOL new_visibility);
- /// add a slider to the track
-// void addSliderKey(F32 time, LLWLParamKey keyframe);
+// /*virtual*/ void draw();
+ connection_t setEditCommitSignal(edit_commit_signal_t::slot_type cb);
- void initCallbacks();
-// LLWLParamKey getSelectedDayCycle();
- bool isNewDay() const;
- void dumpTrack();
- void enableEditing(bool enable);
- void reset();
- void saveRegionDayCycle();
+private:
- void setApplyProgress(bool started);
- bool getApplyProgress() const;
+// /// sync the time slider with day cycle structure
+// void syncTimeSlider();
+//
+// // makes sure key slider has what's in day cycle
+// void loadTrack();
+//
+// /// makes sure day cycle data structure has what's in menu
+// void applyTrack();
+//
+// /// refresh the sky presets combobox
+ void refreshSkyPresetsList();
- void onTimeSliderMoved(); /// time slider moved
- void onKeyTimeMoved(); /// a key frame moved
- void onKeyTimeChanged(); /// a key frame's time changed
- void onKeyPresetChanged(); /// sky preset selected
- void onAddKey(); /// new key added on slider
- void onDeleteKey(); /// a key frame deleted
+ void onDayPresetChanged(); /// sky preset selected
- void onRegionSettingsChange();
- void onRegionChange();
- void onRegionSettingsApplied(bool success);
- void onRegionInfoUpdate();
+ void onBtnSave();
+ void onBtnCancel();
- void onDayCycleNameEdited();
- void onDayCycleSelected();
- void onBtnSave();
- void onBtnCancel();
+// /// refresh the day cycle combobox
+// void refreshDayCyclesList();
+//
+// /// add a slider to the track
+// // void addSliderKey(F32 time, LLWLParamKey keyframe);
+//
+// void initCallbacks();
+// // LLWLParamKey getSelectedDayCycle();
+// bool isNewDay() const;
+// void dumpTrack();
+// void enableEditing(bool enable);
+// void reset();
+// void saveRegionDayCycle();
+//
+// void setApplyProgress(bool started);
+// bool getApplyProgress() const;
+//
+// void onTimeSliderMoved(); /// time slider moved
+// void onKeyTimeMoved(); /// a key frame moved
+// void onKeyTimeChanged(); /// a key frame's time changed
+// void onAddKey(); /// new key added on slider
+// void onDeleteKey(); /// a key frame deleted
+//
+// void onRegionSettingsChange();
+// void onRegionChange();
+// void onRegionSettingsApplied(bool success);
+// void onRegionInfoUpdate();
+//
+// void onDayCycleNameEdited();
+// void onDayCycleSelected();
+//
+// bool onSaveAnswer(const LLSD& notification, const LLSD& response);
+// void onSaveConfirmed();
+//
+// void onDayCycleListChange();
+// void onSkyPresetListChange();
+//
+// static std::string getRegionName();
- bool onSaveAnswer(const LLSD& notification, const LLSD& response);
- void onSaveConfirmed();
+ LLSettingsDay::ptr_t mSavedDay;
+ LLSettingsDay::ptr_t mEditDay;
- void onDayCycleListChange();
- void onSkyPresetListChange();
+ LLComboBox* mDayPresetsCombo;
+ LLButton* mSaveButton;
+ LLButton* mCancelButton;
- static std::string getRegionName();
+ edit_commit_signal_t mCommitSignal;
- /// convenience class for holding keyframes mapped to sliders
-// struct SliderKey
-// {
-// public:
-// SliderKey(LLWLParamKey kf, F32 t) : keyframe(kf), time(t) {}
-// SliderKey() : keyframe(), time(0.f) {} // Don't use this default constructor
-//
-// LLWLParamKey keyframe;
-// F32 time;
-// };
-
- static const F32 sHoursPerDay;
-
- LLLineEditor* mDayCycleNameEditor;
- LLComboBox* mDayCyclesCombo;
- LLMultiSliderCtrl* mTimeSlider;
- LLMultiSliderCtrl* mKeysSlider;
- LLComboBox* mSkyPresetsCombo;
- LLTimeCtrl* mTimeCtrl;
- LLCheckBoxCtrl* mMakeDefaultCheckBox;
- LLButton* mSaveButton;
+// LLComboBox* mDayCyclesCombo;
+// LLMultiSliderCtrl* mTimeSlider;
+// LLMultiSliderCtrl* mKeysSlider;
+ // LLTimeCtrl* mTimeCtrl;
+// LLCheckBoxCtrl* mMakeDefaultCheckBox;
// map of sliders to parameters
// std::map<std::string, SliderKey> mSliderToKey;