Browse Source

qml: TxDetails small form-factor fix, wrap buttons to below fee-bump text if width is constrained

master
Sander van Grieken 3 years ago
parent
commit
abae815777
  1. 13
      electrum/gui/qml/components/TxDetails.qml

13
electrum/gui/qml/components/TxDetails.qml

@ -138,17 +138,23 @@ Pane {
borderColor: constants.colorWarning borderColor: constants.colorWarning
visible: txdetails.canBump || txdetails.canCpfp || txdetails.canCancel visible: txdetails.canBump || txdetails.canCpfp || txdetails.canCancel
RowLayout { GridLayout {
width: parent.width width: parent.width
columns: actionButtonsLayout.implicitWidth > parent.width/2
? 1
: 2
Label { Label {
Layout.fillWidth: true Layout.fillWidth: true
text: qsTr('This transaction is still unconfirmed.') + '\n' + text: qsTr('This transaction is still unconfirmed.') + '\n' + (txdetails.canCancel
qsTr('You can increase fees to speed up the transaction, or cancel this transaction') ? qsTr('You can increase fees to speed up the transaction, or cancel this transaction')
: qsTr('You can increase fees to speed up the transaction'))
wrapMode: Text.Wrap wrapMode: Text.Wrap
} }
ColumnLayout { ColumnLayout {
id: actionButtonsLayout
Layout.alignment: Qt.AlignHCenter Layout.alignment: Qt.AlignHCenter
Pane { Pane {
Layout.alignment: Qt.AlignHCenter
background: Rectangle { color: Material.dialogColor } background: Rectangle { color: Material.dialogColor }
padding: 0 padding: 0
visible: txdetails.canBump || txdetails.canCpfp visible: txdetails.canBump || txdetails.canCpfp
@ -168,6 +174,7 @@ Pane {
} }
} }
Pane { Pane {
Layout.alignment: Qt.AlignHCenter
background: Rectangle { color: Material.dialogColor } background: Rectangle { color: Material.dialogColor }
padding: 0 padding: 0
visible: txdetails.canCancel visible: txdetails.canCancel

Loading…
Cancel
Save