[gtk/wip/matthiasc/popup5: 54/130] widget: guard popover-specific code paths
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/wip/matthiasc/popup5: 54/130] widget: guard popover-specific code paths
- Date: Thu, 2 May 2019 02:12:30 +0000 (UTC)
commit 0f88ed91d36789dd46db5435e34842623e9f10b1
Author: Matthias Clasen <mclasen redhat com>
Date: Sun Feb 24 18:41:26 2019 -0500
widget: guard popover-specific code paths
This is essentially a special case just for GtkPopover,
which is the last widget with a child surface.
gtk/gtkwidget.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
---
diff --git a/gtk/gtkwidget.c b/gtk/gtkwidget.c
index 3ae53fdb09..37a5e6bd95 100644
--- a/gtk/gtkwidget.c
+++ b/gtk/gtkwidget.c
@@ -4437,7 +4437,8 @@ gtk_widget_allocate (GtkWidget *widget,
{
/* Still have to move the window... */
if (_gtk_widget_get_realized (widget) &&
- _gtk_widget_get_has_surface (widget))
+ _gtk_widget_get_has_surface (widget) &&
+ GTK_IS_POPOVER (widget))
{
GtkAllocation window_alloc;
@@ -4649,7 +4650,8 @@ gtk_widget_real_size_allocate (GtkWidget *widget,
GtkWidgetPrivate *priv = gtk_widget_get_instance_private (widget);
if (_gtk_widget_get_realized (widget) &&
- _gtk_widget_get_has_surface (widget))
+ _gtk_widget_get_has_surface (widget) &&
+ GTK_IS_POPOVER (widget))
{
GtkAllocation window_alloc;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]