Bug 30543 [DND] Files deleted when dragged to mozilla
In the Resource or Java perspectives, after dragging an html file from the navigator to be viewed in Mozilla, the file is deleted from the Eclipse views and from the filesystem. Not true of IE 5.5 or Netscape 4.72 on the same machine. Versions: - Eclipse 2.0.2 - NT 4.0 SP6 - Mozilla 1.2.1
bundles/org.eclipse.ui.views/src/org/eclipse/ui/views/navigator/NavigatorDragAdapter.java
LocalSelectionTransfer.getInstance().setSelection(selection);
		event.doit = true;
	}
	
	private IResource[] getSelectedResources(int resourceTypes) {
		List resources = new ArrayList();
		IResource[] result = new IResource[0];
		ISelection selection = selectionProvider.getSelection();
		if (!(selection instanceof IStructuredSelection) || selection.isEmpty()) {
			return null;
		}
		IStructuredSelection structuredSelection = (IStructuredSelection) selection;
		if (structuredSelection == null)
			return null;
		
		Iterator enum = structuredSelection.iterator();
		while (enum.hasNext()) {
			Object obj = enum.next();
			if (obj instanceof IResource) {
				IResource res = (IResource) obj;
				if ((res.getType() & resourceTypes) == res.getType()) {
					resources.add(res);
				}
			}
		}
		result = new IResource[resources.size()];
		resources.toArray(result);
		return result;
	}
}