comparison widgets/Thumbwheel.h @ 1303:13f5f84fbfad

Collect the bits of bookkeeping for mouse wheel events, and use in all widgets
author Chris Cannam
date Fri, 22 Jun 2018 17:19:48 +0100
parents 4a578a360011
children a18e78b9c78b
comparison
equal deleted inserted replaced
1302:f3d3fab250ac 1303:13f5f84fbfad
11 published by the Free Software Foundation; either version 2 of the 11 published by the Free Software Foundation; either version 2 of the
12 License, or (at your option) any later version. See the file 12 License, or (at your option) any later version. See the file
13 COPYING included with this distribution for more information. 13 COPYING included with this distribution for more information.
14 */ 14 */
15 15
16 #ifndef _THUMBWHEEL_H_ 16 #ifndef SV_THUMBWHEEL_H
17 #define _THUMBWHEEL_H_ 17 #define SV_THUMBWHEEL_H
18 18
19 #include <QWidget> 19 #include <QWidget>
20 #include <QImage> 20 #include <QImage>
21 21
22 #include <map> 22 #include <map>
23
24 #include "WheelCounter.h"
23 25
24 class RangeMapper; 26 class RangeMapper;
25 27
26 class Thumbwheel : public QWidget 28 class Thumbwheel : public QWidget
27 { 29 {
94 QPoint m_clickPos; 96 QPoint m_clickPos;
95 float m_clickRotation; 97 float m_clickRotation;
96 bool m_showTooltip; 98 bool m_showTooltip;
97 RangeMapper *m_rangeMapper; 99 RangeMapper *m_rangeMapper;
98 QImage m_cache; 100 QImage m_cache;
101 WheelCounter m_wheelCounter;
99 }; 102 };
100 103
101 #endif 104 #endif