From 0f9c8deebbe51a3413b7a1b88245a4ac38923e9c Mon Sep 17 00:00:00 2001
From: Lee <irina.lee@etu.upmc.fr>
Date: Thu, 12 Jul 2018 23:14:05 +0200
Subject: [PATCH] up (eln)

---
 src/main/java/ui/eln/ELNModule.java                     | 1 +
 src/main/java/ui/eln/sca_eln/ELNComponentCapacitor.java | 6 +++++-
 2 files changed, 6 insertions(+), 1 deletion(-)

diff --git a/src/main/java/ui/eln/ELNModule.java b/src/main/java/ui/eln/ELNModule.java
index 7a1a6b9986..517a64c6fb 100644
--- a/src/main/java/ui/eln/ELNModule.java
+++ b/src/main/java/ui/eln/ELNModule.java
@@ -40,6 +40,7 @@ package ui.eln;
 
 import myutil.GraphicLib;
 import ui.*;
+import ui.eln.sca_eln.ELNComponentCapacitor;
 import ui.eln.sca_eln.ELNComponentNodeRef;
 
 import java.awt.*;
diff --git a/src/main/java/ui/eln/sca_eln/ELNComponentCapacitor.java b/src/main/java/ui/eln/sca_eln/ELNComponentCapacitor.java
index ea2504effe..53ca177560 100644
--- a/src/main/java/ui/eln/sca_eln/ELNComponentCapacitor.java
+++ b/src/main/java/ui/eln/sca_eln/ELNComponentCapacitor.java
@@ -58,7 +58,7 @@ import java.awt.event.ActionListener;
  * @author Irina Kit Yan LEE
  */
 
-public class ELNComponentCapacitor extends TGCScalableWithInternalComponent	implements ActionListener, SwallowTGComponent, ELNComponent {
+public class ELNComponentCapacitor extends TGCScalableWithInternalComponent	implements ActionListener, SwallowTGComponent, SwallowedTGComponent, ELNComponent {
 	protected Color myColor;
 	protected int orientation;
 	private int maxFontSize = 14;
@@ -755,6 +755,10 @@ public class ELNComponentCapacitor extends TGCScalableWithInternalComponent	impl
 				tgcomponent[i].resizeWithFather();
 			}
 		}
+		
+		if (getFather() != null) {
+			resizeWithFather();
+		}
 	}
 	
 	public void resizeWithFather() {
-- 
GitLab