diff options
| author | bernard.xiong <[email protected]> | 2010-07-30 09:47:56 +0000 |
|---|---|---|
| committer | bernard.xiong <[email protected]> | 2010-07-30 09:47:56 +0000 |
| commit | 445da145e267d3998965f2edccda04c2c08e0a66 (patch) | |
| tree | 78c6527df54352c816649700ac99da7731c7668d /components/rtgui/include | |
| parent | b9fcbfc34489856a06554c0a3c453ad60e20cecd (diff) | |
fix compiling error if there is no DFS file system.
git-svn-id: https://rt-thread.googlecode.com/svn/trunk@818 bbd45198-f89e-11dd-88c7-29a3b14d5316
Diffstat (limited to 'components/rtgui/include')
| -rw-r--r-- | components/rtgui/include/rtgui/image.h | 2 | ||||
| -rw-r--r-- | components/rtgui/include/rtgui/rtgui_config.h | 6 | ||||
| -rw-r--r-- | components/rtgui/include/rtgui/widgets/filelist_view.h | 2 |
3 files changed, 10 insertions, 0 deletions
diff --git a/components/rtgui/include/rtgui/image.h b/components/rtgui/include/rtgui/image.h index 5c63747f13..e0a6859246 100644 --- a/components/rtgui/include/rtgui/image.h +++ b/components/rtgui/include/rtgui/image.h @@ -49,7 +49,9 @@ typedef struct rtgui_image rtgui_image_t; /* init rtgui image system */
void rtgui_system_image_init(void);
+#if defined(RTGUI_USING_DFS_FILERW) || defined(RTGUI_USING_STDIO_FILERW)
struct rtgui_image* rtgui_image_create_from_file(const char* type, const char* filename, rt_bool_t load);
+#endif
struct rtgui_image* rtgui_image_create_from_mem(const char* type, const rt_uint8_t* data, rt_size_t length, rt_bool_t load);
void rtgui_image_destroy(struct rtgui_image* image);
diff --git a/components/rtgui/include/rtgui/rtgui_config.h b/components/rtgui/include/rtgui/rtgui_config.h index cb6fa8c373..415cfd05c8 100644 --- a/components/rtgui/include/rtgui/rtgui_config.h +++ b/components/rtgui/include/rtgui/rtgui_config.h @@ -39,6 +39,12 @@ #define RTGUI_USING_HZ_BMP
#define RTGUI_MEM_TRACE
#define RTGUI_USING_WINMOVE
+#else
+ /* native running under RT-Thread */
+ #ifndef RT_USING_DFS
+ #undef RTGUI_USING_DFS_FILERW
+ #undef RTGUI_USING_HZ_FILE
+ #endif
#endif
#if RTGUI_DEFAULT_FONT_SIZE == 0
diff --git a/components/rtgui/include/rtgui/widgets/filelist_view.h b/components/rtgui/include/rtgui/widgets/filelist_view.h index 105b9f3554..0249f31c3e 100644 --- a/components/rtgui/include/rtgui/widgets/filelist_view.h +++ b/components/rtgui/include/rtgui/widgets/filelist_view.h @@ -3,6 +3,7 @@ #include <rtgui/widgets/view.h>
+#if defined(RTGUI_USING_DFS_FILERW) || defined(RTGUI_USING_STDIO_FILERW)
#define RTGUI_FITEM_FILE 0x0
#define RTGUI_FITEM_DIR 0x1
struct rtgui_file_item
@@ -52,5 +53,6 @@ rt_bool_t rtgui_filelist_view_event_handler(struct rtgui_widget* widget, struct void rtgui_filelist_view_set_directory(rtgui_filelist_view_t* view, const char* directory);
void rtgui_filelist_view_get_fullpath(rtgui_filelist_view_t* view, char* path, rt_size_t len);
+#endif
#endif
|
