summaryrefslogtreecommitdiffstats
path: root/apps/settings.c
diff options
context:
space:
mode:
authorJonathan Gordon <rockbox@jdgordon.info>2011-11-28 10:58:15 +0000
committerJonathan Gordon <rockbox@jdgordon.info>2011-11-28 10:58:15 +0000
commitd66592bad11b09ede186751a0fa1751feb29c15f (patch)
tree103c73932fe4a83df04d8b47020449f3faa72c0c /apps/settings.c
parent25bce232f2883d2bba47fa9b908d1b95ee71cd3a (diff)
downloadrockbox-d66592bad11b09ede186751a0fa1751feb29c15f.tar.gz
rockbox-d66592bad11b09ede186751a0fa1751feb29c15f.tar.bz2
rockbox-d66592bad11b09ede186751a0fa1751feb29c15f.zip
Be less smart about when to reload skins as it caused more problems than it was worth. If any theme setting is loading from a .cfg reload all skins. Fixes FS#12410
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@31081 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/settings.c')
-rw-r--r--apps/settings.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/apps/settings.c b/apps/settings.c
index 3c28d316b5..408e377e1a 100644
--- a/apps/settings.c
+++ b/apps/settings.c
@@ -268,6 +268,7 @@ bool settings_load_config(const char* file, bool apply)
char* name;
char* value;
int i;
+ bool theme_changed = false;
fd = open_utf8(file, O_RDONLY);
if (fd < 0)
return false;
@@ -275,13 +276,15 @@ bool settings_load_config(const char* file, bool apply)
while (read_line(fd, line, sizeof line) > 0)
{
if (!settings_parseline(line, &name, &value))
- continue;
+ continue;
for(i=0; i<nb_settings; i++)
{
if (settings[i].cfg_name == NULL)
continue;
if (!strcasecmp(name,settings[i].cfg_name))
{
+ if (settings[i].flags&F_THEMESETTING)
+ theme_changed = true;
switch (settings[i].flags&F_T_MASK)
{
case F_T_CUSTOM:
@@ -363,7 +366,8 @@ bool settings_load_config(const char* file, bool apply)
{
settings_save();
settings_apply(true);
- settings_apply_skins();
+ if (theme_changed)
+ settings_apply_skins();
}
return true;
}