Skip to content

Commit

Permalink
Fix menu bar gone on macOS (JabRef#10967)
Browse files Browse the repository at this point in the history
* Fix menu bar gone on macOS

Fixes JabRef#10966

was introduced in bec55f8

* Add comment

---------

Co-authored-by: Oliver Kopp <[email protected]>
  • Loading branch information
Siedlerchr and koppor authored Mar 4, 2024
1 parent 8f46463 commit f1c099c
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/main/java/org/jabref/preferences/JabRefPreferences.java
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@
import org.jabref.gui.Globals;
import org.jabref.gui.autocompleter.AutoCompleteFirstNameMode;
import org.jabref.gui.autocompleter.AutoCompletePreferences;
import org.jabref.gui.desktop.JabRefDesktop;
import org.jabref.gui.duplicationFinder.DuplicateResolverDialog;
import org.jabref.gui.entryeditor.EntryEditorPreferences;
import org.jabref.gui.externalfiletype.ExternalFileType;
Expand Down Expand Up @@ -712,7 +711,6 @@ private JabRefPreferences() {
defaults.put(WARN_BEFORE_OVERWRITING_KEY, Boolean.TRUE);
defaults.put(CONFIRM_DELETE, Boolean.TRUE);
defaults.put(CONFIRM_LINKED_FILE_DELETE, Boolean.TRUE);
defaults.put(TRASH_INSTEAD_OF_DELETE, JabRefDesktop.moveToTrashSupported());
defaults.put(DEFAULT_CITATION_KEY_PATTERN, "[auth][year]");
defaults.put(UNWANTED_CITATION_KEY_CHARACTERS, "-`ʹ:!;?^+");
defaults.put(RESOLVE_STRINGS_FOR_FIELDS, "author;booktitle;editor;editora;editorb;editorc;institution;issuetitle;journal;journalsubtitle;journaltitle;mainsubtitle;month;publisher;shortauthor;shorteditor;subtitle;titleaddon");
Expand Down Expand Up @@ -2209,7 +2207,8 @@ public FilePreferences getFilePreferences() {
// We choose the data directory, because a ".bak" file should survive cache cleanups
getPath(BACKUP_DIRECTORY, OS.getNativeDesktop().getBackupDirectory()),
getBoolean(CONFIRM_LINKED_FILE_DELETE),
getBoolean(TRASH_INSTEAD_OF_DELETE));
// We make use of the fallback, because we need AWT being initialized, which is not the case at the constructor JabRefPreferences()
getBoolean(TRASH_INSTEAD_OF_DELETE, OS.getNativeDesktop().moveToTrashSupported()));

EasyBind.listen(getInternalPreferences().getUserAndHostProperty(), (obs, oldValue, newValue) -> filePreferences.getUserAndHostProperty().setValue(newValue));
EasyBind.listen(filePreferences.mainFileDirectoryProperty(), (obs, oldValue, newValue) -> put(MAIN_FILE_DIRECTORY, newValue));
Expand Down

0 comments on commit f1c099c

Please sign in to comment.