This commit is contained in:
Alexey Kudravtsev
2014-06-26 13:07:38 +04:00
parent 7b8b14421d
commit 27364a87b7
2 changed files with 6 additions and 6 deletions
@@ -1,5 +1,5 @@
/*
* Copyright 2000-2013 JetBrains s.r.o.
* Copyright 2000-2014 JetBrains s.r.o.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -74,7 +74,7 @@ public class Java15APIUsageInspectionBase extends BaseJavaBatchLocalInspectionTo
loadForbiddenApi("ignore16List.txt", ourIgnored16ClassesAPI);
}
private static Set<String> ourGenerifiedClasses = new HashSet<String>();
private static final Set<String> ourGenerifiedClasses = new HashSet<String>();
static {
ourGenerifiedClasses.add("javax.swing.JComboBox");
ourGenerifiedClasses.add("javax.swing.ListModel");
@@ -37,6 +37,10 @@ public class LazyRangeMarkerFactory {
private final Project myProject;
private static final Key<WeakList<LazyMarker>> LAZY_MARKERS_KEY = Key.create("LAZY_MARKERS_KEY");
public static LazyRangeMarkerFactory getInstance(Project project) {
return ServiceManager.getService(project, LazyRangeMarkerFactory.class);
}
public LazyRangeMarkerFactory(@NotNull Project project, @NotNull final FileDocumentManager fileDocumentManager) {
myProject = project;
@@ -89,10 +93,6 @@ public class LazyRangeMarkerFactory {
markers.add(marker);
}
public static LazyRangeMarkerFactory getInstance(Project project) {
return ServiceManager.getService(project, LazyRangeMarkerFactory.class);
}
@NotNull
public RangeMarker createRangeMarker(@NotNull final VirtualFile file, final int offset) {
return ApplicationManager.getApplication().runReadAction(new Computable<RangeMarker>() {