Disable appearance exporting when triangulation is enabled
This commit is contained in:
parent
c32f524803
commit
29b60d723e
@ -1494,6 +1494,7 @@ OBJOptionChooser.checkbox.exportAppearance = Export appearance
|
|||||||
OBJOptionChooser.checkbox.exportAppearance.ttip = If true, export the component appearances to an MTL file.
|
OBJOptionChooser.checkbox.exportAppearance.ttip = If true, export the component appearances to an MTL file.
|
||||||
OBJOptionChooser.checkbox.exportAsSeparateFiles = Export as separate files
|
OBJOptionChooser.checkbox.exportAsSeparateFiles = Export as separate files
|
||||||
OBJOptionChooser.checkbox.exportAsSeparateFiles.ttip = If true, export each component as a separate OBJ file.
|
OBJOptionChooser.checkbox.exportAsSeparateFiles.ttip = If true, export each component as a separate OBJ file.
|
||||||
|
OBJOptionChooser.checkbox.exportAppearance.ttip.triangulate = You can not export the appearance with the triangulate feature enabled.
|
||||||
OBJOptionChooser.checkbox.removeOffset = Remove origin offset
|
OBJOptionChooser.checkbox.removeOffset = Remove origin offset
|
||||||
OBJOptionChooser.checkbox.removeOffset.ttip = <html>If true, remove the offset of the component from the origin.<br>If false, the component is exported at its original location in the rocket.</html>
|
OBJOptionChooser.checkbox.removeOffset.ttip = <html>If true, remove the offset of the component from the origin.<br>If false, the component is exported at its original location in the rocket.</html>
|
||||||
OBJOptionChooser.btn.showAdvanced = Show Advanced options
|
OBJOptionChooser.btn.showAdvanced = Show Advanced options
|
||||||
|
@ -102,6 +102,22 @@ public class OBJOptionChooser extends JPanel {
|
|||||||
this.triangulate = new JCheckBox(trans.get("OBJOptionChooser.checkbox.triangulate"));
|
this.triangulate = new JCheckBox(trans.get("OBJOptionChooser.checkbox.triangulate"));
|
||||||
this.triangulate.setToolTipText(trans.get("OBJOptionChooser.checkbox.triangulate.ttip"));
|
this.triangulate.setToolTipText(trans.get("OBJOptionChooser.checkbox.triangulate.ttip"));
|
||||||
advancedOptionsPanel.add(triangulate, "spanx, wrap");
|
advancedOptionsPanel.add(triangulate, "spanx, wrap");
|
||||||
|
this.triangulate.addItemListener(new ItemListener() {
|
||||||
|
@Override
|
||||||
|
public void itemStateChanged(ItemEvent e) {
|
||||||
|
if (e.getStateChange() == ItemEvent.SELECTED) {
|
||||||
|
// Disable the export appearance, it is not supported in combination with triangulate
|
||||||
|
exportAppearance.setEnabled(false);
|
||||||
|
exportAppearance.setSelected(false);
|
||||||
|
exportAppearance.setToolTipText(trans.get("OBJOptionChooser.checkbox.exportAppearance.ttip.triangulate"));
|
||||||
|
} else {
|
||||||
|
// Re-enable
|
||||||
|
exportAppearance.setEnabled(true);
|
||||||
|
exportAppearance.setSelected(opts.isExportAppearance());
|
||||||
|
exportAppearance.setToolTipText(trans.get("OBJOptionChooser.checkbox.exportAppearance.ttip"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
//// Level of detail
|
//// Level of detail
|
||||||
JLabel LODLabel = new JLabel(trans.get("OBJOptionChooser.lbl.LevelOfDetail"));
|
JLabel LODLabel = new JLabel(trans.get("OBJOptionChooser.lbl.LevelOfDetail"));
|
||||||
|
Loading…
x
Reference in New Issue
Block a user