fix #22919
This commit is contained in:
parent
e6af7a937d
commit
969d660e60
1 changed files with 11 additions and 0 deletions
|
@ -1417,6 +1417,8 @@ void Score::cmdDeleteSelection()
|
|||
if (selection().state() == SEL_RANGE) {
|
||||
Segment* s1 = selection().startSegment();
|
||||
Segment* s2 = selection().endSegment();
|
||||
int stick1 = s1->tick();
|
||||
int stick2 = s2->tick();
|
||||
|
||||
Segment* ss1 = s1;
|
||||
if (ss1->segmentType() != Segment::SegChordRest)
|
||||
|
@ -1502,6 +1504,15 @@ void Score::cmdDeleteSelection()
|
|||
}
|
||||
}
|
||||
}
|
||||
s1 = tick2segment(stick1);
|
||||
s2 = tick2segment(stick2);
|
||||
if (s1 == 0 || s2 == 0)
|
||||
deselectAll();
|
||||
else {
|
||||
_selection.setStartSegment(s1);
|
||||
_selection.setEndSegment(s2);
|
||||
_selection.updateSelectedElements();
|
||||
}
|
||||
}
|
||||
else {
|
||||
// deleteItem modifies selection().elements() list,
|
||||
|
|
Loading…
Reference in a new issue