summaryrefslogtreecommitdiff
path: root/apps
diff options
context:
space:
mode:
authorFrank Gevaerts <frank@gevaerts.be>2012-06-19 21:51:59 +0200
committerFrank Gevaerts <frank@gevaerts.be>2012-06-19 21:53:29 +0200
commit21ddcbec669801c77e860833f520b748cfff4f22 (patch)
tree8c6af4c71d2fe84264ee897cd12b76e4e0513dff /apps
parentf8eb8c8679633d43e3c1e0d95feb2dab2d5cee8a (diff)
CHARCELL doesn't have sbs support, so disable it properly.
This actually fixes a nullpointer dereference. Change-Id: Ie3e153d72bcacdce46bfe5a514ff77aebdfd7225
Diffstat (limited to 'apps')
-rw-r--r--apps/gui/skin_engine/skin_engine.c8
-rw-r--r--apps/gui/skin_engine/skin_engine.h2
2 files changed, 8 insertions, 2 deletions
diff --git a/apps/gui/skin_engine/skin_engine.c b/apps/gui/skin_engine/skin_engine.c
index 1d73b3266b..e91320b742 100644
--- a/apps/gui/skin_engine/skin_engine.c
+++ b/apps/gui/skin_engine/skin_engine.c
@@ -54,7 +54,9 @@ static struct gui_skin_helper {
char* (*default_skin)(enum screen_type screen);
bool load_on_boot;
} skin_helpers[SKINNABLE_SCREENS_COUNT] = {
+#ifdef HAVE_LCD_BITMAP
[CUSTOM_STATUSBAR] = { sb_preproccess, sb_postproccess, sb_create_from_settings, true },
+#endif
[WPS] = { NULL, NULL, wps_default_skin, true },
#if CONFIG_TUNER
[FM_SCREEN] = { NULL, NULL, default_radio_skin, false }
@@ -198,8 +200,8 @@ static char* get_skin_filename(char *buf, size_t buf_size,
char *setting = NULL, *ext = NULL;
switch (skin)
{
- case CUSTOM_STATUSBAR:
#ifdef HAVE_LCD_BITMAP
+ case CUSTOM_STATUSBAR:
#if defined(HAVE_REMOTE_LCD) && NB_SCREENS > 1
if (screen == SCREEN_REMOTE)
{
@@ -212,8 +214,8 @@ static char* get_skin_filename(char *buf, size_t buf_size,
setting = global_settings.sbs_file;
ext = "sbs";
}
-#endif
break;
+#endif
case WPS:
#if defined(HAVE_REMOTE_LCD) && NB_SCREENS > 1
if (screen == SCREEN_REMOTE)
@@ -258,8 +260,10 @@ static char* get_skin_filename(char *buf, size_t buf_size,
struct gui_wps *skin_get_gwps(enum skinnable_screens skin, enum screen_type screen)
{
+#ifdef HAVE_LCD_BITMAP
if (skin == CUSTOM_STATUSBAR && !skins_initialised)
return &skins[skin][screen].gui_wps;
+#endif
if (skins[skin][screen].data.wps_loaded == false)
{
diff --git a/apps/gui/skin_engine/skin_engine.h b/apps/gui/skin_engine/skin_engine.h
index 625467ea3b..07fafe6a10 100644
--- a/apps/gui/skin_engine/skin_engine.h
+++ b/apps/gui/skin_engine/skin_engine.h
@@ -30,7 +30,9 @@
#include "wps_internals.h" /* TODO: remove this line.. shoudlnt be needed */
enum skinnable_screens {
+#ifdef HAVE_LCD_BITMAP
CUSTOM_STATUSBAR,
+#endif
WPS,
#if CONFIG_TUNER
FM_SCREEN,