Fix #48746 : Spanner span wrong after moving start anchor and undoing

The change in span length (`Spanner::_ticks`) was not noticed nor pushed unto the undo stack.
This commit is contained in:
Maurizio M. Gavioli 2015-02-24 22:03:25 +01:00
parent fd51063ec1
commit faa23617c2

View file

@ -326,7 +326,8 @@ void Spanner::endEdit()
score()->undoPropertyChanged(this, P_ID::SPANNER_TICK, editTick);
rebuild = true;
}
if (editTick2 != tick2()) {
// ticks may also change by moving initial anchor, without moving ending anchor
if (editTick2 != tick2() || editTick2 - editTick != tick2() - tick()) {
score()->undoPropertyChanged(this, P_ID::SPANNER_TICKS, editTick2 - editTick);
rebuild = true;
}