Fixed clipboard not working on GNOME Wayland.

This commit is contained in:
Bettehem
2022-08-17 15:13:01 +03:00
committed by Henrik Friedrichsen
parent d3e89115d7
commit 0af93f816d

View File

@@ -34,7 +34,13 @@ fn is_wayland() -> bool {
fn gdk_backend() -> String {
env::var("GDK_BACKEND").unwrap_or_default()
}
session_type().as_str() == "wayland" || !wl_display().is_empty() || gdk_backend() == "wayland"
fn current_desktop() -> String {
env::var("XDG_CURRENT_DESKTOP").unwrap_or_default()
}
current_desktop() != "GNOME"
&& (session_type().as_str() == "wayland"
|| !wl_display().is_empty()
|| gdk_backend() == "wayland")
}
#[cfg(not(feature = "share_selection"))]