diff options
| author | dsc <dsc@xmr.pm> | 2020-07-07 16:27:57 +0200 |
|---|---|---|
| committer | dsc <dsc@xmr.pm> | 2020-07-08 22:14:28 +0200 |
| commit | 8c8faf29e4d553948b39775e489d3326b2a4effc (patch) | |
| tree | 57903e29bd189810aa285ddf3165b5498299425d | |
| parent | 596b71b29378421d67d1c4660b3b872eec320805 (diff) | |
| download | monzero-gui-8c8faf29e4d553948b39775e489d3326b2a4effc.tar.gz monzero-gui-8c8faf29e4d553948b39775e489d3326b2a4effc.tar.xz monzero-gui-8c8faf29e4d553948b39775e489d3326b2a4effc.zip | |
Support comma seperator for amount field, dynamically change to dot. Fixes #2951
| -rw-r--r-- | pages/Transfer.qml | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/pages/Transfer.qml b/pages/Transfer.qml index 5b136a63..dc344069 100644 --- a/pages/Transfer.qml +++ b/pages/Transfer.qml @@ -296,6 +296,7 @@ Rectangle { inlineButtonText: qsTr("All") + translationManager.emptyString inlineButton.onClicked: amountLine.text = "(all)" onTextChanged: { + amountLine.text = amountLine.text.replace(",", "."); const match = amountLine.text.match(/^0+(\d.*)/); if (match) { const cursorPosition = amountLine.cursorPosition; @@ -311,7 +312,7 @@ Rectangle { } validator: RegExpValidator { - regExp: /^(\d{1,8})?([\.]\d{1,12})?$/ + regExp: /^(\d{1,8})?([\.,]\d{1,12})?$/ } } |
