[gtk: 41/88] gtk/window: Only deal with shadow when (ex|in)cluding csd size




commit a798edc360bc49190034e9b2c0713996eaf16b38
Author: Jonas Ã…dahl <jadahl gmail com>
Date:   Wed Dec 2 17:42:42 2020 +0100

    gtk/window: Only deal with shadow when (ex|in)cluding csd size
    
    The size should correspond what gtk_widget_measure() does, and it
    measures what's within the window excluding the shadow; so make this
    helper function correspond to this.

 gtk/gtkwindow.c | 13 -------------
 1 file changed, 13 deletions(-)
---
diff --git a/gtk/gtkwindow.c b/gtk/gtkwindow.c
index 5f7e363c22..4660dd40ce 100644
--- a/gtk/gtkwindow.c
+++ b/gtk/gtkwindow.c
@@ -3307,19 +3307,6 @@ gtk_window_update_csd_size (GtkWindow *window,
   w = *width + apply * (window_border.left + window_border.right);
   h = *height + apply * (window_border.top + window_border.bottom);
 
-  if (priv->title_box != NULL &&
-      gtk_widget_get_visible (priv->title_box) &&
-      gtk_widget_get_child_visible (priv->title_box))
-    {
-      int minimum_height;
-      int natural_height;
-
-      gtk_widget_measure (priv->title_box, GTK_ORIENTATION_VERTICAL, -1,
-                          &minimum_height, &natural_height,
-                          NULL, NULL);
-      h += apply * natural_height;
-    }
-
   /* Make sure the size remains acceptable */
   if (w < 1)
     w = 1;


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]