From 981db87129880a4c8cf235d1f058cbdd49206335 Mon Sep 17 00:00:00 2001 From: Ming Rui Zhang <mingrui.zhang@savoirfairelinux.com> Date: Thu, 8 Oct 2020 13:49:38 -0400 Subject: [PATCH] mainview: change about jami button from Button to MaterialButton Gitlab: #139 Change-Id: I55bfbc8a7f404cad917f462e5e77c793747fbc21 --- src/constant/JamiStrings.qml | 1 + src/mainview/components/WelcomePage.qml | 25 +++++++++++++------------ 2 files changed, 14 insertions(+), 12 deletions(-) diff --git a/src/constant/JamiStrings.qml b/src/constant/JamiStrings.qml index 5271a9cc2..02b028da7 100644 --- a/src/constant/JamiStrings.qml +++ b/src/constant/JamiStrings.qml @@ -375,6 +375,7 @@ Item { property string errorCreateAccount: qsTr("Error while creating your account. Check your credentials.") property string createNewRV: qsTr("Create new rendezvous point") property string createNewJA: qsTr("Create a Jami account") + property string aboutJami: qsTr("About Jami") // Smart list context menu property string declineContactRequest: qsTr("Decline contact request") diff --git a/src/mainview/components/WelcomePage.qml b/src/mainview/components/WelcomePage.qml index 0a9378ed1..30431a63f 100644 --- a/src/mainview/components/WelcomePage.qml +++ b/src/mainview/components/WelcomePage.qml @@ -46,7 +46,7 @@ Rectangle { Layout.alignment: Qt.AlignCenter Layout.preferredWidth: welcomeRectComponentsGroup.width Layout.preferredHeight: 100 - Layout.topMargin: 32 + Layout.topMargin: JamiTheme.preferredMarginSize Layout.bottomMargin: 10 smooth: true @@ -97,7 +97,7 @@ Rectangle { Layout.alignment: Qt.AlignCenter Layout.preferredWidth: welcomeRectComponentsGroup.width Layout.preferredHeight: 65 - Layout.bottomMargin: 5 + Layout.bottomMargin: JamiTheme.preferredMarginSize visible: AccountAdapter.currentAccountType === Profile.Type.RING @@ -144,21 +144,22 @@ Rectangle { } } - Button { - id: btnAbout + MaterialButton { + id: btnClose anchors.bottom: parent.bottom - anchors.bottomMargin: 10 + anchors.bottomMargin: JamiTheme.preferredMarginSize anchors.horizontalCenter: parent.horizontalCenter - background: Rectangle { - color: "transparent" - } + width: 150 + height: 30 - contentItem: Text { - text: qsTr("About Jami") - color: "grey" - } + color: JamiTheme.buttonTintedBlack + hoveredColor: JamiTheme.buttonTintedBlackHovered + pressedColor: JamiTheme.buttonTintedBlackPressed + outlined: true + + text: JamiStrings.aboutJami onClicked: aboutPopUpDialog.open() } -- GitLab