From 90ac786707de3421341bb2b0b5a0c1321e31d5d6 Mon Sep 17 00:00:00 2001 From: Craig Raw Date: Thu, 12 Nov 2020 08:37:33 +0200 Subject: [PATCH] slow down qr animation --- .../com/sparrowwallet/sparrow/control/QRDisplayDialog.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/main/java/com/sparrowwallet/sparrow/control/QRDisplayDialog.java b/src/main/java/com/sparrowwallet/sparrow/control/QRDisplayDialog.java index c5a93e6d..b94e22c9 100644 --- a/src/main/java/com/sparrowwallet/sparrow/control/QRDisplayDialog.java +++ b/src/main/java/com/sparrowwallet/sparrow/control/QRDisplayDialog.java @@ -32,6 +32,8 @@ public class QRDisplayDialog extends Dialog { private static final int MIN_FRAGMENT_LENGTH = 10; private static final int MAX_FRAGMENT_LENGTH = 100; + private static final int ANIMATION_PERIOD_MILLIS = 200; + private final UR ur; private final UREncoder encoder; @@ -61,7 +63,7 @@ public class QRDisplayDialog extends Dialog { qrImageView.setImage(getQrCode(currentPart)); } else { AnimateQRService animateQRService = new AnimateQRService(); - animateQRService.setPeriod(Duration.millis(100)); + animateQRService.setPeriod(Duration.millis(ANIMATION_PERIOD_MILLIS)); animateQRService.start(); setOnCloseRequest(event -> { animateQRService.cancel();