//修复版本号
if( compareVersion instanceof SVNRevision.Number ){
compareVersion = RbSVNUrlUtils.reviseSVNRevisionAdaptByMaxOrMin( (IResource)ifile,
(SVNRevision.Number)compareVersion, false, null );
}
SVNLocalCompareInput compareEditorInput = null;
try {
svnRemoteResource = localResource.getRemoteResource( compareVersion );
if( null == svnRemoteResource ){
compareEditorInput = new SVNLocalCompareInput(localResource, SVNRevision.BASE, true);
}else{
compareEditorInput = new SVNLocalCompareInput(localResource, svnRemoteResource );
}
} catch (SVNException e) {
MessageDialog.openError(getShell(),
RbSubclipseMessages.getString("ERROR_INFORMATION_LABLE"),
RbSubclipseMessages.getString("ERROR_COMPARE") + e.getMessage()); //$NON-NLS-1$
return ;
}
if( null != compareEditorInput ){
try {
compareEditorInput.run( new NullProgressMonitor() );
} catch (Exception e) {
e.printStackTrace();
}
compareViewerPane.setInput(compareEditorInput.getCompareResult());
compareViewerPane.setTitleArgument( RbSubclipseMessages.getString("COMPARE.dialogTitle_1")
+ (null != svnRemoteResource ? svnRemoteResource.getRevision() : "") );
showComparePane(true);
showCompareButton.setSelection(true);
}