mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
decodeInformation() should return null if it doesn't change anything
This commit is contained in:
@@ -255,7 +255,7 @@ public class JavaChangeUtilSupport implements TreeGenerator, TreeCopyHandler {
|
||||
// shorten references to the same package and to inner classes that can be accessed by short name
|
||||
ref = (PsiJavaCodeReferenceElement)codeStyleManager.shortenClassReferences(ref, JavaCodeStyleManager.DO_NOT_ADD_IMPORTS);
|
||||
}
|
||||
element = (TreeElement)SourceTreeToPsiMap.psiElementToTree(ref);
|
||||
return (TreeElement)SourceTreeToPsiMap.psiElementToTree(ref);
|
||||
}
|
||||
catch (IncorrectOperationException e) {
|
||||
((PsiImportHolder) ref.getContainingFile()).importClass(refClass);
|
||||
@@ -274,7 +274,7 @@ public class JavaChangeUtilSupport implements TreeGenerator, TreeCopyHandler {
|
||||
catch (IncorrectOperationException e) {
|
||||
// TODO[yole] ignore?
|
||||
}
|
||||
element = (TreeElement)SourceTreeToPsiMap.psiElementToTree(ref);
|
||||
return (TreeElement)SourceTreeToPsiMap.psiElementToTree(ref);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -313,7 +313,7 @@ public class JavaChangeUtilSupport implements TreeGenerator, TreeCopyHandler {
|
||||
}
|
||||
}
|
||||
|
||||
return element;
|
||||
return null;
|
||||
}
|
||||
|
||||
private static final Key<Boolean> ALREADY_ESCAPED = new Key<Boolean>("ALREADY_ESCAPED");
|
||||
|
||||
Reference in New Issue
Block a user