This repository was archived by the owner on Feb 22, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 9.7k
[share]fix iOS crash when setting the subject to null #2131
Merged
Merged
Changes from 1 commit
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,3 +1,7 @@ | ||
| ## 0.6.2+2 | ||
|
|
||
| * Fix iOS crash when setting subject to null. | ||
|
|
||
| ## 0.6.2+1 | ||
|
|
||
| * Specify explicit type for `invokeMethod`. | ||
|
|
||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -3,7 +3,7 @@ description: Flutter plugin for sharing content via the platform share UI, using | |
| the ACTION_SEND intent on Android and UIActivityViewController on iOS. | ||
| author: Flutter Team <[email protected]> | ||
| homepage: https://github.com/flutter/plugins/tree/master/packages/share | ||
| version: 0.6.2+1 | ||
| version: 0.6.2+2 | ||
|
|
||
| flutter: | ||
| plugin: | ||
|
|
||
19 changes: 19 additions & 0 deletions
19
packages/video_player/example/test_driver/video_player.dart
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,19 @@ | ||
| import 'dart:async'; | ||
|
||
| import 'package:flutter_driver/driver_extension.dart'; | ||
| import 'package:flutter_test/flutter_test.dart'; | ||
| import 'package:video_player/video_player.dart'; | ||
|
|
||
| void main() { | ||
| final Completer<String> completer = Completer<String>(); | ||
| enableFlutterDriverExtension(handler: (_) => completer.future); | ||
| tearDownAll(() => completer.complete(null)); | ||
|
|
||
| group('VideoPlayer test driver', () { | ||
| test('VideoPlayer dispose without crash', () { | ||
| final VideoPlayerController controller = | ||
| VideoPlayerController.asset('assets/Butterfly-209.mp4'); | ||
| controller.play(); | ||
| controller.initialize(); | ||
| }); | ||
| }); | ||
| } | ||
10 changes: 10 additions & 0 deletions
10
packages/video_player/example/test_driver/video_player_test.dart
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,10 @@ | ||
| import 'package:flutter_driver/flutter_driver.dart'; | ||
| import 'package:test/test.dart'; | ||
|
|
||
| void main() { | ||
| test('video_player', () async { | ||
| final FlutterDriver driver = await FlutterDriver.connect(); | ||
| await driver.requestData(null, timeout: const Duration(minutes: 1)); | ||
| driver.close(); | ||
| }); | ||
| } |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
curious - should this be null?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Per https://developer.apple.com/documentation/uikit/uiactivityitemsource/1620458-activityviewcontrollerplaceholde?language=objc
It should be one that the activity can handle otherwise you may get an activity with empty content.So setting it to null/nil will result the activityController showing an empty content (manually tested)