Deleting a note sometimes triggers an unnecessary change in selection

After I delete a note, the note after it becomes selected. This is good when the currently selected note is the one being deleted. However when I have selected one note and delete another, I expect the selected note to remain selected.

Is the way it currently works done for a specific reason?

It’s only a minor issue, but can be a bit disconcerting to the user because the jump in selection makes it feel like the selected note was the one that got deleted in error.

Desktop v1.0.176 on Linux

If there is no reason, then I suggest that the selection should not change when another note is deleted. The selection should only change if the selected note is deleted.

This applies to notebooks and tags too.

An alternative approach is to change the behaviour of right-click in the note list so that it also selects the target note (in addition to offering the context menu).

This would effectively eliminate the possibility of deleting an unselected note, and so eliminate the associated complexities at the same time.