From d29e5765badbca21a6ef8b40087a8e3587b15dd4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Florian=20M=C3=BCllner?= Date: Mon, 23 Mar 2020 16:14:47 +0100 Subject: [PATCH] keyboard: Fix fallback layout when using variants Commit c1ec7b2ff meant to fall back to the base layout in case a variant like `fr+oss` is set up, but as we are checking for '+' on the array rather than the layout name, the fallback only "works" for a layout that is literally called '+', whoops. https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/2471 --- js/ui/keyboard.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/js/ui/keyboard.js b/js/ui/keyboard.js index 635d9b12e..7d56ef9c8 100644 --- a/js/ui/keyboard.js +++ b/js/ui/keyboard.js @@ -498,7 +498,7 @@ var Key = GObject.registerClass({ var KeyboardModel = class { constructor(groupName) { let names = [groupName]; - if (names.includes('+')) + if (groupName.includes('+')) names.push(groupName.replace(/\+.*/, '')); names.push('us');