comparison widgets/LevelPanWidget.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 f3d3fab250ac
children a575dae05fbf
comparison
equal deleted inserted replaced
1302:f3d3fab250ac 1303:13f5f84fbfad
14 14
15 #ifndef LEVEL_PAN_WIDGET_H 15 #ifndef LEVEL_PAN_WIDGET_H
16 #define LEVEL_PAN_WIDGET_H 16 #define LEVEL_PAN_WIDGET_H
17 17
18 #include <QWidget> 18 #include <QWidget>
19
20 #include "WheelCounter.h"
19 21
20 /** 22 /**
21 * A simple widget for coarse level and pan control. 23 * A simple widget for coarse level and pan control.
22 */ 24 */
23 25
96 float m_monitorRight; 98 float m_monitorRight;
97 bool m_editable; 99 bool m_editable;
98 bool m_editing; 100 bool m_editing;
99 bool m_includeMute; 101 bool m_includeMute;
100 bool m_includeHalfSteps; 102 bool m_includeHalfSteps;
101 int m_pendingWheelAngle; 103
104 WheelCounter m_wheelCounter;
102 105
103 int clampNotch(int notch) const; 106 int clampNotch(int notch) const;
104 int clampPan(int pan) const; 107 int clampPan(int pan) const;
105 108
106 int audioLevelToNotch(float audioLevel) const; 109 int audioLevelToNotch(float audioLevel) const;