[bisq-network/bisq] Use min. refund at mediated payout (#3827)

chimp1984 notifications at github.com
Fri Jan 3 01:16:39 UTC 2020


chimp1984 commented on this pull request.



> -        Coin sellerAmount;
-        if (inputTextField == buyerPayoutAmountInputTextField) {
-            buyerAmount = enteredAmount;
-            sellerAmount = counterPartAsCoin;
-            Coin sellerAmountFromField = ParsingUtils.parseToCoin(sellerPayoutAmountInputTextField.getText(), formatter);
-            Coin totalAmountFromFields = enteredAmount.add(sellerAmountFromField);
-            // RefundAgent can enter less then available
-            if (getDisputeManager(dispute) instanceof MediationManager ||
-                    totalAmountFromFields.compareTo(available) > 0) {
-                sellerPayoutAmountInputTextField.setText(formattedCounterPartAmount);
-            } else {
-                sellerAmount = sellerAmountFromField;
+    private void applyCustomAmounts(InputTextField inputTextField, boolean oldFocusValue, boolean newFocusValue) {
+        // We only apply adjustments at focus out, otherwise we cannot enter certain values if we update at each
+        // keystroke.
+        if (oldFocusValue && !newFocusValue) {

Applied

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/bisq-network/bisq/pull/3827#discussion_r362684649
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.bisq.network/pipermail/bisq-github/attachments/20200102/3fd7f1fc/attachment.html>


More information about the bisq-github mailing list