[gtk+/wip/csd: 429/429] window: Don't decorate non-toplevel windows



commit a580e3b97da1094061751bd97a3ef96fd6624409
Author: Rob Bradford <rob linux intel com>
Date:   Sat Jul 28 15:13:52 2012 +0100

    window: Don't decorate non-toplevel windows

 gtk/gtkwindow.c |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)
---
diff --git a/gtk/gtkwindow.c b/gtk/gtkwindow.c
index f1ff2ab..c9b4dfb 100644
--- a/gtk/gtkwindow.c
+++ b/gtk/gtkwindow.c
@@ -6705,7 +6705,7 @@ gtk_window_get_preferred_width (GtkWidget *widget,
   border_width =
     2 * gtk_container_get_border_width (GTK_CONTAINER (window));
 
-  if (priv->client_decorated)
+  if (priv->client_decorated && priv->type == GTK_WINDOW_TOPLEVEL)
     {
       context = gtk_widget_get_style_context (widget);
       state = gtk_style_context_get_state (context);
@@ -6765,7 +6765,7 @@ gtk_window_get_preferred_height (GtkWidget *widget,
   *minimum_size = 0;
   *natural_size = 0;
 
-  if (priv->client_decorated)
+  if (priv->client_decorated && priv->type == GTK_WINDOW_TOPLEVEL)
     {
       context = gtk_widget_get_style_context (widget);
       state = gtk_style_context_get_state (context);
@@ -7948,7 +7948,7 @@ gtk_window_draw (GtkWidget *widget,
 
       gtk_style_context_add_class (context, GTK_STYLE_CLASS_BACKGROUND);
 
-      if (priv->client_decorated)
+      if (priv->client_decorated && priv->type == GTK_WINDOW_TOPLEVEL)
 	{
 	  gtk_style_context_add_class (context, "window-border");
 	  gtk_widget_get_allocation (widget, &allocation);



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