Skip to content

Commit

Permalink
Enable journal information fetcher directly in popup (JabRef#10598)
Browse files Browse the repository at this point in the history
* fix-for-issue-10458

* l10n and minor code tweak

* CHANGELOG.md

* fix l10n

---------

Co-authored-by: Christoph <[email protected]>
Co-authored-by: Carl Christian Snethlage <[email protected]>
  • Loading branch information
3 people authored Nov 4, 2023
1 parent ec81fc6 commit 5b34fe8
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 6 deletions.
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ Note that this project **does not** adhere to [Semantic Versioning](https://semv

- We fixed an issue where the added protected term has unwanted leading and trailing whitespaces, where the formatted text has unwanted empty brackets and where the word at the cursor in the textbox can be added to the list. [#10415](https://github.com/JabRef/jabref/issues/10415)
- We fixed an issue where in the merge dialog the file field of entries was not correctly merged when the first and second entry both contained values inside the file field. [#10572](https://github.com/JabRef/jabref/issues/10572)
- We fixed some small inconsistencies in the user interface. [#10507](https://github.com/JabRef/jabref/issues/10507)
- We fixed some small inconsistencies in the user interface. [#10507](https://github.com/JabRef/jabref/issues/10507) [#10458](https://github.com/JabRef/jabref/issues/10458)

### Removed

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,18 @@ public static boolean isJournalInfoEnabled(DialogService dialogService, EntryEdi
}

if (preferences.shouldEnableJournalPopup() == EntryEditorPreferences.JournalPopupEnabled.DISABLED) {
dialogService.notify(
Localization.lang("Please enable journal information fetching in %0 > %1",
boolean enableJournalPopup = dialogService.showConfirmationDialogAndWait(
Localization.lang("Enable Journal Information Fetching?"),
Localization.lang("Would you like to enable fetching of journal information? This can be changed later in %0 > %1.",
Localization.lang("Preferences"),
Localization.lang("Web search"))
Localization.lang("Entry editor")), Localization.lang("Enable"), Localization.lang("Keep disabled")
);
return false;

preferences.setEnableJournalPopup(enableJournalPopup
? EntryEditorPreferences.JournalPopupEnabled.ENABLED
: EntryEditorPreferences.JournalPopupEnabled.DISABLED);

return enableJournalPopup;
}

boolean journalInfoEnabled = dialogService.showConfirmationDialogAndWait(
Expand Down
8 changes: 7 additions & 1 deletion src/main/resources/l10n/JabRef_en.properties
Original file line number Diff line number Diff line change
Expand Up @@ -477,7 +477,6 @@ Year=Year
ISSN\ or\ journal\ name\ required\ for\ fetching\ journal\ information=ISSN or journal name required for fetching journal information
Fetch\ journal\ information\ online\ to\ show=Fetch journal information online to show
Allow\ sending\ ISSN\ to\ a\ JabRef\ online\ service\ (SCimago)\ for\ fetching\ journal\ information=Allow sending ISSN to a JabRef online service (SCimago) for fetching journal information
Please\ enable\ journal\ information\ fetching\ in\ %0\ >\ %1=Please enable journal information fetching in %0 > %1
Categories=Categories
ISSN=ISSN
Publisher=Publisher
Expand Down Expand Up @@ -2605,3 +2604,10 @@ Pushing\ citations\ to\ TeXShop\ is\ only\ possible\ on\ macOS\!=Pushing citatio
Single\ instance=Single instance
Enforce\ single\ JabRef\ instance\ (and\ allow\ remote\ operations)\ using\ port=Enforce single JabRef instance (and allow remote operations) using port
Enable\ Journal\ Information\ Fetching?=Enable Journal Information Fetching?
Would\ you\ like\ to\ enable\ fetching\ of\ journal\ information?\ This\ can\ be\ changed\ later\ in\ %0\ >\ %1.=Would you like to enable fetching of journal information? This can be changed later in %0 > %1.
Enable=Enable
Keep\ disabled=Keep disabled

0 comments on commit 5b34fe8

Please sign in to comment.