forked from len0rd/rockbox
Show Track Info: Support fs tags in Playlist Viewer, Properties, and PictureFlow
Playlist Viewer falls back to splashf if there is not enough plugin buffer space left for running the view_text plugin . Change-Id: I418731018b03f396270b68e5e2d2e69635df1af0
This commit is contained in:
parent
4062a6aefc
commit
8f5128da16
11 changed files with 85 additions and 23 deletions
|
|
@ -207,4 +207,4 @@ xobox,games
|
|||
xrick,games
|
||||
xworld,games
|
||||
zxbox,viewers
|
||||
view_text,viewers
|
||||
view_text,viewers
|
||||
|
|
|
|||
|
|
@ -238,4 +238,4 @@ test_touchscreen.c
|
|||
#endif
|
||||
test_usb.c
|
||||
test_viewports.c
|
||||
#endif /* HAVE_TEST_PLUGINS */
|
||||
#endif /* HAVE_TEST_PLUGINS */
|
||||
|
|
|
|||
|
|
@ -33,6 +33,7 @@
|
|||
#include "lib/grey.h"
|
||||
#include "lib/mylcd.h"
|
||||
#include "lib/feature_wrappers.h"
|
||||
#include "lib/simple_viewer.h"
|
||||
|
||||
/******************************* Globals ***********************************/
|
||||
static fb_data *lcd_fb;
|
||||
|
|
@ -4082,7 +4083,7 @@ static int show_id3_info(const char *selected_file)
|
|||
if (is_multiple_tracks)
|
||||
finalize_id3(&id3);
|
||||
|
||||
return rb->browse_id3(&id3, 0, 0, NULL, i) ? PLUGIN_USB_CONNECTED : 0;
|
||||
return rb->browse_id3(&id3, 0, 0, NULL, i, &view_text) ? PLUGIN_USB_CONNECTED : 0;
|
||||
}
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -20,6 +20,7 @@
|
|||
****************************************************************************/
|
||||
#include "plugin.h"
|
||||
#include "lib/mul_id3.h"
|
||||
#include "lib/simple_viewer.h"
|
||||
|
||||
#if !defined(ARRAY_SIZE)
|
||||
#define ARRAY_SIZE(x) (sizeof((x)) / sizeof((x)[0]))
|
||||
|
|
@ -339,12 +340,15 @@ enum plugin_status plugin_start(const void* parameter)
|
|||
}
|
||||
}
|
||||
else if (props_type == PROPS_ID3)
|
||||
ret = rb->browse_id3(&id3, 0, 0, &tm, 1); /* Track Info for single file */
|
||||
/* Track Info for single file */
|
||||
ret = rb->browse_id3(&id3, 0, 0, &tm, 1, &view_text);
|
||||
else if (props_type == PROPS_MUL_ID3)
|
||||
ret = rb->browse_id3(&id3, 0, 0, NULL, mul_id3_count); /* database tracks */
|
||||
/* database tracks */
|
||||
ret = rb->browse_id3(&id3, 0, 0, NULL, mul_id3_count, &view_text);
|
||||
else if ((ret = browse_file_or_dir(&stats)) < 0)
|
||||
ret = assemble_track_info(file, &stats) ? /* playlist or folder tracks */
|
||||
rb->browse_id3(&id3, 0, 0, NULL, mul_id3_count) :
|
||||
ret = assemble_track_info(file, &stats) ?
|
||||
/* playlist or folder tracks */
|
||||
rb->browse_id3(&id3, 0, 0, NULL, mul_id3_count, &view_text) :
|
||||
(stats.canceled ? 0 : -1);
|
||||
|
||||
return ret == -1 ? PLUGIN_ERROR : ret == 1 ? PLUGIN_USB_CONNECTED : PLUGIN_OK;
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@
|
|||
/* this is the plugin entry point */
|
||||
enum plugin_status plugin_start(const void* parameter)
|
||||
{
|
||||
|
||||
|
||||
char** title_and_text = (char**)parameter;
|
||||
view_text(title_and_text[0], title_and_text[1]);
|
||||
return PLUGIN_OK;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue