summaryrefslogtreecommitdiff
path: root/apps/filetypes.h
diff options
context:
space:
mode:
Diffstat (limited to 'apps/filetypes.h')
-rw-r--r--apps/filetypes.h53
1 files changed, 53 insertions, 0 deletions
diff --git a/apps/filetypes.h b/apps/filetypes.h
new file mode 100644
index 0000000000..30bb71a38e
--- /dev/null
+++ b/apps/filetypes.h
@@ -0,0 +1,53 @@
1/***************************************************************************
2 * __________ __ ___.
3 * Open \______ \ ____ ____ | | _\_ |__ _______ ___
4 * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
5 * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
6 * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
7 * \/ \/ \/ \/ \/
8 * $Id:
9 *
10 * Copyright (C) 2002 Henrik Backe
11 *
12 * All files in this archive are subject to the GNU General Public License.
13 * See the file COPYING in the source tree root for full license agreement.
14 *
15 * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
16 * KIND, either express or implied.
17 *
18 ****************************************************************************/
19#ifndef _FILEHANDLE_H_
20#define _FILEHANDLE_H_
21
22#include <stdbool.h>
23#include <tree.h>
24#include <menu.h>
25
26int filetype_get_attr(char*);
27#ifdef HAVE_LCD_BITMAP
28char* filetype_get_icon(int);
29#else
30int filetype_get_icon(int);
31#endif
32char* filetype_get_plugin(struct entry*);
33void filetype_init(void);
34bool filetype_supported(int);
35int filetype_load_menu(struct menu_item*, int);
36void filetype_load_plugin(char*,char*);
37
38struct file_type {
39#ifdef HAVE_LCD_BITMAP
40 unsigned char* icon; /* the icon which shall be used for it, NULL if unknown */
41#else
42 int icon; /* the icon which shall be used for it, -1 if unknown */
43#endif
44 char* plugin; /* Which plugin to use, NULL if unknown */
45 bool no_extension;
46};
47
48struct ext_type {
49 char* extension; /* extension for which the file type is recognized */
50 struct file_type* type;
51};
52
53#endif