summaryrefslogtreecommitdiff
path: root/apps/tree.c
diff options
context:
space:
mode:
authorJonathan Gordon <rockbox@jdgordon.info>2007-01-24 02:19:22 +0000
committerJonathan Gordon <rockbox@jdgordon.info>2007-01-24 02:19:22 +0000
commit228d62dd18906eaef814ec63cf888b30a94cd1c8 (patch)
treea15e27e0e52222e4514e2b163e726869b33b5397 /apps/tree.c
parentcdcffd988372606abea31fad4a815f0b4968b21c (diff)
downloadrockbox-228d62dd18906eaef814ec63cf888b30a94cd1c8.tar.gz
rockbox-228d62dd18906eaef814ec63cf888b30a94cd1c8.zip
Split the system status variables out of global_settings and put them into a new struct global_status. Use status_save() if these need
saving. Added car_adapter_mode to the nvram settings, so nvram settings will be reset. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@12101 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/tree.c')
-rw-r--r--apps/tree.c22
1 files changed, 11 insertions, 11 deletions
diff --git a/apps/tree.c b/apps/tree.c
index e9ac6b5aa7..edd238a3b0 100644
--- a/apps/tree.c
+++ b/apps/tree.c
@@ -474,10 +474,10 @@ void reload_directory(void)
474static void start_resume(bool just_powered_on) 474static void start_resume(bool just_powered_on)
475{ 475{
476 bool do_resume = false; 476 bool do_resume = false;
477 if ( global_settings.resume_index != -1 ) { 477 if ( global_status.resume_index != -1 ) {
478 DEBUGF("Resume index %X offset %X\n", 478 DEBUGF("Resume index %X offset %X\n",
479 global_settings.resume_index, 479 global_status.resume_index,
480 global_settings.resume_offset); 480 global_status.resume_offset);
481 481
482#ifdef HAVE_ALARM_MOD 482#ifdef HAVE_ALARM_MOD
483 if ( rtc_check_alarm_started(true) ) { 483 if ( rtc_check_alarm_started(true) ) {
@@ -507,8 +507,8 @@ static void start_resume(bool just_powered_on)
507 507
508 if (playlist_resume() != -1) 508 if (playlist_resume() != -1)
509 { 509 {
510 playlist_start(global_settings.resume_index, 510 playlist_start(global_status.resume_index,
511 global_settings.resume_offset); 511 global_status.resume_offset);
512 512
513 start_wps = true; 513 start_wps = true;
514 } 514 }
@@ -1439,10 +1439,10 @@ void tree_flush(void)
1439 1439
1440#ifdef HAVE_DIRCACHE 1440#ifdef HAVE_DIRCACHE
1441 { 1441 {
1442 int old_val = global_settings.dircache_size; 1442 int old_val = global_status.dircache_size;
1443 if (global_settings.dircache) 1443 if (global_settings.dircache)
1444 { 1444 {
1445 global_settings.dircache_size = dircache_get_cache_size(); 1445 global_status.dircache_size = dircache_get_cache_size();
1446# ifdef HAVE_EEPROM_SETTINGS 1446# ifdef HAVE_EEPROM_SETTINGS
1447 dircache_save(); 1447 dircache_save();
1448# endif 1448# endif
@@ -1450,10 +1450,10 @@ void tree_flush(void)
1450 } 1450 }
1451 else 1451 else
1452 { 1452 {
1453 global_settings.dircache_size = 0; 1453 global_status.dircache_size = 0;
1454 } 1454 }
1455 if (old_val != global_settings.dircache_size) 1455 if (old_val != global_status.dircache_size)
1456 settings_save(); 1456 status_save();
1457 } 1457 }
1458#endif 1458#endif
1459} 1459}
@@ -1484,7 +1484,7 @@ void tree_restore(void)
1484 gui_textarea_update(&screens[i]); 1484 gui_textarea_update(&screens[i]);
1485 } 1485 }
1486 1486
1487 dircache_build(global_settings.dircache_size); 1487 dircache_build(global_status.dircache_size);
1488 1488
1489 /* Clean the text when we are done. */ 1489 /* Clean the text when we are done. */
1490 FOR_NB_SCREENS(i) 1490 FOR_NB_SCREENS(i)