Skip to content

Commit

Permalink
allow customizing speed search comparator in member chooser
Browse files Browse the repository at this point in the history
  • Loading branch information
yole committed Jan 30, 2013
1 parent 0af8e75 commit 7ae856a
Showing 1 changed file with 5 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@
import com.intellij.ui.*;
import com.intellij.ui.treeStructure.Tree;
import com.intellij.util.PlatformIcons;
import com.intellij.util.PlatformUtils;
import com.intellij.util.containers.Convertor;
import com.intellij.util.containers.FactoryMap;
import com.intellij.util.containers.HashMap;
Expand Down Expand Up @@ -391,7 +390,7 @@ public String convert(TreePath path) {
return text;
}
});
treeSpeedSearch.setComparator(new SpeedSearchComparator(false));
treeSpeedSearch.setComparator(getSpeedSearchComparator());

treeSpeedSearch.addChangeListener(new PropertyChangeListener() {
@Override
Expand All @@ -401,6 +400,10 @@ public void propertyChange(PropertyChangeEvent evt) {
});
}

protected SpeedSearchComparator getSpeedSearchComparator() {
return new SpeedSearchComparator(false);
}

protected void fillToolbarActions(DefaultActionGroup group) {
SortEmAction sortAction = new SortEmAction();
sortAction.registerCustomShortcutSet(new CustomShortcutSet(KeyStroke.getKeyStroke(KeyEvent.VK_A, InputEvent.ALT_MASK)), myTree);
Expand Down

0 comments on commit 7ae856a

Please sign in to comment.