Fix split location problem

This commit is contained in:
2020-01-12 15:01:22 +00:00
parent b6063d2fed
commit 2f9abf7629

View File

@@ -773,6 +773,7 @@ public class AudiobookRecorder extends JFrame {
mainScroll = new JScrollPane();
notesArea = new JTextArea();
notesArea.setFont(new Font("Monospaced", Font.PLAIN, 10));
notesScroll = new JScrollPane();
notesScroll.setViewportView(notesArea);
@@ -800,10 +801,17 @@ public class AudiobookRecorder extends JFrame {
bindKeys(centralPanel);
mainSplit.setResizeWeight(0.8d);
pack();
mainSplit.setDividerLocation(0.8d);
setVisible(true);
SwingUtilities.invokeLater(new Runnable() {
public void run() {
mainSplit.setDividerLocation(0.8d);
}
});
String lastBook = Options.get("path.last-book");
if (lastBook != null && !lastBook.equals("")) {