Only use direct children for auto tab calc
This commit is contained in:
parent
467b1dee1d
commit
c41ed866cd
@ -258,19 +258,17 @@ public abstract class FinSetConfig extends RocketComponentConfig {
|
||||
|
||||
List<CenteringRing> rings = new ArrayList<>();
|
||||
// Do deep recursive iteration to find centering rings and determine radius of inner tube
|
||||
Iterator<RocketComponent> iter = parent.iterator(false);
|
||||
while (iter.hasNext()) {
|
||||
RocketComponent rocketComponent = iter.next();
|
||||
if (rocketComponent instanceof InnerTube) {
|
||||
if (!isComponentInsideFinSpan(rocketComponent)) {
|
||||
for (RocketComponent child : parent.getChildren()) {
|
||||
if (child instanceof InnerTube) {
|
||||
if (!isComponentInsideFinSpan(child)) {
|
||||
continue;
|
||||
}
|
||||
InnerTube tube = (InnerTube) rocketComponent;
|
||||
InnerTube tube = (InnerTube) child;
|
||||
if (tube.getOuterRadius() > maxTubeRad) {
|
||||
maxTubeRad = tube.getOuterRadius();
|
||||
}
|
||||
} else if (rocketComponent instanceof CenteringRing) {
|
||||
CenteringRing ring = (CenteringRing) rocketComponent;
|
||||
} else if (child instanceof CenteringRing) {
|
||||
CenteringRing ring = (CenteringRing) child;
|
||||
if (ring.getOuterRadius() > maxRingRad) {
|
||||
maxRingRad = ring.getOuterRadius();
|
||||
}
|
||||
@ -295,9 +293,9 @@ public abstract class FinSetConfig extends RocketComponentConfig {
|
||||
//Be nice to the user and set the tab relative position enum back the way they had it.
|
||||
tabOffsetMethod.setSelectedItem(temp);
|
||||
} else {
|
||||
tabLength.setValue(component.getLength());
|
||||
tabOffsetMethod.setSelectedItem(AxialMethod.TOP);
|
||||
tabOffset.setValue(0);
|
||||
tabLength.setValue(component.getLength());
|
||||
}
|
||||
|
||||
// Compute tab height
|
||||
|
Loading…
x
Reference in New Issue
Block a user