From 3978efc1bfa0a9808533aa011a34d0af5cfa2507 Mon Sep 17 00:00:00 2001 From: Emil Lundberg Date: Tue, 21 Nov 2017 16:10:40 +0100 Subject: [PATCH] Prettify a long expression --- qml/CredentialItem.qml | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/qml/CredentialItem.qml b/qml/CredentialItem.qml index 9dea7eeb..19e07ac6 100644 --- a/qml/CredentialItem.qml +++ b/qml/CredentialItem.qml @@ -21,13 +21,10 @@ Rectangle { } } - Layout.minimumHeight: { - var baseHeight = issuerLbl.height - + codeLbl.height + nameLbl.height + 10 - return hasCustomTimeBar( - model.credential) ? baseHeight - + 10 : baseHeight - } + Layout.minimumHeight: ( + 10 + issuerLbl.height + codeLbl.height + nameLbl.height + + (hasCustomTimeBar(model.credential) ? 10 : 0) + ) Layout.fillWidth: true Layout.alignment: Qt.AlignTop