在我的应用程序中,我必须添加qr扫描仪,并且已经使用barcode_scan软件包进行了开发,没有任何问题。但是我需要更改扫描覆盖页面。仍然我找不到编辑或添加新扫描覆盖的方法。有人做过这件事,有任何线索将不胜感激吗?
答案 0 :(得分:0)
请尝试使用此软件包https://pub.dev/packages/last_qr_scanner
此软件包使用AndroidView和UiKitView
class _QRViewState extends State<LastQrScannerPreview> {
@override
Widget build(BuildContext context) {
var androidView = AndroidView(
viewType: 'last_qr_scanner/qrview',
onPlatformViewCreated: _onPlatformViewCreated,
);
if (defaultTargetPlatform == TargetPlatform.android) {
return androidView;
}
if (defaultTargetPlatform == TargetPlatform.iOS) {
return UiKitView(
viewType: 'last_qr_scanner/qrview',
onPlatformViewCreated: _onPlatformViewCreated,
creationParams: _CreationParams.fromWidget(0, 0).toMap(),
creationParamsCodec: StandardMessageCodec(),
);
}
演示图片