Skip to content

Commit

Permalink
Fix #319079: Shift Selecting Last Word fails
Browse files Browse the repository at this point in the history
Changed condition to only check for s1. s2 might be nullptr which marks
end of score.

Backport of musescore#7793, resp. duplicate of musescore#7947
  • Loading branch information
ht-gong authored and Jojo-Schmitz committed Jul 27, 2021
1 parent 76829c3 commit 1039ef5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion libmscore/score.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3278,7 +3278,7 @@ void Score::selectRange(Element* e, int staffIdx)
Segment* s2 = tick2segmentMM(t2, true, SegmentType::ChordRest);
if (s2)
s2 = s2->next1MM(SegmentType::ChordRest);
if (s1 && s2) {
if (s1) {
_selection.setRange(s1, s2, idx1, idx2 + 1);
selectSimilarInRange(e);
if (selectedElement->track() == e->track()) {
Expand Down

0 comments on commit 1039ef5

Please sign in to comment.