summaryrefslogtreecommitdiff
path: root/libjava/java/awt/BorderLayout.java
diff options
context:
space:
mode:
Diffstat (limited to 'libjava/java/awt/BorderLayout.java')
-rw-r--r--libjava/java/awt/BorderLayout.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/libjava/java/awt/BorderLayout.java b/libjava/java/awt/BorderLayout.java
index 5033bcf7ab2..7f2b1a00802 100644
--- a/libjava/java/awt/BorderLayout.java
+++ b/libjava/java/awt/BorderLayout.java
@@ -637,7 +637,7 @@ private static final int PREF = 2;
private Dimension
calcCompSize(Component comp, int what)
{
- if (comp == null)
+ if (comp == null || !comp.isVisible())
return new Dimension(0, 0);
if (what == MIN)
return comp.getMinimumSize();