From 6c69559ae61380b298a6c2afa0b321ecee5a6bfb Mon Sep 17 00:00:00 2001 From: =?utf8?q?David=20=E2=80=98Bombe=E2=80=99=20Roden?= Date: Sun, 26 May 2013 14:01:12 +0200 Subject: [PATCH] Use a box instead of a panel. --- src/main/java/net/pterodactylus/sonitus/gui/ControlledPane.java | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/main/java/net/pterodactylus/sonitus/gui/ControlledPane.java b/src/main/java/net/pterodactylus/sonitus/gui/ControlledPane.java index cfc5f83..010fa3a 100644 --- a/src/main/java/net/pterodactylus/sonitus/gui/ControlledPane.java +++ b/src/main/java/net/pterodactylus/sonitus/gui/ControlledPane.java @@ -19,7 +19,6 @@ package net.pterodactylus.sonitus.gui; import javax.swing.Box; import javax.swing.BoxLayout; -import javax.swing.JPanel; import net.pterodactylus.sonitus.data.Controlled; import net.pterodactylus.sonitus.data.Controller; @@ -32,7 +31,7 @@ import net.pterodactylus.sonitus.data.controller.Switch; * * @author David ‘Bombe’ Roden */ -public class ControlledPane extends JPanel { +public class ControlledPane extends Box { /** * Creates a new controlled pane. @@ -41,7 +40,7 @@ public class ControlledPane extends JPanel { * The controlled whose controllers to display */ public ControlledPane(Controlled controlled) { - setLayout(new BoxLayout(this, BoxLayout.Y_AXIS)); + super(BoxLayout.Y_AXIS); for (Controller controller : controlled.controllers()) { if (controller instanceof Fader) { add(new FaderPanel((Fader) controller)); -- 2.7.4