summaryrefslogtreecommitdiff
path: root/apps/plugins
diff options
context:
space:
mode:
authorAndree Buschmann <AndreeBuschmann@t-online.de>2011-05-01 14:44:20 +0000
committerAndree Buschmann <AndreeBuschmann@t-online.de>2011-05-01 14:44:20 +0000
commit27d153db930a231718a18ec5a886c8789077c83a (patch)
tree9d29fd6c1348f3ca1742774cb242177b3d0ca82b /apps/plugins
parentf7c45941344ecfbcdd5d9b311b61573d37c6ef58 (diff)
downloadrockbox-27d153db930a231718a18ec5a886c8789077c83a.zip
rockbox-27d153db930a231718a18ec5a886c8789077c83a.tar.gz
rockbox-27d153db930a231718a18ec5a886c8789077c83a.tar.bz2
rockbox-27d153db930a231718a18ec5a886c8789077c83a.tar.xz
Fix nearly all residual 'variable set but not used' warnings reported from GCC 4.6.0.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29810 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/plugins')
-rw-r--r--apps/plugins/chessbox/chessbox.c7
-rw-r--r--apps/plugins/cube.c8
-rw-r--r--apps/plugins/flipit.c6
-rw-r--r--apps/plugins/fractals/fractal.c11
-rw-r--r--apps/plugins/oscilloscope.c6
-rw-r--r--apps/plugins/rockblox.c4
-rw-r--r--apps/plugins/sliding_puzzle.c4
-rw-r--r--apps/plugins/star.c8
-rw-r--r--apps/plugins/text_viewer/text_viewer.c4
-rw-r--r--apps/plugins/vu_meter.c4
10 files changed, 59 insertions, 3 deletions
diff --git a/apps/plugins/chessbox/chessbox.c b/apps/plugins/chessbox/chessbox.c
index 6e77b62..6437c8d 100644
--- a/apps/plugins/chessbox/chessbox.c
+++ b/apps/plugins/chessbox/chessbox.c
@@ -641,7 +641,10 @@ static int cb_menu(void)
struct cb_command cb_getcommand (void) {
static short x = 4 , y = 3 ;
short c , r , l;
- int button, lastbutton = BUTTON_NONE;
+ int button;
+#if defined(CB_PLAY_PRE) || defined(CB_SELECT_PRE)
+ int lastbutton = BUTTON_NONE;
+#endif
int marked = false , from_marked = false ;
short marked_x = 0 , marked_y = 0 ;
struct cb_command result = { 0, {0,0,0,0,0}, 0 };
@@ -761,8 +764,10 @@ struct cb_command cb_getcommand (void) {
}
break;
}
+#if defined(CB_PLAY_PRE) || defined(CB_SELECT_PRE)
if (button != BUTTON_NONE)
lastbutton = button;
+#endif
}
}
diff --git a/apps/plugins/cube.c b/apps/plugins/cube.c
index 6d0e14f..9540023 100644
--- a/apps/plugins/cube.c
+++ b/apps/plugins/cube.c
@@ -649,7 +649,11 @@ enum plugin_status plugin_start(const void* parameter)
#endif
int button;
+#if defined(CUBE_MODE_PRE) || \
+ defined(CUBE_PAUSE_PRE) || \
+ defined(CUBE_HIGHSPEED_PRE)
int lastbutton = BUTTON_NONE;
+#endif
int curr = 0;
bool highspeed = false;
bool paused = false;
@@ -855,8 +859,12 @@ enum plugin_status plugin_start(const void* parameter)
exit_on_usb(button);
break;
}
+#if defined(CUBE_MODE_PRE) || \
+ defined(CUBE_PAUSE_PRE) || \
+ defined(CUBE_HIGHSPEED_PRE)
if (button != BUTTON_NONE)
lastbutton = button;
+#endif
}
return PLUGIN_OK;
diff --git a/apps/plugins/flipit.c b/apps/plugins/flipit.c
index a837b1a..a61839c 100644
--- a/apps/plugins/flipit.c
+++ b/apps/plugins/flipit.c
@@ -615,7 +615,10 @@ static bool flipit_loop(void)
{
int i;
int button;
+#if defined(FLIPIT_SOLVE_PRE) || defined(FLIPIT_STEP_PRE) || \
+ defined(FLIPIT_TOGGLE_PRE) || defined(FLIPIT_UP_PRE)
int lastbutton = BUTTON_NONE;
+#endif
flipit_init();
while(true) {
@@ -729,8 +732,11 @@ static bool flipit_loop(void)
return PLUGIN_USB_CONNECTED;
break;
}
+#if defined(FLIPIT_SOLVE_PRE) || defined(FLIPIT_STEP_PRE) || \
+ defined(FLIPIT_TOGGLE_PRE) || defined(FLIPIT_UP_PRE)
if (button != BUTTON_NONE)
lastbutton = button;
+#endif
}
}
diff --git a/apps/plugins/fractals/fractal.c b/apps/plugins/fractals/fractal.c
index 21d3338..5d8413c 100644
--- a/apps/plugins/fractals/fractal.c
+++ b/apps/plugins/fractals/fractal.c
@@ -93,7 +93,12 @@ static void cleanup(void)
enum plugin_status plugin_start(const void* parameter)
{
+#if defined(FRACTAL_ZOOM_OUT_PRE) || \
+ defined(FRACTAL_ZOOM_IN_PRE) || \
+ defined(FRACTAL_PRECISION_DEC_PRE) || \
+ defined(FRACTAL_PRECISION_INC)
long lastbutton = BUTTON_NONE;
+#endif
int redraw = REDRAW_FULL;
struct fractal_ops *ops = &mandelbrot_ops;
@@ -246,9 +251,13 @@ enum plugin_status plugin_start(const void* parameter)
exit_on_usb(button);
break;
}
-
+#if defined(FRACTAL_ZOOM_OUT_PRE) || \
+ defined(FRACTAL_ZOOM_IN_PRE) || \
+ defined(FRACTAL_PRECISION_DEC_PRE) || \
+ defined(FRACTAL_PRECISION_INC)
if (button != BUTTON_NONE)
lastbutton = button;
+#endif
}
return PLUGIN_OK;
}
diff --git a/apps/plugins/oscilloscope.c b/apps/plugins/oscilloscope.c
index c55948d..07bf1da 100644
--- a/apps/plugins/oscilloscope.c
+++ b/apps/plugins/oscilloscope.c
@@ -786,7 +786,9 @@ void cleanup(void)
enum plugin_status plugin_start(const void* parameter)
{
int button, vol;
+#if defined(OSCILLOSCOPE_DRAWMODE_PRE) || defined(OSCILLOSCOPE_ORIENTATION_PRE)
int lastbutton = BUTTON_NONE;
+#endif
bool exit = false;
bool paused = false;
bool tell_speed;
@@ -917,9 +919,11 @@ enum plugin_status plugin_start(const void* parameter)
exit_on_usb(button);
break;
}
+#if defined(OSCILLOSCOPE_DRAWMODE_PRE) || defined(OSCILLOSCOPE_ORIENTATION_PRE)
if (button != BUTTON_NONE)
lastbutton = button;
-
+#endif
+
if (tell_speed)
{
rb->snprintf(message, sizeof(message), "%s%d",
diff --git a/apps/plugins/rockblox.c b/apps/plugins/rockblox.c
index b3767c1..dd0bef8 100644
--- a/apps/plugins/rockblox.c
+++ b/apps/plugins/rockblox.c
@@ -1332,7 +1332,9 @@ static int rockblox_menu(void)
static int rockblox_loop (void)
{
int button;
+#if defined(ROCKBLOX_OFF_PRE) || defined(ROCKBLOX_DROP_PRE)
int lastbutton = BUTTON_NONE;
+#endif
long next_down_tick = *rb->current_tick + level_speed(rockblox_status.level);
if (rockblox_menu()) {
@@ -1450,8 +1452,10 @@ static int rockblox_loop (void)
return PLUGIN_USB_CONNECTED;
break;
}
+#if defined(ROCKBLOX_OFF_PRE) || defined(ROCKBLOX_DROP_PRE)
if (button != BUTTON_NONE)
lastbutton = button;
+#endif
#ifdef HAVE_SCROLLWHEEL
/* check if we should enable the scroll wheel, if events
diff --git a/apps/plugins/sliding_puzzle.c b/apps/plugins/sliding_puzzle.c
index aeac96d..92c9db7 100644
--- a/apps/plugins/sliding_puzzle.c
+++ b/apps/plugins/sliding_puzzle.c
@@ -618,7 +618,9 @@ static void puzzle_init(void)
static int puzzle_loop(void)
{
int button;
+#if defined(PUZZLE_SHUFFLE_PICTURE_PRE)
int lastbutton = BUTTON_NONE;
+#endif
bool load_success;
puzzle_init();
@@ -689,8 +691,10 @@ static int puzzle_loop(void)
return PLUGIN_USB_CONNECTED;
break;
}
+#if defined(PUZZLE_SHUFFLE_PICTURE_PRE)
if (button != BUTTON_NONE)
lastbutton = button;
+#endif
}
}
diff --git a/apps/plugins/star.c b/apps/plugins/star.c
index 3506f4b..c9797fd 100644
--- a/apps/plugins/star.c
+++ b/apps/plugins/star.c
@@ -945,7 +945,11 @@ static int star_run_game(int current_level)
int move_x = 0;
int move_y = 0;
int key;
+#if defined(STAR_LEVEL_DOWN_PRE) || \
+ defined(STAR_LEVEL_UP_PRE) || \
+ defined(STAR_TOGGLE_CONTROL_PRE)
int lastkey = BUTTON_NONE;
+#endif
if (!star_load_level(current_level))
return 0;
@@ -1033,8 +1037,12 @@ static int star_run_game(int current_level)
}
break;
}
+#if defined(STAR_LEVEL_DOWN_PRE) || \
+ defined(STAR_LEVEL_UP_PRE) || \
+ defined(STAR_TOGGLE_CONTROL_PRE)
if (key != BUTTON_NONE)
lastkey = key;
+#endif
}
if (control == STAR_CONTROL_BALL)
diff --git a/apps/plugins/text_viewer/text_viewer.c b/apps/plugins/text_viewer/text_viewer.c
index 3c04499..29a2e6d 100644
--- a/apps/plugins/text_viewer/text_viewer.c
+++ b/apps/plugins/text_viewer/text_viewer.c
@@ -31,7 +31,9 @@
enum plugin_status plugin_start(const void* file)
{
int button;
+#if defined(TV_AUTOSCROLL_PRE)
int lastbutton = BUTTON_NONE;
+#endif
bool autoscroll = false;
long old_tick;
bool done = false;
@@ -211,7 +213,9 @@ enum plugin_status plugin_start(const void* file)
}
if (button != BUTTON_NONE)
{
+#if defined(TV_AUTOSCROLL_PRE)
lastbutton = button;
+#endif
rb->yield();
}
if (autoscroll)
diff --git a/apps/plugins/vu_meter.c b/apps/plugins/vu_meter.c
index 8877d7f..5266214 100644
--- a/apps/plugins/vu_meter.c
+++ b/apps/plugins/vu_meter.c
@@ -781,7 +781,9 @@ void digital_meter(void) {
enum plugin_status plugin_start(const void* parameter) {
int button;
+#if defined(VUMETER_HELP_PRE) || defined(VUMETER_MENU_PRE)
int lastbutton = BUTTON_NONE;
+#endif
(void) parameter;
@@ -859,7 +861,9 @@ enum plugin_status plugin_start(const void* parameter) {
return PLUGIN_USB_CONNECTED;
break;
}
+#if defined(VUMETER_HELP_PRE) || defined(VUMETER_MENU_PRE)
if (button != BUTTON_NONE)
lastbutton = button;
+#endif
}
}