aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/niri.rs11
1 files changed, 9 insertions, 2 deletions
diff --git a/src/niri.rs b/src/niri.rs
index 9498a379..fd4112e6 100644
--- a/src/niri.rs
+++ b/src/niri.rs
@@ -2184,7 +2184,7 @@ impl State {
self.niri.dynamic_cast_id_for_portal.get(),
gnome_shell_introspect::WindowProperties {
title: String::from("niri Dynamic Cast Target"),
- app_id: String::from("rs.bxt.niri"),
+ app_id: String::from("rs.bxt.niri.desktop"),
},
);
@@ -2193,7 +2193,14 @@ impl State {
let props = with_toplevel_role(mapped.toplevel(), |role| {
gnome_shell_introspect::WindowProperties {
title: role.title.clone().unwrap_or_default(),
- app_id: role.app_id.clone().unwrap_or_default(),
+ app_id: role
+ .app_id
+ .as_ref()
+ // We don't do proper .desktop file tracking (it's quite involved), and
+ // Wayland windows can set any app id they want. However, this seems to
+ // work well enough in practice.
+ .map(|app_id| format!("{app_id}.desktop"))
+ .unwrap_or_default(),
}
});