From d0c145d5a3bc3dfa286bc25912b34b902660cc1f Mon Sep 17 00:00:00 2001 From: Alexander Golubev Date: Wed, 7 Feb 2024 14:15:49 +0300 Subject: kxkb: handle resetOld correctly in cases if all opions already set Closes: https://mirror.git.trinitydesktop.org/gitea/TDE/tdebase/issues/391 Signed-off-by: Alexander Golubev --- kxkb/extension.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'kxkb') diff --git a/kxkb/extension.cpp b/kxkb/extension.cpp index df61e2fa2..870ee7eb4 100644 --- a/kxkb/extension.cpp +++ b/kxkb/extension.cpp @@ -112,11 +112,9 @@ bool XKBExtension::setXkbOptions(const XkbOptions options) } if (!options.options.isEmpty()) { - p << "-option"; - if (options.resetOld) { - p << options.options; + p << "-option" << options.options; } else { @@ -132,7 +130,9 @@ bool XKBExtension::setXkbOptions(const XkbOptions options) newOptions << option; } } - p << newOptions.join(","); + if (!newOptions.isEmpty()) { + p << "-option" << newOptions.join(","); + } } } -- cgit v1.2.1