summaryrefslogtreecommitdiff
path: root/src/gui/widgets/setupitem.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/widgets/setupitem.h')
-rw-r--r--src/gui/widgets/setupitem.h34
1 files changed, 34 insertions, 0 deletions
diff --git a/src/gui/widgets/setupitem.h b/src/gui/widgets/setupitem.h
index 71856d6e2..220a55494 100644
--- a/src/gui/widgets/setupitem.h
+++ b/src/gui/widgets/setupitem.h
@@ -41,6 +41,7 @@ class EditDialog;
class HorizontContainer;
class IntTextField;
class Label;
+class Slider;
class TextField;
class SetupItem : public gcn::ActionListener
@@ -264,4 +265,37 @@ class SetupItemDropDown : public SetupItem
DropDown *mDropDown;
};
+class SetupItemSlider : public SetupItem
+{
+ public:
+ SetupItemSlider(std::string text, std::string description,
+ std::string keyName, SetupTabScroll *parent,
+ std::string eventName, double min, double max,
+ bool mainConfig = true);
+
+ SetupItemSlider(std::string text, std::string description,
+ std::string keyName, SetupTabScroll *parent,
+ std::string eventName, double min, double max,
+ std::string def, bool mainConfig = true);
+
+ ~SetupItemSlider();
+
+ void createControls();
+
+ void fromWidget();
+
+ void toWidget();
+
+ void action(const gcn::ActionEvent &event);
+
+ void apply(std::string eventName);
+
+ protected:
+ HorizontContainer *mHorizont;
+ Label *mLabel;
+ Slider *mSlider;
+ double mMin;
+ double mMax;
+};
+
#endif