app: more stuff in gimp-tool-options-manager.c

tool_options_manager_tool_changed(): also copy the non-global paint
options of the new tool to the global paint options, so they get used
when "global_foo" is enabled.
This commit is contained in:
Michael Natterer 2018-06-29 00:52:14 +02:00
parent 54257da7c4
commit 1b858eb4ad
1 changed files with 6 additions and 5 deletions

View File

@ -480,11 +480,6 @@ tool_options_manager_tool_changed (GimpContext *user_context,
if (user_context->gimp->busy)
return;
/* note that in this function we only deal with non-global
* properties, so we never have to copy from or to the global paint
* options
*/
if (manager->active_tool)
{
GimpToolInfo *active = manager->active_tool;
@ -513,6 +508,12 @@ tool_options_manager_tool_changed (GimpContext *user_context,
active->context_props &
~manager->global_props);
if (GIMP_IS_PAINT_OPTIONS (active->tool_options))
tool_options_manager_copy_paint_props (GIMP_PAINT_OPTIONS (active->tool_options),
manager->global_paint_options,
active->context_props &
~manager->global_props);
/* then, undefine these properties so the tool syncs with the
* user context automatically
*/