fix: convert styledbuttons to statusbuttons

This commit is contained in:
hydr063n 2020-09-29 10:51:16 +02:00 committed by Iuri Matias
parent a1dbf306e4
commit d41bae62f7
1 changed files with 6 additions and 5 deletions

View File

@ -3,6 +3,7 @@ import QtQuick.Layouts 1.3
import QtQuick.Controls 2.14 import QtQuick.Controls 2.14
import "../../../../../imports" import "../../../../../imports"
import "../../../../../shared" import "../../../../../shared"
import "../../../../../shared/status"
Item { Item {
property string username: "" property string username: ""
@ -260,13 +261,13 @@ Item {
} }
} }
StyledButton { StatusButton {
anchors.bottom: parent.bottom anchors.bottom: parent.bottom
anchors.bottomMargin: Style.current.padding anchors.bottomMargin: Style.current.padding
anchors.left: parent.left anchors.left: parent.left
anchors.leftMargin: Style.current.padding anchors.leftMargin: Style.current.padding
//% "Back" //% "Back"
label: qsTrId("back") text: qsTrId("back")
onClicked: backBtnClicked() onClicked: backBtnClicked()
} }
@ -309,18 +310,18 @@ Item {
} }
} }
StyledButton { StatusButton {
id: startBtn id: startBtn
anchors.bottom: parent.bottom anchors.bottom: parent.bottom
anchors.bottomMargin: Style.current.padding anchors.bottomMargin: Style.current.padding
anchors.right: parent.right anchors.right: parent.right
anchors.rightMargin: Style.current.padding anchors.rightMargin: Style.current.padding
label: parseFloat(utilsModel.getSNTBalance()) < 10 ? text: parseFloat(utilsModel.getSNTBalance()) < 10 ?
//% "Not enough SNT" //% "Not enough SNT"
qsTrId("not-enough-snt") : qsTrId("not-enough-snt") :
//% "Register" //% "Register"
qsTrId("ens-register") qsTrId("ens-register")
disabled: parseFloat(utilsModel.getSNTBalance()) < 10 || !termsAndConditionsCheckbox.checked enabled: parseFloat(utilsModel.getSNTBalance()) >= 10 && termsAndConditionsCheckbox.checked
onClicked: transactionDialog.open() onClicked: transactionDialog.open()
} }
} }