parent
557c068983
commit
f71870cb8f
|
@ -127,7 +127,12 @@ Item {
|
||||||
buttonGroup: gasGroup
|
buttonGroup: gasGroup
|
||||||
checkedByDefault: true
|
checkedByDefault: true
|
||||||
text: qsTr("Optimal")
|
text: qsTr("Optimal")
|
||||||
price: (fastestGasPrice + slowestGasPrice) / 2
|
price: {
|
||||||
|
const price = (fastestGasPrice + slowestGasPrice) / 2
|
||||||
|
// Setting the gas price field here because the binding didn't work
|
||||||
|
inputGasPrice.text = price
|
||||||
|
return price
|
||||||
|
}
|
||||||
gasLimit: inputGasLimit ? inputGasLimit.text : ""
|
gasLimit: inputGasLimit ? inputGasLimit.text : ""
|
||||||
getGasEthValue: root.getGasEthValue
|
getGasEthValue: root.getGasEthValue
|
||||||
getFiatValue: root.getFiatValue
|
getFiatValue: root.getFiatValue
|
||||||
|
@ -182,7 +187,6 @@ Item {
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
width: 130
|
width: 130
|
||||||
customHeight: 56
|
customHeight: 56
|
||||||
text: optimalGasButton.price
|
|
||||||
placeholderText: "20"
|
placeholderText: "20"
|
||||||
onTextChanged: {
|
onTextChanged: {
|
||||||
if (root.validate()) {
|
if (root.validate()) {
|
||||||
|
|
|
@ -24,7 +24,7 @@ Column {
|
||||||
|
|
||||||
function validate() {
|
function validate() {
|
||||||
let isValid = true
|
let isValid = true
|
||||||
if (!(selectedAccount && selectedAccount.assets && selectedAsset && selectedGasEthValue >= 0)) {
|
if (!(selectedAccount && selectedAccount.assets && selectedAsset && selectedGasEthValue > 0)) {
|
||||||
return root.isValid
|
return root.isValid
|
||||||
}
|
}
|
||||||
isValid = true
|
isValid = true
|
||||||
|
|
Loading…
Reference in New Issue