Skip to content

Commit

Permalink
Use DisableShortcutsOnFocusGainedTextField instead of JTextField insi…
Browse files Browse the repository at this point in the history
…de the filter panel

Now when you enter characters into the field for filtering by user, the keystrokes are no longer treated as keyboard shortcuts while the text field has focus.
Fixes #35.
  • Loading branch information
floscher committed Mar 20, 2017
1 parent 5b31aad commit 23318a4
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
import org.openstreetmap.josm.Main;
import org.openstreetmap.josm.gui.SideButton;
import org.openstreetmap.josm.gui.dialogs.ToggleDialog;
import org.openstreetmap.josm.gui.widgets.DisableShortcutsOnFocusGainedTextField;
import org.openstreetmap.josm.plugins.mapillary.MapillaryAbstractImage;
import org.openstreetmap.josm.plugins.mapillary.MapillaryDataListener;
import org.openstreetmap.josm.plugins.mapillary.MapillaryImage;
Expand Down Expand Up @@ -110,7 +111,7 @@ private MapillaryFilterDialog() {

JPanel userSearchPanel = new JPanel();
userSearchPanel.setLayout(new FlowLayout(FlowLayout.LEFT));
this.user = new JTextField(10);
this.user = new DisableShortcutsOnFocusGainedTextField(10);
this.user.addActionListener(new UpdateAction());
userSearchPanel.add(new JLabel(tr("User")));
userSearchPanel.add(this.user);
Expand Down

0 comments on commit 23318a4

Please sign in to comment.