reset the tool-options before loading the user settings. Don't warn if

2003-03-26  Sven Neumann  <sven@gimp.org>

	* app/gui/tool-options-dialog.c (tool_options_dialog_restore_callback):
	reset the tool-options before loading the user settings. Don't warn if
	loading fails.
This commit is contained in:
Sven Neumann
2003-03-26 13:24:40 +00:00
committed by Sven Neumann
parent 42a215195d
commit 05e390692b
3 changed files with 16 additions and 12 deletions

View File

@ -1,3 +1,9 @@
2003-03-26 Sven Neumann <sven@gimp.org>
* app/gui/tool-options-dialog.c (tool_options_dialog_restore_callback):
reset the tool-options before loading the user settings. Don't warn if
loading fails.
2003-03-26 Sven Neumann <sven@gimp.org>
* app/widgets/gimpfontselection-dialog.c

View File

@ -261,18 +261,17 @@ tool_options_dialog_restore_callback (GtkWidget *widget,
GimpContext *context)
{
GimpToolInfo *tool_info;
GError *error = NULL;
tool_info = gimp_context_get_tool (context);
if (! tool_info)
return;
if (! gimp_tool_options_deserialize (tool_info->tool_options, "user", &error))
{
g_message ("EEK: %s\n", error->message);
g_clear_error (&error);
}
/* Need to reset the tool-options since only the changes
* from the default values are written to disk.
*/
gimp_tool_options_reset (tool_info->tool_options);
gimp_tool_options_deserialize (tool_info->tool_options, "user", NULL);
}
static void

View File

@ -261,18 +261,17 @@ tool_options_dialog_restore_callback (GtkWidget *widget,
GimpContext *context)
{
GimpToolInfo *tool_info;
GError *error = NULL;
tool_info = gimp_context_get_tool (context);
if (! tool_info)
return;
if (! gimp_tool_options_deserialize (tool_info->tool_options, "user", &error))
{
g_message ("EEK: %s\n", error->message);
g_clear_error (&error);
}
/* Need to reset the tool-options since only the changes
* from the default values are written to disk.
*/
gimp_tool_options_reset (tool_info->tool_options);
gimp_tool_options_deserialize (tool_info->tool_options, "user", NULL);
}
static void