Index: src/apps/plugins/pictureflow/pictureflow.c =================================================================== --- src/apps/plugins/pictureflow/pictureflow.c (old version) +++ src/apps/plugins/pictureflow/pictureflow.c (new version) @@ -315,6 +315,7 @@ static bool show_fps = false; static int auto_wps = 0; static int last_album = 0; +static int backlight_mode = 0; static bool resize = true; static int cache_version = 0; static int show_album_name = (LCD_HEIGHT > 100) @@ -335,7 +336,8 @@ { TYPE_ENUM, 0, 3, { .int_p = &show_album_name }, "show album name", show_album_name_conf }, { TYPE_INT, 0, 2, { .int_p = &auto_wps }, "auto wps", NULL }, - { TYPE_INT, 0, 999999, { .int_p = &last_album }, "last album", NULL } + { TYPE_INT, 0, 999999, { .int_p = &last_album }, "last album", NULL }, + { TYPE_INT, 0, 1, { .int_p = &backlight_mode }, "backlight", NULL } }; #define CONFIG_NUM_ITEMS (sizeof(config) / sizeof(struct configdata)) @@ -2090,7 +2092,7 @@ MENUITEM_STRINGLIST(settings_menu, "PictureFlow Settings", NULL, "Show FPS", "Spacing", "Centre margin", "Number of slides", "Zoom", "Show album title", "Resize Covers", "Rebuild cache", - "WPS Integration"); + "WPS Integration", "Backlight"); static const struct opt_items album_name_options[] = { { "Hide album title", -1 }, @@ -2102,6 +2104,10 @@ { "Direct", -1 }, { "Via Track list", -1 } }; + static const struct opt_items backlight_options[] = { + { "Always On", -1 }, + { "Normal", -1 }, + }; do { selection=rb->do_menu(&settings_menu,&selection, NULL, true); @@ -2160,7 +2166,10 @@ break; case 8: rb->set_option("WPS Integration", &auto_wps, INT, wps_options, 3, NULL); - break; + break; + case 9: + rb->set_option("Backlight", &backlight_mode, INT, backlight_options, 2, NULL); + break; case MENU_ATTACHED_USB: return PLUGIN_USB_CONNECTED; @@ -2532,6 +2541,10 @@ configfile_load(CONFIG_FILE, config, CONFIG_NUM_ITEMS, CONFIG_VERSION); if(auto_wps == 0) draw_splashscreen(); + if(backlight_mode == 0) { + /* Turn off backlight timeout */ + backlight_force_on(); /* backlight control in lib/helper.c */ + } init_reflect_table(); @@ -2806,8 +2819,6 @@ FOR_NB_SCREENS(i) rb->viewportmanager_theme_enable(i, false, NULL); - /* Turn off backlight timeout */ - backlight_force_on(); /* backlight control in lib/helper.c */ #ifdef HAVE_ADJUSTABLE_CPU_FREQ rb->cpu_boost(true); #endif