diff widgets/LevelPanToolButton.cpp @ 933:9022635c615a tonioni

Fixes to enabled/disabled state in level-pan tool button
author Chris Cannam
date Wed, 25 Mar 2015 11:41:17 +0000
parents 37bb4b416c52
children 325a7aa69055
line wrap: on
line diff
--- a/widgets/LevelPanToolButton.cpp	Wed Mar 25 11:27:46 2015 +0000
+++ b/widgets/LevelPanToolButton.cpp	Wed Mar 25 11:41:17 2015 +0000
@@ -75,8 +75,8 @@
     px.fill(Qt::transparent);
     setIcon(px);
 
-    m_lpw->setFixedWidth(m_pixels * 4);
-    m_lpw->setFixedHeight(m_pixels * 4);
+    m_lpw->setFixedWidth(m_pixels * 3);
+    m_lpw->setFixedHeight(m_pixels * 3);
 }
 
 void
@@ -94,6 +94,13 @@
 }
 
 void
+LevelPanToolButton::setEnabled(bool enabled)
+{
+    m_lpw->setEnabled(enabled);
+    QToolButton::setEnabled(enabled);
+}
+
+void
 LevelPanToolButton::selfLevelChanged(float level)
 {
     if (level > 0.f) {