diff options
author | Jonathan Gordon <rockbox@jdgordon.info> | 2006-11-19 14:11:42 +0000 |
---|---|---|
committer | Jonathan Gordon <rockbox@jdgordon.info> | 2006-11-19 14:11:42 +0000 |
commit | 6288523cfee31a474435ce3445e67733f532d916 (patch) | |
tree | 1fe3350c1d27a0144492d64792cea78f6a833c73 /apps/plugins | |
parent | 687328b7773ae917574841fa63326aa2bec264d6 (diff) | |
download | rockbox-6288523cfee31a474435ce3445e67733f532d916.tar.gz rockbox-6288523cfee31a474435ce3445e67733f532d916.zip |
* Move checkbox to plugin api (core never uses it)
* replace the last of the scrollbar() calls with gui_scrollbar_draw()
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@11552 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/plugins')
-rw-r--r-- | apps/plugins/clock.c | 9 | ||||
-rw-r--r-- | apps/plugins/jpeg.c | 4 | ||||
-rw-r--r-- | apps/plugins/lib/SOURCES | 1 | ||||
-rw-r--r-- | apps/plugins/splitedit.c | 3 | ||||
-rw-r--r-- | apps/plugins/video.c | 4 | ||||
-rw-r--r-- | apps/plugins/viewer.c | 3 |
6 files changed, 14 insertions, 10 deletions
diff --git a/apps/plugins/clock.c b/apps/plugins/clock.c index 032344263a..6a1d306339 100644 --- a/apps/plugins/clock.c +++ b/apps/plugins/clock.c | |||
@@ -89,6 +89,7 @@ Original release, featuring analog / digital modes and a few options. | |||
89 | *****************************/ | 89 | *****************************/ |
90 | #include "plugin.h" | 90 | #include "plugin.h" |
91 | #include "time.h" | 91 | #include "time.h" |
92 | #include "checkbox.h" | ||
92 | #include <pluginbitmaps/clock_logo.h> | 93 | #include <pluginbitmaps/clock_logo.h> |
93 | 94 | ||
94 | PLUGIN_HEADER | 95 | PLUGIN_HEADER |
@@ -2386,7 +2387,7 @@ void draw_extras(int year, int day, int month, int hour, int minute, int second) | |||
2386 | rb->lcd_putsxy((LCDWIDTH/2)-(w/2), 5, buf); | 2387 | rb->lcd_putsxy((LCDWIDTH/2)-(w/2), 5, buf); |
2387 | } | 2388 | } |
2388 | else if(settings.digital[digital_seconds] == 2) /* Second progressbar */ | 2389 | else if(settings.digital[digital_seconds] == 2) /* Second progressbar */ |
2389 | rb->scrollbar(0, 0, LCD_WIDTH, 4, 60, 0, second, HORIZONTAL); | 2390 | rb->gui_scrollbar_draw(rb->screens[SCREEN_MAIN],0, 0, LCD_WIDTH, 4, 60, 0, second, HORIZONTAL); |
2390 | else if(settings.digital[digital_seconds] == 3) /* Invert the LCD as seconds pass */ | 2391 | else if(settings.digital[digital_seconds] == 3) /* Invert the LCD as seconds pass */ |
2391 | { | 2392 | { |
2392 | rb->lcd_set_drawmode(DRMODE_COMPLEMENT); | 2393 | rb->lcd_set_drawmode(DRMODE_COMPLEMENT); |
@@ -2417,7 +2418,7 @@ void draw_extras(int year, int day, int month, int hour, int minute, int second) | |||
2417 | } | 2418 | } |
2418 | else if(settings.lcd[lcd_seconds] == 2) /* Second progressbar */ | 2419 | else if(settings.lcd[lcd_seconds] == 2) /* Second progressbar */ |
2419 | { | 2420 | { |
2420 | rb->scrollbar(0, 0, LCD_WIDTH, 4, 60, 0, second, HORIZONTAL); | 2421 | rb->gui_scrollbar_draw(rb->screens[SCREEN_MAIN],0, 0, LCD_WIDTH, 4, 60, 0, second, HORIZONTAL); |
2421 | } | 2422 | } |
2422 | else if(settings.lcd[lcd_seconds] == 3) /* Invert the LCD as seconds pass */ | 2423 | else if(settings.lcd[lcd_seconds] == 3) /* Invert the LCD as seconds pass */ |
2423 | { | 2424 | { |
@@ -2727,8 +2728,8 @@ void counter_settings(void) | |||
2727 | rb->lcd_puts(0, 7, "OFF: Return"); | 2728 | rb->lcd_puts(0, 7, "OFF: Return"); |
2728 | 2729 | ||
2729 | /* tell user what mode is selected */ | 2730 | /* tell user what mode is selected */ |
2730 | rb->checkbox(1, 17, 8, 6, counting_up); | 2731 | checkbox(rb,1, 17, 8, 6, counting_up); |
2731 | rb->checkbox(1, 25, 8, 6, !counting_up); | 2732 | checkbox(rb,1, 25, 8, 6, !counting_up); |
2732 | 2733 | ||
2733 | switch(cursorpos) | 2734 | switch(cursorpos) |
2734 | { | 2735 | { |
diff --git a/apps/plugins/jpeg.c b/apps/plugins/jpeg.c index 81b5098a2a..878c94408e 100644 --- a/apps/plugins/jpeg.c +++ b/apps/plugins/jpeg.c | |||
@@ -2386,7 +2386,7 @@ void cb_progess(int current, int total) | |||
2386 | rb->yield(); /* be nice to the other threads */ | 2386 | rb->yield(); /* be nice to the other threads */ |
2387 | if(!running_slideshow) | 2387 | if(!running_slideshow) |
2388 | { | 2388 | { |
2389 | rb->scrollbar(0, LCD_HEIGHT-8, LCD_WIDTH, 8, total, 0, | 2389 | rb->gui_scrollbar_draw(rb->screens[SCREEN_MAIN],0, LCD_HEIGHT-8, LCD_WIDTH, 8, total, 0, |
2390 | current, HORIZONTAL); | 2390 | current, HORIZONTAL); |
2391 | rb->lcd_update_rect(0, LCD_HEIGHT-8, LCD_WIDTH, 8); | 2391 | rb->lcd_update_rect(0, LCD_HEIGHT-8, LCD_WIDTH, 8); |
2392 | } | 2392 | } |
@@ -2394,7 +2394,7 @@ void cb_progess(int current, int total) | |||
2394 | else | 2394 | else |
2395 | { | 2395 | { |
2396 | /* in slideshow mode, keep gui interference to a minimum */ | 2396 | /* in slideshow mode, keep gui interference to a minimum */ |
2397 | rb->scrollbar(0, LCD_HEIGHT-4, LCD_WIDTH, 4, total, 0, | 2397 | rb->gui_scrollbar_draw(rb->screens[SCREEN_MAIN],0, LCD_HEIGHT-4, LCD_WIDTH, 4, total, 0, |
2398 | current, HORIZONTAL); | 2398 | current, HORIZONTAL); |
2399 | rb->lcd_update_rect(0, LCD_HEIGHT-4, LCD_WIDTH, 4); | 2399 | rb->lcd_update_rect(0, LCD_HEIGHT-4, LCD_WIDTH, 4); |
2400 | } | 2400 | } |
diff --git a/apps/plugins/lib/SOURCES b/apps/plugins/lib/SOURCES index d57db3bbc8..7441a98182 100644 --- a/apps/plugins/lib/SOURCES +++ b/apps/plugins/lib/SOURCES | |||
@@ -18,6 +18,7 @@ playergfx.c | |||
18 | profile_plugin.c | 18 | profile_plugin.c |
19 | #endif | 19 | #endif |
20 | #ifdef HAVE_LCD_BITMAP | 20 | #ifdef HAVE_LCD_BITMAP |
21 | checkbox.c | ||
21 | xlcd_core.c | 22 | xlcd_core.c |
22 | xlcd_draw.c | 23 | xlcd_draw.c |
23 | xlcd_scroll.c | 24 | xlcd_scroll.c |
diff --git a/apps/plugins/splitedit.c b/apps/plugins/splitedit.c index fa5ff8e35f..3d422ecb6c 100644 --- a/apps/plugins/splitedit.c +++ b/apps/plugins/splitedit.c | |||
@@ -604,7 +604,8 @@ static int copy_file( | |||
604 | return -1; | 604 | return -1; |
605 | } | 605 | } |
606 | 606 | ||
607 | rb->scrollbar(0, prg_y, LCD_WIDTH, prg_h, bytes, 0, i, HORIZONTAL); | 607 | rb->gui_scrollbar_draw(&rb->screens[SCREEN_MAIN],0, prg_y, LCD_WIDTH, |
608 | prg_h, bytes, 0, i, HORIZONTAL); | ||
608 | rb->lcd_update_rect(0, prg_y, LCD_WIDTH, prg_h); | 609 | rb->lcd_update_rect(0, prg_y, LCD_WIDTH, prg_h); |
609 | } | 610 | } |
610 | 611 | ||
diff --git a/apps/plugins/video.c b/apps/plugins/video.c index e82ec1a84f..5891740bfa 100644 --- a/apps/plugins/video.c +++ b/apps/plugins/video.c | |||
@@ -27,7 +27,6 @@ | |||
27 | #include "plugin.h" | 27 | #include "plugin.h" |
28 | #include "sh7034.h" | 28 | #include "sh7034.h" |
29 | #include "system.h" | 29 | #include "system.h" |
30 | #include "../apps/recorder/widgets.h" /* not in search path, booh */ | ||
31 | 30 | ||
32 | #ifndef SIMULATOR /* not for simulator by now */ | 31 | #ifndef SIMULATOR /* not for simulator by now */ |
33 | #ifdef HAVE_LCD_BITMAP /* and definitely not for the Player, haha */ | 32 | #ifdef HAVE_LCD_BITMAP /* and definitely not for the Player, haha */ |
@@ -256,7 +255,8 @@ void DrawPosition(int pos, int total) | |||
256 | /* draw a slider over the rest of the line */ | 255 | /* draw a slider over the rest of the line */ |
257 | rb->lcd_getstringsize(gPrint, &w, &h); | 256 | rb->lcd_getstringsize(gPrint, &w, &h); |
258 | w++; | 257 | w++; |
259 | rb->scrollbar(w, LCD_HEIGHT-7, LCD_WIDTH-w, 7, total, 0, pos, HORIZONTAL); | 258 | rb->gui_scrollbar_draw(&rb->screens[SCREEN_MAIN],w, LCD_HEIGHT-7, LCD_WIDTH-w, |
259 | 7, total, 0, pos, HORIZONTAL); | ||
260 | 260 | ||
261 | if (gPlay.state == paused) /* we have to draw ourselves */ | 261 | if (gPlay.state == paused) /* we have to draw ourselves */ |
262 | rb->lcd_update_rect(0, LCD_HEIGHT-8, LCD_WIDTH, 8); | 262 | rb->lcd_update_rect(0, LCD_HEIGHT-8, LCD_WIDTH, 8); |
diff --git a/apps/plugins/viewer.c b/apps/plugins/viewer.c index af73257508..af795e736b 100644 --- a/apps/plugins/viewer.c +++ b/apps/plugins/viewer.c | |||
@@ -662,7 +662,8 @@ static void viewer_scrollbar(void) { | |||
662 | else | 662 | else |
663 | max_shown = min_shown + (next_screen_ptr - screen_top_ptr); | 663 | max_shown = min_shown + (next_screen_ptr - screen_top_ptr); |
664 | 664 | ||
665 | rb->scrollbar(0, 0, SCROLLBAR_WIDTH-1, LCD_HEIGHT, items, min_shown, max_shown, VERTICAL); | 665 | rb->gui_scrollbar_draw(rb->screens[SCREEN_MAIN],0, 0, SCROLLBAR_WIDTH-1, |
666 | LCD_HEIGHT, items, min_shown, max_shown, VERTICAL); | ||
666 | } | 667 | } |
667 | #endif | 668 | #endif |
668 | 669 | ||