Ejemplo n.º 1
0
static MetaWaylandSurface *
xdg_popup_role_get_toplevel (MetaWaylandSurfaceRole *surface_role)
{
  MetaWaylandXdgPopup *xdg_popup = META_WAYLAND_XDG_POPUP (surface_role);

  return meta_wayland_surface_get_toplevel (xdg_popup->parent_surface);
}
Ejemplo n.º 2
0
static MetaWaylandSurface *
wl_shell_surface_role_get_toplevel (MetaWaylandSurfaceRole *surface_role)
{
  MetaWaylandWlShellSurface *wl_shell_surface =
    META_WAYLAND_WL_SHELL_SURFACE (surface_role);

  if (wl_shell_surface->state == META_WL_SHELL_SURFACE_STATE_POPUP &&
      wl_shell_surface->parent_surface)
    return meta_wayland_surface_get_toplevel (wl_shell_surface->parent_surface);
  else
    return meta_wayland_surface_role_get_surface (surface_role);
}