return occludes;
}
-void stacking_restack_request(ObClient *client, ObClient *sibling,
- gint detail, gboolean activate)
+gboolean stacking_restack_request(ObClient *client, ObClient *sibling,
+ gint detail, gboolean activate)
{
+ gboolean ret = FALSE;
+
if (sibling && ((client->desktop != sibling->desktop &&
client->desktop != DESKTOP_ALL &&
sibling->desktop != DESKTOP_ALL) ||
client->title, sibling ? sibling->title : "(all)");
/* just lower it */
stacking_lower(CLIENT_AS_WINDOW(client));
+ ret = TRUE;
break;
case BottomIf:
ob_debug("Restack request BottomIf for client %s sibling "
client->title, sibling ? sibling->title : "(all)");
/* if this client occludes sibling (or anything if NULL), then
lower it to the bottom */
- if (stacking_occludes(client, sibling))
+ if (stacking_occludes(client, sibling)) {
stacking_lower(CLIENT_AS_WINDOW(client));
+ ret = TRUE;
+ }
break;
case Above:
ob_debug("Restack request Above for client %s sibling %s\n",
client_activate(client, FALSE, TRUE);
else
stacking_raise(CLIENT_AS_WINDOW(client));
+ ret = TRUE;
break;
case TopIf:
ob_debug("Restack request TopIf for client %s sibling %s\n",
client_activate(client, FALSE, TRUE);
else
stacking_raise(CLIENT_AS_WINDOW(client));
+ ret = TRUE;
}
break;
case Opposite:
client_activate(client, FALSE, TRUE);
else
stacking_raise(CLIENT_AS_WINDOW(client));
+ ret = TRUE;
}
- else if (stacking_occludes(client, sibling))
+ else if (stacking_occludes(client, sibling)) {
stacking_lower(CLIENT_AS_WINDOW(client));
+ ret = TRUE;
+ }
break;
}
+ return ret;
}
@param detail One of Above, Below, TopIf, BottomIf, Opposite
@param activate If TRUE, and if the window is going to be raised, it will
be activated instead
+ @return TRUE if the client was restacked
See http://tronche.com/gui/x/xlib/window/configure.html for details on
how each detail works with and without a sibling.
*/
-void stacking_restack_request(struct _ObClient *client,
- struct _ObClient *sibling,
- gint detail, gboolean activate);
+gboolean stacking_restack_request(struct _ObClient *client,
+ struct _ObClient *sibling,
+ gint detail, gboolean activate);
#endif