# HG changeset patch # User matthiasm # Date 1402674617 -3600 # Node ID 7717751f44070920714ed7885b409332556944db # Parent 54efa0a4f728a90a8c42e640a0f9d0a3b79eb6f4 fixed selection by note move to not include the next note on the right diff -r 54efa0a4f728 -r 7717751f4407 layer/FlexiNoteLayer.cpp --- a/layer/FlexiNoteLayer.cpp Fri Jun 13 15:29:06 2014 +0100 +++ b/layer/FlexiNoteLayer.cpp Fri Jun 13 16:50:17 2014 +0100 @@ -1666,8 +1666,10 @@ for (FlexiNoteModel::PointList::iterator i = points.begin(); i != points.end(); ++i) { - bool overlap = !(((s.getStartFrame() < i->frame) && (s.getEndFrame() < i->frame)) - || ((s.getStartFrame() > i->frame+i->duration) && (s.getEndFrame() > i->frame+i->duration))); + bool overlap = !( + ((s.getStartFrame() < i->frame) && (s.getEndFrame() < i->frame)) || // selection is left of note + ((s.getStartFrame() > (i->frame+i->duration-1)) && (s.getEndFrame() > (i->frame+i->duration-1))) // selection is right of note + ); if (overlap) { command->deletePoint(*i); }