summaryrefslogtreecommitdiff
path: root/muse2/muse/arranger/pcanvas.cpp
diff options
context:
space:
mode:
authorTim E. Real <termtech@rogers.com>2011-05-05 22:55:49 +0000
committerTim E. Real <termtech@rogers.com>2011-05-05 22:55:49 +0000
commite35ae165dd7096942e9641dfd9c6d6fc2a89f1c7 (patch)
treea46a4e59bff5ecbb73f2e393303a2281cb86f640 /muse2/muse/arranger/pcanvas.cpp
parent548a9ee76ec16b19f7fc3a387890585575b08321 (diff)
Fixed regression: Plugins would not restore saved control state when loading song.
Diffstat (limited to 'muse2/muse/arranger/pcanvas.cpp')
-rw-r--r--muse2/muse/arranger/pcanvas.cpp10
1 files changed, 7 insertions, 3 deletions
diff --git a/muse2/muse/arranger/pcanvas.cpp b/muse2/muse/arranger/pcanvas.cpp
index c76e4421..35de93ee 100644
--- a/muse2/muse/arranger/pcanvas.cpp
+++ b/muse2/muse/arranger/pcanvas.cpp
@@ -3152,8 +3152,7 @@ void PartCanvas::drawAutomation(QPainter& p, const QRect& r, AudioTrack *t)
ic++;
int prevPosFrame=cvFirst.frame;
prevVal = cvFirst.val;
-
-
+ ///bool discrete = cl->valueType() == VAL_BOOL || cl->mode() == CtrlList::DISCRETE; // Tim
// prepare prevVal
if (cl->valueType() == VAL_LOG ) { // use db scale for volume
@@ -3195,7 +3194,12 @@ void PartCanvas::drawAutomation(QPainter& p, const QRect& r, AudioTrack *t)
p.drawLine( leftX,
(rr.bottom()-2)-prevVal*height,
currentPixel,
- (rr.bottom()-2)-nextVal*height);
+ (rr.bottom()-2)-nextVal*height);
+ ///(rr.bottom()-2)- (discrete?prevVal:nextVal)*height); // Tim
+
+ ///if(discrete)
+ /// p.drawLine( currentPixel, (rr.bottom()-2)-prevVal*height, currentPixel, (rr.bottom()-2)-nextVal*height ); // Tim
+
firstRun=false;
//printf("draw line: %d %f %d %f\n",tempomap.frame2tick(lastPos),rr.bottom()-lastVal*height,tempomap.frame2tick(cv.frame),rr.bottom()-curVal*height);
prevPosFrame=cv.frame;