Commit 9571e804 authored by Lucas Beeler's avatar Lucas Beeler

Fixes a minor Makefile issue introduced by the last commit. Fixes a regression...

Fixes a minor Makefile issue introduced by the last commit. Fixes a regression introduced by the last commit in which the desktop background wouldn't be properly set on GNOME 3 systems.
parent 40208a60
......@@ -69,7 +69,6 @@ UNUNITIZED_SRC_FILES = \
EditingTools.vala \
Properties.vala \
CustomComponents.vala \
Config.vala \
Event.vala \
International.vala \
AppDirs.vala \
......
......@@ -275,64 +275,40 @@ public class GConfConfigurationEngine : ConfigurationEngine, GLib.Object {
}
public int get_int_property(ConfigurableProperty p) throws ConfigurationError {
debug("configuration system '%s': getting property '%s' with value '%d'",
get_name(), p.to_string(), get_gconf_int(property_paths[p]));
return get_gconf_int(property_paths[p]);
}
public void set_int_property(ConfigurableProperty p, int val) throws ConfigurationError {
debug("configuration system '%s': setting property '%s' to value '%d'",
get_name(), p.to_string(), val);
set_gconf_int(property_paths[p], val);
property_changed(p);
}
public string? get_string_property(ConfigurableProperty p) throws ConfigurationError {
debug("configuration system '%s': getting property '%s' with value '%s'",
get_name(), p.to_string(), get_gconf_string(property_paths[p]));
return get_gconf_string(property_paths[p]);
}
public void set_string_property(ConfigurableProperty p, string? val) throws ConfigurationError {
debug("configuration system '%s': setting property '%s' to value '%s'",
get_name(), p.to_string(), val);
set_gconf_string(property_paths[p], val);
property_changed(p);
}
public bool get_bool_property(ConfigurableProperty p) throws ConfigurationError {
debug("configuration system '%s': getting property '%s' with value '%s'",
get_name(), p.to_string(), (get_gconf_bool(property_paths[p]) ? "true" : "false"));
return get_gconf_bool(property_paths[p]);
}
public void set_bool_property(ConfigurableProperty p, bool val) throws ConfigurationError {
debug("configuration system '%s': setting property '%s' to value '%s'",
get_name(), p.to_string(), (val) ? "true" : "false");
set_gconf_bool(property_paths[p], val);
property_changed(p);
}
public double get_double_property(ConfigurableProperty p) throws ConfigurationError {
debug("configuration system '%s': getting property '%s' with value '%f'",
get_name(), p.to_string(), get_gconf_double(property_paths[p]));
return get_gconf_double(property_paths[p]);
}
public void set_double_property(ConfigurableProperty p, double val) throws ConfigurationError {
debug("configuration system '%s': setting property '%s' to value '%f'",
get_name(), p.to_string(), val);
set_gconf_double(property_paths[p], val);
property_changed(p);
......@@ -416,7 +392,6 @@ public class GConfConfigurationEngine : ConfigurationEngine, GLib.Object {
}
public FuzzyPropertyState is_plugin_enabled(string id) {
debug ("GConfConfigurationManager: checking if plugin '%s' is enabled.\n", id);
try {
bool is_enabled =
get_gconf_bool("/apps/shotwell/plugins/%s/enabled".printf(clean_plugin_id(id)));
......
......@@ -26,10 +26,8 @@ public class GSettingsConfigurationEngine : ConfigurationEngine, GLib.Object {
public GSettingsConfigurationEngine() {
known_schemas = new Gee.HashSet<string>();
foreach (string current_schema in Settings.list_schemas()) {
debug("GSettingsConfigurationEngine: found schema '%s'", current_schema);
foreach (string current_schema in Settings.list_schemas())
known_schemas.add(current_schema);
}
schema_names = new string[ConfigurableProperty.NUM_PROPERTIES];
......@@ -262,11 +260,26 @@ public class GSettingsConfigurationEngine : ConfigurationEngine, GLib.Object {
}
public string? get_string_property(ConfigurableProperty p) throws ConfigurationError {
return get_gs_string(schema_names[p], key_names[p]);
string gs_result = get_gs_string(schema_names[p], key_names[p]);
// if we're getting the desktop background file, convert the file uri we get back from
// GSettings into a file path
string result = gs_result;
if (p == ConfigurableProperty.DESKTOP_BACKGROUND_FILE) {
result = gs_result.substring(7);
}
return result;
}
public void set_string_property(ConfigurableProperty p, string? val) throws ConfigurationError {
set_gs_string(schema_names[p], key_names[p], val);
// if we're setting the desktop background file, convert the filename into a file URI
string converted_val = val;
if (p == ConfigurableProperty.DESKTOP_BACKGROUND_FILE) {
converted_val = "file://" + val;
}
set_gs_string(schema_names[p], key_names[p], converted_val);
property_changed(p);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment