#include <QComboBox>
#include <QGridLayout>
#include <QPushButton>
+#include <QSlider>
#include <vlc_keys.h>
spin->setMinimum( p_item->min.i );
}
+IntegerRangeSliderConfigControl::IntegerRangeSliderConfigControl(
+ vlc_object_t *_p_this,
+ module_config_t *_p_item,
+ QLabel *_label, QSlider *_slider,
+ bool *_bool ) :
+ VIntConfigControl( _p_this, _p_item )
+{
+ slider = _slider;
+ label = _label;
+ slider->setMaximum( p_item->max.i );
+ slider->setMinimum( p_item->min.i );
+ slider->setValue( p_item->value.i );
+ slider->setToolTip( qfu(p_item->psz_longtext) );
+ if( label )
+ label->setToolTip( qfu(p_item->psz_longtext) );
+}
+
+int IntegerRangeSliderConfigControl::getValue()
+{
+ return slider->value();
+}
+
+
/********* Integer / choice list **********/
IntegerListConfigControl::IntegerListConfigControl( vlc_object_t *_p_this,
module_config_t *_p_item, QWidget *_parent, bool bycat,
QGridLayout *, int& );
IntegerConfigControl( vlc_object_t *, module_config_t *,
QLabel*, QSpinBox* );
+ IntegerConfigControl( vlc_object_t *, module_config_t *,
+ QLabel*, QSlider* );
virtual ~IntegerConfigControl() {};
virtual int getValue();
virtual void show() { spin->show(); label->show(); }
protected:
QSpinBox *spin;
-
private:
QLabel *label;
void finish();
void finish();
};
+class IntegerRangeSliderConfigControl : public VIntConfigControl
+{
+public:
+ IntegerRangeSliderConfigControl( vlc_object_t *, module_config_t *,
+ QLabel *, QSlider *, bool * );
+ virtual ~IntegerRangeSliderConfigControl() {};
+ virtual int getValue();
+protected:
+ QSlider *slider;
+private:
+ QLabel *label;
+ void finish();
+};
+
class IntegerListConfigControl : public VIntConfigControl
{
public:
#ifdef WIN32
CONFIG_GENERIC( "directx-wallpaper" , Bool , NULL, wallpaperMode );
- CONFIG_GENERIC( "directx-device", String, NULL, dXdisplayDevice );
+ // CONFIG_GENERIC( "directx-device", String, NULL, dXdisplayDevice );
#endif
CONFIG_GENERIC( "snapshot-path", String, NULL,
#endif
CONFIG_GENERIC( "audio", Bool, NULL, enableAudio );
-/* CONFIG_GENERIC( "volume" , RangedInt, NULL, defaultVolume );*/ //FIXME Why ?
+ CONFIG_GENERIC( "volume" , IntegerRangeSlider, NULL, defaultVolume );
+
/* CONFIG_GENERIC( "audio-language" , String , NULL,
preferredAudioLanguage ); */ //FIXME WHy ?
CONFIG_GENERIC( "spdif" , Bool , NULL, spdifBox );
/* CONFIG_GENERIC( "alsadev" , String , NULL, alsaDevice );*/
CONFIG_GENERIC( "dspdev" , String , NULL, OSSDevice );//FIXME File
#else
- CONFIG_GENERIC( "directx-audio-device" , Integer, NULL,
- DirectXDevice );
+/* CONFIG_GENERIC( "directx-audio-device" , Integer, NULL,
+ DirectXDevice );*/
#endif
CONFIG_GENERIC( "audiofile-file" , String , NULL, FileName ); //Fixme File