Commit 1f1050d0 authored by Michael Natterer's avatar Michael Natterer 😴 Committed by Michael Natterer
Browse files

is a GtkRadioAction callback but behaved like a GtkToggleAction callback.

2004-09-19  Michael Natterer  <mitch@gimp.org>

	* app/actions/qmask-commands.c (qmask_invert_cmd_callback): is a
	GtkRadioAction callback but behaved like a GtkToggleAction
	callback. Fixes bug #152948.
parent 9f79a8fc
2004-09-19 Michael Natterer <mitch@gimp.org>
* app/actions/qmask-commands.c (qmask_invert_cmd_callback): is a
GtkRadioAction callback but behaved like a GtkToggleAction
callback. Fixes bug #152948.
2004-09-19 DindinX <dindinx@gimp.org>
* plug-ins/common/bumpmap.c: use a GimpDrawablePreview instead of a
......
......@@ -88,21 +88,19 @@ qmask_toggle_cmd_callback (GtkAction *action,
void
qmask_invert_cmd_callback (GtkAction *action,
gint value,
GtkAction *current,
gpointer data)
{
GimpImage *gimage;
gint value;
return_if_no_image (gimage, data);
if (gtk_toggle_action_get_active (GTK_TOGGLE_ACTION (action)))
{
if (value != gimage->qmask_inverted)
{
gimp_image_qmask_invert (gimage);
value = gtk_radio_action_get_current_value (GTK_RADIO_ACTION (action));
if (gimp_image_get_qmask_state (gimage))
gimp_image_flush (gimage);
}
if (value != gimage->qmask_inverted)
{
gimp_image_qmask_invert (gimage);
gimp_image_flush (gimage);
}
}
......
......@@ -23,7 +23,7 @@
void qmask_toggle_cmd_callback (GtkAction *action,
gpointer data);
void qmask_invert_cmd_callback (GtkAction *action,
gint value,
GtkAction *current,
gpointer data);
void qmask_configure_cmd_callback (GtkAction *action,
gpointer data);
......
......@@ -88,21 +88,19 @@ qmask_toggle_cmd_callback (GtkAction *action,
void
qmask_invert_cmd_callback (GtkAction *action,
gint value,
GtkAction *current,
gpointer data)
{
GimpImage *gimage;
gint value;
return_if_no_image (gimage, data);
if (gtk_toggle_action_get_active (GTK_TOGGLE_ACTION (action)))
{
if (value != gimage->qmask_inverted)
{
gimp_image_qmask_invert (gimage);
value = gtk_radio_action_get_current_value (GTK_RADIO_ACTION (action));
if (gimp_image_get_qmask_state (gimage))
gimp_image_flush (gimage);
}
if (value != gimage->qmask_inverted)
{
gimp_image_qmask_invert (gimage);
gimp_image_flush (gimage);
}
}
......
......@@ -23,7 +23,7 @@
void qmask_toggle_cmd_callback (GtkAction *action,
gpointer data);
void qmask_invert_cmd_callback (GtkAction *action,
gint value,
GtkAction *current,
gpointer data);
void qmask_configure_cmd_callback (GtkAction *action,
gpointer data);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment