gnome-terminal r2812 - trunk/src
- From: chpe svn gnome org
- To: svn-commits-list gnome org
- Subject: gnome-terminal r2812 - trunk/src
- Date: Thu, 29 May 2008 19:56:33 +0000 (UTC)
Author: chpe
Date: Thu May 29 19:56:33 2008
New Revision: 2812
URL: http://svn.gnome.org/viewvc/gnome-terminal?rev=2812&view=rev
Log:
When encountering a gconf value we cannot interpret, use our internal default instead of force a write of the default to gconf. That way we will not clobber values set by future g-t versions.
Modified:
trunk/src/terminal-profile.c
Modified: trunk/src/terminal-profile.c
==============================================================================
--- trunk/src/terminal-profile.c (original)
+++ trunk/src/terminal-profile.c Thu May 29 19:56:33 2008
@@ -528,7 +528,7 @@
GParamSpec *pspec;
GValue value = { 0, };
gboolean equal;
- gboolean force_write = FALSE;
+ gboolean force_set = FALSE;
key = gconf_entry_get_key (entry);
if (!key || !g_str_has_prefix (key, priv->profile_dir))
@@ -666,7 +666,7 @@
{
NOTE (g_message ("Invalid value in gconf for key %s was changed to comply with pspec %s\n",
gconf_entry_get_key (entry), pspec->name);)
- force_write = TRUE;
+ force_set = TRUE;
}
/* Only set the property if the value is different than our current value,
@@ -681,9 +681,7 @@
g_strdup_value_contents (g_value_array_get_nth (priv->properties, pspec->param_id)),
g_strdup_value_contents (&value));)
- if (force_write)
- g_object_set_property (G_OBJECT (profile), pspec->name, &value);
- else if (!equal)
+ if (!equal || force_set)
terminal_profile_set_property (G_OBJECT (profile), pspec->param_id, &value, pspec);
out:
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]