Just record history at zoom changes, the other way sucks

This commit is contained in:
Mark Watkins 2014-07-20 00:34:32 +10:00
parent 084c2a1d1a
commit eec43c7141

View File

@ -761,7 +761,6 @@ void gGraph::mouseMoveEvent(QMouseEvent *event)
min_x = rmax_x - xx;
}
m_graphview->saveHistory();
m_graphview->SetXBounds(min_x, max_x, m_group, false);
doredraw = true;
} else {
@ -785,7 +784,6 @@ void gGraph::mouseMoveEvent(QMouseEvent *event)
min_x = rmax_x - xx;
}
m_graphview->saveHistory();
m_graphview->SetXBounds(min_x, max_x, m_group, false);
doredraw = true;
}
@ -891,7 +889,6 @@ void gGraph::mouseReleaseEvent(QMouseEvent *event)
} else {
if (a2 - a1 < zoom_hard_limit) { a2 = a1 + zoom_hard_limit; }
m_graphview->saveHistory();
m_graphview->SetXBounds(a1, a2, m_group);
}
} else {
@ -909,7 +906,6 @@ void gGraph::mouseReleaseEvent(QMouseEvent *event)
qDebug() << "Foo2??";
} else {
if (a2 - a1 < zoom_hard_limit) { a2 = a1 + zoom_hard_limit; }
m_graphview->saveHistory();
m_graphview->SetXBounds(a1, a2, m_group);
}
}
@ -983,7 +979,6 @@ void gGraph::mouseReleaseEvent(QMouseEvent *event)
min_x = rmax_x - xx;
}
m_graphview->saveHistory();
m_graphview->SetXBounds(min_x, max_x, m_group);
m_lastx23 = x;
}
@ -1122,7 +1117,6 @@ void gGraph::ZoomX(double mult, int origin_px)
extern const int max_history;
m_graphview->saveHistory();
m_graphview->SetXBounds(min, max, m_group);
//updateSelectionTime(max-min);
}