diff options
-rw-r--r-- | apps/plugins/fractals/fractal.c | 25 |
1 files changed, 16 insertions, 9 deletions
diff --git a/apps/plugins/fractals/fractal.c b/apps/plugins/fractals/fractal.c index 5023b2c450..ff768a9516 100644 --- a/apps/plugins/fractals/fractal.c +++ b/apps/plugins/fractals/fractal.c | |||
@@ -46,9 +46,10 @@ static unsigned char *gbuf; | |||
46 | static size_t gbuf_size = 0; | 46 | static size_t gbuf_size = 0; |
47 | #endif | 47 | #endif |
48 | 48 | ||
49 | #define REDRAW_NONE 0 | 49 | #define REDRAW_NONE 0 |
50 | #define REDRAW_PARTIAL 1 | 50 | #define REDRAW_PARTIAL 1 |
51 | #define REDRAW_FULL 2 | 51 | #define REDRAW_FULL 2 |
52 | #define REDRAW_FULL_OVERLAY 3 | ||
52 | 53 | ||
53 | PLUGIN_HEADER | 54 | PLUGIN_HEADER |
54 | 55 | ||
@@ -139,11 +140,17 @@ enum plugin_status plugin_start(const void* parameter) | |||
139 | #ifdef HAVE_ADJUSTABLE_CPU_FREQ | 140 | #ifdef HAVE_ADJUSTABLE_CPU_FREQ |
140 | rb->cpu_boost(true); | 141 | rb->cpu_boost(true); |
141 | #endif | 142 | #endif |
142 | if (redraw == REDRAW_FULL) | 143 | switch (redraw) |
143 | { | 144 | { |
144 | MYLCD(clear_display)(); | 145 | case REDRAW_FULL: |
145 | MYLCD_UPDATE(); | 146 | MYLCD(clear_display)(); |
146 | rects_queue_init(); | 147 | MYLCD_UPDATE(); |
148 | /* fall-through */ | ||
149 | case REDRAW_FULL_OVERLAY: | ||
150 | rects_queue_init(); | ||
151 | break; | ||
152 | default: | ||
153 | break; | ||
147 | } | 154 | } |
148 | 155 | ||
149 | /* paint all rects */ | 156 | /* paint all rects */ |
@@ -229,7 +236,7 @@ enum plugin_status plugin_start(const void* parameter) | |||
229 | break; | 236 | break; |
230 | #endif | 237 | #endif |
231 | if (ops->precision(-1)) | 238 | if (ops->precision(-1)) |
232 | redraw = REDRAW_FULL; | 239 | redraw = REDRAW_FULL_OVERLAY; |
233 | 240 | ||
234 | break; | 241 | break; |
235 | 242 | ||
@@ -239,7 +246,7 @@ enum plugin_status plugin_start(const void* parameter) | |||
239 | break; | 246 | break; |
240 | #endif | 247 | #endif |
241 | if (ops->precision(+1)) | 248 | if (ops->precision(+1)) |
242 | redraw = REDRAW_FULL; | 249 | redraw = REDRAW_FULL_OVERLAY; |
243 | 250 | ||
244 | break; | 251 | break; |
245 | 252 | ||