From 10394dc130f8117b54e0590f41aadff3ee1f9332 Mon Sep 17 00:00:00 2001 From: Christian Mollekopf Date: Sun, 8 Oct 2017 11:46:36 +0200 Subject: Support reentering the password from the settings Additionally this fixes the loader sizing to use the implicit size. This means all settings pages need to set an implicit height. --- framework/qml/EditAccount.qml | 23 ++++++++--------------- framework/qml/Messages.qml | 2 +- 2 files changed, 9 insertions(+), 16 deletions(-) (limited to 'framework/qml') diff --git a/framework/qml/EditAccount.qml b/framework/qml/EditAccount.qml index 85df955b..df567e5a 100644 --- a/framework/qml/EditAccount.qml +++ b/framework/qml/EditAccount.qml @@ -59,36 +59,29 @@ Item { wrapMode: Text.Wrap } - Item { - id: accountEdit + Column { anchors { - top:subHeadline.bottom + top: subHeadline.bottom left: parent.left right: parent.right bottom: footer.top topMargin: Kube.Units.largeSpacing * 2 } - + spacing: Kube.Units.largeSpacing Loader { id: loader anchors { - top: parent.top left: parent.left right: parent.right } - //The initial size is somehow necessary so the loader is properly anchored - height: 10 + height: item ? item.implicitHeight : 0 source: accountFactory.uiPath onLoaded: item.accountId = root.accountId } - Item { - id: spacer - anchors { - top: loader.bottom - left: parent.left - right: parent.right - bottom: parent.bottom - } + Kube.Button { + anchors.right: parent.right + text: qsTr("Change Password") + onClicked: Kube.Fabric.postMessage(Kube.Messages.requestLogin, {}) } } diff --git a/framework/qml/Messages.qml b/framework/qml/Messages.qml index 8d10bc3b..7e415c34 100644 --- a/framework/qml/Messages.qml +++ b/framework/qml/Messages.qml @@ -34,8 +34,8 @@ Item { property string toggleImportant: "toggleImportant" property string moveToFolder: "moveToFolder" property string moveToDrafts: "moveToDrafts" - property string credentials: "credentials" property string unlockKeyring: "unlockKeyring" + property string requestLogin: "requestLogin" property string notification: "notification" property string progressNotification: "progressNotification" -- cgit v1.2.3