]> git.sesse.net Git - vlc/blob - plugins/kde/kde_slider.h
* ./BUGS: added a list of known bugs. Please add your findings!
[vlc] / plugins / kde / kde_slider.h
1 /***************************************************************************
2                           kde_slider.h  -  description
3                              -------------------
4     begin                : Sun Apr 03 2001
5     copyright            : (C) 2001 by andres
6     email                : dae@chez.com
7  ***************************************************************************/
8 /***************************************************************************
9         shamelessly copied from noatun's excellent interface
10 ****************************************************************************/
11 #ifndef _KDE_SLIDER_H_
12 #define _KDE_SLIDER_H_
13
14 #include <qslider.h>
15
16 /**
17  * This slider can be changed by the vlc while not dragged by the user
18  */
19 class KVLCSlider : public QSlider
20 {
21     Q_OBJECT
22     public:
23         KVLCSlider(QWidget * parent, const char * name=0);
24         KVLCSlider(Orientation, QWidget * parent, const char * name=0);
25         KVLCSlider(int minValue, int maxValue, int pageStep, int value,
26                    Orientation, QWidget * parent, const char * name=0);
27
28     signals:
29     /**
30      * emmited only when the user changes the value by hand
31      */
32     void userChanged( int value );
33
34     public slots:
35         virtual void setValue( int );
36
37     protected:
38         virtual void mousePressEvent( QMouseEvent * e );
39         virtual void mouseReleaseEvent( QMouseEvent * e );
40
41     private:
42         bool pressed; // set this to true when the user drags the slider
43 };
44
45 #endif /* _KDE_SLIDER_H_ */