public void run(IProgressMonitor monitor) { CompareUI.openCompareEditorOnPage( new SVNCompareRevisionsInput((IFile)getSelectedResources()[0], entries[0]), getTargetPage());
public void run(IProgressMonitor monitor) throws InvocationTargetException, InterruptedException { SVNCompareRevisionsInput input = new SVNCompareRevisionsInput((IFile)getSelectedResources()[0], entries[0]); if(SVNUIPlugin.getPlugin().getPreferenceStore().getBoolean(ISVNUIConstants.PREF_SHOW_COMPARE_REVISION_IN_DIALOG)) {  input.run(new NullProgressMonitor()); SaveablePartDialog cd = createCompareDialog(getShell(), input); cd.setBlockOnOpen(true); cd.open(); } else { CompareUI.openCompareEditorOnPage(input, getTargetPage()); }
	public void execute(IAction action) throws InvocationTargetException, InterruptedException {				// Setup holders		final ISVNRemoteFile[] file = new ISVNRemoteFile[] { null };		final ILogEntry[][] entries = new ILogEntry[][] { null };				// Get the selected file		run(new IRunnableWithProgress() {			public void run(IProgressMonitor monitor) {				file[0] = getSelectedRemoteFile();			}		}, false /* cancelable */, PROGRESS_BUSYCURSOR);				if (file[0] == null) {			// No revisions for selected file			MessageDialog.openWarning(getShell(), Policy.bind("CompareWithRevisionAction.noRevisions"), Policy.bind("CompareWithRevisionAction.noRevisionsLong")); //$NON-NLS-1$ //$NON-NLS-2$			return;		}				// Fetch the log entries		run(new IRunnableWithProgress() {			public void run(IProgressMonitor monitor) throws InvocationTargetException {				try {					monitor.beginTask(Policy.bind("CompareWithRevisionAction.fetching"), 100); //$NON-NLS-1$					entries[0] = file[0].getLogEntries(Policy.subMonitorFor(monitor, 100));					monitor.done();				} catch (TeamException e) {					throw new InvocationTargetException(e);				}			}		}, true /* cancelable */, PROGRESS_DIALOG);				if (entries[0] == null) return;				// Show the compare viewer		run(new IRunnableWithProgress() {			public void run(IProgressMonitor monitor) {				CompareUI.openCompareEditorOnPage(				  new SVNCompareRevisionsInput((IFile)getSelectedResources()[0], entries[0]),				  getTargetPage());			}		}, false /* cancelable */, PROGRESS_BUSYCURSOR);	}