Fix layout offset on physical Android devices after closing feedback #366
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.
Summary
This PR fixes a layout offset issue on physical Android devices where the main app content remains offset to the right/down after closing the feedback view.
The Issue
On physical Android devices running Flutter 3.24+, when users open and then close the feedback view (either by submitting feedback or cancelling), the underlying application screen content remains offset. This issue does not occur on Android emulators.
The Fix
The fix is simple - explicitly position the screenshot widget at
Offset.zero
when feedback is not displayed in the_FeedbackLayoutDelegate.performLayout
method.Testing
This fix has been tested on a physical Android device and resolves the offset issue.
Related Issues
This addresses the issue reported in #322
Type of Change