+ if (document.getElementById('syncProp').checked) {
+ let otherscale = myscale *
+ document.getElementById('mandelbrot.image.' + otherdim).value /
+ document.getElementById('mandelbrot.image.' + owndim).value;
+ document.getElementById(othercoord + '_scale').value = roundCoord(otherscale);
+ let othermax =
+ parseFloat(document.getElementById(othercoord + '_min').value) +
+ parseFloat(document.getElementById(othercoord + '_scale').value);
+ document.getElementById('mandelbrot.last_image.' + othercoord + '_max').value = roundCoord(othermax);
+ }
+}
+
+function checkProportions() {
+ if (!document.getElementById('syncProp').checked) {
+ recalcCoord('Cr', 'scale');
+ }
+}
+
+function roundCoord(floatval) {
+ // We should round to 10 decimals here or so
+ return floatval;
+}
+
+function callDrawImage() {
+ window.opener.drawImage();
+ window.close();