1
0

qml: add tx options to ConfirmTxDialog, RbfBumpFeeDialog

This commit is contained in:
Sander van Grieken
2024-02-22 17:16:56 +01:00
parent b0227c7e03
commit a9282c0e36
5 changed files with 127 additions and 0 deletions

View File

@@ -137,6 +137,66 @@ ElDialog {
}
}
ToggleLabel {
id: optionstoggle
Layout.columnSpan: 2
labelText: qsTr('Options')
color: Material.accentColor
}
TextHighlightPane {
Layout.columnSpan: 2
Layout.fillWidth: true
visible: !optionstoggle.collapsed
height: optionslayout.height
GridLayout {
id: optionslayout
width: parent.width
columns: 2
ElCheckBox {
Layout.fillWidth: true
text: qsTr('Use multiple change addresses')
onCheckedChanged: {
if (activeFocus) {
Daemon.currentWallet.multipleChange = checked
finalizer.doUpdate()
}
}
Component.onCompleted: {
checked = Daemon.currentWallet.multipleChange
}
}
HelpButton {
heading: qsTr('Use multiple change addresses')
helptext: qsTr('To somewhat protect your privacy, Electrum tries to create change with similar precision to other outputs.')
}
ElCheckBox {
Layout.fillWidth: true
text: qsTr('Enable output value rounding')
onCheckedChanged: {
if (activeFocus) {
Config.outputValueRounding = checked
finalizer.doUpdate()
}
}
Component.onCompleted: {
checked = Config.outputValueRounding
}
}
HelpButton {
heading: qsTr('Enable output value rounding')
helptext: qsTr('In some cases, use up to 3 change addresses in order to break up large coin amounts and obfuscate the recipient address.')
+ ' ' + qsTr('This may result in higher transactions fees.')
}
}
}
InfoTextArea {
Layout.columnSpan: 2
Layout.fillWidth: true

View File

@@ -120,6 +120,46 @@ ElDialog {
}
}
ToggleLabel {
id: optionstoggle
Layout.columnSpan: 2
labelText: qsTr('Options')
color: Material.accentColor
}
TextHighlightPane {
Layout.columnSpan: 2
Layout.fillWidth: true
visible: !optionstoggle.collapsed
height: optionslayout.height
GridLayout {
id: optionslayout
width: parent.width
columns: 2
ElCheckBox {
Layout.fillWidth: true
text: qsTr('Enable output value rounding')
onCheckedChanged: {
if (activeFocus) {
Config.outputValueRounding = checked
rbffeebumper.doUpdate()
}
}
Component.onCompleted: {
checked = Config.outputValueRounding
}
}
HelpButton {
heading: qsTr('Enable output value rounding')
helptext: qsTr('In some cases, use up to 3 change addresses in order to break up large coin amounts and obfuscate the recipient address.')
+ ' ' + qsTr('This may result in higher transactions fees.')
}
}
}
InfoTextArea {
Layout.columnSpan: 2
Layout.preferredWidth: parent.width * 3/4