]> Dogcows Code - chaz/openbox/blobdiff - openbox/client.c
add the notion of "application windows" meaning normal or dialog type windows.
[chaz/openbox] / openbox / client.c
index 34ae4d868f5e770e7e58592f1ccd05cdb8967246..c7859ca67838fa87dfd5c65789d18b24783f44c3 100644 (file)
@@ -2198,6 +2198,12 @@ gboolean client_normal(ObClient *self) {
               self->type == OB_CLIENT_TYPE_SPLASH);
 }
 
+gboolean client_application(ObClient *self)
+{
+    return (self->type == OB_CLIENT_TYPE_NORMAL ||
+            self->type == OB_CLIENT_TYPE_DIALOG);
+}
+
 static void client_apply_startup_state(ObClient *self, gint x, gint y)
 {
     gboolean pos = FALSE; /* has the window's position been configured? */
@@ -3633,3 +3639,17 @@ gboolean client_has_group_siblings(ObClient *self)
 {
     return self->group && self->group->members->next;
 }
+
+gboolean client_has_application_group_siblings(ObClient *self)
+{
+    GSList *it;
+
+    if (!self->group) return FALSE;
+
+    for (it = self->group->members; it; it = g_slist_next(it)) {
+        ObClient *c = it->data;
+        if (c != self && client_application(c))
+            return TRUE;
+    }
+    return FALSE;
+}
This page took 0.020234 seconds and 4 git commands to generate.