Bug 700653 - Duplicate "(time ...)" values in gimp-curves-tool.settings

and gimp-levels-tool.settings

Serialize the channel properties manually (not using
gimp_config_serialize_properties()), so the parent class' "time"
property doesn't end up in the config file once per channel.
This commit is contained in:
Michael Natterer 2013-05-19 21:42:50 +02:00
parent b8dace7a75
commit 6781439fdc
2 changed files with 20 additions and 2 deletions

View File

@ -237,7 +237,14 @@ gimp_curves_config_serialize (GimpConfig *config,
{ {
c_config->channel = channel; c_config->channel = channel;
success = gimp_config_serialize_properties (config, writer); /* Serialize the channel properties manually (not using
* gimp_config_serialize_properties()), so the parent class'
* "time" property doesn't end up in the config file once per
* channel. See bug #700653.
*/
success =
(gimp_config_serialize_property_by_name (config, "channel", writer) &&
gimp_config_serialize_property_by_name (config, "curve", writer));
if (! success) if (! success)
break; break;

View File

@ -255,7 +255,18 @@ gimp_levels_config_serialize (GimpConfig *config,
{ {
l_config->channel = channel; l_config->channel = channel;
success = gimp_config_serialize_properties (config, writer); /* serialize the channel properties manually (not using
* gimp_config_serialize_properties()), so the parent class'
* "time" property doesn't end up in the config file one per
* channel. See bug #700653.
*/
success =
(gimp_config_serialize_property_by_name (config, "channel", writer) &&
gimp_config_serialize_property_by_name (config, "gamma", writer) &&
gimp_config_serialize_property_by_name (config, "low-input", writer) &&
gimp_config_serialize_property_by_name (config, "high-input", writer) &&
gimp_config_serialize_property_by_name (config, "low-output", writer) &&
gimp_config_serialize_property_by_name (config, "high-output", writer));
if (! success) if (! success)
break; break;