Exclude non-drawable widgets from focus

This was showing up as confusion between palette
and editor in the color chooser.
This commit is contained in:
Matthias Clasen 2019-03-02 20:32:11 -05:00
parent 8c1d852a84
commit 94b0e99be5

View File

@ -422,7 +422,9 @@ gtk_widget_focus_sort (GtkWidget *widget,
child != NULL;
child = _gtk_widget_get_next_sibling (child))
{
if (_gtk_widget_get_realized (child))
if (_gtk_widget_get_realized (child) &&
_gtk_widget_is_drawable (child) &&
gtk_widget_get_sensitive (child))
g_ptr_array_add (focus_order, child);
}
}