mirror of
https://github.com/labwc/labwc.git
synced 2026-02-15 22:05:25 -05:00
Chase wlroots: Unified mapping
Need to handle new unified mapping, where mapping is attached to the wlr_surface objects instead of their parents. Also, most of them require a new associate event for xsurface objects, their surface member will be NULL before this event is received. Refactored by jlindgren: - add struct mappable - unify map/unmap logic
This commit is contained in:
parent
bf576e97de
commit
d7dc6e01b4
10 changed files with 142 additions and 52 deletions
17
src/xdg.c
17
src/xdg.c
|
|
@ -163,20 +163,6 @@ set_pending_configure_serial(struct view *view, uint32_t serial)
|
|||
CONFIGURE_TIMEOUT_MS);
|
||||
}
|
||||
|
||||
static void
|
||||
handle_map(struct wl_listener *listener, void *data)
|
||||
{
|
||||
struct view *view = wl_container_of(listener, view, map);
|
||||
view->impl->map(view);
|
||||
}
|
||||
|
||||
static void
|
||||
handle_unmap(struct wl_listener *listener, void *data)
|
||||
{
|
||||
struct view *view = wl_container_of(listener, view, unmap);
|
||||
view->impl->unmap(view, /* client_request */ true);
|
||||
}
|
||||
|
||||
static void
|
||||
handle_destroy(struct wl_listener *listener, void *data)
|
||||
{
|
||||
|
|
@ -688,8 +674,7 @@ xdg_surface_new(struct wl_listener *listener, void *data)
|
|||
/* In support of xdg popups */
|
||||
xdg_surface->surface->data = tree;
|
||||
|
||||
CONNECT_SIGNAL(xdg_surface, view, map);
|
||||
CONNECT_SIGNAL(xdg_surface, view, unmap);
|
||||
view_connect_map(view, xdg_surface->surface);
|
||||
CONNECT_SIGNAL(xdg_surface, view, destroy);
|
||||
|
||||
struct wlr_xdg_toplevel *toplevel = xdg_surface->toplevel;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue