From 7fd8ef192287f2f30e03da69938e13ad3fc23d60 Mon Sep 17 00:00:00 2001 From: Martin Klapetek Date: Wed, 24 Jun 2015 19:37:17 +0200 Subject: [PATCH] [dialer] Put the sub-label under the number label --- dialer/package/contents/ui/Dialer/Dialer.qml | 3 +++ .../package/contents/ui/Dialpad/DialerButton.qml | 14 ++++++-------- dialer/package/contents/ui/Dialpad/Dialpad.qml | 12 ++++-------- 3 files changed, 13 insertions(+), 16 deletions(-) diff --git a/dialer/package/contents/ui/Dialer/Dialer.qml b/dialer/package/contents/ui/Dialer/Dialer.qml index 6d9ec776..e1f70aa3 100644 --- a/dialer/package/contents/ui/Dialer/Dialer.qml +++ b/dialer/package/contents/ui/Dialer/Dialer.qml @@ -56,6 +56,9 @@ Item { } Dialpad { + Layout.fillWidth: true + Layout.fillHeight: true + callback: function (string) { addNumber(string); } diff --git a/dialer/package/contents/ui/Dialpad/DialerButton.qml b/dialer/package/contents/ui/Dialpad/DialerButton.qml index 6df2dc94..a4de3713 100644 --- a/dialer/package/contents/ui/Dialpad/DialerButton.qml +++ b/dialer/package/contents/ui/Dialpad/DialerButton.qml @@ -110,17 +110,15 @@ PlasmaComponents.Label { PlasmaComponents.Label { id: longHold anchors { - verticalCenter: parent.verticalCenter - right: parent.right - rightMargin: units.smallSpacing + bottom: parent.bottom } height: parent.height * 0.4 - width: parent.width / 3 - verticalAlignment: Qt.AlignVCenter - horizontalAlignment: Qt.AlignHCenter + width: parent.width + verticalAlignment: Text.AlignBottom + horizontalAlignment: Text.AlignHCenter visible: text.length > 0 - opacity: 0.6 + opacity: 0.4 - fontSizeMode: Text.Fit + fontSizeMode: Text.VerticalFit } } diff --git a/dialer/package/contents/ui/Dialpad/Dialpad.qml b/dialer/package/contents/ui/Dialpad/Dialpad.qml index 8bff6876..62535187 100644 --- a/dialer/package/contents/ui/Dialpad/Dialpad.qml +++ b/dialer/package/contents/ui/Dialpad/Dialpad.qml @@ -33,9 +33,6 @@ GridLayout { property int buttonHeight: parent.height / 6 - Layout.fillWidth: true - Layout.fillHeight: true - DialerButton { id: one; text: "1" } DialerButton { text: "2"; sub: "ABC" } DialerButton { text: "3"; sub: "DEF" } @@ -55,8 +52,8 @@ GridLayout { DialerIconButton { id: callButton Layout.fillWidth: true - Layout.fillHeight: true - Layout.minimumHeight: buttonHeight + Layout.maximumHeight: buttonHeight + Layout.minimumHeight: Layout.maximumHeight enabled: status.text.length > 0 opacity: enabled ? 1 : 0.5 @@ -67,12 +64,11 @@ GridLayout { } Item { Layout.fillWidth: true - Layout.fillHeight: true } DialerIconButton { Layout.fillWidth: true - Layout.fillHeight: true - Layout.minimumHeight: buttonHeight + Layout.maximumHeight: buttonHeight + Layout.minimumHeight: Layout.maximumHeight enabled: status.text.length > 0 opacity: enabled ? 1 : 0.5