diff options
Diffstat (limited to 'utils/wpseditor/gui/src/slider.cpp')
| -rw-r--r-- | utils/wpseditor/gui/src/slider.cpp | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/utils/wpseditor/gui/src/slider.cpp b/utils/wpseditor/gui/src/slider.cpp new file mode 100644 index 0000000..7e3c9a9 --- /dev/null +++ b/utils/wpseditor/gui/src/slider.cpp @@ -0,0 +1,20 @@ +#include "slider.h" +#include <QDebug> +// +Slider::Slider(QWidget *parent, QString caption, int min, int max ):QDialog(parent) { + setupUi ( this ); + connect(horslider, SIGNAL(valueChanged(int)), this, SIGNAL(valueChanged(int))); + connect(this, SIGNAL(valueChanged(int)), this, SLOT(slotValueChanged(int))); + setWindowTitle(caption); + horslider->setMinimum(min); + horslider->setMaximum(max); +} +// +int Slider::value() { + return horslider->value(); +} +void Slider::slotValueChanged(int step) { + setWindowTitle(tr("Value =%1 ").arg(step)); +} + + |