keyboard: Don't fall back to next model after we found a valid one
The fallback for creating models is to try the next one in case the current one can not be created, until we fall all the way back to the US layout. Obviously we shouldn't fall back in case creating the model actually worked, so break out of the loop and then use the new model. Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3230>
This commit is contained in:
parent
4a81099ff2
commit
fc58f6f053
@ -1429,8 +1429,9 @@ export const Keyboard = GObject.registerClass({
|
||||
for (const group of groups) {
|
||||
try {
|
||||
keyboardModel = new KeyboardModel(group);
|
||||
break;
|
||||
} catch (e) {
|
||||
// Ignore this error
|
||||
// Ignore this error and fall back to next model
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user