Skip to content

Conversation

Copy link

Copilot AI commented Nov 10, 2025

Fixes eclipse-platform#3525. When moving files between projects via drag-and-drop, the file appeared in both source and destination instead of being removed from source.

Changes

  • ResourceDropAdapterAssistant.handleDrop(): Added refresh of source containers after move operations (excludes copy/link operations)
  • ResourceDropAdapterAssistant.handlePluginTransferDrop(): Added refresh of source containers for consistency

Implementation

After the existing target container refresh, iterate through moved resources and refresh their parent containers:

// Refresh source containers to ensure they update in the UI
for (IResource resource : resources) {
    IContainer parent = resource.getParent();
    if (parent != null && parent.isAccessible() && !parent.equals(target)) {
        parent.refreshLocal(IResource.DEPTH_ONE, null);
    }
}

The target was already being refreshed, but source containers were not, causing stale UI state.

Original prompt

Fix eclipse-platform#3525


✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

Copilot AI and others added 2 commits November 10, 2025 11:16
Co-authored-by: laeubi <1331477+laeubi@users.noreply.github.com>
Co-authored-by: laeubi <1331477+laeubi@users.noreply.github.com>
Copilot AI changed the title [WIP] Fix issue #3525 in Eclipse Platform UI Fix Project Explorer not refreshing source containers after drag-and-drop move Nov 10, 2025
Copilot AI requested a review from laeubi November 10, 2025 11:21
Copilot finished work on behalf of laeubi November 10, 2025 11:21
@laeubi laeubi marked this pull request as ready for review November 10, 2025 11:22
@laeubi laeubi merged commit 8dddc60 into master Nov 10, 2025
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.

Project explorer doesn't refresh correctly after moving files

2 participants