From 52c14c4d243e5b1f18c99f78ee8a87223e7ef166 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lucas=20Ple=C3=9F?= Date: Fri, 15 Jun 2012 10:39:04 +0200 Subject: [PATCH] changed layout to behave better on resize --- src/de/ctdo/crashtest/cardplayer/MainFrame.java | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/de/ctdo/crashtest/cardplayer/MainFrame.java b/src/de/ctdo/crashtest/cardplayer/MainFrame.java index 7cb3073..cf632de 100644 --- a/src/de/ctdo/crashtest/cardplayer/MainFrame.java +++ b/src/de/ctdo/crashtest/cardplayer/MainFrame.java @@ -43,10 +43,6 @@ public class MainFrame extends JFrame { }); JScrollPane listScroller = new JScrollPane(jListWall); - listScroller.setPreferredSize(new Dimension(600, 500)); - - contentPane.setLayout(new BorderLayout()); - contentPane.add(listScroller, BorderLayout.WEST); Vector states = new Vector(); states.add("IDLE"); @@ -78,7 +74,11 @@ public class MainFrame extends JFrame { } }); - listScroller = new JScrollPane(jListStates); + JScrollPane listScroller2 = new JScrollPane(jListStates); + listScroller2.setPreferredSize(new Dimension(150, 500)); + + contentPane.setLayout(new BorderLayout()); + contentPane.add(listScroller2, BorderLayout.EAST); contentPane.add(listScroller); pack();