remove unused code

This commit is contained in:
casperlamboo 2017-12-04 19:31:09 +01:00
parent 3dfce6a610
commit 31073e7122
2 changed files with 3 additions and 7 deletions

View File

@ -24,10 +24,7 @@ const jsonLoader = new THREE.JSONLoader();
jsonLoader.load(fileURL, geometry => { jsonLoader.load(fileURL, geometry => {
render(( render((
<MuiThemeProvider> <MuiThemeProvider>
<Interface <Interface geometry={geometry}/>
geometry={geometry}
onCompleteActions={[{ title: 'Download', callback: downloadGCode }]}
/>
</MuiThemeProvider> </MuiThemeProvider>
), document.getElementById('app')); ), document.getElementById('app'));
}); });

View File

@ -82,7 +82,6 @@ class Interface extends React.Component {
} }
}, },
classes: PropTypes.objectOf(PropTypes.string), classes: PropTypes.objectOf(PropTypes.string),
onCompleteActions: PropTypes.arrayOf(PropTypes.shape({ title: PropTypes.string, callback: PropTypes.func })).isRequired,
defaultSettings: PropTypes.object.isRequired, defaultSettings: PropTypes.object.isRequired,
printers: PropTypes.object.isRequired, printers: PropTypes.object.isRequired,
defaultPrinter: PropTypes.string.isRequired, defaultPrinter: PropTypes.string.isRequired,
@ -227,8 +226,8 @@ class Interface extends React.Component {
}; };
render() { render() {
const { classes, onCompleteActions, defaultPrinter, defaultQuality, defaultMaterial } = this.props; const { classes, defaultPrinter, defaultQuality, defaultMaterial, onCancel } = this.props;
const { isSlicing, progress, gcode, settings, printers, quality, material, showFullScreen, error } = this.state; const { isSlicing, progress, settings, printers, quality, material, showFullScreen, error } = this.state;
const percentage = progress ? (progress.uploading + progress.slicing) / 2.0 * 100.0 : 0.0; const percentage = progress ? (progress.uploading + progress.slicing) / 2.0 * 100.0 : 0.0;