diff options
Diffstat (limited to 'apps/gui/backdrop.h')
-rw-r--r-- | apps/gui/backdrop.h | 59 |
1 files changed, 47 insertions, 12 deletions
diff --git a/apps/gui/backdrop.h b/apps/gui/backdrop.h index dc9805f07b..f3ef1d7686 100644 --- a/apps/gui/backdrop.h +++ b/apps/gui/backdrop.h | |||
@@ -22,27 +22,62 @@ | |||
22 | #ifndef _BACKDROP_H | 22 | #ifndef _BACKDROP_H |
23 | #define _BACKDROP_H | 23 | #define _BACKDROP_H |
24 | 24 | ||
25 | enum backdrop_type { | ||
26 | BACKDROP_MAIN, | ||
27 | BACKDROP_SKIN_WPS, | ||
28 | }; | ||
29 | |||
25 | #if LCD_DEPTH > 1 | 30 | #if LCD_DEPTH > 1 |
26 | 31 | ||
27 | #include "lcd.h" | 32 | #include "lcd.h" |
28 | #include "bmp.h" | 33 | #include "bmp.h" |
29 | 34 | ||
30 | bool load_main_backdrop(const char* filename); | 35 | bool backdrop_load(enum backdrop_type bdrop, const char*); |
31 | bool load_wps_backdrop(const char* filename); | 36 | void backdrop_unload(enum backdrop_type bdrop); |
37 | void backdrop_show(enum backdrop_type bdrop); | ||
38 | |||
39 | #else /* LCD_DEPTH > 1 */ | ||
40 | |||
41 | static inline | ||
42 | bool backdrop_load(enum backdrop_type bdrop, const char* filename) | ||
43 | { | ||
44 | (void)filename; (void)bdrop; return true; | ||
45 | } | ||
32 | 46 | ||
33 | void unload_main_backdrop(void); | 47 | static inline void backdrop_unload(enum backdrop_type bdrop) |
34 | void unload_wps_backdrop(void); | 48 | { |
49 | (void)bdrop; | ||
50 | } | ||
51 | static inline void backdrop_show(enum backdrop_type bdrop) | ||
52 | { | ||
53 | (void)bdrop; | ||
54 | } | ||
35 | 55 | ||
36 | void show_main_backdrop(void); | 56 | #endif |
37 | void show_wps_backdrop(void); | 57 | |
58 | #if defined(HAVE_REMOTE_LCD) | ||
59 | /* no main backdrop, stubs! */ | ||
60 | #if LCD_REMOTE_DEPTH > 1 | ||
61 | bool remote_backdrop_load(enum backdrop_type bdrop,const char* filename); | ||
62 | void remote_backdropunload(enum backdrop_type bdrop); | ||
63 | void remote_backdrop_show(enum backdrop_type bdrop); | ||
64 | #else | ||
65 | static inline | ||
66 | bool remote_backdrop_load(enum backdrop_type bdrop,const char* filename) | ||
67 | { | ||
68 | (void)filename; (void)bdrop; return true; | ||
69 | } | ||
38 | 70 | ||
39 | #endif /* LCD_DEPTH > 1 */ | 71 | static inline void remote_backdrop_unload(enum backdrop_type bdrop) |
72 | { | ||
73 | (void)bdrop; | ||
74 | } | ||
40 | 75 | ||
41 | #if defined(HAVE_REMOTE_LCD) && LCD_REMOTE_DEPTH > 1 | 76 | static inline void remote_backdrop_show(enum backdrop_type bdrop) |
42 | bool load_remote_wps_backdrop(const char* filename); | 77 | { |
43 | void unload_remote_wps_backdrop(void); | 78 | (void)bdrop; |
44 | void show_remote_wps_backdrop(void); | 79 | } |
45 | void show_remote_main_backdrop(void); /* only clears the wps backdrop */ | 80 | #endif |
46 | #endif | 81 | #endif |
47 | 82 | ||
48 | #endif /* _BACKDROP_H */ | 83 | #endif /* _BACKDROP_H */ |