Fractal::Point newcentre = (TR+BL)/(Fractal::Value)2.0;
Fractal::Point newsize = TR-BL;
main->update_params(newcentre, newsize);
- main->new_centre_checked( newcentre );
+ main->new_centre_checked( newcentre, false );
main->do_plot(false);
}
return true;
// LP#1033910: Go ahead with a recentring zoom if at max, as we need to replot anyway
// (but won't actually zoom).
zoom_mechanics(type);
- new_centre_checked(newcentre);
+ new_centre_checked(newcentre, true);
do_plot(false);
}
void MainWindow::update_params(Fractal::Point& ncentre, Fractal::Point& nsize)
{
size = nsize;
- new_centre_checked(ncentre);
+ new_centre_checked(ncentre, false);
}
-void MainWindow::new_centre_checked(const Fractal::Point& ncentre)
+void MainWindow::new_centre_checked(const Fractal::Point& ncentre, bool is_zoom)
{
centre = ncentre;
Fractal::Point halfsize = size/2.0;
BL = centre - halfsize;
bool clipped = false;
+ if (!is_zoom)
+ at_min_zoom = at_max_zoom = false;
+ // if is_zoom, those mechanics check and update the min/max flags.
+
if (real(TR) > fractal->xmax) {
Fractal::Point shift(fractal->xmax-real(TR), 0);
centre += shift; TR += shift; BL += shift;
bool is_aspect_fixed() const { return aspectfix; }
void update_params(Fractal::Point& centre, Fractal::Point& size);
- void new_centre_checked(const Fractal::Point& centre);
+ void new_centre_checked(const Fractal::Point& centre, bool is_zoom);
void do_zoom(enum Zoom z);
void do_zoom(enum Zoom z, const Fractal::Point& newcentre);