Fix #18428: Undo pitch change can leave tied note on wrong line

In Measure::updateAccidentals() the line of a tied back note is set to the line of the starting note of the tie. 
When undoing a pitch change this leads to a wrong line, because the pitch change undo is done from 'right to left'. So the starting note's pitch/tpc/line is undone last. 
During such an undo operation it is not necessary to set the line for any of the notes here, because undo will do this anyway.

My proposed solution to find out if such an undo operation is going on: If the pitch of a tied back note is different from the starting note's pitch, this is due to the fact, that undo runs through the notes 'from right to left'. In this case we don't set the line, but let undo do this.