summaryrefslogtreecommitdiff
path: root/apps/plugins
diff options
context:
space:
mode:
Diffstat (limited to 'apps/plugins')
-rw-r--r--apps/plugins/rockboy/input.h4
-rw-r--r--apps/plugins/rockboy/lcd.c6
-rw-r--r--apps/plugins/rockboy/menu.c40
3 files changed, 28 insertions, 22 deletions
diff --git a/apps/plugins/rockboy/input.h b/apps/plugins/rockboy/input.h
index 4ee1c9eb40..aa992380e9 100644
--- a/apps/plugins/rockboy/input.h
+++ b/apps/plugins/rockboy/input.h
@@ -14,7 +14,7 @@ typedef struct event_s
14#define EV_PRESS 1 14#define EV_PRESS 1
15#define EV_RELEASE 2 15#define EV_RELEASE 2
16 16
17int ev_postevent(event_t *ev) ICODE_ATTR; 17int ev_postevent(event_t *ev);
18int ev_getevent(event_t *ev) ICODE_ATTR; 18int ev_getevent(event_t *ev);
19 19
20 20
diff --git a/apps/plugins/rockboy/lcd.c b/apps/plugins/rockboy/lcd.c
index bf44ccf136..494160dc85 100644
--- a/apps/plugins/rockboy/lcd.c
+++ b/apps/plugins/rockboy/lcd.c
@@ -876,6 +876,7 @@ void lcd_begin(void)
876 876
877 set_pal(); 877 set_pal();
878 878
879#ifdef HAVE_LCD_COLOR
879 if(options.rotate) 880 if(options.rotate)
880 { 881 {
881 if(options.fullscreen == 0) 882 if(options.fullscreen == 0)
@@ -894,18 +895,22 @@ void lcd_begin(void)
894 else 895 else
895 vdest=fb.ptr+S1; 896 vdest=fb.ptr+S1;
896 } 897 }
898#endif
897 WY = R_WY; 899 WY = R_WY;
898} 900}
899 901
902#ifdef HAVE_LCD_COLOR
900int SCALEWL IDATA_ATTR=1<<16; 903int SCALEWL IDATA_ATTR=1<<16;
901int SCALEWS IDATA_ATTR=1<<16; 904int SCALEWS IDATA_ATTR=1<<16;
902int SCALEHL IDATA_ATTR=1<<16; 905int SCALEHL IDATA_ATTR=1<<16;
903int SCALEHS IDATA_ATTR=1<<16; 906int SCALEHS IDATA_ATTR=1<<16;
904int swidth IDATA_ATTR=160; 907int swidth IDATA_ATTR=160;
905int sremain IDATA_ATTR=LCD_WIDTH-160; 908int sremain IDATA_ATTR=LCD_WIDTH-160;
909#endif
906 910
907void setvidmode(void) 911void setvidmode(void)
908{ 912{
913#ifdef HAVE_LCD_COLOR
909 switch(options.fullscreen) 914 switch(options.fullscreen)
910 { 915 {
911 case 0: 916 case 0:
@@ -972,6 +977,7 @@ void setvidmode(void)
972 sremain=-(((160*SCALEWL)>>16)*LCD_WIDTH+1); 977 sremain=-(((160*SCALEWL)>>16)*LCD_WIDTH+1);
973 else 978 else
974 sremain=LCD_WIDTH-swidth; 979 sremain=LCD_WIDTH-swidth;
980#endif
975} 981}
976 982
977void lcd_refreshline(void) 983void lcd_refreshline(void)
diff --git a/apps/plugins/rockboy/menu.c b/apps/plugins/rockboy/menu.c
index e358bafbb9..803310f70c 100644
--- a/apps/plugins/rockboy/menu.c
+++ b/apps/plugins/rockboy/menu.c
@@ -325,14 +325,6 @@ static void do_opt_menu(void)
325 { "On" , -1 }, 325 { "On" , -1 },
326 }; 326 };
327 327
328 static const struct opt_items fullscreen[]= {
329 { "Scaled", -1 },
330 { "Scaled - Maintain Ratio", -1 },
331#if (LCD_WIDTH>=160) && (LCD_HEIGHT>=144)
332 { "Unscaled", -1 },
333#endif
334 };
335
336 static const struct opt_items frameskip[]= { 328 static const struct opt_items frameskip[]= {
337 { "0 Max", -1 }, 329 { "0 Max", -1 },
338 { "1 Max", -1 }, 330 { "1 Max", -1 },
@@ -343,7 +335,15 @@ static void do_opt_menu(void)
343 { "6 Max", -1 }, 335 { "6 Max", -1 },
344 }; 336 };
345 337
346#ifdef HAVE_LCD_COLOR 338#ifdef HAVE_LCD_COLOR
339 static const struct opt_items fullscreen[]= {
340 { "Scaled", -1 },
341 { "Scaled - Maintain Ratio", -1 },
342#if (LCD_WIDTH>=160) && (LCD_HEIGHT>=144)
343 { "Unscaled", -1 },
344#endif
345 };
346
347 static const struct opt_items palette[]= { 347 static const struct opt_items palette[]= {
348 { "Brown (Default)", -1 }, 348 { "Brown (Default)", -1 },
349 { "Gray", -1 }, 349 { "Gray", -1 },
@@ -369,17 +369,17 @@ static void do_opt_menu(void)
369 { "Max Frameskip", NULL }, 369 { "Max Frameskip", NULL },
370 { "Sound" , NULL }, 370 { "Sound" , NULL },
371 { "Stats" , NULL }, 371 { "Stats" , NULL },
372 { "Screen Size" , NULL },
373 { "Screen Rotate" , NULL },
374 { "Set Keys (Buggy)", NULL }, 372 { "Set Keys (Buggy)", NULL },
375#ifdef HAVE_LCD_COLOR 373#ifdef HAVE_LCD_COLOR
374 { "Screen Size" , NULL },
375 { "Screen Rotate" , NULL },
376 { "Set Palette" , NULL }, 376 { "Set Palette" , NULL },
377#endif 377#endif
378 }; 378 };
379 379
380 m = menu_init(rb,items, sizeof(items) / sizeof(*items), NULL, NULL, NULL, NULL); 380 m = menu_init(rb,items, sizeof(items) / sizeof(*items), NULL, NULL, NULL, NULL);
381 381
382 options.dirty=1; /* Just assume that the settings have been changed */ 382 options.dirty=1; /* Assume that the settings have been changed */
383 383
384 while(!done) 384 while(!done)
385 { 385 {
@@ -400,19 +400,19 @@ static void do_opt_menu(void)
400 case 2: /* Stats */ 400 case 2: /* Stats */
401 rb->set_option(items[2].desc, &options.showstats, INT, onoff, 2, NULL ); 401 rb->set_option(items[2].desc, &options.showstats, INT, onoff, 2, NULL );
402 break; 402 break;
403 case 3: /* Screen Size */ 403 case 3: /* Keys */
404 rb->set_option(items[3].desc, &options.fullscreen, INT, fullscreen, 404 setupkeys();
405 break;
406#ifdef HAVE_LCD_COLOR
407 case 4: /* Screen Size */
408 rb->set_option(items[4].desc, &options.fullscreen, INT, fullscreen,
405 sizeof(fullscreen)/sizeof(*fullscreen), NULL ); 409 sizeof(fullscreen)/sizeof(*fullscreen), NULL );
406 setvidmode(); 410 setvidmode();
407 break; 411 break;
408 case 4: /* Screen rotate */ 412 case 5: /* Screen rotate */
409 rb->set_option(items[4].desc, &options.rotate, INT, onoff, 2, NULL ); 413 rb->set_option(items[5].desc, &options.rotate, INT, onoff, 2, NULL );
410 setvidmode(); 414 setvidmode();
411 break; 415 break;
412 case 5: /* Keys */
413 setupkeys();
414 break;
415#ifdef HAVE_LCD_COLOR
416 case 6: /* Palette */ 416 case 6: /* Palette */
417 rb->set_option(items[6].desc, &options.pal, INT, palette, 17, NULL ); 417 rb->set_option(items[6].desc, &options.pal, INT, palette, 17, NULL );
418 set_pal(); 418 set_pal();