diff options
Diffstat (limited to 'apps/settings_menu.c')
-rw-r--r-- | apps/settings_menu.c | 23 |
1 files changed, 21 insertions, 2 deletions
diff --git a/apps/settings_menu.c b/apps/settings_menu.c index eabe153810..0193aa0102 100644 --- a/apps/settings_menu.c +++ b/apps/settings_menu.c | |||
@@ -56,6 +56,7 @@ | |||
56 | #include "yesno.h" | 56 | #include "yesno.h" |
57 | #include "list.h" | 57 | #include "list.h" |
58 | #include "color_picker.h" | 58 | #include "color_picker.h" |
59 | #include "scrobbler.h" | ||
59 | 60 | ||
60 | #ifdef HAVE_LCD_BITMAP | 61 | #ifdef HAVE_LCD_BITMAP |
61 | #include "peakmeter.h" | 62 | #include "peakmeter.h" |
@@ -1387,6 +1388,23 @@ static bool next_folder(void) | |||
1387 | INT, names, 3, NULL ); | 1388 | INT, names, 3, NULL ); |
1388 | } | 1389 | } |
1389 | 1390 | ||
1391 | static bool audioscrobbler(void) | ||
1392 | { | ||
1393 | bool result = set_bool_options(str(LANG_AUDIOSCROBBLER), | ||
1394 | &global_settings.audioscrobbler, | ||
1395 | STR(LANG_ON), | ||
1396 | STR(LANG_OFF), | ||
1397 | NULL); | ||
1398 | |||
1399 | if (!scrobbler_is_enabled() && global_settings.audioscrobbler) | ||
1400 | gui_syncsplash(HZ*2, true, str(LANG_PLEASE_REBOOT)); | ||
1401 | |||
1402 | if(!result) | ||
1403 | scrobbler_shutdown(); | ||
1404 | |||
1405 | return result; | ||
1406 | } | ||
1407 | |||
1390 | static bool codepage_setting(void) | 1408 | static bool codepage_setting(void) |
1391 | { | 1409 | { |
1392 | static const struct opt_items names[] = { | 1410 | static const struct opt_items names[] = { |
@@ -1605,7 +1623,7 @@ static bool dircache(void) | |||
1605 | NULL); | 1623 | NULL); |
1606 | 1624 | ||
1607 | if (!dircache_is_enabled() && global_settings.dircache) | 1625 | if (!dircache_is_enabled() && global_settings.dircache) |
1608 | gui_syncsplash(HZ*2, true, str(LANG_DIRCACHE_REBOOT)); | 1626 | gui_syncsplash(HZ*2, true, str(LANG_PLEASE_REBOOT)); |
1609 | 1627 | ||
1610 | if (!result) | 1628 | if (!result) |
1611 | dircache_disable(); | 1629 | dircache_disable(); |
@@ -1747,8 +1765,9 @@ static bool playback_settings_menu(void) | |||
1747 | { ID2P(LANG_ID3_ORDER), id3_order }, | 1765 | { ID2P(LANG_ID3_ORDER), id3_order }, |
1748 | { ID2P(LANG_NEXT_FOLDER), next_folder }, | 1766 | { ID2P(LANG_NEXT_FOLDER), next_folder }, |
1749 | #ifdef HAVE_HEADPHONE_DETECTION | 1767 | #ifdef HAVE_HEADPHONE_DETECTION |
1750 | { ID2P(LANG_UNPLUG), unplug_menu } | 1768 | { ID2P(LANG_UNPLUG), unplug_menu }, |
1751 | #endif | 1769 | #endif |
1770 | { ID2P(LANG_AUDIOSCROBBLER), audioscrobbler} | ||
1752 | }; | 1771 | }; |
1753 | 1772 | ||
1754 | bool old_shuffle = global_settings.playlist_shuffle; | 1773 | bool old_shuffle = global_settings.playlist_shuffle; |