Skip to content

Commit

Permalink
Merge pull request #4346 from dmitrio95/279172-debussy
Browse files Browse the repository at this point in the history
fix #279172,  fix #279448: fix two issues related to beams containing pointer to invalid system
  • Loading branch information
anatoly-os committed Dec 13, 2018
2 parents e5d17fc + 7664bcf commit aed2b3c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
3 changes: 3 additions & 0 deletions libmscore/beam.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -286,6 +286,7 @@ bool Beam::twoBeamedNotes()
//---------------------------------------------------------
// layout1
// - remove beam segments
// - detach from system
// - calculate stem direction and set chord
//---------------------------------------------------------

Expand All @@ -295,6 +296,8 @@ void Beam::layout1()
qDeleteAll(beamSegments);
beamSegments.clear();

setParent(nullptr); // parent is System

maxDuration.setType(TDuration::DurationType::V_INVALID);
Chord* c1 = 0;
Chord* c2 = 0;
Expand Down
1 change: 1 addition & 0 deletions libmscore/select.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -585,6 +585,7 @@ void Selection::setRangeTicks(int tick1, int tick2, int staffStart, int staffEnd
{
Q_ASSERT(staffEnd > staffStart && staffStart >= 0 && staffEnd >= 0 && staffEnd <= _score->nstaves());

deselectAll();
_plannedTick1 = tick1;
_plannedTick2 = tick2;
_startSegment = _endSegment = _activeSegment = nullptr;
Expand Down

0 comments on commit aed2b3c

Please sign in to comment.