mirror of
https://github.com/Rockbox/rockbox.git
synced 2026-05-12 11:43:16 -04:00
plugins: imageviewer: fix incomplete previous commits
missed in commit2690418: grayscale targets need to have access to the Display Options menu now, since it contains the hide_info option missed in commitf4dc4d8: "resizing" message for bmp files wasn't hidden even with hide_info enabled Change-Id: I1a73e3816305ab6f032fc226d79f09df0d9aa96b
This commit is contained in:
parent
ae8013405a
commit
6d699f08f4
2 changed files with 11 additions and 12 deletions
|
|
@ -276,7 +276,8 @@ static int get_image(struct image_info *info, int frame, int ds)
|
|||
buf_images += size;
|
||||
buf_images_size -= size;
|
||||
|
||||
if (!iv->running_slideshow)
|
||||
if (!iv->settings->hide_info &&
|
||||
!iv->running_slideshow)
|
||||
{
|
||||
rb->lcd_putsf(0, 3, "resizing %d*%d", info->width, info->height);
|
||||
rb->lcd_update();
|
||||
|
|
|
|||
|
|
@ -246,28 +246,32 @@ static bool set_option_dithering(void)
|
|||
return false;
|
||||
}
|
||||
|
||||
MENUITEM_FUNCTION(grayscale_item, 0, ID2P(LANG_GRAYSCALE),
|
||||
set_option_grayscale, NULL, Icon_NOICON);
|
||||
MENUITEM_FUNCTION(dithering_item, 0, ID2P(LANG_DITHERING),
|
||||
set_option_dithering, NULL, Icon_NOICON);
|
||||
|
||||
#endif /* HAVE_LCD_COLOR */
|
||||
|
||||
static bool set_option_hide_info(void)
|
||||
{
|
||||
rb->set_bool(rb->str(LANG_HIDE_INFO), &settings.hide_info);
|
||||
return false;
|
||||
}
|
||||
|
||||
MENUITEM_FUNCTION(grayscale_item, 0, ID2P(LANG_GRAYSCALE),
|
||||
set_option_grayscale, NULL, Icon_NOICON);
|
||||
MENUITEM_FUNCTION(dithering_item, 0, ID2P(LANG_DITHERING),
|
||||
set_option_dithering, NULL, Icon_NOICON);
|
||||
MENUITEM_FUNCTION(hide_info_item, 0, ID2P(LANG_HIDE_INFO),
|
||||
set_option_hide_info, NULL, Icon_NOICON);
|
||||
MAKE_MENU(display_menu, ID2P(LANG_MENU_DISPLAY_OPTIONS), NULL, Icon_NOICON,
|
||||
#ifdef HAVE_LCD_COLOR
|
||||
&grayscale_item,
|
||||
&dithering_item,
|
||||
#endif /* HAVE_LCD_COLOR */
|
||||
&hide_info_item);
|
||||
|
||||
static void display_options(void)
|
||||
{
|
||||
rb->do_menu(&display_menu, NULL, NULL, false);
|
||||
}
|
||||
#endif /* HAVE_LCD_COLOR */
|
||||
|
||||
static int show_menu(void) /* return 1 to quit */
|
||||
{
|
||||
|
|
@ -281,9 +285,7 @@ static int show_menu(void) /* return 1 to quit */
|
|||
#ifdef USE_PLUG_BUF
|
||||
MIID_SHOW_PLAYBACK_MENU,
|
||||
#endif
|
||||
#ifdef HAVE_LCD_COLOR
|
||||
MIID_DISPLAY_OPTIONS,
|
||||
#endif
|
||||
MIID_QUIT,
|
||||
};
|
||||
|
||||
|
|
@ -294,9 +296,7 @@ static int show_menu(void) /* return 1 to quit */
|
|||
#ifdef USE_PLUG_BUF
|
||||
ID2P(LANG_PLAYBACK_CONTROL),
|
||||
#endif
|
||||
#ifdef HAVE_LCD_COLOR
|
||||
ID2P(LANG_MENU_DISPLAY_OPTIONS),
|
||||
#endif
|
||||
ID2P(LANG_MENU_QUIT));
|
||||
|
||||
static const struct opt_items slideshow[2] = {
|
||||
|
|
@ -332,11 +332,9 @@ static int show_menu(void) /* return 1 to quit */
|
|||
}
|
||||
break;
|
||||
#endif
|
||||
#ifdef HAVE_LCD_COLOR
|
||||
case MIID_DISPLAY_OPTIONS:
|
||||
display_options();
|
||||
break;
|
||||
#endif
|
||||
case MIID_QUIT:
|
||||
return 1;
|
||||
break;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue