Search
lxdream.org :: lxdream/src/config.c :: diff
lxdream 0.9.1
released Jun 29
Download Now
filename src/config.c
changeset 724:f2bc1c7cca14
prev643:653b0a70f173
next736:a02d1475ccfd
author nkeynes
date Sun Jul 06 03:17:32 2008 +0000 (11 years ago)
permissions -rw-r--r--
last change Add descriptive (localized) label to config entries for UI use
file annotate diff log raw
1.1 --- a/src/config.c Tue Feb 26 01:10:48 2008 +0000
1.2 +++ b/src/config.c Sun Jul 06 03:17:32 2008 +0000
1.3 @@ -36,17 +36,17 @@
1.4 gboolean lxdream_save_config_stream( FILE *f );
1.5
1.6 static struct lxdream_config_entry global_config[] =
1.7 - {{ "bios", CONFIG_TYPE_FILE, "dcboot.rom" },
1.8 - { "flash", CONFIG_TYPE_FILE, "dcflash.rom" },
1.9 - { "default path", CONFIG_TYPE_PATH, "." },
1.10 - { "save path", CONFIG_TYPE_PATH, "save" },
1.11 - { "bootstrap", CONFIG_TYPE_FILE, "IP.BIN" },
1.12 - { "gdrom", CONFIG_TYPE_FILE, NULL },
1.13 - { "recent", CONFIG_TYPE_FILE, NULL },
1.14 + {{ "bios", N_("Bios ROM"), CONFIG_TYPE_FILE, "dcboot.rom" },
1.15 + { "flash", N_("Flash ROM"), CONFIG_TYPE_FILE, "dcflash.rom" },
1.16 + { "default path", N_("Default disc path"), CONFIG_TYPE_PATH, "." },
1.17 + { "save path", N_("Save-state path"), CONFIG_TYPE_PATH, "save" },
1.18 + { "bootstrap", N_("Bootstrap IP.BIN"), CONFIG_TYPE_FILE, "IP.BIN" },
1.19 + { "gdrom", NULL, CONFIG_TYPE_FILE, NULL },
1.20 + { "recent", NULL, CONFIG_TYPE_FILE, NULL },
1.21 { NULL, CONFIG_TYPE_NONE }};
1.22
1.23 static struct lxdream_config_entry serial_config[] =
1.24 - {{ "device", CONFIG_TYPE_FILE, "/dev/ttyS1" },
1.25 + {{ "device", N_("Serial device"), CONFIG_TYPE_FILE, "/dev/ttyS1" },
1.26 { NULL, CONFIG_TYPE_NONE }};
1.27
1.28 struct lxdream_config_group lxdream_config_root[] =
1.29 @@ -135,6 +135,11 @@
1.30 lxdream_set_config_value(&global_config[key], value);
1.31 }
1.32
1.33 +const lxdream_config_entry_t lxdream_get_config_entry( int key )
1.34 +{
1.35 + return &global_config[key];
1.36 +}
1.37 +
1.38 gboolean lxdream_set_group_value( lxdream_config_group_t group, const gchar *key, const gchar *value )
1.39 {
1.40 int i;
.