Index: apps/plugins/mandelbrot.c
===================================================================
RCS file: /cvsroot/rockbox/apps/plugins/mandelbrot.c,v
retrieving revision 1.25
diff -p -u -d -r1.25 mandelbrot.c
--- apps/plugins/mandelbrot.c	5 Feb 2006 12:59:07 -0000	1.25
+++ apps/plugins/mandelbrot.c	17 Feb 2006 23:44:38 -0000
@@ -301,7 +301,6 @@ void recalc_parameters(void)
     y_step = (y_max - y_min) / LCD_HEIGHT;
     y_delta = y_step * (LCD_HEIGHT/8);
     step_log2 = ilog2_fp(MIN(x_step, y_step));
-    max_iter = MAX(15, -15 * step_log2 - 45);
 }
 
 void init_mandelbrot_set(void)
@@ -316,6 +315,7 @@ void init_mandelbrot_set(void)
     y_min = -19L<<22;  // -1.1875<<26
     y_max =  19L<<22;  //  1.1875<<26
     recalc_parameters();
+    max_iter = MAX(15, -15 * step_log2 - 45);
 }
 
 void calc_mandelbrot_low_prec(void)
@@ -498,6 +498,7 @@ enum plugin_status plugin_start(struct p
             py_min = 0;
             py_max = LCD_HEIGHT;
             redraw = REDRAW_NONE;
+            rb->button_clear_queue();
         }
 
         button = rb->button_get(true);
