summaryrefslogtreecommitdiff
path: root/apps/filetypes.c
diff options
context:
space:
mode:
authorWilliam Wilgus <wilgus.william@gmail.com>2024-05-06 16:39:57 -0400
committerWilliam Wilgus <wilgus.william@gmail.com>2024-05-06 17:27:25 -0400
commitee840709d3d93376f9b5da6c34572424079304b8 (patch)
tree2357bb53651524d1cc5dd386fb32ddba15e7be0d /apps/filetypes.c
parent30482bd9087444c434ee4c4cc1756ca9a402f5ad (diff)
downloadrockbox-ee840709d3d93376f9b5da6c34572424079304b8.tar.gz
rockbox-ee840709d3d93376f9b5da6c34572424079304b8.zip
[Feature] Open plugins now recognizes known filetypes and can run them
now you can run your lua files without having to add the viewer to the shortcut or if you want a bmp file to be displayed when you start the device that can be done as well Change-Id: Ia56b566789623a2ca78d9e4583086db6e2cd689b
Diffstat (limited to 'apps/filetypes.c')
-rw-r--r--apps/filetypes.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/apps/filetypes.c b/apps/filetypes.c
index bda7018381..e992b86060 100644
--- a/apps/filetypes.c
+++ b/apps/filetypes.c
@@ -604,9 +604,9 @@ int filetype_get_icon(int attr)
604 return filetypes[index].icon; 604 return filetypes[index].icon;
605} 605}
606 606
607char* filetype_get_plugin(const struct entry* file, char *buffer, size_t buffer_len) 607char* filetype_get_plugin(int attr, char *buffer, size_t buffer_len)
608{ 608{
609 int index = find_attr(file->attr); 609 int index = find_attr(attr);
610 if (index < 0 || !buffer) 610 if (index < 0 || !buffer)
611 return NULL; 611 return NULL;
612 struct file_type *ft_indexed = &filetypes[index]; 612 struct file_type *ft_indexed = &filetypes[index];