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
[camerax] Wrap methods necessary for preview implementation #7046
Merged
Merged
Changes from 1 commit
Commits
Show all changes
26 commits
Select commit
Hold shift + click to select a range
496ca83
Add code needed from proof of concept
camsim99 c9593ba
Add test files, delete unecessary method
camsim99 8e8779e
Merge remote-tracking branch 'upstream/main' into camx_s3
camsim99 6e5bc8e
Add tests, remove unecessary code
camsim99 268d9f5
Fix analyze
camsim99 2001c33
Update changelog
camsim99 7552ad9
Merge remote-tracking branch 'upstream/main' into camx_s3
camsim99 7ff2a94
Cleanup:
camsim99 dfc3071
Cleanup and add switch
camsim99 4ba07e2
Finish todo
camsim99 754939c
Merge remote-tracking branch 'upstream/main' into camx_s3
camsim99 fb44db3
Add onCameraError
camsim99 858815d
Fix pigeon file
camsim99 78edaa2
Add method for releasing flutter texture and cleanup surface logic
camsim99 3527322
Add test for release method
camsim99 335372b
Add dart test
camsim99 4dd9c4c
Update changelog
camsim99 24b1bdb
Modify flutter api names to avoid stack overflow
camsim99 e0efef2
Cleanup
camsim99 e90f45c
Fix tests
camsim99 73cb5f8
Delete space
camsim99 abf4e58
Address review 1
camsim99 659c2e0
Update switch
camsim99 5f269c7
Add annotations and constants in tests
camsim99 a6fe15c
Merge remote-tracking branch 'upstream/main' into camx_s3
camsim99 78e0d0f
Reset verification behavior
camsim99 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
Modify flutter api names to avoid stack overflow
- Loading branch information
commit 24b1bdb44b5caeeaa4a9f437b0aaaaa8ca2b0481
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
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
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.
This switch is confusing.
Success releases the surface and breaks but so does canceled invalid and "will not provide".
Canceled feels like an expected condition but invalid and will not provide feel like errors even though they fall through and have the same behavior as success.
Finally Already provided feels like a code error but it falls through to default which is usually dangerous.
I am not sure what the expected conditions are but I might suggest trying to structure this in a way that is a bit easier to follow.
For example if the result code is a actually being used as a proxy for if we have a flutterSurface then maybe we always check flutterSurface and if it exists it is released. Then if we get a value that should return an error we do that. Finally we should ensure we dont hit default and if we do perhaps we error and then test that all values of Result code do not error in a unit test.
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.
Modified this and replied below: #7046 (comment)