summaryrefslogtreecommitdiff
path: root/apps/plugins/spacerocks.c
diff options
context:
space:
mode:
authorAndrew Mahone <andrew.mahone@gmail.com>2009-01-16 10:34:40 +0000
committerAndrew Mahone <andrew.mahone@gmail.com>2009-01-16 10:34:40 +0000
commit23d9812273d9c74af72ccdc3aa4cfea971f220a4 (patch)
tree8e60c3a2a41879f8b2a52516fa416b3ab906e239 /apps/plugins/spacerocks.c
parent35677cbc54bbe400ebbff59b489dda7ca7f04916 (diff)
loader-initialized global plugin API:
struct plugin_api *rb is declared in PLUGIN_HEADER, and pointed to by __header.api the loader uses this pointer to initialize rb before calling entry_point entry_point is no longer passed a pointer to the plugin API all plugins, and pluginlib functions, are modified to refer to the global rb pluginlib functions which only served to copy the API pointer are removed git-svn-id: svn://svn.rockbox.org/rockbox/trunk@19776 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/plugins/spacerocks.c')
-rw-r--r--apps/plugins/spacerocks.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/apps/plugins/spacerocks.c b/apps/plugins/spacerocks.c
index 6c2496a781..b4cddd9a12 100644
--- a/apps/plugins/spacerocks.c
+++ b/apps/plugins/spacerocks.c
@@ -25,7 +25,6 @@
PLUGIN_HEADER
/******************************* Globals ***********************************/
-static const struct plugin_api* rb; /* global api struct pointer */
/* variable button definitions */
#if CONFIG_KEYPAD == RECORDER_PAD
#define AST_PAUSE BUTTON_ON
@@ -2074,11 +2073,10 @@ enum plugin_status start_game(void)
}
}
-enum plugin_status plugin_start(const struct plugin_api* api, const void* parameter)
+enum plugin_status plugin_start(const void* parameter)
{
enum plugin_status retval;
(void)(parameter);
- rb = api;
game_state = ATTRACT_MODE;
@@ -2088,12 +2086,12 @@ enum plugin_status plugin_start(const struct plugin_api* api, const void* parame
/* universal font */
rb->lcd_setfont(FONT_SYSFIXED);
/* Turn off backlight timeout */
- backlight_force_on(rb); /* backlight control in lib/helper.c */
+ backlight_force_on(); /* backlight control in lib/helper.c */
iohiscore();
retval = start_game();
iohiscore();
rb->lcd_setfont(FONT_UI);
/* Turn on backlight timeout (revert to settings) */
- backlight_use_settings(rb); /* backlight control in lib/helper.c */
+ backlight_use_settings(); /* backlight control in lib/helper.c */
return retval;
}