mirror of
https://github.com/monero-project/monero-gui.git
synced 2025-01-09 19:32:03 +02:00
Merge pull request #1794
e650818
TextField.onEditingFinished() is not available in Qt versions lower than 5.9. Replace with onEditingFinished() (xmrdsc)b466f9f
string.startsWith() is not available in Qt versions lower than 5.8. Replace with string.indexOf() (xmrdsc)
This commit is contained in:
commit
f8cd4c86d9
@ -452,7 +452,7 @@ Rectangle {
|
||||
fontBold: true
|
||||
inlineIcon: true
|
||||
onTextChanged: {
|
||||
if (amountToReceiveLine.text.startsWith('.')) {
|
||||
if(amountToReceiveLine.text.indexOf('.') === 0){
|
||||
amountToReceiveLine.text = '0' + amountToReceiveLine.text;
|
||||
}
|
||||
}
|
||||
|
@ -145,7 +145,7 @@ Rectangle {
|
||||
inlineButtonText: qsTr("All") + translationManager.emptyString
|
||||
inlineButton.onClicked: amountLine.text = "(all)"
|
||||
onTextChanged: {
|
||||
if (amountLine.text.startsWith('.')) {
|
||||
if(amountLine.text.indexOf('.') === 0){
|
||||
amountLine.text = '0' + amountLine.text;
|
||||
}
|
||||
}
|
||||
|
@ -385,7 +385,7 @@ ColumnLayout {
|
||||
color: "#4A4949"
|
||||
text: persistentSettings.kdfRounds
|
||||
validator: IntValidator { bottom: 1 }
|
||||
onTextEdited: {
|
||||
onEditingFinished: {
|
||||
kdfRoundsText.text = persistentSettings.kdfRounds = parseInt(kdfRoundsText.text) >= 1 ? parseInt(kdfRoundsText.text) : 1;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user