diff --git a/lib/src/pages/downloader.dart b/lib/src/pages/downloader.dart index c76e21e..ecfbc20 100644 --- a/lib/src/pages/downloader.dart +++ b/lib/src/pages/downloader.dart @@ -32,7 +32,6 @@ class Downloader extends StatefulWidget { class _DownloaderState extends State { final notificationsClient = NotificationsClient(); final wgetPattern = RegExp("( [0-9.]+%)"); - final macRecoveryPattern = RegExp("([0-9]+\\.[0-9])"); final ariaPattern = RegExp("([0-9.]+%)"); late final Stream _progressStream; bool _downloadFinished = false; @@ -67,17 +66,6 @@ class _DownloaderState extends State { } } - void parseMacRecoveryProgress(String line) { - var matches = macRecoveryPattern.allMatches(line).toList(); - if (matches.isNotEmpty) { - var size = matches[0].group(1); - if (size != null) { - var value = double.parse(size); - controller.add(value); - } - } - } - Stream progressStream() { var options = [widget.operatingSystem.code, widget.version.version]; if (widget.option != null) { @@ -88,10 +76,6 @@ class _DownloaderState extends State { process.stderr.transform(utf8.decoder).forEach(parseWgetProgress); } else if (widget.option!.downloader == 'zsync') { controller.add(-1); - } else if (widget.option!.downloader == 'macrecovery') { - process.stdout - .transform(utf8.decoder) - .forEach(parseMacRecoveryProgress); } else if (widget.option!.downloader == 'aria2c') { process.stderr.transform(utf8.decoder).forEach(parseAriaProgress); }