diff options
author | Thomas Martitz <kugel@rockbox.org> | 2009-10-20 21:54:59 +0000 |
---|---|---|
committer | Thomas Martitz <kugel@rockbox.org> | 2009-10-20 21:54:59 +0000 |
commit | d85c3ec41020a6c56b0d5d95a9ed790f57d73c6e (patch) | |
tree | 2f51ed47fee689024ed8c145634044362c8ed7d5 /apps/plugins/mpegplayer/mpeg_settings.c | |
parent | 774bacc692b4d5c7b769bb88d24e182db9e4656f (diff) | |
download | rockbox-d85c3ec41020a6c56b0d5d95a9ed790f57d73c6e.tar.gz rockbox-d85c3ec41020a6c56b0d5d95a9ed790f57d73c6e.zip |
Convert lcd_activation callbacks to use the event system to allow for multiple parallel callbacks (for custom statusbar).
Increase maximum event count as we need more (I actually had a report about it during custom statusbar testing).
Removed corresponding functions from the core and plugin api. Bump min version and sort.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@23302 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/plugins/mpegplayer/mpeg_settings.c')
-rw-r--r-- | apps/plugins/mpegplayer/mpeg_settings.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/apps/plugins/mpegplayer/mpeg_settings.c b/apps/plugins/mpegplayer/mpeg_settings.c index df926f4c17..eb55c1444e 100644 --- a/apps/plugins/mpegplayer/mpeg_settings.c +++ b/apps/plugins/mpegplayer/mpeg_settings.c | |||
@@ -599,8 +599,9 @@ static uint32_t increment_time(uint32_t val, int32_t amount, uint32_t range) | |||
599 | } | 599 | } |
600 | 600 | ||
601 | #if defined(HAVE_LCD_ENABLE) && defined(HAVE_LCD_COLOR) | 601 | #if defined(HAVE_LCD_ENABLE) && defined(HAVE_LCD_COLOR) |
602 | static void get_start_time_lcd_enable_hook(void) | 602 | static void get_start_time_lcd_enable_hook(void *param) |
603 | { | 603 | { |
604 | (void)param; | ||
604 | rb->queue_post(rb->button_queue, LCD_ENABLE_EVENT_0, 0); | 605 | rb->queue_post(rb->button_queue, LCD_ENABLE_EVENT_0, 0); |
605 | } | 606 | } |
606 | #endif /* HAVE_LCD_ENABLE */ | 607 | #endif /* HAVE_LCD_ENABLE */ |
@@ -619,7 +620,7 @@ static int get_start_time(uint32_t duration) | |||
619 | lcd_(update)(); | 620 | lcd_(update)(); |
620 | 621 | ||
621 | #if defined(HAVE_LCD_ENABLE) && defined(HAVE_LCD_COLOR) | 622 | #if defined(HAVE_LCD_ENABLE) && defined(HAVE_LCD_COLOR) |
622 | rb->lcd_activation_set_hook(get_start_time_lcd_enable_hook); | 623 | rb->add_event(LCD_EVENT_ACTIVATION, false, get_start_time_lcd_enable_hook); |
623 | #endif | 624 | #endif |
624 | 625 | ||
625 | draw_slider(0, 100, &rc_bound); | 626 | draw_slider(0, 100, &rc_bound); |
@@ -810,7 +811,7 @@ static int get_start_time(uint32_t duration) | |||
810 | } | 811 | } |
811 | 812 | ||
812 | #if defined(HAVE_LCD_ENABLE) || defined(HAVE_LCD_SLEEP) | 813 | #if defined(HAVE_LCD_ENABLE) || defined(HAVE_LCD_SLEEP) |
813 | rb->lcd_activation_set_hook(NULL); | 814 | rb->remove_event(LCD_EVENT_ACTIVATION, get_start_time_lcd_enable_hook); |
814 | #endif | 815 | #endif |
815 | #ifndef HAVE_LCD_COLOR | 816 | #ifndef HAVE_LCD_COLOR |
816 | stream_gray_show(false); | 817 | stream_gray_show(false); |