Fix qr scanner for camerax blacklisted devices.

This commit is contained in:
Cody Henthorne
2022-09-27 07:05:54 -04:00
parent 931b9f8831
commit 866853ff99
3 changed files with 6 additions and 3 deletions

View File

@@ -15,6 +15,7 @@ import org.signal.core.util.logging.Log;
import org.signal.qr.QrScannerView;
import org.thoughtcrime.securesms.LoggingFragment;
import org.thoughtcrime.securesms.R;
import org.thoughtcrime.securesms.mediasend.camerax.CameraXModelBlocklist;
import org.thoughtcrime.securesms.payments.MobileCoinPublicAddress;
import org.thoughtcrime.securesms.util.LifecycleDisposable;
import org.thoughtcrime.securesms.util.navigation.SafeNavigation;
@@ -52,7 +53,7 @@ public final class PaymentsTransferQrScanFragment extends LoggingFragment {
Toolbar toolbar = view.findViewById(R.id.payments_transfer_scan_qr);
toolbar.setNavigationOnClickListener(v -> Navigation.findNavController(v).popBackStack());
scannerView.start(getViewLifecycleOwner());
scannerView.start(getViewLifecycleOwner(), CameraXModelBlocklist.isBlocklisted());
lifecycleDisposable.bindTo(getViewLifecycleOwner());