From ae0fe76d9d889e3c07e5d426bd33079a9274f9bd Mon Sep 17 00:00:00 2001 From: Jakub Homlala Date: Sat, 15 Jun 2024 16:04:05 +0200 Subject: [PATCH] feat: updated dependencies, flutter/dart version, metadata --- CHANGELOG.md | 6 +- README.md | 2 +- docs/install.md | 2 +- example/analysis_options.yaml | 28 +++ .../android/app/src/main/AndroidManifest.xml | 3 +- example/pubspec.yaml | 6 +- lib/src/core/better_player.dart | 8 +- pubspec.lock | 196 ++++++++++-------- pubspec.yaml | 24 +-- 9 files changed, 165 insertions(+), 110 deletions(-) create mode 100644 example/analysis_options.yaml diff --git a/CHANGELOG.md b/CHANGELOG.md index 87d7d7714..9ba8d3454 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,7 +1,9 @@ ## 0.0.84 +* [BREAKING_CHANGE] Updated min. Flutter version to 3.3.0 and min. Dart version to 3.0.0. * Recreated example project. -* Updated dependencies. -* Updated readme. +* Replaced wakelock with wakelock plus. +* Updated other dependencies. +* Updated metadata. ## 0.0.83 * Updated dependencies. diff --git a/README.md b/README.md index 5037270a2..8d0a49595 100644 --- a/README.md +++ b/README.md @@ -7,7 +7,7 @@ [![pub package](https://img.shields.io/github/license/jhomlala/betterplayer.svg?style=flat)](https://github.com/jhomlala/betterplayer) [![pub package](https://img.shields.io/badge/platform-flutter-blue.svg)](https://github.com/jhomlala/betterplayer) -Advanced video player based on video_player and Chewie. It's solves many typical use cases and it's easy to run. +Advanced video player. It solves many typical use cases and it's easy to run. diff --git a/docs/install.md b/docs/install.md index cfe123190..84d72acaf 100644 --- a/docs/install.md +++ b/docs/install.md @@ -4,7 +4,7 @@ ```yaml dependencies: - better_player: ^0.0.83 + better_player: ^0.0.84 ``` 2. Install it diff --git a/example/analysis_options.yaml b/example/analysis_options.yaml new file mode 100644 index 000000000..0d2902135 --- /dev/null +++ b/example/analysis_options.yaml @@ -0,0 +1,28 @@ +# This file configures the analyzer, which statically analyzes Dart code to +# check for errors, warnings, and lints. +# +# The issues identified by the analyzer are surfaced in the UI of Dart-enabled +# IDEs (https://dart.dev/tools#ides-and-editors). The analyzer can also be +# invoked from the command line by running `flutter analyze`. + +# The following line activates a set of recommended lints for Flutter apps, +# packages, and plugins designed to encourage good coding practices. +include: package:flutter_lints/flutter.yaml + +linter: + # The lint rules applied to this project can be customized in the + # section below to disable rules from the `package:flutter_lints/flutter.yaml` + # included above or to enable additional rules. A list of all available lints + # and their documentation is published at https://dart.dev/lints. + # + # Instead of disabling a lint rule for the entire project in the + # section below, it can also be suppressed for a single line of code + # or a specific dart file by using the `// ignore: name_of_lint` and + # `// ignore_for_file: name_of_lint` syntax on the line or in the file + # producing the lint. + rules: + # avoid_print: false # Uncomment to disable the `avoid_print` rule + # prefer_single_quotes: true # Uncomment to enable the `prefer_single_quotes` rule + +# Additional information about this file can be found at +# https://dart.dev/guides/language/analysis-options diff --git a/example/android/app/src/main/AndroidManifest.xml b/example/android/app/src/main/AndroidManifest.xml index 74a78b939..cc6967bd9 100644 --- a/example/android/app/src/main/AndroidManifest.xml +++ b/example/android/app/src/main/AndroidManifest.xml @@ -2,7 +2,8 @@ + android:icon="@mipmap/ic_launcher" + android:usesCleartextTraffic="true"> ///full screen is on, then full screen route must be pop and return to normal ///state. if (_isFullScreen) { - Wakelock.disable(); + WakelockPlus.disable(); _navigatorState.maybePop(); SystemChrome.setEnabledSystemUIMode(SystemUiMode.manual, overlays: _betterPlayerConfiguration.systemOverlaysAfterFullScreen); @@ -244,7 +244,7 @@ class _BetterPlayerState extends State } if (!_betterPlayerConfiguration.allowedScreenSleep) { - Wakelock.enable(); + WakelockPlus.enable(); } await Navigator.of(context, rootNavigator: true).push(route); @@ -253,7 +253,7 @@ class _BetterPlayerState extends State // The wakelock plugins checks whether it needs to perform an action internally, // so we do not need to check Wakelock.isEnabled. - Wakelock.disable(); + WakelockPlus.disable(); await SystemChrome.setEnabledSystemUIMode(SystemUiMode.manual, overlays: _betterPlayerConfiguration.systemOverlaysAfterFullScreen); diff --git a/pubspec.lock b/pubspec.lock index 7ac9b0833..11837d5a6 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -1,6 +1,14 @@ # Generated by pub # See https://dart.dev/tools/pub/glossary#lockfile packages: + args: + dependency: transitive + description: + name: args + sha256: "7cf60b9f0cc88203c5a190b4cd62a99feea42759a7fa695010eb5de1c0b2252a" + url: "https://pub.dev" + source: hosted + version: "2.5.0" async: dependency: transitive description: @@ -53,10 +61,18 @@ packages: dependency: "direct main" description: name: cupertino_icons - sha256: e35129dc44c9118cee2a5603506d823bab99c68393879edb440e0090d07586be + sha256: ba631d1c7f7bef6b729a622b7b752645a2d076dba9976925b8f25725a30e1ee6 + url: "https://pub.dev" + source: hosted + version: "1.0.8" + dbus: + dependency: transitive + description: + name: dbus + sha256: "365c771ac3b0e58845f39ec6deebc76e3276aa9922b0cc60840712094d9047ac" url: "https://pub.dev" source: hosted - version: "1.0.5" + version: "0.7.10" fake_async: dependency: transitive description: @@ -69,10 +85,10 @@ packages: dependency: transitive description: name: ffi - sha256: d97fffd9d86f3dccc7a9059128b468a99320c69007cc9d41a3a1bda07d4e86dc + sha256: "493f37e7df1804778ff3a53bd691d8692ddf69702cf4c1c1096a2e41b4779e21" url: "https://pub.dev" source: hosted - version: "1.0.0" + version: "2.1.2" file: dependency: transitive description: @@ -105,18 +121,10 @@ packages: dependency: "direct main" description: name: flutter_widget_from_html_core - sha256: e8f4f8b461a140ffb7c71f938bc76efc758893e7468843d9dbf70cb0b9e900cb - url: "https://pub.dev" - source: hosted - version: "0.8.5+3" - fwfh_text_style: - dependency: transitive - description: - name: fwfh_text_style - sha256: "1ab7f3539c095265bd9a1226555d76d0882936462c1d018efcdc4057ec782f6a" + sha256: df7c7c9e5ea144f7ab0adfbad733b4d4f7d408ab733c94e6e9fdcb327af92aa1 url: "https://pub.dev" source: hosted - version: "2.7.2" + version: "0.15.1" html: dependency: transitive description: @@ -125,22 +133,30 @@ packages: url: "https://pub.dev" source: hosted version: "0.15.0" - intl: + http: dependency: transitive description: - name: intl - sha256: d6f56758b7d3014a48af9701c085700aac781a92a87a62b1333b46d8879661cf + name: http + sha256: "761a297c042deedc1ffbb156d6e2af13886bb305c2a343a4d972504cd67dd938" url: "https://pub.dev" source: hosted - version: "0.19.0" - js: + version: "1.2.1" + http_parser: dependency: transitive description: - name: js - sha256: a5e201311cb08bf3912ebbe9a2be096e182d703f881136ec1e81a2338a9e120d + name: http_parser + sha256: "2aa08ce0341cc9b354a498388e30986515406668dbcc4f7c950c3e715496693b" url: "https://pub.dev" source: hosted - version: "0.6.4" + version: "4.0.2" + intl: + dependency: transitive + description: + name: intl + sha256: d6f56758b7d3014a48af9701c085700aac781a92a87a62b1333b46d8879661cf + url: "https://pub.dev" + source: hosted + version: "0.19.0" leak_tracker: dependency: transitive description: @@ -169,10 +185,18 @@ packages: dependency: "direct dev" description: name: lint - sha256: "5715d702a2c3b493e09ed9e223625f0fc1f75e04167e338133a4cef28b868c1f" + sha256: d758a5211fce7fd3f5e316f804daefecdc34c7e53559716125e6da7388ae8565 url: "https://pub.dev" source: hosted - version: "1.8.2" + version: "2.3.0" + logging: + dependency: transitive + description: + name: logging + sha256: "623a88c9594aa774443aa3eb2d41807a48486b5613e67599fb4c41c0ad47c340" + url: "https://pub.dev" + source: hosted + version: "1.2.0" matcher: dependency: transitive description: @@ -197,6 +221,22 @@ packages: url: "https://pub.dev" source: hosted version: "1.12.0" + package_info_plus: + dependency: transitive + description: + name: package_info_plus + sha256: b93d8b4d624b4ea19b0a5a208b2d6eff06004bc3ce74c06040b120eeadd00ce0 + url: "https://pub.dev" + source: hosted + version: "8.0.0" + package_info_plus_platform_interface: + dependency: transitive + description: + name: package_info_plus_platform_interface + sha256: f49918f3433a3146047372f9d4f1f847511f2acd5cd030e1f44fe5a50036b70e + url: "https://pub.dev" + source: hosted + version: "3.0.0" path: dependency: transitive description: @@ -209,66 +249,58 @@ packages: dependency: "direct main" description: name: path_provider - sha256: "3f6e0d697dc557ed6589107c8c13eda5ad488285917788379bbf392e3e30ea37" + sha256: c9e7d3a4cd1410877472158bee69963a4579f78b68c65a2b7d40d1a7a88bb161 url: "https://pub.dev" source: hosted - version: "2.0.10" + version: "2.1.3" path_provider_android: dependency: transitive description: name: path_provider_android - sha256: c69109bae02c6116bd8ac81319b13eb73dfae02ef74690d2a1a98c1ddd3aaefc + sha256: "9c96da072b421e98183f9ea7464898428e764bc0ce5567f27ec8693442e72514" url: "https://pub.dev" source: hosted - version: "2.0.11" - path_provider_ios: + version: "2.2.5" + path_provider_foundation: dependency: transitive description: - name: path_provider_ios - sha256: "038d0141ff5d08c60ed071eee2758b68c50c42a1c10066a1fb6c28ab32fac84c" + name: path_provider_foundation + sha256: f234384a3fdd67f989b4d54a5d73ca2a6c422fa55ae694381ae0f4375cd1ea16 url: "https://pub.dev" source: hosted - version: "2.0.7" + version: "2.4.0" path_provider_linux: dependency: transitive description: name: path_provider_linux - sha256: "368c48aec7d1eee5412145ebda483e0ae646f7bcfc11366e13898e359ec0593f" + sha256: f7a1fe3a634fe7734c8d3f2766ad746ae2a2884abe22e241a8b301bf5cac3279 url: "https://pub.dev" source: hosted - version: "2.1.2" - path_provider_macos: - dependency: transitive - description: - name: path_provider_macos - sha256: eb58b896ea3a504f0b0fa7870646bda6935a6f752b2a54df33f97070dacca8d4 - url: "https://pub.dev" - source: hosted - version: "2.0.0" + version: "2.2.1" path_provider_platform_interface: dependency: transitive description: name: path_provider_platform_interface - sha256: c2af5a8a6369992d915f8933dfc23172071001359d17896e83db8be57db8a397 + sha256: "88f5779f72ba699763fa3a3b06aa4bf6de76c8e5de842cf6f29e2e06476c2334" url: "https://pub.dev" source: hosted - version: "2.0.1" + version: "2.1.2" path_provider_windows: dependency: transitive description: name: path_provider_windows - sha256: "74056f334c58bd6db429ba93164e872a1996c8196b3132a100c40924b2672abf" + sha256: "8bc9f22eee8690981c22aa7fc602f5c85b497a6fb2ceb35ee5a5e5ed85ad8170" url: "https://pub.dev" source: hosted - version: "2.0.4" + version: "2.2.1" petitparser: dependency: transitive description: name: petitparser - sha256: "2ebb289dc4764ec397f5cd3ca9881c6d17196130a7d646ed022a0dd9c2e25a71" + sha256: c15605cd28af66339f8eb6fbe0e541bfe2d1b72d5825efc6598f3e0a31b9ad27 url: "https://pub.dev" source: hosted - version: "5.0.0" + version: "6.0.2" platform: dependency: transitive description: @@ -281,10 +313,10 @@ packages: dependency: transitive description: name: plugin_platform_interface - sha256: c2c49e16d42fd6983eb55e44b7f197fdf16b4da7aab7f8e1d21da307cad3fb02 + sha256: "4820fbfdb9478b1ebae27888254d445073732dae3d6ea81f0b7e06d5dedc3f02" url: "https://pub.dev" source: hosted - version: "2.0.0" + version: "2.1.8" process: dependency: transitive description: @@ -346,6 +378,14 @@ packages: url: "https://pub.dev" source: hosted version: "0.7.0" + typed_data: + dependency: transitive + description: + name: typed_data + sha256: facc8d6582f16042dd49f2463ff1bd6e2c9ef9f3d5da3d9b087e244a7b564b3c + url: "https://pub.dev" + source: hosted + version: "1.3.2" vector_math: dependency: transitive description: @@ -358,10 +398,10 @@ packages: dependency: "direct main" description: name: visibility_detector - sha256: "15c54a459ec2c17b4705450483f3d5a2858e733aee893dcee9d75fd04814940d" + sha256: dd5cc11e13494f432d15939c3aa8ae76844c42b723398643ce9addb88a5ed420 url: "https://pub.dev" source: hosted - version: "0.3.3" + version: "0.4.0+2" vm_service: dependency: transitive description: @@ -370,54 +410,38 @@ packages: url: "https://pub.dev" source: hosted version: "14.2.1" - wakelock: + wakelock_plus: dependency: "direct main" description: - name: wakelock - sha256: b18a1a7b1ec71b1a9105766e06a73a2411e3eb5564bc569d99df92b57530bb4b - url: "https://pub.dev" - source: hosted - version: "0.6.1+2" - wakelock_macos: - dependency: transitive - description: - name: wakelock_macos - sha256: "047c6be2f88cb6b76d02553bca5a3a3b95323b15d30867eca53a19a0a319d4cd" + name: wakelock_plus + sha256: "14758533319a462ffb5aa3b7ddb198e59b29ac3b02da14173a1715d65d4e6e68" url: "https://pub.dev" source: hosted - version: "0.4.0" - wakelock_platform_interface: + version: "1.2.5" + wakelock_plus_platform_interface: dependency: transitive description: - name: wakelock_platform_interface - sha256: "1f4aeb81fb592b863da83d2d0f7b8196067451e4df91046c26b54a403f9de621" + name: wakelock_plus_platform_interface + sha256: "422d1cdbb448079a8a62a5a770b69baa489f8f7ca21aef47800c726d404f9d16" url: "https://pub.dev" source: hosted - version: "0.3.0" - wakelock_web: - dependency: transitive - description: - name: wakelock_web - sha256: "1b256b811ee3f0834888efddfe03da8d18d0819317f20f6193e2922b41a501b5" - url: "https://pub.dev" - source: hosted - version: "0.4.0" - wakelock_windows: + version: "1.2.1" + web: dependency: transitive description: - name: wakelock_windows - sha256: "108b1b73711f1664ee462e73af34a9286ff496e27d4d8371e2fb4da8fde4cdac" + name: web + sha256: "97da13628db363c635202ad97068d47c5b8aa555808e7a9411963c533b449b27" url: "https://pub.dev" source: hosted - version: "0.2.0" + version: "0.5.1" win32: dependency: transitive description: name: win32 - sha256: c6a3f4e4058b70b46e27b2935de2d1562c50680e7fb44833911d981db73826c2 + sha256: a79dbe579cb51ecd6d30b17e0cae4e0ea15e2c0e66f69ad4198f22a6789e94f4 url: "https://pub.dev" source: hosted - version: "2.0.0" + version: "5.5.1" xdg_directories: dependency: transitive description: @@ -430,10 +454,10 @@ packages: dependency: "direct main" description: name: xml - sha256: ac0e3f4bf00ba2708c33fbabbbe766300e509f8c82dbd4ab6525039813f7e2fb + sha256: b015a8ad1c488f66851d762d3090a21c600e479dc75e68328c52774040cf9226 url: "https://pub.dev" source: hosted - version: "6.1.0" + version: "6.5.0" sdks: - dart: ">=3.3.0 <4.0.0" - flutter: ">=3.18.0-18.0.pre.54" + dart: ">=3.4.0 <4.0.0" + flutter: ">=3.22.0" diff --git a/pubspec.yaml b/pubspec.yaml index 78dd5fe11..31b237d02 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,27 +1,27 @@ name: better_player -description: Advanced video player. It's solves many typical use cases and it's easy to run. +description: Advanced video player. It solves many typical use cases and it's easy to run. version: 0.0.84 homepage: https://github.com/jhomlala/betterplayer documentation: https://jhomlala.github.io/betterplayer/ environment: - sdk: '>=2.12.0 <3.0.0' - flutter: ">=2.2.3" + sdk: ">=3.0.0 <4.0.0" + flutter: ">=3.3.0" dependencies: flutter: sdk: flutter - cupertino_icons: ^1.0.5 - wakelock: ^0.6.1+2 - meta: ^1.7.0 - flutter_widget_from_html_core: ^0.8.5+3 - visibility_detector: ^0.3.3 - path_provider: ^2.0.10 - collection: ^1.16.0 - xml: ^6.1.0 + cupertino_icons: ^1.0.8 + wakelock_plus: ^1.2.5 + meta: ^1.12.0 + flutter_widget_from_html_core: ^0.15.1 + visibility_detector: ^0.4.0+2 + path_provider: ^2.1.3 + collection: ^1.18.0 + xml: ^6.5.0 dev_dependencies: - lint: ^1.8.2 + lint: ^2.3.0 flutter_test: sdk: flutter flutter_localizations: