diff --git a/hw/xwayland/desktop/org.freedesktop.Xwayland.desktop b/hw/xwayland/desktop/org.freedesktop.Xwayland.desktop new file mode 100644 index 000000000..d0122adf5 --- /dev/null +++ b/hw/xwayland/desktop/org.freedesktop.Xwayland.desktop @@ -0,0 +1,7 @@ +[Desktop Entry] +Name=Xwayland +Comment=A rootful instance of the Xwayland X11 server +Terminal=false +Type=Application +Categories=System; +NoDisplay=true diff --git a/hw/xwayland/meson.build b/hw/xwayland/meson.build index cd5bf7a53..40aec1587 100644 --- a/hw/xwayland/meson.build +++ b/hw/xwayland/meson.build @@ -173,3 +173,7 @@ xwayland_manpage = configure_file( configuration: manpage_config, ) install_man(xwayland_manpage) + +datadir = join_paths(get_option('prefix'), get_option('datadir')) +desktopdir = join_paths(datadir, 'applications') +install_data('desktop/org.freedesktop.Xwayland.desktop', install_dir : desktopdir) diff --git a/hw/xwayland/xwayland-window.c b/hw/xwayland/xwayland-window.c index a8dce8d45..f3ca987fd 100644 --- a/hw/xwayland/xwayland-window.c +++ b/hw/xwayland/xwayland-window.c @@ -489,6 +489,15 @@ xwl_window_rootful_update_title(struct xwl_window *xwl_window) xdg_toplevel_set_title(xwl_window->xdg_toplevel, title); } +static void +xwl_window_rootful_set_app_id(struct xwl_window *xwl_window) +{ + const char *app_id = "org.freedesktop.Xwayland"; + + if (xwl_window->xdg_toplevel) + xdg_toplevel_set_app_id(xwl_window->xdg_toplevel, app_id); +} + static void xdg_surface_handle_configure(void *data, struct xdg_surface *xdg_surface, @@ -594,6 +603,7 @@ xwl_create_root_surface(struct xwl_window *xwl_window) NULL); xwl_window_rootful_update_title(xwl_window); + xwl_window_rootful_set_app_id(xwl_window); wl_surface_commit(xwl_window->surface);