[gtk/present-toplevel-2: 46/79] surface: Implement toplevel wm properties



commit 784181ca75ef4390b8149a2f35081b57c3ae1c84
Author: Matthias Clasen <mclasen redhat com>
Date:   Tue Mar 3 12:19:54 2020 -0800

    surface: Implement toplevel wm properties

 gdk/gdksurface.c | 19 +++++++++++++++++++
 1 file changed, 19 insertions(+)
---
diff --git a/gdk/gdksurface.c b/gdk/gdksurface.c
index 0709f9b60c..7b42135d6a 100644
--- a/gdk/gdksurface.c
+++ b/gdk/gdksurface.c
@@ -696,6 +696,17 @@ gdk_surface_set_property (GObject      *object,
           g_object_notify_by_pspec (G_OBJECT (surface), pspec);
         }
       break;
+
+    case LAST_PROP + GDK_POPUP_NUM_PROPERTIES + GDK_TOPLEVEL_PROP_DECORATED:
+      GDK_SURFACE_GET_CLASS (surface)->set_decorations (surface, g_value_get_boolean (value) ? GDK_DECOR_ALL 
: 0);
+      g_object_notify_by_pspec (G_OBJECT (surface), pspec);
+      break;
+
+    case LAST_PROP + GDK_POPUP_NUM_PROPERTIES + GDK_TOPLEVEL_PROP_DELETABLE:
+      GDK_SURFACE_GET_CLASS (surface)->set_functions (surface, g_value_get_boolean (value) ? GDK_FUNC_ALL : 
GDK_FUNC_ALL | GDK_FUNC_CLOSE);
+      g_object_notify_by_pspec (G_OBJECT (surface), pspec);
+      break;
+
     default:
       G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
       break;
@@ -784,6 +795,14 @@ gdk_surface_get_property (GObject    *object,
       g_value_set_boolean (value, surface->focus_on_map);
       break;
 
+    case LAST_PROP + GDK_POPUP_NUM_PROPERTIES + GDK_TOPLEVEL_PROP_DECORATED:
+      g_value_set_boolean (value, FALSE); // FIXME
+      break;
+
+    case LAST_PROP + GDK_POPUP_NUM_PROPERTIES + GDK_TOPLEVEL_PROP_DELETABLE:
+      g_value_set_boolean (value, FALSE); // FIXME
+      break;
+
     default:
       G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
       break;


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