Lint: fix Lint additional checkers with the custom handlers
This commit is contained in:
@@ -1445,7 +1445,6 @@ public class LintDriver {
|
||||
if (ideaProject == null) {
|
||||
return;
|
||||
}
|
||||
List<UastLanguagePlugin> plugins = mClient.getLanguagePlugins();
|
||||
|
||||
for (JavaContext context : contexts) {
|
||||
fireEvent(LintListener.EventType.SCANNING_FILE, context);
|
||||
@@ -1456,10 +1455,10 @@ public class LintDriver {
|
||||
UastVisitor customVisitor = scanner.createUastVisitor(context);
|
||||
if (customVisitor != null) {
|
||||
UastChecker.INSTANCE.checkWithCustomHandler(
|
||||
ideaProject, context.file, plugins, customVisitor);
|
||||
ideaProject, context.file, context, customVisitor);
|
||||
} else {
|
||||
UastChecker.INSTANCE.check(
|
||||
ideaProject, context.file, (UastScanner)check, plugins, context);
|
||||
ideaProject, context.file, (UastScanner)check, context);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1516,9 +1515,9 @@ public class LintDriver {
|
||||
for (UastScanner detector : detectors) {
|
||||
UastVisitor customHandler = detector.createUastVisitor(context);
|
||||
if (customHandler != null) {
|
||||
checker.checkWithCustomHandler(intellijProject, file, plugins, customHandler);
|
||||
checker.checkWithCustomHandler(intellijProject, file, context, customHandler);
|
||||
} else {
|
||||
checker.check(intellijProject, file, detector, plugins, context);
|
||||
checker.check(intellijProject, file, detector, context);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user