Commit febca287b4b357240246f7149075ee3917f6c20c
- Diff rendering mode:
- inline
- side by side
src/gui/widgets/qabstractslider.cpp
(0 / 2)
|   | |||
| 739 | 739 | { | |
| 740 | 740 | Q_D(QAbstractSlider); | |
| 741 | 741 | e->ignore(); | |
| 742 | if (e->orientation() != d->orientation && !rect().contains(e->pos())) | ||
| 743 | return; | ||
| 744 | 742 | int delta = e->delta(); | |
| 745 | 743 | if (d->scrollByDelta(e->orientation(), e->modifiers(), delta)) | |
| 746 | 744 | e->accept(); |
tests/auto/qabstractslider/tst_qabstractslider.cpp
(4 / 4)
|   | |||
| 768 | 768 | << true // inverted controls | |
| 769 | 769 | << 20 // wheel scroll lines | |
| 770 | 770 | << false // with modifiers | |
| 771 | << 1 // delta | ||
| 771 | << -1 // delta | ||
| 772 | 772 | << int(Qt::Horizontal) // orientation of slider | |
| 773 | 773 | << int(Qt::Horizontal) // orientation of wheel | |
| 774 | 774 | << 30 // expected position after | |
| … | … | ||
| 782 | 782 | << false // inverted controls | |
| 783 | 783 | << 1 // wheel scroll lines | |
| 784 | 784 | << false // with modifiers | |
| 785 | << 2 // delta | ||
| 785 | << -2 // delta | ||
| 786 | 786 | << int(Qt::Horizontal) // orientation of slider | |
| 787 | 787 | << int(Qt::Horizontal) // orientation of wheel | |
| 788 | 788 | << 100 // expected position after | |
| … | … | ||
| 796 | 796 | << false // inverted controls | |
| 797 | 797 | << 1 // wheel scroll lines | |
| 798 | 798 | << false // with modifiers | |
| 799 | << -2 // delta | ||
| 799 | << 2 // delta | ||
| 800 | 800 | << int(Qt::Horizontal) // orientation of slider | |
| 801 | 801 | << int(Qt::Horizontal) // orientation of wheel | |
| 802 | 802 | << 0 // expected position after | |
| … | … | ||
| 810 | 810 | << false // inverted controls | |
| 811 | 811 | << 20 // wheel scroll lines | |
| 812 | 812 | << true // with modifiers | |
| 813 | << 1 // delta | ||
| 813 | << -1 // delta | ||
| 814 | 814 | << int(Qt::Horizontal) // orientation of slider | |
| 815 | 815 | << int(Qt::Horizontal) // orientation of wheel | |
| 816 | 816 | << 90 // expected position after |
Comments
Add a new comment:
Login or create an account to post a comment
Add your comment
Please log in to comment

