From 19ae80dbcae1f260f6b7aa3f086288c763581ef5 Mon Sep 17 00:00:00 2001 From: Priyanshu Gupta Date: Mon, 27 Jan 2025 11:24:23 +0530 Subject: [PATCH 1/3] Fix the F3 shortcut key --- CHANGELOG.md | 1 + src/main/java/org/jabref/gui/maintable/MainTable.java | 9 +++++++++ 2 files changed, 10 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 78969b0b554..60276d86b87 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -17,6 +17,7 @@ Note that this project **does not** adhere to [Semantic Versioning](https://semv ### Fixed +- We fixed an issue where the F3 shortcut key does not work without opening the right-click context menu. - We fixed an issue where a bib file with UFF-8 charset was wrongly loaded with a different charset [forum#5369](https://discourse.jabref.org/t/jabref-5-15-opens-bib-files-with-shift-jis-encoding-instead-of-utf-8/5369/) - We fixed an issue where new entries were inserted in the middle of the table instead of at the end. [#12371](https://github.com/JabRef/jabref/pull/12371) - We fixed an issue where removing the sort from the table did not restore the original order. [#12371](https://github.com/JabRef/jabref/pull/12371) diff --git a/src/main/java/org/jabref/gui/maintable/MainTable.java b/src/main/java/org/jabref/gui/maintable/MainTable.java index c24019ea46b..d86de6e6793 100644 --- a/src/main/java/org/jabref/gui/maintable/MainTable.java +++ b/src/main/java/org/jabref/gui/maintable/MainTable.java @@ -71,6 +71,8 @@ public class MainTable extends TableView { private final LibraryTab libraryTab; private final StateManager stateManager; private final BibDatabaseContext database; + private final GuiPreferences preferences; + private final DialogService dialogService; private final MainTableDataModel model; private final CustomLocalDragboard localDragboard; private final TaskExecutor taskExecutor; @@ -100,6 +102,8 @@ public MainTable(MainTableDataModel model, this.libraryTab = libraryTab; this.stateManager = stateManager; this.database = Objects.requireNonNull(database); + this.preferences = preferences; + this.dialogService = dialogService; this.model = model; this.taskExecutor = taskExecutor; this.undoManager = libraryTab.getUndoManager(); @@ -323,6 +327,7 @@ private void setupKeyBindings(KeyBindingRepository keyBindings) { EditAction copyAction = new EditAction(StandardActions.COPY, () -> libraryTab, stateManager, undoManager); EditAction cutAction = new EditAction(StandardActions.CUT, () -> libraryTab, stateManager, undoManager); EditAction deleteAction = new EditAction(StandardActions.DELETE_ENTRY, () -> libraryTab, stateManager, undoManager); + OpenUrlAction openUrlAction = new OpenUrlAction(dialogService, stateManager, preferences); this.addEventFilter(KeyEvent.KEY_PRESSED, event -> { if (event.getCode() == KeyCode.ENTER) { @@ -368,6 +373,10 @@ private void setupKeyBindings(KeyBindingRepository keyBindings) { scrollToPreviousMatchCategory(); event.consume(); break; + case OPEN_URL_OR_DOI: + openUrlAction.execute(); + event.consume(); + break; default: // Pass other keys to parent } From 2b1c89a1bd5c0397a6753c4ac65c42ecfc29253e Mon Sep 17 00:00:00 2001 From: Priyanshu Gupta Date: Mon, 27 Jan 2025 11:30:27 +0530 Subject: [PATCH 2/3] Complete the CHANGELOG.md entry --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 60276d86b87..8e747e9b44e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -17,7 +17,7 @@ Note that this project **does not** adhere to [Semantic Versioning](https://semv ### Fixed -- We fixed an issue where the F3 shortcut key does not work without opening the right-click context menu. +- We fixed an issue where the F3 shortcut key does not work without opening the right-click context menu. [#12417](https://github.com/JabRef/jabref/pull/12417) - We fixed an issue where a bib file with UFF-8 charset was wrongly loaded with a different charset [forum#5369](https://discourse.jabref.org/t/jabref-5-15-opens-bib-files-with-shift-jis-encoding-instead-of-utf-8/5369/) - We fixed an issue where new entries were inserted in the middle of the table instead of at the end. [#12371](https://github.com/JabRef/jabref/pull/12371) - We fixed an issue where removing the sort from the table did not restore the original order. [#12371](https://github.com/JabRef/jabref/pull/12371) From b962b794f945d4654e8cbf50ceded4c1fd8103f8 Mon Sep 17 00:00:00 2001 From: Priyanshu Gupta Date: Mon, 27 Jan 2025 16:47:17 +0530 Subject: [PATCH 3/3] Update CHANGELOG.md Co-authored-by: Subhramit Basu Bhowmick --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 416e5fb9629..e9c1bb9123c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -17,7 +17,7 @@ Note that this project **does not** adhere to [Semantic Versioning](https://semv ### Fixed -- We fixed an issue where the F3 shortcut key does not work without opening the right-click context menu. [#12417](https://github.com/JabRef/jabref/pull/12417) +- We fixed an issue where the F3 shortcut key did not work without opening the right-click context menu. [#12417](https://github.com/JabRef/jabref/pull/12417) - We fixed an issue where a bib file with UFF-8 charset was wrongly loaded with a different charset [forum#5369](https://discourse.jabref.org/t/jabref-5-15-opens-bib-files-with-shift-jis-encoding-instead-of-utf-8/5369/) - We fixed an issue where new entries were inserted in the middle of the table instead of at the end. [#12371](https://github.com/JabRef/jabref/pull/12371) - We fixed an issue where removing the sort from the table did not restore the original order. [#12371](https://github.com/JabRef/jabref/pull/12371)