mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
IDEA-199698 visual glitches in new SE
This commit is contained in:
+2
-2
@@ -102,8 +102,8 @@ public abstract class AbstractGotoSEContributor<F> implements SearchEverywhereCo
|
||||
}, progressIndicator);
|
||||
}
|
||||
|
||||
//todo param is unnecessary #UX-1
|
||||
protected abstract FilteringGotoByModel<F> createModel(Project project);
|
||||
@NotNull
|
||||
protected abstract FilteringGotoByModel<F> createModel(@NotNull Project project);
|
||||
|
||||
@NotNull
|
||||
@Override
|
||||
|
||||
+2
-1
@@ -56,8 +56,9 @@ public class ClassSearchEverywhereContributor extends AbstractGotoSEContributor<
|
||||
return 100;
|
||||
}
|
||||
|
||||
@NotNull
|
||||
@Override
|
||||
protected FilteringGotoByModel<Language> createModel(Project project) {
|
||||
protected FilteringGotoByModel<Language> createModel(@NotNull Project project) {
|
||||
return new GotoClassModel2(project);
|
||||
}
|
||||
|
||||
|
||||
+4
-2
@@ -29,6 +29,7 @@ import java.util.stream.Stream;
|
||||
|
||||
/**
|
||||
* @author Konstantin Bulenkov
|
||||
* @author Mikhail Sokolov
|
||||
*/
|
||||
public class FileSearchEverywhereContributor extends AbstractGotoSEContributor<FileType> {
|
||||
private final GotoFileModel myModelForRenderer;
|
||||
@@ -54,8 +55,9 @@ public class FileSearchEverywhereContributor extends AbstractGotoSEContributor<F
|
||||
return 200;
|
||||
}
|
||||
|
||||
@NotNull
|
||||
@Override
|
||||
protected FilteringGotoByModel<FileType> createModel(Project project) {
|
||||
protected FilteringGotoByModel<FileType> createModel(@NotNull Project project) {
|
||||
return new GotoFileModel(project);
|
||||
}
|
||||
|
||||
@@ -80,7 +82,7 @@ public class FileSearchEverywhereContributor extends AbstractGotoSEContributor<F
|
||||
public boolean processSelectedItem(@NotNull Object selected, int modifiers, @NotNull String searchText) {
|
||||
if (selected instanceof PsiFile) {
|
||||
VirtualFile file = ((PsiFile)selected).getVirtualFile();
|
||||
if (file != null) {
|
||||
if (file != null && myProject != null) {
|
||||
Pair<Integer, Integer> pos = getLineAndColumn(searchText);
|
||||
OpenFileDescriptor descriptor = new OpenFileDescriptor(myProject, file, pos.first, pos.second);
|
||||
descriptor.setUseCurrentWindow(openInCurrentWindow(modifiers));
|
||||
|
||||
+4
@@ -60,6 +60,10 @@ public class RecentFilesSEContributor extends FileSearchEverywhereContributor {
|
||||
@Override
|
||||
public void fetchElements(@NotNull String pattern, boolean everywhere, @Nullable SearchEverywhereContributorFilter<FileType> filter,
|
||||
@NotNull ProgressIndicator progressIndicator, @NotNull Function<Object, Boolean> consumer) {
|
||||
if (myProject == null) {
|
||||
return; //nothing to search
|
||||
}
|
||||
|
||||
String searchString = filterControlSymbols(pattern);
|
||||
MinusculeMatcher matcher = NameUtil.buildMatcher("*" + searchString).build();
|
||||
List<VirtualFile> opened = Arrays.asList(FileEditorManager.getInstance(myProject).getSelectedFiles());
|
||||
|
||||
+2
-1
@@ -54,8 +54,9 @@ public class SymbolSearchEverywhereContributor extends AbstractGotoSEContributor
|
||||
return false;
|
||||
}
|
||||
|
||||
@NotNull
|
||||
@Override
|
||||
protected FilteringGotoByModel<Language> createModel(Project project) {
|
||||
protected FilteringGotoByModel<Language> createModel(@NotNull Project project) {
|
||||
return new GotoSymbolModel2(project);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user