mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-10-01 19:02:13 +07:00
Merge remote branch 'origin/master'
This commit is contained in:
@@ -33,6 +33,8 @@ import com.intellij.openapi.util.Pair;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
import java.awt.*;
|
||||
import java.util.Collections;
|
||||
import java.util.Comparator;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
@@ -87,6 +89,14 @@ public class GotoActionAction extends GotoActionBase implements DumbAware {
|
||||
ChooseByNamePopup.createPopup(project, model, new DefaultChooseByNameItemProvider(null) {
|
||||
@Override
|
||||
protected void sortNamesList(@NotNull String namePattern, List<String> namesList) {
|
||||
Collections.sort(namesList, new Comparator<String>() {
|
||||
@Override
|
||||
public int compare(String o1, String o2) {
|
||||
if (o1.equals(GotoActionModel.SETTINGS_KEY)) return 1;
|
||||
if (o2.equals(GotoActionModel.SETTINGS_KEY)) return -1;
|
||||
return o1.compareToIgnoreCase(o2);
|
||||
}
|
||||
});
|
||||
}
|
||||
}, start.first, false, start.second));
|
||||
}
|
||||
|
||||
@@ -47,7 +47,7 @@ import java.awt.*;
|
||||
import java.util.*;
|
||||
|
||||
public class GotoActionModel implements ChooseByNameModel, CustomMatcherModel, Comparator<Object> {
|
||||
@NonNls private static final String SETTINGS_KEY = "$$$SETTINGS$$$";
|
||||
@NonNls public static final String SETTINGS_KEY = "$$$SETTINGS$$$";
|
||||
@Nullable private final Project myProject;
|
||||
private final Component myContextComponent;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user