[gtk+] frame: Properly initialize clip
- From: Timm Bäder <baedert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+] frame: Properly initialize clip
- Date: Fri, 28 Apr 2017 09:25:33 +0000 (UTC)
commit bbe53855419737915cfbd90bf91d785f7f1f48a8
Author: Timm Bäder <mail baedert org>
Date: Fri Apr 28 11:26:25 2017 +0200
frame: Properly initialize clip
GtkCssGadget initializes the content clip to {0, 0, 0, 0}, so we can't
just union the child clip with it.
gtk/gtkframe.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
---
diff --git a/gtk/gtkframe.c b/gtk/gtkframe.c
index fc4381c..05b603d 100644
--- a/gtk/gtkframe.c
+++ b/gtk/gtkframe.c
@@ -688,7 +688,7 @@ static void
gtk_frame_size_allocate (GtkWidget *widget,
GtkAllocation *allocation)
{
- GtkAllocation clip = *allocation;
+ GtkAllocation clip;
gtk_widget_set_allocation (widget, allocation);
@@ -721,6 +721,8 @@ gtk_frame_allocate (GtkCssGadget *gadget,
gtk_frame_compute_child_allocation (frame, &new_allocation);
priv->child_allocation = new_allocation;
+ *out_clip = *allocation;
+
if (priv->label_widget &&
gtk_widget_get_visible (priv->label_widget))
{
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]