[rygel/rygel-0-16] rygel: Fix environment config
- From: Jens Georg <jensgeorg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [rygel/rygel-0-16] rygel: Fix environment config
- Date: Mon, 14 Jan 2013 12:25:18 +0000 (UTC)
commit f8c4f0a73117d283730fc3cec8777844febfce9f
Author: Jens Georg <jensg openismus com>
Date: Sat Dec 15 01:55:00 2012 +0100
rygel: Fix environment config
https://bugzilla.gnome.org/show_bug.cgi?id=679262
src/librygel-core/rygel-environment-config.vala | 11 ++++++-----
1 files changed, 6 insertions(+), 5 deletions(-)
---
diff --git a/src/librygel-core/rygel-environment-config.vala b/src/librygel-core/rygel-environment-config.vala
index 35d991b..59bf2b2 100644
--- a/src/librygel-core/rygel-environment-config.vala
+++ b/src/librygel-core/rygel-environment-config.vala
@@ -29,7 +29,7 @@ using Gee;
*/
internal class Rygel.EnvironmentConfig : GLib.Object, Configuration {
private static string RYGEL_PREFIX = "RYGEL";
- private static string TITLE_KEY = RYGEL_PREFIX + "_TITLE";
+ private static string TITLE_KEY = "TITLE";
private static string DISABLE_PREFIX = RYGEL_PREFIX + "_DISABLE";
private static string ENABLED_KEY = "ENABLED";
private static string INTERFACE_ENV = RYGEL_PREFIX + "_IFACE";
@@ -132,14 +132,14 @@ internal class Rygel.EnvironmentConfig : GLib.Object, Configuration {
}
public string get_title (string section) throws GLib.Error {
- return this.get_string (RYGEL_PREFIX + "_" + section, TITLE_KEY);
+ return this.get_string (section, TITLE_KEY);
}
public string get_string (string section,
string key) throws GLib.Error {
return this.get_string_variable (RYGEL_PREFIX + "_" +
section.up () + "_" +
- key.up ());
+ key.up ().replace ("-", "_"));
}
public Gee.ArrayList<string> get_string_list (string section,
@@ -160,7 +160,8 @@ internal class Rygel.EnvironmentConfig : GLib.Object, Configuration {
int max)
throws GLib.Error {
return this.get_int_variable (RYGEL_PREFIX + "_" +
- section.up () + "_" + key,
+ section.up () + "_" +
+ key.up ().replace ("-","_"),
min,
max);
}
@@ -182,7 +183,7 @@ internal class Rygel.EnvironmentConfig : GLib.Object, Configuration {
throws GLib.Error {
return this.get_bool_variable (RYGEL_PREFIX + "_" +
section.up () + "_" +
- key);
+ key.up ().replace ("-","_"));
}
private string get_string_variable (string variable) throws GLib.Error {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]