Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Searching for an entry on the web shouldn't take forever #9199

Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,9 @@ public ImportEntriesViewModel(BackgroundTask<ParserResult> task,
this.parserResult = parserResult;
// fill in the list for the user, where one can select the entries to import
entries.addAll(parserResult.getDatabase().getEntries());
if (entries.isEmpty()) {
task.updateMessage(Localization.lang("No entries corresponding to given query"));
}
}).onFailure(ex -> {
LOGGER.error("Error importing", ex);
dialogService.showErrorDialogAndWait(ex);
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/org/jabref/gui/util/BackgroundTask.java
Original file line number Diff line number Diff line change
Expand Up @@ -257,7 +257,7 @@ protected void updateProgress(double workDone, double max) {
updateProgress(new BackgroundProgress(workDone, max));
}

protected void updateMessage(String newMessage) {
public void updateMessage(String newMessage) {
message.setValue(newMessage);
}

Expand Down
2 changes: 2 additions & 0 deletions src/main/resources/l10n/JabRef_en.properties
Original file line number Diff line number Diff line change
Expand Up @@ -2508,3 +2508,5 @@ The\ %0s\ are\ the\ same.\ However,\ the\ order\ of\ field\ content\ differs=The
Keep\ from\ import=Keep from import
Keep\ merged=Keep merged
Keep\ old\ entry=Keep old entry

No\ entries\ corresponding\ to\ given\ query=No entries corresponding to given query