Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[MU4] Fix #319079: Shift Selecting Last Word #7793

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion src/libmscore/score.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3407,6 +3407,12 @@ void Score::selectRange(Element* e, int staffIdx)
if (selectedElement && e->type() == selectedElement->type()) {
int idx1 = selectedElement->staffIdx();
int idx2 = e->staffIdx();
if (idx2 < idx1) {
int temp = idx1;
idx1 = idx2;
idx2 = temp;
}

if (idx1 >= 0 && idx2 >= 0) {
Fraction t1 = selectedElement->tick();
Fraction t2 = e->tick();
Expand All @@ -3421,7 +3427,7 @@ void Score::selectRange(Element* e, int staffIdx)
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