summaryrefslogtreecommitdiffstats
path: root/src/widget/wdisplay.cpp
diff options
context:
space:
mode:
authorRJ Ryan <rryan@mixxx.org>2014-01-10 13:33:19 -0500
committerRJ Ryan <rryan@mixxx.org>2014-01-10 18:08:07 -0500
commit4837f3fb22cf9285cc0279c5d63380f2623cd7e5 (patch)
treea672493a93ee3b7e7a89146ecf227d13b307cca5 /src/widget/wdisplay.cpp
parentbed60ca6d326a397fea175bbd0a75fe85989d7db (diff)
Remove widget values.
* WWidget no longer stores a value independent of its connected controls. * Make a connection explicitly the display value. For legacy reasons this is the last connection with connectValueToWidget. * Update all WWidget descendents to use the connected display value when painting. * Push buttons update the left or right connected control for push-button behavior or toggling. This allows WPushButton to toggle a multi-state button on left and right click. This was previously impossible.
Diffstat (limited to 'src/widget/wdisplay.cpp')
-rw-r--r--src/widget/wdisplay.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/widget/wdisplay.cpp b/src/widget/wdisplay.cpp
index 614ebaa5a3..6791760f64 100644
--- a/src/widget/wdisplay.cpp
+++ b/src/widget/wdisplay.cpp
@@ -145,7 +145,7 @@ int WDisplay::getActivePixmapIndex() const {
// Subtracting an epsilon prevents out of bound values at the end of the
// range and biases the middle value towards the lower of the 2 center
// pixmaps when there are an even number of pixmaps.
- return static_cast<int>(getValue() * numPixmaps() - 0.00001);
+ return static_cast<int>(getConnectedDisplayValue() * numPixmaps() - 0.00001);
}
void WDisplay::paintEvent(QPaintEvent* ) {