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

Moved a few more initialization to GUIGlobals.init() #1756

Merged
merged 1 commit into from
Aug 18, 2016
Merged
Show file tree
Hide file tree
Changes from all 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
3 changes: 0 additions & 3 deletions src/main/java/net/sf/jabref/JabRefGUI.java
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
*/
package net.sf.jabref;

import java.awt.Font;
import java.io.File;
import java.util.ArrayList;
import java.util.Collections;
Expand Down Expand Up @@ -117,8 +116,6 @@ private void openWindow() {
}

GUIGlobals.init();
GUIGlobals.currentFont = new Font(Globals.prefs.get(JabRefPreferences.FONT_FAMILY),
Globals.prefs.getInt(JabRefPreferences.FONT_STYLE), Globals.prefs.getInt(JabRefPreferences.FONT_SIZE));

LOGGER.debug("Initializing frame");
JabRefGUI.mainFrame = new JabRefFrame();
Expand Down
12 changes: 7 additions & 5 deletions src/main/java/net/sf/jabref/gui/GUIGlobals.java
Original file line number Diff line number Diff line change
Expand Up @@ -66,11 +66,6 @@ public class GUIGlobals {
public static final int WIDTH_ICON_COL = 26;
public static final int WIDTH_ICON_COL_RANKING = 80; // Width of Ranking Icon Column

static {
// Set up entry editor colors, first time:
GUIGlobals.updateEntryEditorColors();
}

public static JLabel getTableIcon(String fieldType) {
JLabel label = GUIGlobals.TABLE_ICONS.get(fieldType);
if (label == null) {
Expand Down Expand Up @@ -164,6 +159,13 @@ public static void init() {
if (Globals.prefs.getBoolean(JabRefPreferences.EDITOR_EMACS_KEYBINDINGS)) {
EmacsKeyBindings.load();
}

// Set up entry editor colors, first time:
GUIGlobals.updateEntryEditorColors();

GUIGlobals.currentFont = new Font(Globals.prefs.get(JabRefPreferences.FONT_FAMILY),
Globals.prefs.getInt(JabRefPreferences.FONT_STYLE), Globals.prefs.getInt(JabRefPreferences.FONT_SIZE));

}

}