diff --git a/sddm-theme/KeyboardButton.qml b/sddm-theme/KeyboardButton.qml index 5282b16df..6b4dc4b3b 100644 --- a/sddm-theme/KeyboardButton.qml +++ b/sddm-theme/KeyboardButton.qml @@ -32,6 +32,8 @@ PlasmaComponents.ToolButton { } } + signal keyboardLayoutChanged + PlasmaComponents.Menu { id: menu PlasmaCore.ColorScope.colorGroup: PlasmaCore.Theme.NormalColorGroup @@ -47,6 +49,7 @@ PlasmaComponents.ToolButton { property string shortName: modelData.shortName onTriggered: { keyboard.currentLayout = model.index + keyboardLayoutChanged() } } } diff --git a/sddm-theme/Main.qml b/sddm-theme/Main.qml index 690c132e3..eddb60231 100644 --- a/sddm-theme/Main.qml +++ b/sddm-theme/Main.qml @@ -557,11 +557,23 @@ PlasmaCore.ColorScope { KeyboardButton { font.pointSize: config.fontSize + + keyboardLayoutChanged: { + // Otherwise the password field loses focus and virtual keyboard + // keystrokes get eaten + userListComponent.mainPasswordBox.forceActiveFocus(); + } } SessionButton { id: sessionButton font.pointSize: config.fontSize + + onSessionChanged: { + // Otherwise the password field loses focus and virtual keyboard + // keystrokes get eaten + userListComponent.mainPasswordBox.forceActiveFocus(); + } } Item { diff --git a/sddm-theme/SessionButton.qml b/sddm-theme/SessionButton.qml index 5661a1ecd..03e549e70 100644 --- a/sddm-theme/SessionButton.qml +++ b/sddm-theme/SessionButton.qml @@ -29,6 +29,8 @@ PlasmaComponents.ToolButton { } } + signal sessionChanged + PlasmaComponents.Menu { PlasmaCore.ColorScope.colorGroup: PlasmaCore.Theme.NormalColorGroup PlasmaCore.ColorScope.inherit: false @@ -43,6 +45,7 @@ PlasmaComponents.ToolButton { text: model.name onTriggered: { root.currentIndex = model.index + sessionChanged() } } }