plug-ins: Fix image-map grid type change
Resolves #10611. In GTK3, GtkRadioButtons are set using the "active" property rather than selected, so the callback needed to check the GTK_STATE_FLAG_ACTIVE flag instead of GTK_STATE_FLAG_SELECTED when changing grid types. The code was also reformatted to match current coding style.
This commit is contained in:
parent
45ea994e89
commit
bbbf6df52d
1 changed files with 7 additions and 6 deletions
|
|
@ -112,13 +112,14 @@ snap_toggled_cb (GtkWidget *widget,
|
|||
}
|
||||
|
||||
static void
|
||||
type_toggled_cb(GtkWidget *widget, gpointer data)
|
||||
type_toggled_cb (GtkWidget *widget,
|
||||
gpointer data)
|
||||
{
|
||||
if (gtk_widget_get_state_flags (widget) & GTK_STATE_FLAG_SELECTED)
|
||||
{
|
||||
grid_type = GPOINTER_TO_INT (data);
|
||||
preview_redraw();
|
||||
}
|
||||
if (gtk_widget_get_state_flags (widget) & GTK_STATE_FLAG_ACTIVE)
|
||||
{
|
||||
grid_type = GPOINTER_TO_INT (data);
|
||||
preview_redraw ();
|
||||
}
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
|
|||
Loading…
Reference in a new issue