libgimpwidgets: in GimpChainButton, emit "toggled" signal when "active" changes

In GimpChainButton, emit the "toggled" signal whenever the chain
button's "active" property changes, either due to user interaction,
or programatically.  Previously, it would only get emitted when the
button was actually clicked.

In particular, this fixes an issue where the aspect ratio of a
coordinates size-entry won't get updated when its chain button got
toggled programatically, as can happen with the scale tool.
This commit is contained in:
Ell
2019-02-08 08:07:05 -05:00
parent cb025cec64
commit c0c055b4e9

View File

@ -393,6 +393,8 @@ gimp_chain_button_set_active (GimpChainButton *button,
gimp_chain_button_update_image (button);
g_signal_emit (button, gimp_chain_button_signals[TOGGLED], 0);
g_object_notify (G_OBJECT (button), "active");
}
}
@ -447,8 +449,6 @@ gimp_chain_button_clicked_callback (GtkWidget *widget,
GimpChainButtonPrivate *private = GET_PRIVATE (button);
gimp_chain_button_set_active (button, ! private->active);
g_signal_emit (button, gimp_chain_button_signals[TOGGLED], 0);
}
static void