Fix progress bar misaligned on photo task#3671
Open
andreia-ferreira wants to merge 3 commits intomasterfrom
Open
Fix progress bar misaligned on photo task#3671andreia-ferreira wants to merge 3 commits intomasterfrom
andreia-ferreira wants to merge 3 commits intomasterfrom
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #3671 +/- ##
============================================
- Coverage 67.40% 67.34% -0.06%
+ Complexity 1608 1607 -1
============================================
Files 365 365
Lines 9182 9182
Branches 1171 1171
============================================
- Hits 6189 6184 -5
- Misses 2341 2347 +6
+ Partials 652 651 -1
🚀 New features to boost your workflow:
|
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
while testing the latest master to prepare for a new release @jo-spek found that the progress bar was misaligned. This seems to happen after taking a picture in the photo task and it's because, when going back to the app, the fragment collects the latest value from
footerVerticalPositionand applies it immediately. However, the system window insets are not yet fully re-dispatched after resuming the Activity, which means the top system bar inset may temporarily be reported as 0. This causes the calculated footer position to be incorrect.In order to fix this, the
windowInsetsfrom the MainViewModel is now also being combined withfooterVerticalPositionbefore applying the final position. This ensures that every time the insets or footer position change, the progress bar updates accordingly.As an extra precaution,
TaskScreenwas updated to store the Y position as a Float instead of relying on LayoutCoordinates, since its reused reference may not trigger updates in composeBefore
Screen_recording_20260414_110920.webm
After
Screen_recording_20260414_110803.webm
@shobhitagarwal1612 PTAL?