mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
IDEA-140862 Changed the "Regex" checkbox ChangeListener to ItemListener
The only change they actually need is the selection change. Also add a mnemonic. https://github.com/JetBrains/intellij-community/pull/540
This commit is contained in:
committed by
Kirill Likhodedov
parent
7abc8b35e7
commit
d25cddaeeb
@@ -466,7 +466,7 @@ outdated.version.text.deleted=Outdated version. Deleted by {0} {1}: {2}
|
||||
current.version.text={4}<br/><br/>Current version is {3}.<br/>Modified by {0}<br/>{1}<br/>{2}
|
||||
committed.changes.filter.title=Filter by
|
||||
committed.changes.group.title=Group by
|
||||
committed.changes.regex.title=Regex
|
||||
committed.changes.regex.title=Re&gex
|
||||
changelist.details.committed.format=Committed by {0} {1}
|
||||
incoming.changes.indicator.tooltip={0} incoming changelists available
|
||||
column.name.type=Type
|
||||
|
||||
+5
-2
@@ -52,6 +52,8 @@ import javax.swing.*;
|
||||
import javax.swing.event.ChangeEvent;
|
||||
import javax.swing.event.ChangeListener;
|
||||
import java.awt.*;
|
||||
import java.awt.event.ItemEvent;
|
||||
import java.awt.event.ItemListener;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collections;
|
||||
import java.util.LinkedList;
|
||||
@@ -103,9 +105,10 @@ public class CommittedChangesPanel extends JPanel implements TypeSafeDataProvide
|
||||
toolbarPanel.add(Box.createHorizontalGlue());
|
||||
myRegexCheckbox = new JCheckBox(VcsBundle.message("committed.changes.regex.title"));
|
||||
myRegexCheckbox.setSelected(false);
|
||||
myRegexCheckbox.getModel().addChangeListener(new ChangeListener() {
|
||||
myRegexCheckbox.getModel().addItemListener(new ItemListener() {
|
||||
@Override
|
||||
public void stateChanged(ChangeEvent e) {
|
||||
public void itemStateChanged(ItemEvent e) {
|
||||
// TODO: no need to re-filter if the text field is empty anyway
|
||||
myFilterComponent.filter();
|
||||
}
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user