mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-04-29 19:45:01 +02:00
Cosmetics.
This commit is contained in:
parent
b2d8caa6b0
commit
b0e167dd8e
1 changed files with 27 additions and 33 deletions
|
@ -42,7 +42,6 @@ import org.eclipse.cdt.internal.ui.refactoring.MethodContext;
|
||||||
* General class for common Node operations.
|
* General class for common Node operations.
|
||||||
*
|
*
|
||||||
* @author Lukas Felber & Guido Zgraggen
|
* @author Lukas Felber & Guido Zgraggen
|
||||||
*
|
|
||||||
*/
|
*/
|
||||||
public class NodeHelper {
|
public class NodeHelper {
|
||||||
|
|
||||||
|
@ -57,7 +56,6 @@ public class NodeHelper {
|
||||||
return new IASTDeclaration[0];
|
return new IASTDeclaration[0];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
public static IASTNode findFollowingNode(IASTNode currentNode) {
|
public static IASTNode findFollowingNode(IASTNode currentNode) {
|
||||||
if (currentNode == null || currentNode.getParent() == null) {
|
if (currentNode == null || currentNode.getParent() == null) {
|
||||||
return null;
|
return null;
|
||||||
|
@ -126,9 +124,8 @@ public class NodeHelper {
|
||||||
return context;
|
return context;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private static void getMethodContex(IASTTranslationUnit translationUnit, MethodContext context,
|
||||||
private static void getMethodContex(IASTTranslationUnit translationUnit,
|
IASTName name) {
|
||||||
MethodContext context, IASTName name) {
|
|
||||||
if (name instanceof ICPPASTQualifiedName){
|
if (name instanceof ICPPASTQualifiedName){
|
||||||
ICPPASTQualifiedName qname =( ICPPASTQualifiedName )name;
|
ICPPASTQualifiedName qname =( ICPPASTQualifiedName )name;
|
||||||
context.setMethodQName(qname);
|
context.setMethodQName(qname);
|
||||||
|
@ -141,14 +138,11 @@ public class NodeHelper {
|
||||||
context.setType(MethodContext.ContextType.METHOD);
|
context.setType(MethodContext.ContextType.METHOD);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private static void getMethodContexWithIndex(IIndex index, IASTTranslationUnit translationUnit,
|
||||||
private static void getMethodContexWithIndex(IIndex index,
|
MethodContext context, IASTName name) throws CoreException {
|
||||||
IASTTranslationUnit translationUnit, MethodContext context,
|
|
||||||
IASTName name) throws CoreException {
|
|
||||||
IBinding bind = name.resolveBinding();
|
IBinding bind = name.resolveBinding();
|
||||||
if (bind instanceof ICPPMethod) {
|
if (bind instanceof ICPPMethod) {
|
||||||
context.setType(MethodContext.ContextType.METHOD);
|
context.setType(MethodContext.ContextType.METHOD);
|
||||||
|
|
Loading…
Add table
Reference in a new issue