Numerous bug fixes and updates
[debian/openrocket] / src / net / sf / openrocket / gui / configdialog / FreeformFinSetConfig.java
index 889d4adf61786de2cbcd3a931e5c92c55d0bb957..18b18032aee09a0f0f619f19c24e7b762ac25296 100644 (file)
@@ -30,6 +30,7 @@ import net.sf.openrocket.gui.scalefigure.ScaleSelector;
 import net.sf.openrocket.material.Material;
 import net.sf.openrocket.rocketcomponent.FinSet;
 import net.sf.openrocket.rocketcomponent.FreeformFinSet;
+import net.sf.openrocket.rocketcomponent.IllegalFinPointException;
 import net.sf.openrocket.rocketcomponent.RocketComponent;
 import net.sf.openrocket.unit.UnitGroup;
 import net.sf.openrocket.util.Coordinate;
@@ -208,7 +209,7 @@ public class FreeformFinSetConfig extends FinSetConfig {
 //             panel.add(new JLabel("    View:"), "wrap, aligny bottom");
                
                
-               panel.add(tablePane,"growy, width :100lp:, height 100lp:250lp:");
+               panel.add(tablePane,"growy, width 100lp:100lp:, height 100lp:250lp:");
                panel.add(figurePane,"gap unrel, spanx, growx, growy 1000, height 100lp:250lp:, wrap");
                
                panel.add(new ResizeLabel("Double-click", -2), "alignx 50%");
@@ -275,7 +276,7 @@ public class FreeformFinSetConfig extends FinSetConfig {
                                finset.addPoint(index);
                                try {
                                        finset.setPoint(index, point.x, point.y);
-                               } catch (IllegalArgumentException ignore) { }
+                               } catch (IllegalFinPointException ignore) { }
                                dragIndex = index;
                                
                                return;
@@ -299,7 +300,7 @@ public class FreeformFinSetConfig extends FinSetConfig {
                        
                        try {
                                finset.setPoint(dragIndex, point.x, point.y);
-                       } catch (IllegalArgumentException ignore) {
+                       } catch (IllegalFinPointException ignore) {
                                System.out.println("IAE:"+ignore);
                        }
                }
@@ -328,7 +329,7 @@ public class FreeformFinSetConfig extends FinSetConfig {
 
                        try {
                                finset.removePoint(index);
-                       } catch (IllegalArgumentException ignore) {
+                       } catch (IllegalFinPointException ignore) {
                        }
                }
                
@@ -462,6 +463,7 @@ public class FreeformFinSetConfig extends FinSetConfig {
                                finset.setPoint(rowIndex, c.x, c.y);
                        
                        } catch (NumberFormatException ignore) {
+                       } catch (IllegalFinPointException ignore) {
                        }
                }