Skip to content

Commit

Permalink
Merge pull request #5031 from mattmcclinch/49856-paste-glissando
Browse files Browse the repository at this point in the history
fix #49856: Glissando not copied if destination staff has links
  • Loading branch information
anatoly-os committed May 20, 2019
2 parents f75b55f + 282a443 commit aa81f8d
Showing 1 changed file with 4 additions and 17 deletions.
21 changes: 4 additions & 17 deletions libmscore/note.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1430,26 +1430,13 @@ void Note::readAddConnector(ConnectorInfoReader* info, bool pasteMode)
_tieFor = tie;
}
else {
// DISABLE pasting of glissandi into staves with other lionked staves
// because the glissando is not properly cloned into the linked staves
if (pasteMode && staff() && staff()->links() && !staff()->links()->empty()) {
// Do nothing. The spanner is no longer needed.
info->releaseConnector();
delete sp;
}
else {
sp->setAnchor(Spanner::Anchor::NOTE);
sp->setStartElement(this);
addSpannerFor(sp);
sp->setParent(this);
}
sp->setAnchor(Spanner::Anchor::NOTE);
sp->setStartElement(this);
addSpannerFor(sp);
sp->setParent(this);
}
}
else if (info->isEnd()) {
// We might have deleted a spanner (see "DISABLE pasting
// of glissandi..." note above)
if (!sp)
break;
sp->setTrack2(l.track());
sp->setTick2(tick());
sp->setEndElement(this);
Expand Down

0 comments on commit aa81f8d

Please sign in to comment.