diff --git a/WINGs/wclient_wl.c b/WINGs/wclient_wl.c index 246ec9c..4cc34e4 100644 --- a/WINGs/wclient_wl.c +++ b/WINGs/wclient_wl.c @@ -305,6 +305,18 @@ xdg_surface_handle_configure(void *data, struct xdg_surface *xs, uint32_t serial W_SetViewBacking(top->view->window, nb->image); top->view->size.width = top->pending_w; top->view->size.height = top->pending_h; + + /* Notify WINGs of the resize so widget delegates relayout */ + WMEvent cev; + memset(&cev, 0, sizeof(cev)); + cev.type = WME_CONFIGURE; + cev.window = top->view->window; + cev.u.configure.window = top->view->window; + cev.u.configure.event = top->view->window; + cev.u.configure.width = top->pending_w; + cev.u.configure.height = top->pending_h; + W_WL_EnqueueEvent(top->ctx->scr, &cev, top->view); + /* Repaint all content into the new buffer */ if (top->view->flags.mapped) { extern void (*W_WLClientRedisplayFn)(W_View *view); diff --git a/WINGs/wview_wl.c b/WINGs/wview_wl.c index 2bf7984..dbf3994 100644 --- a/WINGs/wview_wl.c +++ b/WINGs/wview_wl.c @@ -443,13 +443,18 @@ static void wl_redisplay(void *vctx, W_View *view) /* Re-composite all mapped children into this view's backing */ W_View *child = view->childrenList; + int _childcount = 0; while (child) { W_View *next = child->nextSister; + _childcount++; if (child->flags.mapped && child->flags.realized && !child->flags.alreadyDead) { wl_redisplay(vctx, child); } child = next; } + if (_childcount > 2 && view->size.height > 50 && view->size.height < 100) + wwarning("wl_redisplay: view %p size=%dx%d children=%d", + (void*)view, view->size.width, view->size.height, _childcount); /* Composite this view's backing into its parent's backing */ if (view->parent) {