Don't show the "Settings" button when adding a new account
As much as I like opening Settings while I'm in Settings, this doesn't make much sense.
This commit is contained in:
@@ -17,6 +17,7 @@ Kirigami.Page {
|
|||||||
|
|
||||||
property bool showExisting: false
|
property bool showExisting: false
|
||||||
property bool _showExisting: showExisting && root.currentStepString === root.initialStep
|
property bool _showExisting: showExisting && root.currentStepString === root.initialStep
|
||||||
|
property bool showSettings: true
|
||||||
property alias currentStep: module.item
|
property alias currentStep: module.item
|
||||||
property string currentStepString: initialStep
|
property string currentStepString: initialStep
|
||||||
property string initialStep: "LoginRegister"
|
property string initialStep: "LoginRegister"
|
||||||
@@ -265,6 +266,7 @@ Kirigami.Page {
|
|||||||
FormCard.FormCard {
|
FormCard.FormCard {
|
||||||
Layout.topMargin: Kirigami.Units.largeSpacing * 2
|
Layout.topMargin: Kirigami.Units.largeSpacing * 2
|
||||||
maximumWidth: Kirigami.Units.gridUnit * 20
|
maximumWidth: Kirigami.Units.gridUnit * 20
|
||||||
|
visible: root.showSettings
|
||||||
FormCard.FormButtonDelegate {
|
FormCard.FormButtonDelegate {
|
||||||
text: i18nc("@action:button", "Settings")
|
text: i18nc("@action:button", "Settings")
|
||||||
icon.name: "settings-configure"
|
icon.name: "settings-configure"
|
||||||
|
|||||||
@@ -117,7 +117,7 @@ FormCard.FormCardPage {
|
|||||||
id: addAccountDelegate
|
id: addAccountDelegate
|
||||||
text: i18n("Add Account")
|
text: i18n("Add Account")
|
||||||
icon.name: "list-add"
|
icon.name: "list-add"
|
||||||
onClicked: root.QQC2.ApplicationWindow.window.pageStack.layers.push(Qt.createComponent('org.kde.neochat.login', 'WelcomePage'))
|
onClicked: root.QQC2.ApplicationWindow.window.pageStack.layers.push(Qt.createComponent('org.kde.neochat.login', 'WelcomePage'), { showSettings: false })
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user