Skip to content

fix (filebrowser): clear selection and expand target after drag-and-drop move#3769

Merged
shroffk merged 2 commits intoControlSystemStudio:masterfrom
emilioheredia-source:filebrowser/fix-drag-drop-tree-state
Apr 6, 2026
Merged

fix (filebrowser): clear selection and expand target after drag-and-drop move#3769
shroffk merged 2 commits intoControlSystemStudio:masterfrom
emilioheredia-source:filebrowser/fix-drag-drop-tree-state

Conversation

@emilioheredia-source
Copy link
Copy Markdown

After a MOVE drag-and-drop, the removed TreeItem was left in the SelectionModel, leaving the tree highlighted in a confused state until the file browser was closed and reopened.

Two fixes in FileTreeCell:

  • onDragDone: call clearSelection() after removing the moved item so the tree view returns to a clean state immediately.
  • move_or_copy: expand the target folder and select the newly added item so the moved/copied file is immediately visible without requiring the user to manually expand the destination directory.

…op move

After a MOVE drag-and-drop, the removed TreeItem was left in the
SelectionModel, leaving the tree highlighted in a confused state until
the file browser was closed and reopened.

Two fixes in FileTreeCell:
- onDragDone: call clearSelection() after removing the moved item so the
  tree view returns to a clean state immediately.
- move_or_copy: expand the target folder and select the newly added item
  so the moved/copied file is immediately visible without requiring the
  user to manually expand the destination directory.
@sonarqubecloud
Copy link
Copy Markdown

sonarqubecloud bot commented Apr 4, 2026

@shroffk shroffk merged commit 4e94b24 into ControlSystemStudio:master Apr 6, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants