editor: Dismiss drag selection when dropped outside editor (#32382)

This PR fixes two issues:

1. On macOS, using Alt to copy the selection instead of cutting it.
2. Dropping the drag selection outside the editor dismisses it.  


https://github.com/user-attachments/assets/341e21c3-3eca-4e58-9bcc-8ec1de18e999


Release Notes:

- N/A

---------

Co-authored-by: Smit Barmase <heysmitbarmase@gmail.com>
This commit is contained in:
CharlesChen0823
2025-06-10 15:41:59 +05:30
committed by GitHub
co-authored by Smit Barmase
parent 2dad48d8d9
commit eb5f59577d
2 changed files with 25 additions and 14 deletions
+1
View File
@@ -918,6 +918,7 @@ enum SelectionDragState {
Dragging {
selection: Selection<Anchor>,
drop_cursor: Selection<Anchor>,
hide_drop_cursor: bool,
},
}