Fix GPtrArray sorting function
GPtrArray's GCompareFunc passes a double pointer that needs to be dereferenced in order to use the data you are actually wanting to compare. See: https://developer.gnome.org/glib/stable/glib-Pointer-Arrays.html#g-ptr-array-sort
This commit is contained in:
parent
e930c7ef64
commit
6a507c0b63
@ -1228,8 +1228,8 @@ static gint
|
|||||||
gtk_tool_palette_compare_groups (gconstpointer a,
|
gtk_tool_palette_compare_groups (gconstpointer a,
|
||||||
gconstpointer b)
|
gconstpointer b)
|
||||||
{
|
{
|
||||||
const GtkToolItemGroupInfo *group_a = a;
|
const GtkToolItemGroupInfo *group_a = *((GtkToolItemGroupInfo **) a);
|
||||||
const GtkToolItemGroupInfo *group_b = b;
|
const GtkToolItemGroupInfo *group_b = *((GtkToolItemGroupInfo **) b);
|
||||||
|
|
||||||
return group_a->pos - group_b->pos;
|
return group_a->pos - group_b->pos;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user