render windows across monitors

This commit is contained in:
Devin J. Pohly 2020-04-26 20:00:06 -05:00
parent aa7020b344
commit b025b7bdbd
1 changed files with 6 additions and 4 deletions

10
dwl.c
View File

@ -855,10 +855,12 @@ renderclients(Monitor *m, struct timespec *now)
* our stacking list is ordered front-to-back, we iterate over it backwards. */ * our stacking list is ordered front-to-back, we iterate over it backwards. */
Client *c; Client *c;
wl_list_for_each_reverse(c, &stack, slink) { wl_list_for_each_reverse(c, &stack, slink) {
/* Only render clients which are on this monitor. */ /* Only render visible clients which show on this monitor */
/* XXX consider checking wlr_output_layout_intersects, in case a struct wlr_box cbox = {
* window can be seen on multiple outputs */ .x = c->x, .y = c->y, .width = c->w, .height = c->h,
if (!VISIBLEON(c, m)) };
if (!VISIBLEON(c, c->mon) || !wlr_output_layout_intersects(
output_layout, m->wlr_output, &cbox))
continue; continue;
double ox = c->x, oy = c->y; double ox = c->x, oy = c->y;