Skip to content

Commit

Permalink
Fix that web search pane steals input
Browse files Browse the repository at this point in the history
Fixes #4330 by making the search button in the web search pane not the default button.
  • Loading branch information
tobiasdiez committed Sep 11, 2018
1 parent 4c3e520 commit 5e05e82
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -71,11 +71,12 @@ protected Node createContentPane() {

// Create text field for query input
TextField query = SearchTextField.create();
query.setOnAction(event -> viewModel.search());
viewModel.queryProperty().bind(query.textProperty());

// Create button that triggers search
Button search = new Button(Localization.lang("Search"));
search.setDefaultButton(true);
search.setDefaultButton(false);
search.setOnAction(event -> viewModel.search());

// Put everything together
Expand Down

0 comments on commit 5e05e82

Please sign in to comment.