From ab450a81ec1d81d3ea92a5b14edd2265fc2227ea Mon Sep 17 00:00:00 2001 From: Tomer Shalev Date: Sun, 17 Jan 2010 21:15:56 +0000 Subject: Fractals: Prevent zooming more than deepest possible zoom This prevent the mandelbrost set from being trashed if zooming too much git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24264 a1c6a512-1295-4272-9138-f99709370657 --- apps/plugins/fractals/fractal.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'apps/plugins/fractals/fractal.c') diff --git a/apps/plugins/fractals/fractal.c b/apps/plugins/fractals/fractal.c index aa8f39853c..7543963ded 100644 --- a/apps/plugins/fractals/fractal.c +++ b/apps/plugins/fractals/fractal.c @@ -167,8 +167,8 @@ enum plugin_status plugin_start(const void* parameter) if (lastbutton != FRACTAL_ZOOM_OUT_PRE) break; #endif - ops->zoom(-1); - redraw = REDRAW_FULL; + if (!ops->zoom(-1)) + redraw = REDRAW_FULL; break; @@ -180,8 +180,8 @@ enum plugin_status plugin_start(const void* parameter) #ifdef FRACTAL_ZOOM_IN2 case FRACTAL_ZOOM_IN2: #endif - ops->zoom(1); - redraw = REDRAW_FULL; + if (!ops->zoom(1)) + redraw = REDRAW_FULL; break; case FRACTAL_UP: -- cgit v1.2.3