mirror of
https://github.com/labwc/labwc.git
synced 2026-03-17 05:33:47 -04:00
xwayland: fix missing title and icon with override-redirect toggle
When an X11 client clears override-redirect on a window (i.e. it becomes "managed") without an unmap/map cycle, wlroots doesn't re-emit the set_title/class/icon events. We need to synthesize them to re-read the values from the surface. From what I can tell, only older/misbehaving X11 clients would actually do this (toggle override-redirect without unmap/map), so this is perhaps a bit pedantic, but an easy fix anyway.
This commit is contained in:
parent
5a9ae66332
commit
c4effef0ec
1 changed files with 10 additions and 0 deletions
|
|
@ -1091,6 +1091,16 @@ xwayland_view_create(struct server *server,
|
|||
|
||||
if (xsurface->surface) {
|
||||
handle_associate(&xwayland_view->associate, NULL);
|
||||
/*
|
||||
* If a surface is already associated, then we've
|
||||
* missed the various initial set_* events as well.
|
||||
*
|
||||
* TODO: update_icon() -> handle_set_icon() after
|
||||
* https://github.com/labwc/labwc/pull/2760
|
||||
*/
|
||||
handle_set_title(&view->set_title, NULL);
|
||||
handle_set_class(&xwayland_view->set_class, NULL);
|
||||
update_icon(xwayland_view);
|
||||
}
|
||||
if (mapped) {
|
||||
handle_map(&xwayland_view->base.mappable.map, NULL);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue