private void handleDropCopy(final Object target, DropTargetEvent event) throws JavaModelException, InvocationTargetException, InterruptedException{ IJavaElement[] javaElements= ReorgUtils.getJavaElements(fElements); IResource[] resources= ReorgUtils.getResources(fElements); ReorgCopyStarter starter= null; if (target instanceof IResource) starter= ReorgCopyStarter.create(javaElements, resources, (IResource)target); else if (target instanceof IJavaElement) starter= ReorgCopyStarter.create(javaElements, resources, (IJavaElement)target); if (starter != null) starter.run(getShell()); }
private void handleDropMove(final Object target, DropTargetEvent event) throws JavaModelException, InvocationTargetException, InterruptedException{ IJavaElement[] javaElements= ReorgUtils.getJavaElements(fElements); IResource[] resources= ReorgUtils.getResources(fElements); ReorgMoveStarter starter= null; if (target instanceof IResource) starter= ReorgMoveStarter.create(javaElements, resources, (IResource)target); else if (target instanceof IJavaElement) starter= ReorgMoveStarter.create(javaElements, resources, (IJavaElement)target); if (starter != null) starter.run(getShell()); }
private boolean handleDropCopy(final Object target) throws JavaModelException, InvocationTargetException, InterruptedException{ IJavaElement[] javaElements= ReorgUtils.getJavaElements(fElements); IResource[] resources= ReorgUtils.getResources(fElements); ReorgCopyStarter starter= ReorgCopyStarter.create(javaElements, resources, ReorgDestinationFactory.createDestination(target, getCurrentLocation())); if (starter != null) { starter.run(getShell()); return true; } return false; }
private boolean handleDropMove(final Object target) throws JavaModelException, InvocationTargetException, InterruptedException{ IJavaElement[] javaElements= ReorgUtils.getJavaElements(fElements); IResource[] resources= ReorgUtils.getResources(fElements); ReorgMoveStarter starter= ReorgMoveStarter.create(javaElements, resources, ReorgDestinationFactory.createDestination(target, getCurrentLocation())); if (starter != null) return starter.run(getShell()); return false; }
private boolean handleDropCopy(final Object target) throws JavaModelException, InvocationTargetException, InterruptedException{ IJavaElement[] javaElements= ReorgUtils.getJavaElements(fElements); IResource[] resources= ReorgUtils.getResources(fElements); ReorgCopyStarter starter= ReorgCopyStarter.create(javaElements, resources, ReorgDestinationFactory.createDestination(target, getCurrentLocation())); if (starter != null) { starter.run(getShell()); return true; } return false; }
private boolean handleDropMove(final Object target) throws JavaModelException, InvocationTargetException, InterruptedException{ IJavaElement[] javaElements= ReorgUtils.getJavaElements(fElements); IResource[] resources= ReorgUtils.getResources(fElements); ReorgMoveStarter starter= ReorgMoveStarter.create(javaElements, resources, ReorgDestinationFactory.createDestination(target, getCurrentLocation())); if (starter != null) return starter.run(getShell()); return false; }