diff --git a/lookandfeel/contents/lockscreen/LockScreenUi.qml b/lookandfeel/contents/lockscreen/LockScreenUi.qml --- a/lookandfeel/contents/lockscreen/LockScreenUi.qml +++ b/lookandfeel/contents/lockscreen/LockScreenUi.qml @@ -84,12 +84,6 @@ icon: kscreenlocker_userImage, }) - if (sessionsModel.canStartNewSession) { - users.append({realName: i18nd("plasma_lookandfeel_org.kde.lookandfeel", "New Session"), - name: "__new_session", - iconName: "list-add" - }) - } } } @@ -111,10 +105,6 @@ return text } - onNewSession: { - sessionsModel.startNewSession(false); - } - onLoginRequest: { root.notification = "" authenticator.tryUnlock(password) @@ -125,7 +115,7 @@ text: i18nd("org.kde.plasma_lookandfeel_org.kde.lookandfeel", "Switch User") iconSource: "system-switch-user" onClicked: mainStack.push(switchSessionPage) - visible: sessionsModel.count > 1 && sessionsModel.canSwitchUser + visible: sessionsModel.canSwitchUser } ] } @@ -138,7 +128,7 @@ PlasmaComponents.Button { Layout.fillWidth: true - text: i18nd("plasma_lookandfeel_org.kde.lookandfeel", "Switch Session") + text: userListCurrentIndex == sessionsModel.count - 1 ? i18nd("plasma_lookandfeel_org.kde.lookandfeel", "Start New Session") : i18nd("plasma_lookandfeel_org.kde.lookandfeel", "Switch Session") onClicked: { sessionsModel.switchUser(userListCurrentModelData.vtNumber) mainStack.pop() diff --git a/lookandfeel/contents/lockscreen/MainBlock.qml b/lookandfeel/contents/lockscreen/MainBlock.qml --- a/lookandfeel/contents/lockscreen/MainBlock.qml +++ b/lookandfeel/contents/lockscreen/MainBlock.qml @@ -34,16 +34,7 @@ */ signal loginRequest(string password) - /* - */ - signal newSession() - function startLogin() { - if (userListCurrentIndex == 1) { - newSession() - return; - } - var password = passwordBox.text //this is partly because it looks nicer @@ -64,8 +55,6 @@ onAccepted: startLogin() - visible: userListCurrentIndex == 0 - //if empty and left or right is pressed change selection in user switch //this cannot be in keys.onLeftPressed as then it doesn't reach the password box Keys.onPressed: { @@ -92,7 +81,7 @@ id: loginButton Layout.fillWidth: true - text: userListCurrentIndex == 0 ? i18nd("plasma_lookandfeel_org.kde.lookandfeel", "Unlock") : i18nd("plasma_lookandfeel_org.kde.lookandfeel", "Start New Session") + text: i18nd("plasma_lookandfeel_org.kde.lookandfeel", "Unlock") onClicked: startLogin() } }