diff --git a/src/frmmain.cpp b/src/frmmain.cpp index 4bedcd7b..48fee72f 100644 --- a/src/frmmain.cpp +++ b/src/frmmain.cpp @@ -34,7 +34,6 @@ #include #include "frmmain.h" #include "ui_frmmain.h" -#include "windows.h" frmMain::frmMain(QWidget *parent) : QMainWindow(parent), diff --git a/src/widgets/slider.cpp b/src/widgets/slider.cpp index 66ddaf48..5620c9a2 100644 --- a/src/widgets/slider.cpp +++ b/src/widgets/slider.cpp @@ -14,20 +14,9 @@ void Slider::paintEvent(QPaintEvent *ev) QPainter painter(this); painter.setRenderHint(QPainter::Antialiasing); - QPen pen(0x999999); - pen.setWidth(3); - - QPolygon poly(QVector() << QPoint(0, 7) << QPoint(-5, 0) << QPoint(5, 0)); - int pos = ((double)this->width() - 18) / (this->maximum() - this->minimum()) * (this->m_currentValue - this->minimum()) + 9; - poly.translate(pos, 2); - QImage image(":/images/handle2s1.png"); - - painter.setPen(pen); - painter.setBrush(QBrush(0x999999)); - // painter.drawPolygon(poly); -// painter.drawLine(pos, 3, pos, this->height() - 3); - painter.drawImage(pos - image.width() / 2, 2, image); + int pos = ((double)this->width() - 18) / (this->maximum() - this->minimum()) * (this->m_currentValue - this->minimum()) + 9; + painter.drawImage(pos - image.width() / 2, (this->height() - image.height()) / 2, image); } }