From 4dd43c0f1c0520ad93b3b836aab06baedf8eb919 Mon Sep 17 00:00:00 2001 From: Thomas Deutschmann Date: Thu, 2 Apr 2020 23:16:14 +0200 Subject: [PATCH] www-client/firefox: don't enable XINPUT2 for KWin users Closes: https://bugs.gentoo.org/715604 Package-Manager: Portage-2.3.96, Repoman-2.3.22 Signed-off-by: Thomas Deutschmann --- www-client/firefox/files/firefox.sh | 20 ++++++++++++++++++- ...6.0-r3.ebuild => firefox-68.6.0-r4.ebuild} | 0 ...-74.0-r2.ebuild => firefox-74.0-r3.ebuild} | 0 3 files changed, 19 insertions(+), 1 deletion(-) rename www-client/firefox/{firefox-68.6.0-r3.ebuild => firefox-68.6.0-r4.ebuild} (100%) rename www-client/firefox/{firefox-74.0-r2.ebuild => firefox-74.0-r3.ebuild} (100%) diff --git a/www-client/firefox/files/firefox.sh b/www-client/firefox/files/firefox.sh index f1fde8fdfce0..c08d555196d6 100644 --- a/www-client/firefox/files/firefox.sh +++ b/www-client/firefox/files/firefox.sh @@ -93,7 +93,25 @@ fi ## ## Enable Xinput2 (#617344) ## -export MOZ_USE_XINPUT2=1 + +# respect user settings +MOZ_USE_XINPUT2=${MOZ_USE_XINPUT2:-auto} + +if [[ ${MOZ_USE_XINPUT2} == auto && -n ${WAYLAND_DISPLAY} ]]; then + # enabling XINPUT2 should be safe for all wayland users + MOZ_USE_XINPUT2=1 +elif [[ ${MOZ_USE_XINPUT2} == auto && ${XDG_CURRENT_DESKTOP^^} == KDE ]]; then + # XINPUT2 is known to cause problems for KWin users + MOZ_USE_XINPUT2=0 +elif [[ ${MOZ_USE_XINPUT2} == auto && ${XDG_CURRENT_DESKTOP^^} == LXQT ]]; then + # LXQt uses KWin + MOZ_USE_XINPUT2=0 +elif [[ ${MOZ_USE_XINPUT2} == auto ]]; then + # should work on Mate, Xfce, FluxBox, OpenBox and all the others ... + MOZ_USE_XINPUT2=1 +fi + +[[ ${MOZ_USE_XINPUT2} != 0 ]] && export MOZ_USE_XINPUT2=${MOZ_USE_XINPUT2} # Don't throw "old profile" dialog box. export MOZ_ALLOW_DOWNGRADE=1 diff --git a/www-client/firefox/firefox-68.6.0-r3.ebuild b/www-client/firefox/firefox-68.6.0-r4.ebuild similarity index 100% rename from www-client/firefox/firefox-68.6.0-r3.ebuild rename to www-client/firefox/firefox-68.6.0-r4.ebuild diff --git a/www-client/firefox/firefox-74.0-r2.ebuild b/www-client/firefox/firefox-74.0-r3.ebuild similarity index 100% rename from www-client/firefox/firefox-74.0-r2.ebuild rename to www-client/firefox/firefox-74.0-r3.ebuild -- 2.26.2