Skip to content

Commit

Permalink
Merge pull request #1644 from abdelaziz-mahdy/fix-flutter-3.27-compil…
Browse files Browse the repository at this point in the history
…e-error

removing v1 embedding to fix compile on flutter 3.27
  • Loading branch information
navaronbracke authored Dec 16, 2024
2 parents 7726f3c + 3b299bb commit 525840e
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 11 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## 8.1.6
### Android
Fix [#1643](https://github.com/miguelpruivo/flutter_file_picker/issues/1643)

## 8.1.5
### Android
Fix [#872](https://github.com/miguelpruivo/flutter_file_picker/issues/872)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -254,16 +254,11 @@ public void onCancel(final Object arguments) {
});
this.observer = new LifeCycleObserver(activity);

if (registrar != null) {
// V1 embedding setup for activity listeners.
application.registerActivityLifecycleCallbacks(this.observer);
registrar.addActivityResultListener(this.delegate);
} else {
// V2 embedding setup for activity listeners.
activityBinding.addActivityResultListener(this.delegate);
this.lifecycle = FlutterLifecycleAdapter.getActivityLifecycle(activityBinding);
this.lifecycle.addObserver(this.observer);
}
// V2 embedding setup for activity listeners.
activityBinding.addActivityResultListener(this.delegate);
this.lifecycle = FlutterLifecycleAdapter.getActivityLifecycle(activityBinding);
this.lifecycle.addObserver(this.observer);

}

private void tearDown() {
Expand Down
2 changes: 1 addition & 1 deletion pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ description: A package that allows you to use a native file explorer to pick sin
homepage: https://github.com/miguelpruivo/plugins_flutter_file_picker
repository: https://github.com/miguelpruivo/flutter_file_picker
issue_tracker: https://github.com/miguelpruivo/flutter_file_picker/issues
version: 8.1.5
version: 8.1.6

dependencies:
flutter:
Expand Down

0 comments on commit 525840e

Please sign in to comment.