Skip to content

Update plugin for Flutter 3.44.2 / Dart 3.12.2 compatibility - #208

Open
47gurvinder wants to merge 8 commits into
justsoft:masterfrom
47gurvinder:master
Open

Update plugin for Flutter 3.44.2 / Dart 3.12.2 compatibility#208
47gurvinder wants to merge 8 commits into
justsoft:masterfrom
47gurvinder:master

Conversation

@47gurvinder

@47gurvinder 47gurvinder commented Jun 22, 2026

Copy link
Copy Markdown

Summary

  • Updates Android Gradle configuration (build.gradle, settings.gradle, gradle-wrapper.properties, gradle.properties) for compatibility with current Flutter/AGP toolchains
  • Updates example app (main.dart, pubspec.yaml/lock, AndroidManifest.xml) to work with Flutter 3.44.2 and Dart 3.12.2
  • Removes a stale unused import in lib/video_thumbnail.dart
  • Bumps iOS podspec version
  • Updates example's .gitignore (both root and ios/) to match current flutter create output, so generated files like Flutter/ephemeral/flutter_lldbinit aren't tracked as untracked changes

Test plan

  • flutter pub get succeeds in both root and example/
  • Example app builds and runs on Android with current Flutter/Dart versions
  • Example app builds and runs on iOS

47gurvinder and others added 3 commits June 22, 2026 16:15
- Bump SDK constraints in pubspec.yaml (plugin and example) to support
  Dart 3 / Flutter 3.3+, replacing the pre-null-safety constraints that
  failed `pub get` on current Flutter.
- Android: drop deprecated jcenel()/jcenter(), bump AGP 4.1.0 -> 8.11.1,
  Gradle wrapper 6.5 -> 8.14, compileSdk/targetSdk -> 36, ndkVersion ->
  28.2.13676358, Java 8 -> 11, and migrate example's Gradle files to the
  modern pluginManagement/plugins{} DSL required by current Flutter
  tooling. Add the now-required android:exported="true" on MainActivity.
- iOS: bump podspec deployment target 8.0 -> 12.0 to match current
  Xcode/Flutter minimums.
- Dart: migrate example/lib/main.dart to null safety and the current
  image_picker v1 API (ImagePicker().pickVideo() returning XFile?).
  Drop an unnecessary import in lib/video_thumbnail.dart.
- Tests: fix test/video_thumbnail_test.dart to use the current
  flutter_test mock-channel binding API and correct a stale assertion
  key that the old (broken) binding had been masking.

Verified with flutter analyze, flutter test, and flutter build apk
--debug on Flutter 3.44.2 / Dart 3.12.2.
Add Flutter/ephemeral/ (iOS) and other entries current `flutter create`
ignores, so generated files like Flutter/ephemeral/flutter_lldbinit
don't show up as untracked.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Copilot AI review requested due to automatic review settings June 22, 2026 11:31

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR modernizes the video_thumbnail Flutter plugin and its example app to align with newer Flutter/Dart toolchains (Flutter 3.44.2 / Dart 3.12.2), including updates to platform build configurations and example dependencies.

Changes:

  • Updated pubspec SDK constraints / lockfiles and modernized example app code for null-safety & current plugin APIs.
  • Migrated Android/iOS example project configuration to newer Gradle/AGP and Xcode/CocoaPods templates.
  • Updated tests to use the current MethodChannel name + modern mock handler APIs.

Reviewed changes

Copilot reviewed 21 out of 25 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
test/video_thumbnail_test.dart Updates channel name and MethodChannel mocking to current Flutter test APIs.
pubspec.yaml Bumps Dart/Flutter SDK constraints for the plugin package.
pubspec.lock Refreshes resolved dependency versions for the new SDK range.
lib/video_thumbnail.dart Removes an import (per PR description) while keeping the public API intact.
ios/video_thumbnail.podspec Raises iOS deployment target for compatibility with modern Flutter/iOS toolchains.
example/pubspec.yaml Updates example SDK constraints and moves runtime deps into dependencies.
example/pubspec.lock Refreshes example dependency resolution for the new SDK range.
example/lib/main.dart Migrates example app code to null-safety and newer image_picker APIs.
example/ios/Runner/Info.plist Syncs Info.plist with current flutter create defaults.
example/ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings Removes stale workspace settings file.
example/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme Updates scheme settings to current Flutter/Xcode defaults.
example/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata Updates workspace reference format.
example/ios/Runner.xcodeproj/project.pbxproj Updates Xcode project settings (deployment target, frameworks, build phases) for current Flutter.
example/ios/Podfile Migrates Podfile to current Flutter pod helper approach.
example/ios/Podfile.lock Refreshes pods resolution for updated iOS dependencies/tooling.
example/ios/Flutter/AppFrameworkInfo.plist Removes old MinimumOSVersion entry consistent with updated deployment targets.
example/ios/.gitignore Ignores Flutter ephemeral iOS outputs.
example/android/settings.gradle Migrates to pluginManagement + flutter plugin loader.
example/android/gradle/wrapper/gradle-wrapper.properties Updates Gradle wrapper for current AGP.
example/android/gradle.properties Adds Flutter migrator flags for Kotlin/new DSL behavior.
example/android/build.gradle Migrates repositories + modernizes the clean task.
example/android/app/build.gradle Migrates to plugins DSL + modern Android config (namespace, compileSdk, etc.).
example/android/app/src/main/AndroidManifest.xml Adds android:exported required by modern Android.
example/.gitignore Aligns ignores with current Flutter output layout.
android/build.gradle Updates plugin Android module buildscript/repos and Android SDK settings.
Files not reviewed (1)
  • example/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata: Generated file

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread example/lib/main.dart
Comment thread example/lib/main.dart
Comment thread android/build.gradle
@Ssiswent

Ssiswent commented Jul 3, 2026

Copy link
Copy Markdown

@justsoft Could you please merge this?

…tation, and examples for the new package name. Preserve original license and credits. Increase Gradle heap limit for compatibility with current Flutter builds.
- Changed Android and iOS plugin identifiers to allow coexistence with the original video_thumbnail package.
- Updated Android build.gradle and AndroidManifest.xml to reflect new package names.
- Removed old VideoThumbnailPlugin implementation and added VideoThumbnailGdxPlusPlugin for iOS.
- Updated Podfile.lock and pubspec.lock to version 0.5.8.
- Adjusted Dart files to use new method channel names and updated plugin class references.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants