[gtk+] popover: Update scrollable on relative-to hierarchy changes
- From: Carlos Garnacho <carlosg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+] popover: Update scrollable on relative-to hierarchy changes
- Date: Thu, 29 Sep 2016 10:48:59 +0000 (UTC)
commit 769ee1156de0cb2b4528e56234315848fc73acc8
Author: Carlos Garnacho <carlosg gnome org>
Date: Wed Sep 28 19:56:49 2016 +0200
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
gtk/gtkpopover.c | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
---
diff --git a/gtk/gtkpopover.c b/gtk/gtkpopover.c
index 94da422..abfb90f 100644
--- a/gtk/gtkpopover.c
+++ b/gtk/gtkpopover.c
@@ -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);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]