forked from AuroraMiddleware/gtk
popover: Update scrollable on relative-to hierarchy changes
The relative-to widget may be reparented itself into/out of a scrollable. In this cases make the hierachy-changed handler to unset the parent scrollable when unparented, and look up again the parent scrollable after it's reparented. https://bugzilla.gnome.org/show_bug.cgi?id=771812
This commit is contained in:
parent
588a1dce2b
commit
769ee1156d
@ -1821,11 +1821,15 @@ _gtk_popover_parent_hierarchy_changed (GtkWidget *widget,
|
||||
if (priv->window)
|
||||
_gtk_window_remove_popover (priv->window, GTK_WIDGET (popover));
|
||||
|
||||
if (priv->parent_scrollable)
|
||||
gtk_popover_set_scrollable_full (popover, NULL);
|
||||
|
||||
priv->window = new_window;
|
||||
|
||||
if (new_window)
|
||||
{
|
||||
_gtk_window_add_popover (new_window, GTK_WIDGET (popover), priv->widget, TRUE);
|
||||
gtk_popover_update_scrollable (popover);
|
||||
gtk_popover_update_position (popover);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user